//--------------------------------------- Entity* MageGame::SpawnEntity( const std::string& name, const Vec2f& position ) { EntityDefinition* entityDef = EntityDefinition::GetDefinitionByName( name ); if ( entityDef ) { Entity& entity = entityDef->Create( position ); entity.SetGameMap( &mGameMap ); return &entity; } ConsolePrintf( CONSOLE_ERROR, "Failed to spawn Entity: No Entity found '%s'\n", name.c_str() ); return NULL; }