summaryrefslogtreecommitdiff
path: root/world/map/npc/functions/stat_reset.txt
diff options
context:
space:
mode:
authorwushin <pasekei@gmail.com>2015-01-07 20:44:06 -0600
committerwushin <pasekei@gmail.com>2015-01-07 20:44:06 -0600
commit7987a556ec3030bf136fb16559960dba5dfd789f (patch)
tree027c55e2fdc1fb7cc6badc2daba59a47288eaf7a /world/map/npc/functions/stat_reset.txt
parenta8db9aab074c8e33cba2971e994fe43262e52424 (diff)
downloadserverdata-7987a556ec3030bf136fb16559960dba5dfd789f.tar.gz
serverdata-7987a556ec3030bf136fb16559960dba5dfd789f.tar.bz2
serverdata-7987a556ec3030bf136fb16559960dba5dfd789f.tar.xz
serverdata-7987a556ec3030bf136fb16559960dba5dfd789f.zip
Add Function Changes
Diffstat (limited to 'world/map/npc/functions/stat_reset.txt')
-rw-r--r--world/map/npc/functions/stat_reset.txt55
1 files changed, 55 insertions, 0 deletions
diff --git a/world/map/npc/functions/stat_reset.txt b/world/map/npc/functions/stat_reset.txt
new file mode 100644
index 00000000..d8f484ff
--- /dev/null
+++ b/world/map/npc/functions/stat_reset.txt
@@ -0,0 +1,55 @@
+//
+
+function|script|StatReset
+{
+// if (ResetA_charstate == 1) goto L_Multiple;
+
+// set @cost, 10000000 / ($ResetA_uses + 1);
+
+ set @cost, BaseLevel * 100;
+
+ mes "[" + @NpcName$ + "]";
+ mes "\"I have come across a spell that will";
+ mes "reset your status points.";
+ mes "Normally this spell is expensive, but";
+ mes "due to an unusual constellation of the";
+ mes "stars I can cast it very cheaply!";
+ mes "For you it will cost only "+@cost+" gp.\"";
+ next;
+ menu
+ "Reset my stats",L_Next,
+ "Forget about it",L_Pass;
+
+L_Next:
+ if (Zeny<@cost) goto L_NoMoney;
+ goto L_Reset;
+
+// set $ResetA_uses, $ResetA_uses + 1;
+// set ResetA_charstate, 1;
+
+L_Reset:
+ set Zeny, Zeny-@cost;
+ resetstatus;
+
+ mes "[" + @NpcName$ + "]";
+ mes "\"There you are.";
+ mes "";
+ mes "Good as new!\"";
+ goto L_Return;
+
+L_Pass:
+ mes "[" + @NpcName$ + "]";
+ mes "\"Very well then, see you.\"";
+ goto L_Return;
+
+L_NoMoney:
+ mes "[" + @NpcName$ + "]";
+ mes "\"Oh dear, the price cannot be bargained.";
+ mes "";
+ mes "Perhaps you can borrow from a friend?\"";
+ goto L_Return;
+
+L_Return:
+ set @cost, 0;
+ return;
+}