mirror of
https://github.com/mangosfour/server.git
synced 2025-12-13 13:37:05 +00:00
[10644] Remove wrong check preventing lootable itesm have at-use spell casts.
But note: like at use spells cast at loot open not implemnted yet. Also fixed typo in ITEM_DYNFLAG_READABLE.
This commit is contained in:
parent
23c920ca4b
commit
b09838fe3b
4 changed files with 4 additions and 17 deletions
|
|
@ -215,7 +215,7 @@ enum ItemDynFlags
|
||||||
ITEM_DYNFLAG_UNK6 = 0x00000040, // ? old note: usable
|
ITEM_DYNFLAG_UNK6 = 0x00000040, // ? old note: usable
|
||||||
ITEM_DYNFLAG_UNK7 = 0x00000080,
|
ITEM_DYNFLAG_UNK7 = 0x00000080,
|
||||||
ITEM_DYNFLAG_UNK8 = 0x00000100,
|
ITEM_DYNFLAG_UNK8 = 0x00000100,
|
||||||
ITEM_DYNFLAG_READBLE = 0x00000200, // can be open for read, it or item proto pagetText make show "Right click to read"
|
ITEM_DYNFLAG_READABLE = 0x00000200, // can be open for read, it or item proto pagetText make show "Right click to read"
|
||||||
ITEM_DYNFLAG_UNK10 = 0x00000400,
|
ITEM_DYNFLAG_UNK10 = 0x00000400,
|
||||||
ITEM_DYNFLAG_UNK11 = 0x00000800,
|
ITEM_DYNFLAG_UNK11 = 0x00000800,
|
||||||
ITEM_DYNFLAG_UNK12 = 0x00001000,
|
ITEM_DYNFLAG_UNK12 = 0x00001000,
|
||||||
|
|
|
||||||
|
|
@ -716,7 +716,7 @@ void WorldSession::HandleMailCreateTextItem(WorldPacket & recv_data )
|
||||||
bodyItem->SetText(m->body);
|
bodyItem->SetText(m->body);
|
||||||
|
|
||||||
bodyItem->SetGuidValue(ITEM_FIELD_CREATOR, ObjectGuid(HIGHGUID_PLAYER, m->sender));
|
bodyItem->SetGuidValue(ITEM_FIELD_CREATOR, ObjectGuid(HIGHGUID_PLAYER, m->sender));
|
||||||
bodyItem->SetFlag(ITEM_FIELD_FLAGS, ITEM_DYNFLAG_READBLE | ITEM_DYNFLAG_UNK15 | ITEM_DYNFLAG_UNK16);
|
bodyItem->SetFlag(ITEM_FIELD_FLAGS, ITEM_DYNFLAG_READABLE | ITEM_DYNFLAG_UNK15 | ITEM_DYNFLAG_UNK16);
|
||||||
|
|
||||||
|
|
||||||
DETAIL_LOG("HandleMailCreateTextItem mailid=%u", mailId);
|
DETAIL_LOG("HandleMailCreateTextItem mailid=%u", mailId);
|
||||||
|
|
|
||||||
|
|
@ -2014,7 +2014,7 @@ void ObjectMgr::LoadItemPrototypes()
|
||||||
if(proto->Flags & ITEM_FLAG_LOOTABLE)
|
if(proto->Flags & ITEM_FLAG_LOOTABLE)
|
||||||
{
|
{
|
||||||
sLog.outErrorDb("Item container (Entry: %u) has not allowed for containers flag ITEM_FLAG_LOOTABLE (%u), flag removed.",i,ITEM_FLAG_LOOTABLE);
|
sLog.outErrorDb("Item container (Entry: %u) has not allowed for containers flag ITEM_FLAG_LOOTABLE (%u), flag removed.",i,ITEM_FLAG_LOOTABLE);
|
||||||
const_cast<ItemPrototype*>(proto)->Flags |= ITEM_FLAG_LOOTABLE;
|
const_cast<ItemPrototype*>(proto)->Flags &= ~ITEM_FLAG_LOOTABLE;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -2098,12 +2098,6 @@ void ObjectMgr::LoadItemPrototypes()
|
||||||
const_cast<ItemPrototype*>(proto)->Spells[1].SpellId = 0;
|
const_cast<ItemPrototype*>(proto)->Spells[1].SpellId = 0;
|
||||||
const_cast<ItemPrototype*>(proto)->Spells[1].SpellTrigger = ITEM_SPELLTRIGGER_ON_USE;
|
const_cast<ItemPrototype*>(proto)->Spells[1].SpellTrigger = ITEM_SPELLTRIGGER_ON_USE;
|
||||||
}
|
}
|
||||||
// ok case for spell_1 (and other)
|
|
||||||
else if(proto->Flags & ITEM_FLAG_LOOTABLE)
|
|
||||||
{
|
|
||||||
sLog.outErrorDb("Item container (Entry: %u) has not allowed for spell learning items flag ITEM_FLAG_LOOTABLE (%u), flag removed.",i,ITEM_FLAG_LOOTABLE);
|
|
||||||
const_cast<ItemPrototype*>(proto)->Flags |= ITEM_FLAG_LOOTABLE;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// spell_3*,spell_4*,spell_5* is empty
|
// spell_3*,spell_4*,spell_5* is empty
|
||||||
|
|
@ -2154,13 +2148,6 @@ void ObjectMgr::LoadItemPrototypes()
|
||||||
sLog.outErrorDb("Item (Entry: %u) has broken spell in spellid_%d (%u)",i,j+1,proto->Spells[j].SpellId);
|
sLog.outErrorDb("Item (Entry: %u) has broken spell in spellid_%d (%u)",i,j+1,proto->Spells[j].SpellId);
|
||||||
const_cast<ItemPrototype*>(proto)->Spells[j].SpellId = 0;
|
const_cast<ItemPrototype*>(proto)->Spells[j].SpellId = 0;
|
||||||
}
|
}
|
||||||
// ok cast at use case
|
|
||||||
else if((proto->Spells[j].SpellTrigger == ITEM_SPELLTRIGGER_ON_USE || proto->Spells[j].SpellTrigger == ITEM_SPELLTRIGGER_ON_NO_DELAY_USE) &&
|
|
||||||
proto->Flags & ITEM_FLAG_LOOTABLE)
|
|
||||||
{
|
|
||||||
sLog.outErrorDb("Item container (Entry: %u) has not allowed for spell casting at use items flag ITEM_FLAG_LOOTABLE (%u), flag removed.",i,ITEM_FLAG_LOOTABLE);
|
|
||||||
const_cast<ItemPrototype*>(proto)->Flags |= ITEM_FLAG_LOOTABLE;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#ifndef __REVISION_NR_H__
|
#ifndef __REVISION_NR_H__
|
||||||
#define __REVISION_NR_H__
|
#define __REVISION_NR_H__
|
||||||
#define REVISION_NR "10643"
|
#define REVISION_NR "10644"
|
||||||
#endif // __REVISION_NR_H__
|
#endif // __REVISION_NR_H__
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue