MTA:Eir/functions/engineSetWorldStreamingEnabled: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
(Created page with "__NOTOC__ This function enables or disables the rendering and streaming of world instances. World instances are IPL sectors, COL sectors, buildings, objects and dummies. This fu...")
 
No edit summary
Line 4: Line 4:
==Syntax==  
==Syntax==  
<syntaxhighlight lang="lua">
<syntaxhighlight lang="lua">
element engineSetWorldStreamingEnabled ( bool enabled )
bool engineSetWorldStreamingEnabled ( bool enabled )
</syntaxhighlight>
</syntaxhighlight>



Revision as of 19:55, 10 December 2013

This function enables or disables the rendering and streaming of world instances. World instances are IPL sectors, COL sectors, buildings, objects and dummies. This function does not affect world instances created by MTA.

Syntax

bool engineSetWorldStreamingEnabled ( bool enabled )

Returns

Returns true if enabled is passed as valid bool, false otherwise.

Example

Click to collapse [-]
Client

This snippet clears the entire GTA:SA world of native entities and increases engine performance.

addEvent( "onClientGameEnterTCMode", true );
addEvent( "onClientGameEnterTCMode", root,
    function()
        engineSetWorldStreamingEnabled( false );
    end
);