# HG changeset patch # User Wuzzy # Date 1555525677 -3600 # Node ID fc9a202d27ba062bd8f1183dc4ba672345c20ed4 # Parent e514ad7c39a30ffb611b0a6d99be3182dcecce49 LuaEvents: Update onGameInit info diff -r e514ad7c39a3 -r fc9a202d27ba LuaEvents.wiki --- a/LuaEvents.wiki Wed Apr 17 19:26:51 2019 +0100 +++ b/LuaEvents.wiki Wed Apr 17 19:27:57 2019 +0100 @@ -10,9 +10,10 @@ == Initialization == === onGameInit() === This function is called before the game loads its resources. One can read and modify various [LuaGlobals#Game_variables game variables] here. These variables will become globally available after `onGameInit` has been invoked, but changing them has only an effect in `onGameInit`. -Most game variables are optional, but for missions, `Theme` must be set by the scripter if you want to use a random map, rather than an image map. All other variables do not need to be set by the scripter and have default values. -For a list of game variables that can be set here, see [LuaGlobals#Game_variables]. +Most game variables are optional, but for missions, `Theme` must be set by the scripter if you want to use a random map, rather than an image map. All other variables do not need to be set by the scripter and have default values. For a list of game variables that can be set here, see [LuaGlobals#Game_variables]. + +If you want to add teams or hogs manually, you have to do it here. If you want to draw your own map using `AddPoint` and `FlushPoints`, you have to do this within this function as well. === onGameStart() === This function is called when the first round starts.