summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2025-05-16 19:47:52 -0300
committerJesusaves <cpntb1@ymail.com>2025-05-16 19:47:52 -0300
commit18c87454d5b7a4760da7774bfb971cc58f252be0 (patch)
tree00564928e77265a79b91c231a46af647646c5d2f
parent62a903372e6708752364432516fb4c9e3955a62f (diff)
downloadserverdata-18c87454d5b7a4760da7774bfb971cc58f252be0.tar.gz
serverdata-18c87454d5b7a4760da7774bfb971cc58f252be0.tar.bz2
serverdata-18c87454d5b7a4760da7774bfb971cc58f252be0.tar.xz
serverdata-18c87454d5b7a4760da7774bfb971cc58f252be0.zip
Refactor Heroes Hold traps, as I've promised
-rw-r--r--npc/018-2-2/main.txt16
1 files changed, 13 insertions, 3 deletions
diff --git a/npc/018-2-2/main.txt b/npc/018-2-2/main.txt
index 73865de2f..e650737bf 100644
--- a/npc/018-2-2/main.txt
+++ b/npc/018-2-2/main.txt
@@ -99,10 +99,20 @@ OnPlayerCycle:
dispbottom l("You were rescued by DUSTMAN.");
end;
}
- // TODO: Handle traps (We'll use isin() command because you can give 3~4 steps each counter)
- if (rand2(1000) <= @HH_LEVEL) {
- dispbottom l("You set off a trap!");
+ // Heroes Hold has some "traps" which complement the difficulty
+ if (@HH_NOTRAP < @HH_TIMER && rand2(1000) <= @HH_LEVEL) {
+ dispbottom any(l("You set off a trap!"),
+ l("A trap is sprung on you!"),
+ l("The floor suddenly raises spikes up!"),
+ l("The walls suddenly shoots needles at you!"),
+ l("You're suddenly affected by a weird chant!"),
+ l("A trap appears out of nowhere!"),
+ l("The ceiling shoot needles at you!"));
+ // You lose some HP and MP, depending on the difficulty
heal -(@HH_LEVEL*rand2(3,6)), -(@HH_LEVEL/2);
+ // Depending on your INT and VIT, you can avoid further traps
+ @HH_NOTRAP = @HH_TIMER + min(10, readparam2(bVit)/15) + min(10, readparam2(bInt)/15);
+ // Otherwise, depending on your VIT, you get an ailment
if (rand2(250) > readparam2(bVit)) {
// Determine the dangers of the random trap
// SC_Bonus(delay, SC, min{, max})