summaryrefslogtreecommitdiff
path: root/npc/functions
diff options
context:
space:
mode:
Diffstat (limited to 'npc/functions')
-rw-r--r--npc/functions/util.txt5
1 files changed, 4 insertions, 1 deletions
diff --git a/npc/functions/util.txt b/npc/functions/util.txt
index 10073c715..facabc0a3 100644
--- a/npc/functions/util.txt
+++ b/npc/functions/util.txt
@@ -763,7 +763,7 @@ function script learn_magic {
.@it=$@MSK_ITEM[.@ski];
.@am=$@MSK_AMOUNT[.@ski];
.@msp=$@MSK_MSPCOST[.@ski];
- .@ap=$@MSK_COST[.@ski]**((getskilllv(.@ski)+1)/2)-1+getskilllv(.@ski);
+ .@ap=($@MSK_COST[.@ski]*getskilllv(.@ski)*100)**2;
// Pre-requisite check
if (.@pre) {
@@ -785,6 +785,9 @@ function script learn_magic {
if (getskilllv(.@ski)) {
.@msp=50; // FIXME NYI
.@learn$=l("Upgrading");
+ } else if (.@msp <= 1) {
+ // 1 MSP skills take no Research Points
+ .@ap=0;
}
mesc l("%s %s will require:", .@learn$, getskillname(.@ski));