void InitializeMonster(MonsterType m) { if (m == MonsterType.Empty) { return; } if (m == MonsterType.Slime) { Slime temp = new Slime(); temp.Start(); temp.Setmtype(MonsterType.Slime); Monster tempMonster = temp; magic.addMonster(tempMonster); } if (m == MonsterType.DoubleSwordMan) { DoubleSwordMan temp = new DoubleSwordMan(); temp.Start(); temp.Setmtype(MonsterType.DoubleSwordMan); Monster tempMonster = temp; magic.addMonster(tempMonster); } if (m == MonsterType.BigSpider) { BigSpider temp = new BigSpider(); temp.Start(); temp.Setmtype(MonsterType.BigSpider); Monster tempMonster = temp; magic.addMonster(tempMonster); } if (m == MonsterType.Vampire) { Vampire temp = new Vampire(); temp.Start(); temp.Setmtype(MonsterType.Vampire); Monster tempMonster = temp; magic.addMonster(tempMonster); } if (m == MonsterType.Boss_TurnMan) { Boss_TurnMan temp = new Boss_TurnMan(); temp.Start(); temp.Setmtype(MonsterType.Boss_TurnMan); Monster tempMonster = temp; magic.addMonster(tempMonster); } }
public override void Realize() { if (realizedCreature != null) { return; } switch (creatureTemplate.TopAncestor().type) { case CreatureTemplate.Type.Slugcat: realizedCreature = new Player(this, world); break; case CreatureTemplate.Type.LizardTemplate: realizedCreature = new Lizard(this, world); break; case CreatureTemplate.Type.Fly: realizedCreature = new Fly(this, world); break; case CreatureTemplate.Type.Leech: realizedCreature = new Leech(this, world); break; case CreatureTemplate.Type.Snail: realizedCreature = new Snail(this, world); break; case CreatureTemplate.Type.Vulture: realizedCreature = new Vulture(this, world); break; case CreatureTemplate.Type.GarbageWorm: GarbageWormAI.MoveAbstractCreatureToGarbage(this, Room); realizedCreature = new GarbageWorm(this, world); break; case CreatureTemplate.Type.LanternMouse: realizedCreature = new LanternMouse(this, world); break; case CreatureTemplate.Type.CicadaA: realizedCreature = new Cicada(this, world, creatureTemplate.type == CreatureTemplate.Type.CicadaA); break; case CreatureTemplate.Type.Spider: realizedCreature = new Spider(this, world); break; case CreatureTemplate.Type.JetFish: realizedCreature = new JetFish(this, world); break; case (CreatureTemplate.Type)patch_CreatureTemplate.Type.SeaDrake: realizedCreature = new SeaDrake(this, world); break; case CreatureTemplate.Type.BigEel: realizedCreature = new BigEel(this, world); break; case CreatureTemplate.Type.Deer: realizedCreature = new Deer(this, world); break; case (CreatureTemplate.Type)patch_CreatureTemplate.Type.WalkerBeast: realizedCreature = new WalkerBeast(this, world); break; case CreatureTemplate.Type.TubeWorm: realizedCreature = new TubeWorm(this, world); break; case CreatureTemplate.Type.DaddyLongLegs: realizedCreature = new DaddyLongLegs(this, world); break; case CreatureTemplate.Type.TentaclePlant: if (creatureTemplate.type == CreatureTemplate.Type.TentaclePlant) { realizedCreature = new TentaclePlant(this, world); } else { realizedCreature = new PoleMimic(this, world); } break; case CreatureTemplate.Type.MirosBird: realizedCreature = new MirosBird(this, world); break; case CreatureTemplate.Type.TempleGuard: realizedCreature = new TempleGuard(this, world); break; case CreatureTemplate.Type.Centipede: case CreatureTemplate.Type.RedCentipede: case CreatureTemplate.Type.Centiwing: case CreatureTemplate.Type.SmallCentipede: realizedCreature = new Centipede(this, world); break; case CreatureTemplate.Type.Scavenger: realizedCreature = new Scavenger(this, world); break; case CreatureTemplate.Type.Overseer: realizedCreature = new Overseer(this, world); break; case CreatureTemplate.Type.VultureGrub: if (creatureTemplate.type == CreatureTemplate.Type.VultureGrub) { realizedCreature = new VultureGrub(this, world); } else if (creatureTemplate.type == CreatureTemplate.Type.Hazer) { realizedCreature = new Hazer(this, world); } break; case CreatureTemplate.Type.EggBug: realizedCreature = new EggBug(this, world); break; case CreatureTemplate.Type.BigSpider: case CreatureTemplate.Type.SpitterSpider: realizedCreature = new BigSpider(this, world); break; case CreatureTemplate.Type.BigNeedleWorm: if (creatureTemplate.type == CreatureTemplate.Type.SmallNeedleWorm) { realizedCreature = new SmallNeedleWorm(this, world); } else { realizedCreature = new BigNeedleWorm(this, world); } break; case CreatureTemplate.Type.DropBug: realizedCreature = new DropBug(this, world); break; } InitiateAI(); for (int i = 0; i < stuckObjects.Count; i++) { if (stuckObjects[i].A.realizedObject == null) { stuckObjects[i].A.Realize(); } if (stuckObjects[i].B.realizedObject == null) { stuckObjects[i].B.Realize(); } } }