public static IEnemy Get(EnemyType type) { IEnemy returnInstance = null; switch (type) { case EnemyType.Balloom: returnInstance = GlobalFactory <IEnemy> .Get(typeof(Balloom)); break; case EnemyType.Doll: returnInstance = GlobalFactory <IEnemy> .Get(typeof(Doll)); break; case EnemyType.Oneal: returnInstance = GlobalFactory <IEnemy> .Get(typeof(Oneal)); break; case EnemyType.Minvo: returnInstance = GlobalFactory <IEnemy> .Get(typeof(Minvo)); break; case EnemyType.Ovapi: returnInstance = GlobalFactory <IEnemy> .Get(typeof(Ovapi)); break; case EnemyType.Kondoria: returnInstance = GlobalFactory <IEnemy> .Get(typeof(Kondoria)); break; case EnemyType.Pass: returnInstance = GlobalFactory <IEnemy> .Get(typeof(Pass)); break; case EnemyType.Pontan: returnInstance = GlobalFactory <IEnemy> .Get(typeof(Pontan)); break; default: break; } return(returnInstance); }
public static IPowerup Get(PowerUpType type) { IPowerup toReturn = null; switch (type) { case PowerUpType.PW_SPEED: toReturn = GlobalFactory <SpeedPow> .Get(typeof(SpeedPow)); break; case PowerUpType.PW_BOMB: toReturn = GlobalFactory <BombPow> .Get(typeof(BombPow)); break; case PowerUpType.PW_BOMB_PASS: break; case PowerUpType.PW_FLAME: break; case PowerUpType.PW_FLAME_PASS: break; case PowerUpType.PW_WALL_PASS: toReturn = GlobalFactory <WallPass> .Get(typeof(WallPass)); break; case PowerUpType.PW_MYSTERY: toReturn = GlobalFactory <Mystery> .Get(typeof(Mystery)); break; case PowerUpType.PW_DETONATOR: break; default: break; } return(toReturn); }