summaryrefslogtreecommitdiff
path: root/npc
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2018-07-03 11:35:49 -0300
committerJesusaves <cpntb1@ymail.com>2018-07-03 11:35:49 -0300
commitfc95bd988cbb647e23706535b2cb93ee00f5ae44 (patch)
tree6dac9abb2c7396859f5e35b8cef3b0f132511f31 /npc
parentb33c033cee0b5e74e36471c284cb2d580e679929 (diff)
downloadserverdata-fc95bd988cbb647e23706535b2cb93ee00f5ae44.tar.gz
serverdata-fc95bd988cbb647e23706535b2cb93ee00f5ae44.tar.bz2
serverdata-fc95bd988cbb647e23706535b2cb93ee00f5ae44.tar.xz
serverdata-fc95bd988cbb647e23706535b2cb93ee00f5ae44.zip
[skip ci] penalty for parties not sharing EXP: Their time is halved.
Diffstat (limited to 'npc')
-rw-r--r--npc/008-0/master.txt6
-rw-r--r--npc/functions/util.txt6
2 files changed, 12 insertions, 0 deletions
diff --git a/npc/008-0/master.txt b/npc/008-0/master.txt
index adf4211bd..2cf7129f7 100644
--- a/npc/008-0/master.txt
+++ b/npc/008-0/master.txt
@@ -23,6 +23,8 @@
next;
mesn;
mesq l("You also can't stay there forever! You will have about 20 minutes to entirely clear it out and defeat the last boss.");
+ if (!party_expon(getcharid(1)))
+ mesc l("Note: your party is not sharing experience, and will suffer a time penalty. Your time will be halved.");
next;
// Get info about your party, and backup it
getpartymember(getcharid(1));
@@ -123,6 +125,10 @@ OnLoop:
warp "008-0", 47, 64;
dispbottom l("You are not a member of a party anymore.");
}
+ if (!party_expon(getcharid(1))) {
+ // Party exp sharing disabled means time penalty.
+ @pmloop+=1;
+ }
// Add new cycle or finish.
if (@pmloop < 1200) {
diff --git a/npc/functions/util.txt b/npc/functions/util.txt
index 48937d157..9e2ef7700 100644
--- a/npc/functions/util.txt
+++ b/npc/functions/util.txt
@@ -233,4 +233,10 @@ function script reachable {
return 0;
}
+// Determines if party exp sharing is enabled
+// ( Party ID )
+function script party_expon {
+ .@nb = query_sql("SELECT exp FROM `party` WHERE party_id="+escape_sql(getarg(0))+" LIMIT 2", .@value);
+ return .@value[0];
+}