You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
return"mixed {[player, [slot]]} Gets the inventory information for the specified player, or the current "
71
+
return"array {[player, [slot]]} Gets the inventory information for the specified player, or the current "
66
72
+ " player if none specified. If the index is specified, only the slot given will be returned."
67
73
+ " The index of the array in the array is 0 - 35, 100 - 103, -106, which corresponds to the slot"
68
74
+ " in the player's inventory. To access armor slots, you may also specify the index. (100 - 103)."
69
75
+ " The quick bar is 0 - 8. If index is null, the item in the player's hand is returned, regardless"
70
76
+ " of what slot is selected. If index is -106, the player's off-hand item is returned. If there is"
71
77
+ " no item at the slot specified, null is returned."
72
78
+ " ---- If all slots are requested, an associative array of item objects is returned, and if"
73
-
+ " only one item is requested, just that single item object is returned. An item object"
74
-
+ " consists of the following associative array(name: the string id of the item,"
75
-
+ " type: The numeric id of the item, data: The data value of the item,"
76
-
+ " or the damage if a damagable item, qty: The number of items in their inventory, meta: An array"
77
-
+ " of item meta or null if none exists. See {{function|get_itemmeta}} for details about item meta.";
79
+
+ " only one item is requested, just that single item object is returned." + ITEM_OBJECT;
78
80
}
79
81
80
82
@Override
@@ -442,8 +444,7 @@ public String docs() {
442
444
+ " second slot to be a stack of stone. set_pinv(array(103: array(type: 298))) gives them a hat."
443
445
+ " To set the item in hand, use something like set_pinv(player(), null, array(type: 298))."
444
446
+ " If you set a null key in an inventory array, only one of the items will be used (which one is"
445
-
+ " undefined). Use an index of -106 to set the item in the player's off-hand. The type key"
446
-
+ " supports the string item format (eg. \"35:11\") for convenience and backwards compatibility.";
447
+
+ " undefined). Use an index of -106 to set the item in the player's off-hand.";
447
448
448
449
}
449
450
@@ -1203,9 +1204,7 @@ public String docs() {
1203
1204
+ " enderchest would be: set_penderchest(array(2: array(type: 1, qty: 64))) This sets the chest's second slot"
1204
1205
+ " to be a stack of stone. set_penderchest(array(103: array(type: 298))) gives them a hat."
1205
1206
+ " Note that this uses the unsafe"
1206
-
+ " enchantment mechanism to add enchantments, so any enchantment value will work. If"
1207
-
+ " type uses the old format (for instance, \"35:11\"), then the second number is taken"
1208
-
+ " to be the data, making this backwards compatible (and sometimes more convenient).";
1207
+
+ " enchantment mechanism to add enchantments, so any enchantment value will work.";
1209
1208
1210
1209
}
1211
1210
@@ -1301,16 +1300,12 @@ public Integer[] numArgs() {
1301
1300
1302
1301
@Override
1303
1302
publicStringdocs() {
1304
-
return"mixed {[player, [index]]} Gets the inventory information for the specified player's enderchest, or the current player if none specified. If the index is specified, only the slot "
1305
-
+ " given will be returned."
1306
-
+ " The index of the array in the array is 0 - 26, which corresponds to the slot in the enderchest inventory."
1307
-
+ " If there is no item at the slot specified, null is returned."
1303
+
return"array {[player, [index]]} Gets the inventory for the specified player's enderchest, or the current"
1304
+
+ " player if none specified. If the index is specified, only the slot given will be returned."
1305
+
+ " The index of the array in the array is 0 - 26, which corresponds to the slot in the enderchest"
1306
+
+ " inventory. If there is no item at the slot specified, null is returned."
1308
1307
+ " ---- If all slots are requested, an associative array of item objects is returned, and if"
1309
-
+ " only one item is requested, just that single item object is returned. An item object"
1310
-
+ " consists of the following associative array(type: The id of the item, data: The data value of the item,"
1311
-
+ " or the damage if a damagable item, qty: The number of items in their inventory, enchants: An array"
1312
-
+ " of enchant objects, with 0 or more associative arrays which look like:"
1313
-
+ " array(etype: The type of enchantment, elevel: The strength of the enchantment))";
1308
+
+ " only one item is requested, just that single item object is returned." + ITEM_OBJECT;
1314
1309
}
1315
1310
1316
1311
@Override
@@ -1749,16 +1744,12 @@ public Integer[] numArgs() {
1749
1744
1750
1745
@Override
1751
1746
publicStringdocs() {
1752
-
return"mixed {entityID, [index] | locationArray, [index]} Gets the inventory information for the specified block or entity."
1747
+
return"array {entityID, [index] | locationArray, [index]} Gets the inventory for the specified block or entity."
1753
1748
+ " If the block or entity can't have an inventory, a FormatException is thrown. If the index is specified,"
1754
-
+ " only the slot given will be returned. The max index of the array in the array is different for different types"
1755
-
+ " of inventories. If there is no item at the slot specified, null is returned."
1749
+
+ " only the slot given will be returned. The max index of the array in the array is different for"
1750
+
+ " different types of inventories. If there is no item at the slot specified, null is returned."
1756
1751
+ " ---- If all slots are requested, an associative array of item objects is returned, and if"
1757
-
+ " only one item is requested, just that single item object is returned. An item object"
1758
-
+ " consists of the following associative array(type: The id of the item, data: The data value of the item,"
1759
-
+ " or the damage if a damagable item, qty: The number of items in their inventory, enchants: An array"
1760
-
+ " of enchant objects, with 0 or more associative arrays which look like:"
1761
-
+ " array(etype: The type of enchantment, elevel: The strength of the enchantment))";
1752
+
+ " only one item is requested, just that single item object is returned." + ITEM_OBJECT;
1762
1753
}
1763
1754
1764
1755
@Override
@@ -1835,9 +1826,7 @@ public String docs() {
1835
1826
+ " and it is skipped, but the function will not fail as a whole. A simple way to set one item would be:"
1836
1827
+ " set_inventory(123, array(2: array(type: 1, qty: 64))) This sets the inventory second slot"
1837
1828
+ " to be a stack of stone for entity with ID = 123. Note that this uses the unsafe"
1838
-
+ " enchantment mechanism to add enchantments, so any enchantment value will work. If"
1839
-
+ " type uses the old format (for instance, \"35:11\"), then the second number is taken"
1840
-
+ " to be the data, making this backwards compatible (and sometimes more convenient).";
1829
+
+ " enchantment mechanism to add enchantments, so any enchantment value will work.";
Copy file name to clipboardExpand all lines: src/main/resources/docs/Compatibility
+29-14Lines changed: 29 additions & 14 deletions
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
This page lists compatibility of various milestone versions of CommandHelper. Note that this chart was created starting with build 1498, so earlier builds may not be accurate. In general, the compatibility requirements, if not listed, are the same as the previous milestone build. The minimum requirements for the current builds are:
2
2
3
-
* Java 7
3
+
* Java 8
4
4
* Bukkit version as specified below (when used as a Bukkit plugin)
5
5
6
6
Also note that CommandHelper may still be backwards and forward compatible to a large degree, many of the advanced features that normally have hard dependencies on certain versions of external dependencies have been configured to "soft" fail, that is, individual components may not work, but in general the plugin should continue to function. Regardless, only the most current dev builds are officially supported.
@@ -13,8 +13,8 @@ Also note that CommandHelper may still be backwards and forward compatible to a
0 commit comments