summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorHaru <haru@dotalux.com>2018-10-21 23:51:35 +0200
committerGitHub <noreply@github.com>2018-10-21 23:51:35 +0200
commiteb71c78f0872567a33196b72420d3d081651a23f (patch)
treec14b23ec6f2532487ceacb275a71f086def15ef6 /doc
parentb196e2b794bb96c1584c885f50e63326678ae89e (diff)
parent9b878ee44765010758c7c6da630431d9aaef71dc (diff)
downloadhercules-eb71c78f0872567a33196b72420d3d081651a23f.tar.gz
hercules-eb71c78f0872567a33196b72420d3d081651a23f.tar.bz2
hercules-eb71c78f0872567a33196b72420d3d081651a23f.tar.xz
hercules-eb71c78f0872567a33196b72420d3d081651a23f.zip
Merge pull request #2172 from dastgirp/enhance/getiteminfo
Updated getiteminfo and setiteminfo.
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 64468ed49..5cba5afc8 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