AzerothCore 3.3.5a
OpenSource WoW Emulator
|
#include "Bag.h"
Protected Attributes | |
Item * | m_bagslot [MAX_BAG_SIZE] |
Protected Attributes inherited from Object | |
uint16 | m_objectType |
TypeID | m_objectTypeId |
uint16 | m_updateFlag |
union { | |
int32 * m_int32Values | |
uint32 * m_uint32Values | |
float * m_floatValues | |
}; | |
UpdateMask | _changesMask |
uint16 | m_valuesCount |
uint16 | _fieldNotifyFlags |
bool | m_objectUpdated |
Additional Inherited Members | |
Static Public Member Functions inherited from Item | |
static Item * | CreateItem (uint32 item, uint32 count, Player const *player=nullptr, bool clone=false, uint32 randomPropertyId=0) |
static void | DeleteFromDB (CharacterDatabaseTransaction trans, ObjectGuid::LowType itemGuid) |
static void | DeleteFromInventoryDB (CharacterDatabaseTransaction trans, ObjectGuid::LowType itemGuid) |
static int32 | GenerateItemRandomPropertyId (uint32 item_id) |
Static Public Member Functions inherited from Object | |
static ObjectGuid | GetGUID (Object const *o) |
Public Attributes inherited from Item | |
Loot | loot |
bool | m_lootGenerated |
Public Attributes inherited from Object | |
DataMap | CustomData |
Protected Member Functions inherited from Object | |
Object () | |
void | _InitValues () |
void | _Create (ObjectGuid::LowType guidlow, uint32 entry, HighGuid guidhigh) |
std::string | _ConcatFields (uint16 startIndex, uint16 size) const |
bool | _LoadIntoDataField (std::string const &data, uint32 startOffset, uint32 count) |
uint32 | GetUpdateFieldData (Player const *target, uint32 *&flags) const |
void | BuildMovementUpdate (ByteBuffer *data, uint16 flags) const |
virtual void | BuildValuesUpdate (uint8 updateType, ByteBuffer *data, Player *target) |
virtual void | AddToObjectUpdate ()=0 |
virtual void | RemoveFromObjectUpdate ()=0 |
void | AddToObjectUpdateIfNeeded () |
Bag::Bag | ( | ) |
References CONTAINER_END, m_bagslot, Object::m_objectType, Object::m_objectTypeId, Object::m_valuesCount, MAX_BAG_SIZE, TYPEID_CONTAINER, and TYPEMASK_CONTAINER.
|
override |
References Item::GetBagSlot(), Object::GetEntry(), Item::GetSlot(), LOG_FATAL, m_bagslot, and MAX_BAG_SIZE.
|
overridevirtual |
Reimplemented from Object.
References Object::AddToWorld(), GetBagSize(), and m_bagslot.
|
overridevirtual |
Reimplemented from Object.
References Object::BuildCreateUpdateBlockForPlayer(), GetBagSize(), and m_bagslot.
|
overridevirtual |
Reimplemented from Item.
References Object::_Create(), CONTAINER_FIELD_NUM_SLOTS, CONTAINER_FIELD_SLOT_1, ItemTemplate::ContainerSlots, ObjectGuid::Empty, Object::GetGUID(), ITEM_FIELD_CONTAINED, ITEM_FIELD_DURABILITY, ITEM_FIELD_MAXDURABILITY, ITEM_FIELD_OWNER, ITEM_FIELD_STACK_COUNT, m_bagslot, MAX_BAG_SIZE, ItemTemplate::MaxDurability, Object::SetEntry(), Object::SetGuidValue(), Object::SetObjectScale(), Object::SetUInt32Value(), and sObjectMgr.
|
overridevirtual |
Reimplemented from Item.
References Item::DeleteFromDB(), m_bagslot, and MAX_BAG_SIZE.
|
inline |
References CONTAINER_FIELD_NUM_SLOTS, and Object::GetUInt32Value().
Referenced by AddToWorld(), BuildCreateUpdateBlockForPlayer(), Player::CanStoreItem_InBag(), GetFreeSlots(), GetItemByPos(), GetItemCount(), GetItemCountWithLimitCategory(), GetSlotByItemGUID(), IsEmpty(), RemoveFromWorld(), reset_commandscript::ResetItemsInBags(), reset_commandscript::ResetItemsInBank(), and Player::SwapItem().
|
overridevirtual |
Reimplemented from Object.
References Item::GetDebugInfo().
uint32 Bag::GetFreeSlots | ( | ) | const |
References GetBagSize(), and m_bagslot.
References GetBagSize(), and m_bagslot.
Referenced by reset_commandscript::ResetItemsInBags(), reset_commandscript::ResetItemsInBank(), and Player::SwapItem().
References _Socket::Color, ItemTemplate::GemProperties, GetBagSize(), Item::GetCount(), Object::GetEntry(), Item::GetGemCountWithID(), Item::GetTemplate(), m_bagslot, and ItemTemplate::Socket.
References GetBagSize(), Item::GetCount(), and m_bagslot.
uint8 Bag::GetSlotByItemGUID | ( | ObjectGuid | guid | ) | const |
References GetBagSize(), Object::GetGUID(), m_bagslot, and NULL_SLOT.
bool Bag::IsEmpty | ( | ) | const |
References GetBagSize(), and m_bagslot.
Referenced by Player::SwapItem().
|
overridevirtual |
Reimplemented from Item.
References CONTAINER_FIELD_NUM_SLOTS, CONTAINER_FIELD_SLOT_1, ItemTemplate::ContainerSlots, ObjectGuid::Empty, Item::GetTemplate(), Item::LoadFromDB(), m_bagslot, MAX_BAG_SIZE, Object::SetGuidValue(), and Object::SetUInt32Value().
|
overridevirtual |
Reimplemented from Object.
References GetBagSize(), m_bagslot, and Object::RemoveFromWorld().
void Bag::RemoveItem | ( | uint8 | slot, |
bool | update | ||
) |
References ASSERT, CONTAINER_FIELD_SLOT_1, ObjectGuid::Empty, m_bagslot, MAX_BAG_SIZE, Item::SetContainer(), and Object::SetGuidValue().
Referenced by Player::SwapItem().
|
overridevirtual |
References ASSERT, CONTAINER_FIELD_SLOT_1, Object::GetGUID(), Item::GetOwnerGUID(), ITEM_FIELD_CONTAINED, ITEM_FIELD_OWNER, m_bagslot, MAX_BAG_SIZE, Item::SetContainer(), Object::SetGuidValue(), and Item::SetSlot().
Referenced by Player::_StoreItem(), and Player::SwapItem().
|
protected |