diff --git a/init.lua b/init.lua index b238b8e..74126ee 100644 --- a/init.lua +++ b/init.lua @@ -42,6 +42,7 @@ arena_lib.register_minigame("the_bridge", { temp_properties = { finished = false, scoring = false, + setup = false, }, in_game_physics = { diff --git a/setup.lua b/setup.lua index 902bf46..03503a5 100644 --- a/setup.lua +++ b/setup.lua @@ -45,6 +45,7 @@ arena_lib.on_load("the_bridge", function(arena) after_goal(arena) --gives all players their items and teleports them to spawners send_message(arena,S("GO!")) + arena.setup = true end) arena_lib.on_enable("the_bridge", function(arena, p_name) diff --git a/the_bridge.lua b/the_bridge.lua index 8041eb5..ff82098 100644 --- a/the_bridge.lua +++ b/the_bridge.lua @@ -43,6 +43,7 @@ function after_goal(arena) --global because its called once outside of this file gain = 2.0, }) end + if not arena.setup then return end time = os.clock() while (os.clock() < time +3) do end arena.scoring = false