[9702] Drop now redundent item_text table.

* In beggining bad news: at 3.3.3 switch has been forgoted item_instance.data field chnage.
  In result items with texts (mail copy in to inventory, some other) lost text content.
* That why in current commit item_text droped without convertion. In result all itesm with texts
  will lost text. Sorry for this as i think small porblem :(
* Now text stored in item itself.
This commit is contained in:
VladimirMangos 2010-04-09 01:50:18 +04:00
parent 53486545b5
commit 24f2d03485
17 changed files with 85 additions and 152 deletions

View file

@ -1120,18 +1120,18 @@ void Guild::LoadGuildBankFromDB()
delete result;
// data needs to be at first place for Item::LoadFromDB
// 0 1 2 3 4
result = CharacterDatabase.PQuery("SELECT data, TabId, SlotId, item_guid, item_entry FROM guild_bank_item JOIN item_instance ON item_guid = guid WHERE guildid='%u' ORDER BY TabId", m_Id);
// 0 1 2 3 4 5
result = CharacterDatabase.PQuery("SELECT data, text, TabId, SlotId, item_guid, item_entry FROM guild_bank_item JOIN item_instance ON item_guid = guid WHERE guildid='%u' ORDER BY TabId", m_Id);
if (!result)
return;
do
{
Field *fields = result->Fetch();
uint8 TabId = fields[1].GetUInt8();
uint8 SlotId = fields[2].GetUInt8();
uint32 ItemGuid = fields[3].GetUInt32();
uint32 ItemEntry = fields[4].GetUInt32();
uint8 TabId = fields[2].GetUInt8();
uint8 SlotId = fields[3].GetUInt8();
uint32 ItemGuid = fields[4].GetUInt32();
uint32 ItemEntry = fields[5].GetUInt32();
if (TabId >= m_PurchasedTabs || TabId >= GUILD_BANK_MAX_TABS)
{