summaryrefslogtreecommitdiff
path: root/npc/003-3/malindou.txt
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2022-04-27 11:39:16 -0300
committerJesusaves <cpntb1@ymail.com>2022-04-27 11:39:16 -0300
commit41078f975c105cff3247653bcc59be7705a620c9 (patch)
tree17ab2b98fb2565433d5434550a7eba27c9f4ba27 /npc/003-3/malindou.txt
parent2f1b1a5b4890fcaf611170237cff3d3eceefe0b3 (diff)
downloadserverdata-41078f975c105cff3247653bcc59be7705a620c9.tar.gz
serverdata-41078f975c105cff3247653bcc59be7705a620c9.tar.bz2
serverdata-41078f975c105cff3247653bcc59be7705a620c9.tar.xz
serverdata-41078f975c105cff3247653bcc59be7705a620c9.zip
Move chat sanitization to Malindou instead of blackbox
Diffstat (limited to 'npc/003-3/malindou.txt')
-rw-r--r--npc/003-3/malindou.txt16
1 files changed, 15 insertions, 1 deletions
diff --git a/npc/003-3/malindou.txt b/npc/003-3/malindou.txt
index e43edeea1..0c5c7b836 100644
--- a/npc/003-3/malindou.txt
+++ b/npc/003-3/malindou.txt
@@ -729,7 +729,21 @@ OnPCBonusEvent:
end;
OnGlobalChat:
- SK_Scripture(@chat$);
+ .@msg$ = @chat$;
+
+ // We don't care with punctuation or capitalization
+ .@msg$ = strtolower(.@msg$);
+ .@msg$ = replacestr(.@msg$, ",", "");
+ .@msg$ = replacestr(.@msg$, ".", "");
+ .@msg$ = replacestr(.@msg$, "!", "");
+ .@msg$ = replacestr(.@msg$, ":", "");
+ .@msg$ = replacestr(.@msg$, ";", "");
+ .@msg$ = replacestr(.@msg$, "(", "");
+ .@msg$ = replacestr(.@msg$, ")", "");
+ .@msg$ = replacestr(.@msg$, "<", "");
+ .@msg$ = replacestr(.@msg$, ">", "");
+
+ SK_Scripture(.@msg$);
end;
// Level up events