summaryrefslogtreecommitdiff
path: root/npc/other/Global_Functions.txt
diff options
context:
space:
mode:
authorL0ne_W0lf <L0ne_W0lf@54d463be-8e91-2dee-dedb-b68131a5f0ec>2008-02-28 03:32:45 +0000
committerL0ne_W0lf <L0ne_W0lf@54d463be-8e91-2dee-dedb-b68131a5f0ec>2008-02-28 03:32:45 +0000
commit64169298d9e64182e882a76f9fe4c94c1c7c24d5 (patch)
tree279196f08fe789e054c49a0b70dee25d0eba47ea /npc/other/Global_Functions.txt
parentcbe4b008af7c80ed1c9de9250d6b69592c78e5e8 (diff)
downloadhercules-64169298d9e64182e882a76f9fe4c94c1c7c24d5.tar.gz
hercules-64169298d9e64182e882a76f9fe4c94c1c7c24d5.tar.bz2
hercules-64169298d9e64182e882a76f9fe4c94c1c7c24d5.tar.xz
hercules-64169298d9e64182e882a76f9fe4c94c1c7c24d5.zip
* Implemented new function F_CheckMaxCount.
- Checks if you have enough room in your inventory to accept items * Updated 2004 headgear quests to fully official. - Implemented usage of F_checkMaxCount in the 2004 headgear quests. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@12255 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'npc/other/Global_Functions.txt')
-rw-r--r--npc/other/Global_Functions.txt21
1 files changed, 20 insertions, 1 deletions
diff --git a/npc/other/Global_Functions.txt b/npc/other/Global_Functions.txt
index 63e877b28..e905dc25e 100644
--- a/npc/other/Global_Functions.txt
+++ b/npc/other/Global_Functions.txt
@@ -3,7 +3,7 @@
//===== By: ==================================================
//= Lupus, kobra_k88
//===== Current Version: =====================================
-//= 2.09
+//= 2.10
//===== Compatible With: =====================================
//= eAthena 1.0
//===== Description: =========================================
@@ -31,6 +31,7 @@
//= 2.06 Pass to Bio-Lab -> MISC_QUEST|512 [Lupus]
//= 2.07 Added TK_Q variable clear. 2.08 Added NINJ_Q variable clear [Lupus]
//= 2.09 Cleared F_ClearGarbage [Lupus]
+//= 2.10 Added F_CheckMaxCount to check count of carrid items. [L0ne_w0lf]
//============================================================
@@ -306,3 +307,21 @@ function script F_Load2Skills {
set ADV_QSK2,0; //Clear var
return;
}
+
+//////////////////////////////////////////////////////////////////////////////////
+// *** Function "F_CheckMaxCount"
+//////////////////////////////////////////////////////////////////////////////////
+// Return 1 if the max items in inventory is 100, else 0.
+// Ensure that this corrisponds to MAX_INVENTORY in src/common/mmo.h,
+// otherwise you will not be able to use several quests, as they will
+// check this if you have over 100 items in your inventory.
+// This function will return 1 if you cannot carry anymore items.
+
+function script F_CheckMaxCount {
+ getinventorylist;
+ if (@inventorylist_count > 99) {
+ return 1;
+ }
+ return 0;
+}
+