-
-
Notifications
You must be signed in to change notification settings - Fork 647
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: split player death event handler into smaller functions
- Loading branch information
1 parent
73f5c5a
commit 73c5351
Showing
5 changed files
with
192 additions
and
260 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
146 changes: 0 additions & 146 deletions
146
data-otservbr-global/scripts/creaturescripts/others/player_death.lua
This file was deleted.
Oops, something went wrong.
9 changes: 9 additions & 0 deletions
9
data-otservbr-global/scripts/quests/svargrond_arena/creaturescripts_player_death.lua
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
local svargrondArenaPlayerDeath = CreatureEvent("SvargrondArenaPlayerDeath") | ||
|
||
function svargrondArenaPlayerDeath.onDeath(player, corpse, killer, mostDamageKiller, unjustified, mostDamageUnjustified) | ||
if player:getStorageValue(Storage.Quest.U8_0.BarbarianArena.PitDoor) > 0 then | ||
player:setStorageValue(Storage.Quest.U8_0.BarbarianArena.PitDoor, 0) | ||
end | ||
end | ||
|
||
svargrondArenaPlayerDeath:register() |
File renamed without changes.
Oops, something went wrong.