Execute( "ObjectTemplate.create PlayerControlObject ahe_ah1z ") Create a new empty scope for this object Scope scope = new Scope() Save() Example #2Ĭreating and Modifying an object using only Scopes Value = 35) // is True // And formating the object back to Con File format string formated = file. Any object created in scope via Scope.Execute() can be fetched normally PlayerControlObject Ah1z = file. Execute( "ObjectTemplate.maxVertRegAngle 35 ") Execute( "ObjectTemplate.create PlayerControlObject ahe_ah1z ") įile. = // There is even a third option for setting a value on an object, though it is not recommended // to do it this way due to Reflection costs! For this example, we will use the // ahe_ah1z helicopter // = // Make sure to set the vehicle as active first by calling activeSafe or create file. Setting a value (safely), if "basicTemp" was not defined in file, it will be created here obj. Setting a value (Unsafe, Exception will be thrown if BasicTemp was never defined) obj. Fetching an object property Value (Strongly Typed) int value = obj. Getting a loaded object from its defined scope AiTemplate obj = file. Loading a file ConFile file = await ScriptEngine.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |