From eeb0da013e14bd2efafc050ade4c8b98fccb4cb7 Mon Sep 17 00:00:00 2001 From: Marco Date: Wed, 21 Feb 2024 15:59:23 -0300 Subject: [PATCH] feat: add missing achievement on giant spider wyda (#2296) --- .../scripts/creaturescripts/monster/wyda.lua | 6 ------ .../monster/giant_spider_wyda_death.lua | 12 ++++++++++++ 2 files changed, 12 insertions(+), 6 deletions(-) delete mode 100644 data-otservbr-global/scripts/creaturescripts/monster/wyda.lua create mode 100644 data/scripts/creaturescripts/monster/giant_spider_wyda_death.lua diff --git a/data-otservbr-global/scripts/creaturescripts/monster/wyda.lua b/data-otservbr-global/scripts/creaturescripts/monster/wyda.lua deleted file mode 100644 index 27c9887eae8..00000000000 --- a/data-otservbr-global/scripts/creaturescripts/monster/wyda.lua +++ /dev/null @@ -1,6 +0,0 @@ -local wyda = CreatureEvent("Wyda") -function wyda.onDeath(creature, corpse, killer, mostDamage, unjustified, mostDamage_unjustified) - creature:say("It seems this was just an illusion.", TALKTYPE_ORANGE_1) -end - -wyda:register() diff --git a/data/scripts/creaturescripts/monster/giant_spider_wyda_death.lua b/data/scripts/creaturescripts/monster/giant_spider_wyda_death.lua new file mode 100644 index 00000000000..37ba34ffbf3 --- /dev/null +++ b/data/scripts/creaturescripts/monster/giant_spider_wyda_death.lua @@ -0,0 +1,12 @@ +local creatureevent = CreatureEvent("GiantSpiderWyda") + +function creatureevent.onDeath(creature, corpse, killer, mostDamageKiller, lastHitUnjustified, mostDamageUnjustified) + creature:say("It seems this was just an illusion.", TALKTYPE_MONSTER_SAY) + + if mostDamageKiller:isPlayer() then + mostDamageKiller:addAchievement("Someone's Bored") + end + return true +end + +creatureevent:register()