summaryrefslogtreecommitdiff
path: root/npc/jobs/2-2/rogue.txt
diff options
context:
space:
mode:
authorEmistry Haoyan <equinox1991@gmail.com>2019-06-16 18:44:45 +0800
committerHaru <haru@dotalux.com>2019-07-28 18:17:09 +0200
commit371d056df80b6f83484534f64883c3d020c4112d (patch)
tree20d38a8581f3a6159157bfa6644027d4007485bc /npc/jobs/2-2/rogue.txt
parentef8bc3a8375d4fe9a5f75faf951b3deecb891d57 (diff)
downloadhercules-371d056df80b6f83484534f64883c3d020c4112d.tar.gz
hercules-371d056df80b6f83484534f64883c3d020c4112d.tar.bz2
hercules-371d056df80b6f83484534f64883c3d020c4112d.tar.xz
hercules-371d056df80b6f83484534f64883c3d020c4112d.zip
Sanitize handling of the input() values.
- avoid potential hacks for old scripts that use `input()` script commands. Signed-off-by: Haru <haru@dotalux.com>
Diffstat (limited to 'npc/jobs/2-2/rogue.txt')
-rw-r--r--npc/jobs/2-2/rogue.txt15
1 files changed, 6 insertions, 9 deletions
diff --git a/npc/jobs/2-2/rogue.txt b/npc/jobs/2-2/rogue.txt
index 311915097..656b9eed4 100644
--- a/npc/jobs/2-2/rogue.txt
+++ b/npc/jobs/2-2/rogue.txt
@@ -1292,7 +1292,7 @@ in_rogue,270,130,0 script he_to_rogue#rg WARPNPC,1,1,{
OnTouch:
mes "^3355FFThe door is locked. You'll need to enter the four number combination to open it.^000000";
next;
- input .@input;
+ input(.@input);
if (.@input < 1 || .@input > 10000) {
if (ROGUE_Q == 12)
mes "^3355FFIt didn't work. Please re-enter the four number combination.^000000";
@@ -1300,7 +1300,7 @@ OnTouch:
mes "^3355FFPlease enter a combination of four numbers.^000000";
close;
}
- else if (.@input == 3019) {
+ if (.@input == 3019) {
if (ROGUE_Q == 12) {
mes "^3355FFThe door";
mes "has opened.^000000";
@@ -1308,8 +1308,7 @@ OnTouch:
warp "in_rogue",10,21;
ROGUE_Q = 12;
end;
- }
- else {
+ } else {
mes "[HermanthornJr.]";
mes "Well...";
mes "Didn't I tell you";
@@ -1318,11 +1317,9 @@ OnTouch:
close;
}
}
- else {
- mes "^3355FFThe door";
- mes "is still locked.^000000";
- close;
- }
+ mes "^3355FFThe door";
+ mes "is still locked.^000000";
+ close;
}
in_rogue,200,389,0 script gen_ro#1 FAKE_NPC,3,3,{