Skip to content

Commit

Permalink
Fix gamemodePlayerReady being triggered many times
Browse files Browse the repository at this point in the history
  • Loading branch information
jlillis committed Jul 18, 2024
1 parent 0fe7640 commit 0218854
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion [gamemodes]/[deathmatch]/deathmatch/server/player.lua
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,10 @@ addEventHandler("onPlayerQuit", root, processPlayerQuit)
-- gamemodePlayerReady: triggered when a client is ready to play
--
-- triggered by the client post-onClientResourceStart
function gamemodePlayerReady()
function gamemodePlayerReady(loadedResource)
if loadedResource ~= resource then
return
end
-- inform client of current game state by triggering certain events
local gameState = getElementData(resourceRoot, "gameState")
if gameState == GAME_STARTING then
Expand Down

0 comments on commit 0218854

Please sign in to comment.