summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2025-03-03 18:26:05 -0300
committerJesusaves <cpntb1@ymail.com>2025-03-03 18:26:05 -0300
commita08de39d556e83be9428f685158e9adefdfb79db (patch)
treeeb2703a1445bcdba82bfb48d7a8e9c17ef411dc7
parent661199ce3753917328dcbd0f290e3c011fa67800 (diff)
downloadserverdata-a08de39d556e83be9428f685158e9adefdfb79db.tar.gz
serverdata-a08de39d556e83be9428f685158e9adefdfb79db.tar.bz2
serverdata-a08de39d556e83be9428f685158e9adefdfb79db.tar.xz
serverdata-a08de39d556e83be9428f685158e9adefdfb79db.zip
Provide an use case for the new feature requested by @ThinkSome / @specing
-rw-r--r--npc/003-0-1/professor.txt3
-rw-r--r--npc/commands/rate-management.txt6
2 files changed, 6 insertions, 3 deletions
diff --git a/npc/003-0-1/professor.txt b/npc/003-0-1/professor.txt
index c361c3184..a4d304ac7 100644
--- a/npc/003-0-1/professor.txt
+++ b/npc/003-0-1/professor.txt
@@ -60,6 +60,9 @@ OnSpeeching:
.@bxp=min(1+.@sk, 12);
.@jxp=min(1+(.@sk/3), 6);
+ // Adjust the experience to take bonuses in account
+ .@bxp = .@bxp * "@exprate"::expRecalc() / 100;
+
getexp .@bxp, .@jxp;
// (Extra) Experience for Homunculus
diff --git a/npc/commands/rate-management.txt b/npc/commands/rate-management.txt
index 1dbf7efef..e19ba5ae3 100644
--- a/npc/commands/rate-management.txt
+++ b/npc/commands/rate-management.txt
@@ -2,15 +2,15 @@
- script @exprate 32767,{
end;
- function expRateReal {
+ public function expRateReal {
if (is_night())
return $BCONFB_EXPR+$BCONFN_EXPR;
else
return $BCONFB_EXPR+$BCONFD_EXPR;
}
- function expRecalc {
- .@val=getarg(0);
+ public function expRecalc {
+ .@val=getarg(0, .current_rate);
if (is_night())
return .@val+$BCONFN_EXPR;
else