summaryrefslogtreecommitdiff
path: root/npc/functions/politics.txt
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2021-09-23 19:23:06 -0300
committerJesusaves <cpntb1@ymail.com>2021-09-23 19:23:06 -0300
commit11c2c4dec0a4d694182cb4dd702700889ce15159 (patch)
tree48a18e9a242d24439f35353e7816ea148a155839 /npc/functions/politics.txt
parent6afbb9507dea2dc891a0a750abb6fd06805d22c1 (diff)
downloadserverdata-11c2c4dec0a4d694182cb4dd702700889ce15159.tar.gz
serverdata-11c2c4dec0a4d694182cb4dd702700889ce15159.tar.bz2
serverdata-11c2c4dec0a4d694182cb4dd702700889ce15159.tar.xz
serverdata-11c2c4dec0a4d694182cb4dd702700889ce15159.zip
Town Defense Program, which raises siege experience to 3×
(Default is a 35~42% exp bonus)
Diffstat (limited to 'npc/functions/politics.txt')
-rw-r--r--npc/functions/politics.txt19
1 files changed, 19 insertions, 0 deletions
diff --git a/npc/functions/politics.txt b/npc/functions/politics.txt
index 7d32fbca1..7c9dd5c8d 100644
--- a/npc/functions/politics.txt
+++ b/npc/functions/politics.txt
@@ -400,6 +400,7 @@ function script POL_Manage {
.@RP=getd("$"+getarg(0)+"_REPUTATION");
.@CR=getd("$"+getarg(0)+"_TAXOFF");
.@DQ=getd("$"+getarg(0)+"_DAILYQUEST");
+ .@SE=getd("$"+getarg(0)+"_SIEGEXP");
.@left=(gettimeparam(GETTIME_HOUR)/4)-TOWN_ACTIONS[.@TP];
mesc l("Town Money: @@", .@GP), 2;
@@ -416,6 +417,7 @@ function script POL_Manage {
rif(.@left, l("Lower city taxes")), 35,
rif(.@CR && .@RP, l("Tax crafters")), 40,
rif(!.@CR, l("Don't tax crafters")), 41,
+ rif(.@left && !.@SE, l("Town Defense Program")), 60,
rif(.@left >= 6, l("Exile a player")), 70,
rif(.@left >= 6, l("Revert a player exile")), 71,
rif(.@left, l("Raise server wide EXP")), 80,
@@ -515,6 +517,23 @@ function script POL_Manage {
setd(.@town$+"_REPUTATION", .@RP+1);
mesc l("Crafters no longer pays taxes. (Tax exempt)"), 1;
break;
+ // Mark 60: Global events interference
+ case 60:
+ .@cost = 2000 - (.@RP * 10);
+ mesc l("Town Defense Program"), 3;
+ mesc l("You need @@ GP to make this investment.", .@cost);
+ mesc l("This program will cause experience gain to be tripled during the next siege to the town.");
+ if (.@GP < .@cost)
+ break;
+ mesc l("Are you sure?");
+ if (askyesno() == ASK_YES) {
+ setd(.@town$+"_SIEGEXP", 1);
+ setd(.@town$+"_MONEY", .@GP-.@cost);
+ TOWN_ACTIONS[.@TP]+=1;
+ mesc l("Town Defense Program enabled."), 1;
+ next;
+ }
+ break;
// Mark 70: Exile and Player functions
case 70:
mesc l("Exiled players will not be able to save to menhir."), 1;