Skip to content

Commit

Permalink
Fix invinsible typo
Browse files Browse the repository at this point in the history
  • Loading branch information
agustinesco committed Apr 4, 2024
1 parent 52fc65c commit abbacf7
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions apps/arena/lib/arena/game/player.ex
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ defmodule Arena.Game.Player do
|> put_in([:direction], skill_direction |> Utils.normalize())
|> put_in([:is_moving], false)
|> put_in([:aditional_info, :last_skill_triggered], System.monotonic_time(:millisecond))
|> maybe_make_invinsible(skill)
|> maybe_make_invincible(skill)

put_in(game_state, [:players, player.id], player)
end
Expand Down Expand Up @@ -383,15 +383,15 @@ defmodule Arena.Game.Player do
end
end

defp maybe_make_invinsible(
defp maybe_make_invincible(
player,
%{inmune_while_executing: true, execution_duration_ms: execution_duration_ms} = _skill
) do
Process.send_after(self(), {:remove_damage_immunity, player.id}, execution_duration_ms)
put_in(player, [:aditional_info, :damage_immunity], true)
end

defp maybe_make_invinsible(player, _) do
defp maybe_make_invincible(player, _) do
player
end
end

0 comments on commit abbacf7

Please sign in to comment.