summaryrefslogtreecommitdiff
path: root/npc/003-0/sage.txt
diff options
context:
space:
mode:
Diffstat (limited to 'npc/003-0/sage.txt')
-rw-r--r--npc/003-0/sage.txt32
1 files changed, 7 insertions, 25 deletions
diff --git a/npc/003-0/sage.txt b/npc/003-0/sage.txt
index 0d84de4d7..9df6a2dec 100644
--- a/npc/003-0/sage.txt
+++ b/npc/003-0/sage.txt
@@ -130,31 +130,13 @@ L_Member:
mesc l("Temporaly switch weapon element to @@. Success rate is fixed at 70%.", .@Skill$);
mes "";
mesn;
- mesq l("This useful skill will only require:");
- mesc l("@@/@@ @@", countitem(.@Item), (getskilllv(.@Skill)+1)*30, getitemlink(.@Item));
- mesc l("@@/@@ @@", countitem(FluoPowder), (getskilllv(.@Skill)+1)*15, getitemlink(FluoPowder));
- mesc l("@@/@@ @@", countitem(HerbalTea), (getskilllv(.@Skill)+1)*3, getitemlink(HastePotion));
- mesc l("@@/@@ @@", countitem(WoodenLog), (getskilllv(.@Skill)+1)*2, getitemlink(DiamondPowder));
- mesc l("@@/@@ @@", countitem(.@ItemB), (getskilllv(.@Skill)+1)*1, getitemlink(.@ItemB));
- next;
- if (askyesno() == ASK_YES) {
- if (
- countitem(.@Item) < (getskilllv(.@Skill)+1)*30 ||
- countitem(FluoPowder) < (getskilllv(.@Skill)+1)*15 ||
- countitem(HerbalTea) < (getskilllv(.@Skill)+1)*3 ||
- countitem(WoodenLog) < (getskilllv(.@Skill)+1)*2 ||
- countitem(.@ItemB) < (getskilllv(.@Skill)+1)*1) goto L_Missing;
-
- delitem .@Item, (getskilllv(.@Skill)+1)*30;
- delitem FluoPowder, (getskilllv(.@Skill)+1)*15;
- delitem HerbalTea, (getskilllv(.@Skill)+1)*3;
- delitem WoodenLog, (getskilllv(.@Skill)+1)*2;
- delitem .@ItemB, (getskilllv(.@Skill)+1)*1;
-
- sk_lvup(.@Skill);
-
- next;
- }
+ if (!mlearn(.@Skill,
+ .@Item, 30,
+ FluoPowder, 10,
+ WoodenLog, 5,
+ HerbalTea, 3,
+ .@ItemB, 1))
+ goto L_Missing;
break;
case 8:
// All skills related may include the basic class skills if they're related.