summaryrefslogtreecommitdiff
path: root/npc/functions/politics.txt
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2019-09-09 17:33:00 -0300
committerJesusaves <cpntb1@ymail.com>2019-09-09 17:33:00 -0300
commit545e83916fcf78fd82033de0bc7a11e97fa3f144 (patch)
tree14a4505027529ec4da3356079e039bfc025f1149 /npc/functions/politics.txt
parent67a3c5acc38d76d83cfbaa401f29f470f645d230 (diff)
downloadserverdata-545e83916fcf78fd82033de0bc7a11e97fa3f144.tar.gz
serverdata-545e83916fcf78fd82033de0bc7a11e97fa3f144.tar.bz2
serverdata-545e83916fcf78fd82033de0bc7a11e97fa3f144.tar.xz
serverdata-545e83916fcf78fd82033de0bc7a11e97fa3f144.zip
Remove Artis and Esperia Teleporter Constants.
Add LoF teleporter constant. Prepare POL_LocToTP
Diffstat (limited to 'npc/functions/politics.txt')
-rw-r--r--npc/functions/politics.txt26
1 files changed, 26 insertions, 0 deletions
diff --git a/npc/functions/politics.txt b/npc/functions/politics.txt
index b1c92a726..ba7cd4a90 100644
--- a/npc/functions/politics.txt
+++ b/npc/functions/politics.txt
@@ -68,6 +68,32 @@ function script SaleTaxes {
return;
}
+// Convert LOC (uppercase) to a TP variable
+// POL_LocToTP( {TOWNCODE} )
+function script POL_LocToTP {
+ .@tw$=strtoupper(getarg(0, LOCATION$));
+
+ if (.@tw$ == "TULIM")
+ return TP_TULIM;
+
+ if (.@tw$ == "HALIN")
+ return TP_HALIN;
+
+ if (.@tw$ == "HURNS")
+ return TP_HURNS;
+
+ if (.@tw$ == "LOF")
+ return TP_LOF;
+
+ if (.@tw$ == "NIVAL")
+ return TP_NIVAL;
+
+ if (.@tw$ == "FROSTIA")
+ return TP_FROSTIA;
+
+ return Exception("Invalid town requested / POL_LocToTP", RB_DEFAULT|RB_SPEECH, -1);
+}
+
- script Politics NPC_HIDDEN,{
OnSun0000: