summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorDastgir <dastgirp@gmail.com>2018-08-08 15:34:57 +0530
committerHaru <haru@dotalux.com>2018-10-21 21:19:14 +0200
commit9b878ee44765010758c7c6da630431d9aaef71dc (patch)
tree2686dfd2dced77902c01c1bb8550250861bd925c /doc
parent852c13305f67948531bd0277eb1922dbd02b1f26 (diff)
downloadhercules-9b878ee44765010758c7c6da630431d9aaef71dc.tar.gz
hercules-9b878ee44765010758c7c6da630431d9aaef71dc.tar.bz2
hercules-9b878ee44765010758c7c6da630431d9aaef71dc.tar.xz
hercules-9b878ee44765010758c7c6da630431d9aaef71dc.zip
Updated getiteminfo and setiteminfo.
Added ITR_TRADE (Trade restriction) for both script commands
Diffstat (limited to 'doc')
-rw-r--r--doc/sample/getiteminfo.txt9
-rw-r--r--doc/script_commands.txt1
2 files changed, 7 insertions, 3 deletions
diff --git a/doc/sample/getiteminfo.txt b/doc/sample/getiteminfo.txt
index 57407c072..9d5121635 100644
--- a/doc/sample/getiteminfo.txt
+++ b/doc/sample/getiteminfo.txt
@@ -9,12 +9,12 @@
//============================================================
prontera,156,179,6 script test_getiteminfo 4_F_KAFRA1,{
- mes "Please enter an item ID.";
- input .@value;
+ mes("Please enter an item ID.");
+ input(.@value);
// This line uses an INTERNAL function of your client to show item name by its ID!
// ^nItemID^XXXX -> Item Name
- mes "Item ID: "+.@value+" ^nItemID^"+.@value;
+ mesf("Item ID: %d ^nItemID^%d", .@value, .@value);
mes("Current item info:");
mesf("Buy Price: %d", getiteminfo(.@value, ITEMINFO_BUYPRICE));
@@ -34,5 +34,8 @@ prontera,156,179,6 script test_getiteminfo 4_F_KAFRA1,{
mesf("View ID: %d", getiteminfo(.@value, ITEMINFO_VIEWID));
mesf("MATK: %d", getiteminfo(.@value, ITEMINFO_MATK));
mesf("View Sprite: %d", getiteminfo(.@value, ITEMINFO_VIEWSPRITE));
+
+ .@trade$ = callfunc("F_GetTradeRestriction", .@value);
+ mesf("Trade Restriction: %s", .@trade$);
close;
}
diff --git a/doc/script_commands.txt b/doc/script_commands.txt
index 343eb02cb..8f5ce6c78 100644
--- a/doc/script_commands.txt
+++ b/doc/script_commands.txt
@@ -3239,6 +3239,7 @@ Valid types are:
ITEMINFO_VIEWID - View ID ("Sprite" field in the Item DB)
ITEMINFO_MATK - MATK (only relevant if RENEWAL is set)
ITEMINFO_VIEWSPRITE - View Sprite ("ViewSprite" field in the Item DB)
+ ITEMINFO_TRADE - Trade Restriction (see "doc/constant.md": item trade restriction)
Check sample in doc/sample/getiteminfo.txt