SetGameSpeed: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
No edit summary
mNo edit summary
Line 5: Line 5:


==Syntax==
==Syntax==
<syntaxhighlight lang="lua">setGameSpeed ( int value )</syntaxhighlight>
<syntaxhighlight lang="lua">bool setGameSpeed ( int value )</syntaxhighlight>


===Required Arguments===
===Required Arguments===

Revision as of 11:57, 14 May 2009

Description

This function sets the game speed to the given value.

Syntax

bool setGameSpeed ( int value )

Required Arguments

  • value: The int value of the game speed (Range 0 - 10)

Example

Click to collapse [-]
Server
addCommandHandler("setgamespeed",
  function(sourcePlayer, command, value)
    setGameSpeed(tonumber(value))
  end
)
Click to collapse [-]
Client
addCommandHandler("setgamespeed",
  function(command, value)
    setGameSpeed(tonumber(value))
  end
)

See Also