OTB loading fix

This commit is contained in:
Samuel 2013-03-01 15:30:50 +01:00
parent 50b6cc69e1
commit 884102833e
1 changed files with 1 additions and 1 deletions

View File

@ -267,7 +267,7 @@ void ThingTypeManager::parseItemType(uint16 id, TiXmlElement* elem)
void ThingTypeManager::addItemType(const ItemTypePtr& itemType)
{
uint16 id = itemType->getServerId();
if(id > m_itemTypes.size())
if(id >= m_itemTypes.size())
m_itemTypes.resize(id + 1, m_nullItemType);
m_itemTypes[id] = itemType;
}