summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2019-07-22 09:55:44 -0300
committerJesusaves <cpntb1@ymail.com>2019-07-22 09:55:44 -0300
commit4df3fdd86e26090675d009640b753f926f4e8bec (patch)
tree8d603011c07e19c863f139ba5085da0dfb2b7288
parent6648bb2b5e6d8b7a04437474c763c72bf533a91a (diff)
downloadserverdata-4df3fdd86e26090675d009640b753f926f4e8bec.tar.gz
serverdata-4df3fdd86e26090675d009640b753f926f4e8bec.tar.bz2
serverdata-4df3fdd86e26090675d009640b753f926f4e8bec.tar.xz
serverdata-4df3fdd86e26090675d009640b753f926f4e8bec.zip
Scholarship Badge (ID 911) - Grants you a free skill learning and is used first.
-rw-r--r--db/re/item_db.conf18
-rw-r--r--npc/functions/util.txt7
2 files changed, 23 insertions, 2 deletions
diff --git a/db/re/item_db.conf b/db/re/item_db.conf
index e6e842764..dfaa4ea4e 100644
--- a/db/re/item_db.conf
+++ b/db/re/item_db.conf
@@ -5424,6 +5424,24 @@ item_db: (
Refine: false
},
// <!-- ID 900~910 Reserved -->
+{
+ Id: 911
+ AegisName: "ScholarshipBadge"
+ Name: "Scholarship Badge"
+ Type: "IT_ETC"
+ Buy: 10000
+ Sell: 3500
+ Weight: 1
+ Refine: false
+ ViewSprite: 911
+ Trade: {
+ notrade: true
+ nodrop: true
+ noselltonpc: true
+ nomail: true
+ noauction: true
+ }
+},
// <!-- Necklaces -->
{
Id: 1000
diff --git a/npc/functions/util.txt b/npc/functions/util.txt
index f41c343fc..835eae988 100644
--- a/npc/functions/util.txt
+++ b/npc/functions/util.txt
@@ -639,12 +639,15 @@ function script mlearn {
next;
if (askyesno() == ASK_NO)
return true;
- if (countitem(.@it) < .@am)
+ if (countitem(.@it) < .@am && !(countitem(ScholarshipBadge)))
return false;
if (!sk_canlvup(.@ap))
return false;
- delitem .@it, .@am;
+ if (countitem(ScholarshipBadge))
+ delitem ScholarshipBadge, 1;
+ else
+ delitem .@it, .@am;
sk_lvup(.@sk, .@ap);
return true;
}