mirror of
https://github.com/edubart/otclient.git
synced 2025-10-15 03:54:54 +02:00
OTB loading fix
This commit is contained in:
@@ -267,7 +267,7 @@ void ThingTypeManager::parseItemType(uint16 id, TiXmlElement* elem)
|
|||||||
void ThingTypeManager::addItemType(const ItemTypePtr& itemType)
|
void ThingTypeManager::addItemType(const ItemTypePtr& itemType)
|
||||||
{
|
{
|
||||||
uint16 id = itemType->getServerId();
|
uint16 id = itemType->getServerId();
|
||||||
if(id > m_itemTypes.size())
|
if(id >= m_itemTypes.size())
|
||||||
m_itemTypes.resize(id + 1, m_nullItemType);
|
m_itemTypes.resize(id + 1, m_nullItemType);
|
||||||
m_itemTypes[id] = itemType;
|
m_itemTypes[id] = itemType;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user