summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--npc/magic/study.txt15
1 files changed, 15 insertions, 0 deletions
diff --git a/npc/magic/study.txt b/npc/magic/study.txt
index 6f039ce9d..71beded64 100644
--- a/npc/magic/study.txt
+++ b/npc/magic/study.txt
@@ -13,12 +13,27 @@ function script SK_study {
return;
}
.@mobID=getunitdata(.@mobGD, UDT_CLASS);
+
+ // Research Points
+ if (array_rfind(@study, @mobGD) < 0) {
+ .@rp=getmonsterinfo(MOB_LV)/10+1;
+ array_push(@study, @mobGD);
+ dispbottom l("Research Points +%d", .@rp);
+ }
+
+ // Report
dispbottom l("%s - %d/%d HP, %d/%d MP",
getmonsterinfo(.@mobID, MOB_NAME),
fnum(getunitdata(.@mobGD, UDT_HP)),
fnum(getunitdata(.@mobGD, UDT_MAXHP)),
fnum(getunitdata(.@mobGD, UDT_SP)),
fnum(getunitdata(.@mobGD, UDT_MAXSP)));
+
+ // Truncate
+ if (getarraysize(@study) > 99) {
+ //array_shift(@study);
+ deletearray(@study, 30);
+ }
return;
}