|
TorqueScript Reference
|
Inherits SimObject.
Public Member Functions | |
| string | acquireAsset (assetId,[asPrivate?]) |
| bool | addDeclaredAsset (moduleDefinition, assetFilePath) |
| bool | addModuleDeclaredAssets (moduleDefinition) |
| string | addPrivateAsset (assetObject) |
| bool | compileReferencedAssets (moduleDefinition) |
| bool | deleteAsset (assetId, deleteLooseFiles, deleteDependencies) |
| void | dumpDeclaredAssets () |
| int | findAllAssets (assetQuery,[ignoreInternal?],[ignorePrivate?]) |
| int | findAssetAutoUnload (assetQuery, assetAutoUnload,[assetQueryAsSource?]) |
| int | findAssetCategory (assetQuery, assetCategory,[assetQueryAsSource?]) |
| int | findAssetDependsOn (assetQuery, assetId) |
| int | findAssetInternal (assetQuery, assetInternal,[assetQueryAsSource?]) |
| int | findAssetIsDependedOn (assetQuery, assetId) |
| int | findAssetLooseFile (assetQuery, assetLooseFile,[assetQueryAsSource?]) |
| int | findAssetName (assetQuery, assetName,[partialName?]) |
| int | findAssetPrivate (assetQuery, assetPrivate,[assetQueryAsSource?]) |
| int | findAssetType (assetQuery, assetType,[assetQueryAsSource?]) |
| int | findInvalidAssetReferences (assetQuery) |
| int | findTaggedAssets (assetQuery, assetTagNames,[assetQueryAsSource?]) |
| string | getAssetCategory (assetId) |
| string | getAssetDescription (assetId) |
| string | getAssetFilePath (assetId) |
| string | getAssetModule (assetId) |
| string | getAssetName (assetId) |
| string | getAssetPath (assetId) |
| int | getAssetTags () |
| string | getAssetType (assetId) |
| bool | getDeclaredAssetCount () |
| bool | getLoadedExternalAssetCount () |
| bool | getLoadedInternalAssetCount () |
| bool | getMaxLoadedExternalAssetCount () |
| bool | getMaxLoadedInternalAssetCount () |
| bool | getReferencedAssetCount () |
| bool | isAssetAutoUnload (assetId) |
| bool | isAssetInternal (assetId) |
| bool | isAssetLoaded (assetId) |
| bool | isAssetPrivate (assetId) |
| bool | isDeclaredAsset (assetId) |
| bool | isReferencedAsset (assetId) |
| void | purgeAssets () |
| void | refreshAllAssets ([bool includeUnloaded]) |
| void | refreshAsset (assetId) |
| bool | releaseAsset (assetId) |
| bool | removeDeclaredAsset (assetId) |
| bool | removeDeclaredAssets (moduleDefinition) |
| bool | renameDeclaredAsset (assetIdFrom, assetIdTo) |
| bool | renameReferencedAsset (assetIdFrom, assetIdTo) |
| bool | restoreAssetTags () |
| bool | saveAssetTags () |
Public Member Functions inherited from SimObject | |
| string | call (functionName,[args]*) |
| int | clone ([bool copyDynamicFields?=false]?) |
| void | delete () |
| void | dump () |
| void | dumpClassHierarchy () |
| const char * | getClassName () |
| string | getClassNamespace () |
| string | getDynamicField (index) |
| int | getDynamicFieldCount () |
| string | getField (int index) |
| int | getFieldCount () |
| const char * | getFieldType (fieldName) |
| const char * | getFieldValue (fieldName) |
| int | getGroup () |
| int | getId () |
| string | getInternalName () |
| const char * | getName () |
| string | getProgenitorFile () |
| string | getSuperClassNamespace () |
| int | getType () |
| bool | isChildOfGroup () |
| bool | isMemberOfClass (string classname) |
| bool | isMethod (const char *methodName) |
| bool | isMethod (string method name) |
| bool | isTimerActive () |
| bool | save (fileName,[selectedOnly]?) |
| int | schedule (time, command,[arg]*) |
| void | setClassNamespace () |
| bool | setFieldValue (fieldName, value) |
| void | setInternalName (string InternalName) |
| void | setName (newName) |
| void | setProgenitorFile (file) |
| void | setSuperClassNamespace () |
| bool | startTimer (callbackFunction, float timePeriod,[repeat]?) |
| void | stopTimer () |
Additional Inherited Members | |
Static Public Member Functions inherited from SimObject | |
| static S32 QSORT_CALLBACK | compareFields (const void *a, const void *b) |
| string acquireAsset | ( | assetId | ) |
Acquire the specified asset Id. You must release the asset once you're finish with it using 'releaseAsset'.
| assetId | The selected asset Id. |
| asPrivate | Whether to acquire the asset Id as a private asset. |
| bool addDeclaredAsset | ( | moduleDefinition | , |
| assetFilePath | |||
| ) |
Add the specified asset against the specified module definition.
| moduleDefinition | The module definition that may contain declared assets. |
| bool addModuleDeclaredAssets | ( | moduleDefinition | ) |
Add any the declared assets specified by the module definition.
| moduleDefinition | The module definition specifies the asset manifest. |
| string addPrivateAsset | ( | assetObject | ) |
Adds a private asset object.
| assetObject | The asset object to add as a private asset. |
| bool compileReferencedAssets | ( | moduleDefinition | ) |
Compile the referenced assets determined by the specified module definition.
| moduleDefinition | The module definition specifies the asset manifest. |
| bool deleteAsset | ( | assetId | , |
| deleteLooseFiles | , | ||
| deleteDependencies | |||
| ) |
Deletes the specified asset Id and optionally its loose files and asset dependencies.
| assetId | The selected asset Id. |
| deleteLooseFiles | Whether to delete an assets loose files or not. |
| deleteDependencies | Whether to delete assets that depend on this asset or not. |
| void dumpDeclaredAssets | ( | ) |
Dumps a breakdown of all declared assets.
| int findAllAssets | ( | assetQuery | ) |
Performs an asset query searching for all assets optionally ignoring internal assets.
| assetQuery | The asset query object that will be populated with the results. |
| ignoreInternal | Whether to ignore internal assets or not. Optional: Defaults to true. |
| ignorePrivate | Whether to ignore private assets or not. Optional: Defaults to true. |
| int findAssetAutoUnload | ( | assetQuery | , |
| assetAutoUnload | |||
| ) |
Performs an asset query searching for the specified asset auto-unload flag.
| assetQuery | The asset query object that will be populated with the results. |
| assetInternal | The asset internal flag to search for. |
| assetQueryAsSource | Whether to use the asset query as the data-source rather than the asset managers database or not. Doing this effectively filters the asset query. Optional: Defaults to false. |
| int findAssetCategory | ( | assetQuery | , |
| assetCategory | |||
| ) |
Performs an asset query searching for the specified asset category.
| assetQuery | The asset query object that will be populated with the results. |
| assetCategory | The asset category to search for. |
| assetQueryAsSource | Whether to use the asset query as the data-source rather than the asset managers database or not. Doing this effectively filters the asset query. Optional: Defaults to false. |
| int findAssetDependsOn | ( | assetQuery | , |
| assetId | |||
| ) |
Performs an asset query searching for asset Ids that the specified asset Id depends on.
| assetQuery | The asset query object that will be populated with the results. |
| assetId | The asset Id to query for any asset Ids that it depends on. |
| int findAssetInternal | ( | assetQuery | , |
| assetInternal | |||
| ) |
Performs an asset query searching for the specified asset internal flag.
| assetQuery | The asset query object that will be populated with the results. |
| assetInternal | The asset internal flag to search for. |
| assetQueryAsSource | Whether to use the asset query as the data-source rather than the asset managers database or not. Doing this effectively filters the asset query. Optional: Defaults to false. |
| int findAssetIsDependedOn | ( | assetQuery | , |
| assetId | |||
| ) |
Performs an asset query searching for asset Ids that depend on the specified asset Id.
| assetQuery | The asset query object that will be populated with the results. |
| assetId | The asset Id to query for any asset Ids that may depend on it. |
| int findAssetLooseFile | ( | assetQuery | , |
| assetLooseFile | |||
| ) |
Performs an asset query searching for the specified loose file.
| assetQuery | The asset query object that will be populated with the results. |
| assetLooseFile | The loose-file used by the asset to search for. |
| assetQueryAsSource | Whether to use the asset query as the data-source rather than the asset managers database or not. Doing this effectively filters the asset query. Optional: Defaults to false. |
| int findAssetName | ( | assetQuery | , |
| assetName | |||
| ) |
Performs an asset query searching for the specified asset name.
| assetQuery | The asset query object that will be populated with the results. |
| assetName | The asset name to search for. This may be a partial name if 'partialName' is true. |
| partialName | Whether the asset name is to be used as a partial name or not. Optional: Defaults to false. |
| int findAssetPrivate | ( | assetQuery | , |
| assetPrivate | |||
| ) |
Performs an asset query searching for the specified asset private flag.
| assetQuery | The asset query object that will be populated with the results. |
| assetPrivate | The asset private flag to search for. |
| assetQueryAsSource | Whether to use the asset query as the data-source rather than the asset managers database or not. Doing this effectively filters the asset query. Optional: Defaults to false. |
| int findAssetType | ( | assetQuery | , |
| assetType | |||
| ) |
Performs an asset query searching for the specified asset type.
| assetQuery | The asset query object that will be populated with the results. |
| assetType | The asset type to search for. |
| assetQueryAsSource | Whether to use the asset query as the data-source rather than the asset managers database or not. Doing this effectively filters the asset query. Optional: Defaults to false. |
| int findInvalidAssetReferences | ( | assetQuery | ) |
Performs an asset query searching for invalid asset references.
| assetQuery | The asset query object that will be populated with the results. |
| int findTaggedAssets | ( | assetQuery | , |
| assetTagNames | |||
| ) |
Performs an asset query searching for the specified asset tag name(s).
| assetQuery | The asset query object that will be populated with the results. |
| assetTagNames | The asset tag name or names to search for. Multiple names can be specified using comma, space, tab or newline separation. Tags use an OR operation i.e. only assets tagged with ANY of the specified tags will be returned. |
| assetQueryAsSource | Whether to use the asset query as the data-source rather than the asset managers database or not. Doing this effectively filters the asset query. Optional: Defaults to false. |
| string getAssetCategory | ( | assetId | ) |
Gets the asset category from the specified asset Id.
| assetId | The selected asset Id. |
| string getAssetDescription | ( | assetId | ) |
Gets the asset description from the specified asset Id.
| assetId | The selected asset Id. |
| string getAssetFilePath | ( | assetId | ) |
Gets the asset file-path from the specified asset Id.
| assetId | The selected asset Id. |
| string getAssetModule | ( | assetId | ) |
Gets the module definition where the the specified asset Id is located.
| assetId | The selected asset Id. |
| string getAssetName | ( | assetId | ) |
Gets the asset name from the specified asset Id.
| assetId | The selected asset Id. |
| string getAssetPath | ( | assetId | ) |
Gets the asset path (not including the asset file) from the specified asset Id.
| assetId | The selected asset Id. |
| int getAssetTags | ( | ) |
Gets the currently loaded asset tags manifest.
| string getAssetType | ( | assetId | ) |
Gets the asset type from the specified asset Id.
| assetId | The selected asset Id. |
| bool getDeclaredAssetCount | ( | ) |
Gets the number of declared assets.
| bool getLoadedExternalAssetCount | ( | ) |
Gets the number of loaded external assets.
| bool getLoadedInternalAssetCount | ( | ) |
Gets the number of loaded internal assets.
| bool getMaxLoadedExternalAssetCount | ( | ) |
Gets the maximum number of loaded external assets.
| bool getMaxLoadedInternalAssetCount | ( | ) |
Gets the maximum number of loaded internal assets.
| bool getReferencedAssetCount | ( | ) |
Gets the number of asset referenced.
| bool isAssetAutoUnload | ( | assetId | ) |
Check whether the specified asset Id is auto-unload or not.
| assetId | The selected asset Id. |
| bool isAssetInternal | ( | assetId | ) |
Check whether the specified asset Id is internal or not.
| assetId | The selected asset Id. |
| bool isAssetLoaded | ( | assetId | ) |
Check whether the specified asset Id is loaded or not.
| assetId | The selected asset Id. |
| bool isAssetPrivate | ( | assetId | ) |
Check whether the specified asset Id is private or not.
| assetId | The selected asset Id. |
| bool isDeclaredAsset | ( | assetId | ) |
Check whether the specified asset Id is declared or not.
| assetId | The selected asset Id. |
| bool isReferencedAsset | ( | assetId | ) |
Check whether the specified asset Id is referenced or not.
| assetId | The selected asset Id. |
| void purgeAssets | ( | ) |
Purge all assets that are not referenced even if they are set to not auto-unload. Assets can be in this state because they are either set to not auto-unload or the asset manager has/is disabling auto-unload.
| void refreshAllAssets | ( | ) |
Refresh all declared assets.
| Whether | to include currently unloaded assets in the refresh or not. Optional: Defaults to false. Refreshing all assets can be an expensive (time-consuming) operation to perform. |
| void refreshAsset | ( | assetId | ) |
Refresh the specified asset Id.
| assetId | The selected asset Id. |
| bool releaseAsset | ( | assetId | ) |
Release the specified asset Id. The asset should have been acquired using 'acquireAsset'.
| assetId | The selected asset Id. |
| bool removeDeclaredAsset | ( | assetId | ) |
Remove the specified declared asset Id.
| assetId | The selected asset Id. |
| bool removeDeclaredAssets | ( | moduleDefinition | ) |
Remove any the declared assets specified by the module definition.
| moduleDefinition | The module definition that may contain declared assets. |
| bool renameDeclaredAsset | ( | assetIdFrom | , |
| assetIdTo | |||
| ) |
Rename declared asset Id.
| assetIdFrom | The selected asset Id to rename from. |
| assetIdFrom | The selected asset Id to rename to. |
| bool renameReferencedAsset | ( | assetIdFrom | , |
| assetIdTo | |||
| ) |
Rename referenced asset Id.
| assetIdFrom | The selected asset Id to rename from. |
| assetIdFrom | The selected asset Id to rename to. |
| bool restoreAssetTags | ( | ) |
Restore the currently loaded asset tags manifest from disk (replace anything in memory).
| bool saveAssetTags | ( | ) |
Save the currently loaded asset tags manifest.
1.8.3.1