GetMTAVersion

From Multi Theft Auto: Wiki
Revision as of 16:36, 13 February 2015 by AlexTMjugador (talk | contribs) (Changed "DeprecatedWithAlt" template to "Deprecated" and removed an unnecessary section)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

This function is deprecated. This means that its use is discouraged and that it might not exist in future versions.

Please use getVersion instead.


This function returns a string which tell you which MTA version player uses. From DP2.1 onwards.

Syntax

string getMTAVersion( )

Required Arguments

None

Returns

A string - currently: "1.0 dp2.1"

Example

function checkVersion( )
    if getMTAVersion( ) ~= "1.0 dp2.1" then
        outputChatBox( "Download the latest MTA:SA DM and come back!" )
    end
end
addEventHandler( "onClientResourceStart", getResourceRootElement(), checkVersion )

See Also