#include "precompile.h" #include "entityfactory.h" #include "obstacle.h" #include "roomobstacle.h" #include "building.h" #include "loot.h" #include "bullet.h" #include "android.h" #include "player.h" void EntityFactory::Init() { } void EntityFactory::UnInit() { } Obstacle* EntityFactory::MakeObstacle(int entity_uniid) { Obstacle* obstacle = new Obstacle(); obstacle->entity_uniid_ = entity_uniid; obstacle->entity_type_ = ET_Obstacle; obstacle->entity_subtype_ = EST_PermanentObstacle; return obstacle; } RoomObstacle* EntityFactory::MakeRoomObstacle(int entity_uniid) { RoomObstacle* obstacle = new RoomObstacle(); obstacle->entity_uniid_ = entity_uniid; obstacle->entity_type_ = ET_Obstacle; obstacle->entity_subtype_ = EST_RoomObstacle; return obstacle; } Building* EntityFactory::MakeBuilding(int entity_uniid) { Building* building = new Building(); building->entity_uniid_ = entity_uniid; building->entity_type_ = ET_Building; return building; } Loot* EntityFactory::MakeLoot(int entity_uniid) { Loot* loot = new Loot(); loot->entity_uniid_ = entity_uniid; loot->entity_type_ = ET_Loot; return loot; } Bullet* EntityFactory::MakeBullet(int entity_uniid) { Bullet* bullet = new Bullet(); bullet->entity_uniid_ = entity_uniid; bullet->entity_type_ = ET_Bullet; return bullet; } Android* EntityFactory::MakeAndroid(int entity_uniid) { Android* hum = new Android(); hum->entity_uniid_ = entity_uniid; hum->entity_type_ = ET_Player; hum->entity_subtype_ = EST_Android; return hum; } Player* EntityFactory::MakePlayer(int entity_uniid) { Player* hum = new Player(); hum->entity_uniid_ = entity_uniid; hum->entity_type_ = ET_Player; hum->entity_subtype_ = EST_Player; return hum; }