From 9eaf6cc1fd583a4d4deeb61a28d07168ace9fb50 Mon Sep 17 00:00:00 2001 From: Damgam Date: Mon, 1 Apr 2024 18:36:10 +0200 Subject: [PATCH] Boombox spawning hotfix --- luarules/gadgets/game_boombox_spawner.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/luarules/gadgets/game_boombox_spawner.lua b/luarules/gadgets/game_boombox_spawner.lua index fbcb1adde5e..6080bbeb780 100644 --- a/luarules/gadgets/game_boombox_spawner.lua +++ b/luarules/gadgets/game_boombox_spawner.lua @@ -67,7 +67,7 @@ function gadget:GameFrame(frame) if math.random(1,10) == 1 then for j = 1,1000 do local posx = math.random(math.floor(Game.mapSizeX*0.02), math.ceil(Game.mapSizeX*0.98)) - local posz = math.random(math.floor(Game.mapSizeX*0.02), math.ceil(Game.mapSizeX*0.98)) + local posz = math.random(math.floor(Game.mapSizeZ*0.02), math.ceil(Game.mapSizeZ*0.98)) local posy = Spring.GetGroundHeight(posx, posz) local blockerDistance = getNearestBlocker(posx, posz) if posy > 0 and positionCheckLibrary.FlatAreaCheck(posx, posy, posz, 64, 25, true) and blockerDistance > 196 then