Item
The Item class represent a single in-game Item object. Examples of Item are: Swords, bags, bandages, reagents, clothing. While the Item.Serial is unique for each Item, Item.ItemID is the unique for the Item apparence, or image. Sometimes is also called ID or Graphics ID. Item can also be house foriture as well as decorative items on the ground, like lamp post and banches. However, for Item on the ground that cannot be picked up, they might be part of the world map, see Statics class.
TODO: Item Constructors
Properties
Item.AmountInt32
Item.AmountInt32
Read amount from item type object.
Item.ContainerInt32
Item.ContainerInt32
Serial of the container which contains the object.
Item.ContainerOpenedBoolean
Item.ContainerOpenedBoolean
True when the container was opened
Item.ContainsList[Item]
Item.ContainsList[Item]
Contains the list of Item inside a container.
Item.CorpseNumberItemsInt32
Item.CorpseNumberItemsInt32
-1 until corpse is checked, then # items in corpse. Used by looter to ignore empty corpses
Item.DeletedBoolean
Item.DeletedBoolean
Item.DirectionString
Item.DirectionString
Item direction.
Item.DurabilityInt32
Item.DurabilityInt32
Get the current durability of an Item. (0: no durability)
Item.GridNumByte
Item.GridNumByte
Returns the GridNum of the item. (need better documentation)
Item.HueInt32
Item.HueInt32
Item.ImageBitmap
Item.ImageBitmap
Get the in-game image on an Item as Bitmap object. See MSDN: https://docs.microsoft.com/dotnet/api/system.drawing.bitmap
Item.IsBagOfSendingBoolean
Item.IsBagOfSendingBoolean
True: if the item is a bag of sending - False: otherwise.
Item.IsContainerBoolean
Item.IsContainerBoolean
True: if the item is a container - False: otherwise.
Item.IsCorpseBoolean
Item.IsCorpseBoolean
True: if the item is a corpse - False: otherwise.
Item.IsDoorBoolean
Item.IsDoorBoolean
True: if the item is a door - False: otherwise.
Item.IsInBankBoolean
Item.IsInBankBoolean
True: if the item is in the Player's bank - False: otherwise.
Item.IsLootableBoolean
Item.IsLootableBoolean
True: For regualar items - False: for hair, beards, etc.
Item.IsPotionBoolean
Item.IsPotionBoolean
True: if the item is a potion - False: otherwise.
Item.IsResourceBoolean
Item.IsResourceBoolean
True: if the item is a resource (ore, sand, wood, stone, fish) - False: otherwise
Item.IsSearchableBoolean
Item.IsSearchableBoolean
True: if the item is a pouch - False: otherwise.
Item.IsTwoHandedBoolean
Item.IsTwoHandedBoolean
True: if the item is a 2-handed weapon - False: otherwise.
Item.IsVirtueShieldBoolean
Item.IsVirtueShieldBoolean
True: if the item is a virtue shield - False: otherwise.
Item.ItemIDInt32
Item.ItemIDInt32
Represents the type of Item, usually unique for the Item image. Sometime called ID or Graphics ID.
Item.LayerString
Item.LayerString
Gets the Layer, for werable items only. (need better documentation)
Item.LightByte
Item.LightByte
Item light's direction (e.g. will affect corpse's facing direction)
Item.MaxDurabilityInt32
Item.MaxDurabilityInt32
Get the maximum durability of an Item. (0: no durability)
Item.MovableBoolean
Item.MovableBoolean
Item is movable
Item.NameString
Item.NameString
Item name
Item.OnGroundBoolean
Item.OnGroundBoolean
True: if the item is on the ground - False: otherwise.
Item.PositionPoint3D
Item.PositionPoint3D
Item.PropertiesList[Property]
Item.PropertiesList[Property]
Get the list of Properties of an Item.
Item.PropsUpdatedBoolean
Item.PropsUpdatedBoolean
True: if Properties are updated - False: otherwise.
Item.RootContainerInt32
Item.RootContainerInt32
Get serial of root container of item.
Item.SerialInt32
Item.SerialInt32
Item.UpdatedBoolean
Item.UpdatedBoolean
Check if the Item already have been updated with all the properties. (need better documentation)
Item.VisibleBoolean
Item.VisibleBoolean
Item is Visible
Item.WeightInt32
Item.WeightInt32
Get the weight of a item. (0: no weight)
Methods
Item.DistanceTo(mob)
Item.DistanceTo(mob)
Return the distance in number of tiles, from Item to Mobile.
Parameters
mobItem Mobile
Target as Mobile Target as Item
Return
Int32
Distance in number of tiles.
Item.GetWorldPosition()
Item.GetWorldPosition()
Return
Point3D
Item.IsChildOf(container)
Item.IsChildOf(container)
Check if an Item is contained in a container. Can be a Item or a Mobile (wear by).
Parameters
containerItem Mobile
Item as container. Mobile as container.
Return
Boolean
True: if is contained - False: otherwise.
Item.ToString()
Item.ToString()
Return
String