| 78 | } |
| 79 | |
| 80 | void CGameWorld::InsertEntity(CEntity *pEnt) |
| 81 | { |
| 82 | #ifdef CONF_DEBUG |
| 83 | for(CEntity *pCur = m_apFirstEntityTypes[pEnt->m_ObjType]; pCur; pCur = pCur->m_pNextTypeEntity) |
| 84 | dbg_assert(pCur != pEnt, "err"); |
| 85 | #endif |
| 86 | |
| 87 | // insert it |
| 88 | if(m_apFirstEntityTypes[pEnt->m_ObjType]) |
| 89 | m_apFirstEntityTypes[pEnt->m_ObjType]->m_pPrevTypeEntity = pEnt; |
| 90 | pEnt->m_pNextTypeEntity = m_apFirstEntityTypes[pEnt->m_ObjType]; |
| 91 | pEnt->m_pPrevTypeEntity = nullptr; |
| 92 | m_apFirstEntityTypes[pEnt->m_ObjType] = pEnt; |
| 93 | } |
| 94 | |
| 95 | void CGameWorld::RemoveEntity(CEntity *pEnt) |
| 96 | { |
no outgoing calls