Script::getNumberOfInstancesOfStreamedScript: Difference between revisions

From RAGE Multiplayer Wiki
(yay)
No edit summary
 
Line 13: Line 13:
{{Script_s_function_c}}
{{Script_s_function_c}}
[[Category:Clientside API]]
[[Category:Clientside API]]
[[Category:Script API]]
[[Category:TODO: Example]]
[[Category:TODO: Example]]

Latest revision as of 21:25, 11 May 2017

Gets the number of instances of the specified script is currently running.

Actually returns numInstances - 1.
if (scriptPtr)
v3 = GetNumberOfInstancesOfScript(scriptPtr) - 1;
return v3;

Syntax

mp.game.script.getNumberOfInstancesOfStreamedScript(scriptHash);

Required Arguments

  • scriptHash: Model hash or name

Return value

  • int

Example

// todo

See also

Template:Script s function c