Skip to content

Commit

Permalink
fix: players were not respawning
Browse files Browse the repository at this point in the history
  • Loading branch information
tvillegas98 committed Nov 11, 2024
1 parent b93e2b1 commit 3eb0d77
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions apps/arena/lib/arena/game_updater.ex
Original file line number Diff line number Diff line change
Expand Up @@ -1911,7 +1911,7 @@ defmodule Arena.GameUpdater do
end
end

defp add_players_to_respawn_queue(game_state, %{game: %{game_mode: :deathmatch}} = game_config) do
defp add_players_to_respawn_queue(game_state, %{game: %{game_mode: :DEATHMATCH}} = game_config) do
death_players =
game_state.players
|> Enum.filter(fn {_player_id, player} ->
Expand All @@ -1934,7 +1934,7 @@ defmodule Arena.GameUpdater do

defp add_players_to_respawn_queue(game_state, _game_config), do: game_state

defp respawn_players(game_state, %{game: %{game_mode: :deathmatch}} = game_config) do
defp respawn_players(game_state, %{game: %{game_mode: :DEATHMATCH}} = game_config) do
now = DateTime.utc_now() |> DateTime.to_unix(:millisecond)

players_to_respawn =
Expand Down

0 comments on commit 3eb0d77

Please sign in to comment.