# HG changeset patch # User Wuzzy # Date 1510892419 0 # Node ID f8b1be6befc7867a46c1292f973a98e41e840aad # Parent f6d0d5772a6c799845a51f7b5809d15736aeb19e LuaAPI: ReadyTimeLeft and AmmoTypeMax diff -r f6d0d5772a6c -r f8b1be6befc7 LuaAPI.wiki --- a/LuaAPI.wiki Fri Nov 17 04:16:37 2017 +0000 +++ b/LuaAPI.wiki Fri Nov 17 04:20:19 2017 +0000 @@ -87,9 +87,11 @@ || `ClansCount` || Number of clans in the game (teams with the same color belong to one clan) || || `TeamsCount` || Number of teams in the game || || `TurnTimeLeft` || Number of game ticks (milliseconds) left until the current turn ends. You can change this variable directly. || +|| `ReadyTimeLeft` || Remaining ready time in millseconds, 0 if turn in progress. Can be set in onNewTurn. In other places, it should only be read, not written. || || `GameTime` || Number of total game ticks || || `TotalRounds` || Number of rounds that have passed || || `CurrentHedgehog` || The hedgehog gear that is currently in play || +|| `AmmoTypeMax` || Maximum ammo type ID (useful to iterate through all ammo types, starting by 0) === !GameFlags === The !GameFlags are used to store simple boolean settings of the game. @@ -215,7 +217,7 @@ This function is called every 20 game ticks, which equals 50 times a second. It reduces Lua overhead for simple monitoring that doesn’t need to happen every single tick. === onNewTurn() === -This function calls at the start of every turn. +This function calls at the start of every turn. You can set `ReadyTimeLeft` here to change the ready time for this turn. (See also: `Ready`) === onSuddenDeath() (0.9.22) === This function is called on the start of Sudden Death.