diff --git a/P3D/World/ActionScript/V2/ScriptConstructs/DoSystem.vb b/P3D/World/ActionScript/V2/ScriptConstructs/DoSystem.vb index 36b50d61c..464075131 100644 --- a/P3D/World/ActionScript/V2/ScriptConstructs/DoSystem.vb +++ b/P3D/World/ActionScript/V2/ScriptConstructs/DoSystem.vb @@ -152,8 +152,10 @@ Return output Case "scriptlevel" Return ActionScript.ScriptLevelIndex.ToString() - case "language" + Case "language" Return Localization.LanguageSuffix + Case "fileexists" + Return ReturnBoolean(GameModeManager.ContentFileExists(argument)) End Select Return DefaultNull diff --git a/P3D/World/ActionScript/V2/ScriptLibrary.vb b/P3D/World/ActionScript/V2/ScriptLibrary.vb index d332c96f2..c5c8bfa01 100644 --- a/P3D/World/ActionScript/V2/ScriptLibrary.vb +++ b/P3D/World/ActionScript/V2/ScriptLibrary.vb @@ -435,6 +435,8 @@ Namespace ScriptVersion2 r(New ScriptCommand("system", "issng", "bool", {New ScriptArgument("expression", ScriptArgument.ArgumentTypes.Str)}.ToList(), "Checks if the expression is a single (Outdated, use <math.issng> instead).", ",", True)) r(New ScriptCommand("system", "chrw", "str", {New ScriptArgument("charCodes", ScriptArgument.ArgumentTypes.IntArr)}.ToList(), "Converts Unicode CharCodes into a string.", ",", True)) r(New ScriptCommand("system", "scriptlevel", "int", "Returns the current script level (call depth).", ",", True)) + r(New ScriptCommand("system", "Language", "str", "Returns the current game language suffix.", ",", True)) + r(New ScriptCommand("system", "FileExists", "bool", {New ScriptArgument("filePath", ScriptArgument.ArgumentTypes.Str)}.ToList(), "Returns if the specified file (including extension) exists (relative to the GameMode's ContentPath).", ",", True)) End Sub Private Shared Sub DoEnvironment()