Squirrel/Server/Functions/Cheats/SetHandlingCheat
From Liberty Unleashed Wiki
(Difference between revisions)
(→Example) |
|||
Line 11: | Line 11: | ||
== Example == | == Example == | ||
+ | |||
+ | This example enables the handling cheat if someone types '/handlinghax'. | ||
<code lang="squirrel"> | <code lang="squirrel"> | ||
Line 21: | Line 23: | ||
=== Notes === | === Notes === | ||
− | + | The event [[Squirrel/Server/Events/Player/onPlayerCommand|onPlayerCommand]] was used in in this example. More info about it in the corresponding page. | |
== Related Functions == | == Related Functions == | ||
{{Squirrel/Server/Functions/Cheats}} | {{Squirrel/Server/Functions/Cheats}} |
Revision as of 17:48, 7 January 2010
This function enables or disables the improved handling cheat code (cornerslikemad in GTA III / gripiseverything in GTA:VC).
Syntax
bool SetHandlingCheat( bool enabled )
Arguments
- enabled - A boolean to either enable (true) or disable (false) this cheat code
Example
This example enables the handling cheat if someone types '/handlinghax'.
function onPlayerCommand( player, command, text ) { if ( command == "handlinghax" ) SetHandlingCheat( true ); }
Notes
The event onPlayerCommand was used in in this example. More info about it in the corresponding page.
Related Functions
- GetFlyingCars
- GetHandlingCheat
- SetFlyingCars
- SetHandlingCheat