Items¶
Methods¶
filter:
Items.FilterA filter object.
Filter the global list of Items according to the options specified by the filter ( see: Items.Filter ).
- Items.BackpackCount(itemid, color) → Int32¶
itemid:
Int32ItemID to search.color:
Int32Color to search. (default -1: any color)
Count items in Player Backpack.
- Items.ContainerCount(serial, itemid, color, recursive) → Int32¶
serial:
Int32itemid:
Int32color:
Int32recursive:
Boolean
- Items.ContainerCount(container, itemid, color, recursive) → Int32¶
container:
ItemSerial or Item to search into.itemid:
Int32ItemID of the item to search.color:
Int32Color to match. (default: -1, any color)recursive:
BooleanSearch also in already open subcontainers.
Count items inside a container, summing also the amount in stacks.
- Items.ContextExist(i, name) → Int32¶
i:
Itemname:
String
- Items.ContextExist(serial, name) → Int32¶
serial:
Int32Serial or Item to check.name:
StringName of the Context Manu entry
Check if Context Menu entry exists for an Item.
- Items.DropFromHand(item, container) → Void¶
Drop into a bag an Item currently held in-hand. ( see: Items.Lift )
- Items.DropItemGroundSelf(serialitem, amount) → Void¶
serialitem:
Int32amount:
Int32
- Items.DropItemGroundSelf(item, amount) → Void¶
item:
ItemItem object to drop.amount:
Int32Amount to move. (default: 0, the whole stack)
Drop an Item on the ground, at the current Player position. NOTE: On some server is not allowed to drop Items on tiles occupied by Mobiles and the Player.
itemid:
Int32color:
Int32container:
Int32range:
Int32considerIgnoreList:
Boolean
itemid:
Int32ItemID filter.color:
Int32Color filter. (-1: any, 0: natural )container:
Int32Serial of the container to search. (-1: any Item)- recursive:
BooleanSearch subcontainers. True: all subcontainers False: only main 1,2,n: Maximum subcontainer depth
- recursive:
considerIgnoreList:
BooleanTrue: Ignore Items are excluded - False: any Item.
Find a single Item matching specific ItemID, Color and Container. Optionally can search in all subcontaners or to a maximum depth in subcontainers. Can use -1 on color for no chose color, can use -1 on container for search in all item in memory. The depth defaults to only the top but can search for # of sub containers.
serial:
Int32Serial of the Item.
Search for a specific Item by using it Serial
- Items.GetImage(itemID, hue) → Bitmap¶
itemID:
Int32ItemID to use.hue:
Int32Optional: Color to apply. (Default 0, natural)
Get the Image on an Item by specifing the ItemID. Optinally is possible to apply a color.
- Items.GetPropStringByIndex(serial, index) → String¶
serial:
Int32Serial or Item to read.index:
Int32Number of the Property line.
Get a Property line, by index. if not found returns and empty string.
- Items.GetPropStringByIndex(item, index) → String¶
item:
Itemindex:
Int32
- Items.GetPropStringList(serial) → List[String]¶
serial:
Int32Serial or Item to read.
Get string list of all Properties of an item, if item no props list is empty.
- Items.GetPropStringList(item) → List[String]¶
item:
Item
- Items.GetPropValue(serial, name) → Single¶
serial:
Int32Serial or Item to read.name:
StringName of the Propery.
Read the value of a Property.
- Items.GetPropValue(item, name) → Single¶
item:
Itemname:
String
- Items.Hide(item) → Void¶
item:
Item
- Items.Hide(serial) → Void¶
serial:
Int32Serial or Item to hide.
Hied an Item, affects only the player.
- Items.Lift(item, amount) → Void¶
item:
ItemItem object to Lift.amount:
Int32Amount to lift. (0: the whole stack)
Lift an Item and hold it in-hand. ( see: Items.DropFromHand )
- Items.Message(serial, hue, message) → Void¶
serial:
Int32hue:
Int32message:
String
- Items.Message(item, hue, message) → Void¶
item:
ItemSerial or Item to display text on.hue:
Int32Color of the message.message:
StringMessage as
Display an in-game message on top of an Item, visibile only for the Player.
- Items.Move(source, destination, amount) → Void¶
source:
Int32destination:
Itemamount:
Int32
- Items.Move(source, destination, amount, x, y) → Void¶
- Items.Move(source, destination, amount) → Void¶
source:
Int32destination:
Int32amount:
Int32
- Items.Move(source, destination, amount) → Void¶
- Items.Move(source, destination, amount, x, y) → Void¶
source:
Int32destination:
Mobileamount:
Int32x:
Int32y:
Int32
- Items.Move(source, destination, amount) → Void¶
source:
Itemdestination:
Int32amount:
Int32
- Items.Move(source, destination, amount) → Void¶
source:
Int32destination:
Mobileamount:
Int32
- Items.Move(source, destination, amount, x, y) → Void¶
source:
Int32Serial or Item of the Item to move.destination:
Int32Serial, Mobile or Item as destination.amount:
Int32Amount to move (-1: the whole stack)x:
Int32Optional: X coordinate inside the container.y:
Int32Optional: Y coordinate inside the container.
Move an Item to a destination, which can be an Item or a Mobile.
- Items.Move(source, destination, amount, x, y) → Void¶
source:
Int32destination:
Itemamount:
Int32x:
Int32y:
Int32
- Items.Move(source, destination, amount) → Void¶
- Items.Move(source, destination, amount, x, y) → Void¶
- Items.Move(source, destination, amount, x, y) → Void¶
source:
Itemdestination:
Int32amount:
Int32x:
Int32y:
Int32
- Items.MoveOnGround(source, amount, x, y, z) → Void¶
source:
Int32Serial or Item to move.amount:
Int32Amount of Items to move (0: the whole stack )x:
Int32X world coordinates.y:
Int32Y world coordinates.z:
Int32Z world coordinates.
Move an Item on the ground to a specific location.
- Items.MoveOnGround(source, amount, x, y, z) → Void¶
source:
Itemamount:
Int32x:
Int32y:
Int32z:
Int32
items:
List[Item]selector:
String
- Items.SetColor(serial, color) → Void¶
serial:
Int32Serial of the Item.color:
Int32Color as number. (default: -1, reset original color)
Change/override the Color of an Item, the change affects only Player client. The change is not persistent. If the color is -1 or unspecified, the color of the item is restored.
- Items.SingleClick(itemserial) → Void¶
itemserial:
Int32
- Items.SingleClick(item) → Void¶
item:
ItemSerial or Item to click
Send a single click network event to the server.
- Items.UseItem(item, target) → Void¶
item:
Itemtarget:
Int32
- Items.UseItem(item, target) → Void¶
item:
Itemtarget:
EnhancedEntity
- Items.UseItem(item) → Void¶
item:
Item
- Items.UseItem(itemSerial, targetSerial) → Void¶
itemSerial:
Int32targetSerial:
Int32
- Items.UseItem(item, target) → Void¶
item:
Int32target:
EnhancedEntity
- Items.UseItem(itemSerial, targetSerial, wait) → Void¶
itemSerial:
Int32Serial or Item to use.targetSerial:
Int32Optional: Serial of the Item or Mobile target.wait:
BooleanOptional: Wait for confirmation by the server. (default: True)
Use an Item, optionally is possible to specify a Item or Mobile target. NOTE: The optional target may not work on some free shards. Use Target.Execute instead.
- Items.UseItem(itemserial) → Void¶
itemserial:
Int32
- Items.UseItemByID(itemid, color) → Boolean¶
itemid:
Int32ItemID to be used.color:
Int32Color to be used. (default: -1, any)
Use any item of a specific type, matching Item.ItemID. Optionally also of a specific color, matching Item.Hue.
- Items.WaitForContents(bag, delay) → Void¶
bag:
ItemContainer as Item object.delay:
Int32Maximum wait, in milliseconds.
Open a container an wait for the Items to load, for a maximum amount of time.
- Items.WaitForContents(bag_serial, delay) → Void¶
bag_serial:
Int32Container as Item serial.delay:
Int32
- Items.WaitForProps(i, delay) → Void¶
i:
Itemdelay:
Int32
- Items.WaitForProps(itemserial, delay) → Void¶
itemserial:
Int32Serial or Item read.delay:
Int32Maximum waiting time, in milliseconds.
If not updated, request to the Properties of an Item, and wait for a maximum amount of time.