diff options
author | Jesusaves <cpntb1@ymail.com> | 2021-09-23 18:56:15 -0300 |
---|---|---|
committer | Jesusaves <cpntb1@ymail.com> | 2021-09-23 18:56:15 -0300 |
commit | 6e498ef65cef5d78e76f2f9146875a06c5fcd996 (patch) | |
tree | 06cf8c9301e1d91ef04087458d7a4aea320da1e1 /npc | |
parent | dd9bdd6a917b5b1aff3de58a172e8b5552980148 (diff) | |
download | serverdata-6e498ef65cef5d78e76f2f9146875a06c5fcd996.tar.gz serverdata-6e498ef65cef5d78e76f2f9146875a06c5fcd996.tar.bz2 serverdata-6e498ef65cef5d78e76f2f9146875a06c5fcd996.tar.xz serverdata-6e498ef65cef5d78e76f2f9146875a06c5fcd996.zip |
The town admins may now donate their GP to the town vault.
This allow them to assume a more lax tax policy.
Diffstat (limited to 'npc')
-rw-r--r-- | npc/003-3/malindou.txt | 12 | ||||
-rw-r--r-- | npc/functions/politics.txt | 13 |
2 files changed, 25 insertions, 0 deletions
diff --git a/npc/003-3/malindou.txt b/npc/003-3/malindou.txt index 3d8a62c24..971d33665 100644 --- a/npc/003-3/malindou.txt +++ b/npc/003-3/malindou.txt @@ -69,6 +69,8 @@ OnInit: $BCONFD_DROP = 0; $BETASERVER = false; $AUTORESTART = false; + $ALLIANCE_TAX1 = 7500; + $ALLIANCE_TAX2 = 30; $FIRESOFSTEAM[1] = 2000; $FIRESOFSTEAM[2] = 2000; $FIRESOFSTEAM[3] = 2000; @@ -633,6 +635,16 @@ OnInit: debugmes "* Skill changes"; debugmes ""; } + // Current UPDATE value: Qui Set 23 18:46:36 BRT 2021 + // Variable Update + if ($UPDATE < 1632433596) { + $UPDATE=1632433596; + $ALLIANCE_TAX1 = 7500; + $ALLIANCE_TAX2 = 30; + debugmes ""; + debugmes "* New global variables"; + debugmes ""; + } // This mensures Contributors Credits, and changes only during updates. diff --git a/npc/functions/politics.txt b/npc/functions/politics.txt index 0a35d2458..7d32fbca1 100644 --- a/npc/functions/politics.txt +++ b/npc/functions/politics.txt @@ -419,6 +419,7 @@ function script POL_Manage { 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, + rif(Zeny > $ALLIANCE_TAX1, l("Donate to town")), 90, l("Resign"), 99; mes ""; switch (@menuret) { @@ -601,6 +602,18 @@ function script POL_Manage { } break; // Mark 90: Office + case 90: + mesc l("The alliance will take %s GP as fee, +%d%% tax over donations.", fnum($ALLIANCE_TAX1), $ALLIANCE_TAX2), 1; + mesc l("You can donate up to %s GP.", fnum(Zeny-$ALLIANCE_TAX1)); + input .@donate, 0, Zeny-$ALLIANCE_TAX1; + if (.@donate <= 0) + break; + Zeny -= $ALLIANCE_TAX1; + .@tax = .@donate * (100-$ALLIANCE_TAX2) / 100; + setd(.@town$+"_MONEY", .@GP+.@tax); + Zeny -= .@donate; + mesc l("Donation completed."), 2; + break; case 99: mesc l("Really resign?"), 1; next; |