void CWorldSA::Add ( CEntity * pEntity, eDebugCaller CallerId ) { DEBUG_TRACE("VOID CWorldSA::Add ( CEntity * pEntity )"); CEntitySA* pEntitySA = dynamic_cast < CEntitySA* > ( pEntity ); if ( pEntitySA ) { CEntitySAInterface * pInterface = pEntitySA->GetInterface(); if ( (DWORD)pInterface->vtbl == VTBL_CPlaceable ) { SString strMessage ( "Caller: %i ", CallerId ); LogEvent ( 506, "CWorld::Add ( CEntity * ) Crash", "", strMessage ); } DWORD dwEntity = (DWORD) pEntitySA->GetInterface(); DWORD dwFunction = FUNC_Add; _asm { push dwEntity call dwFunction add esp, 4 } } }