From 273c601a94464bef2161b9c3a29ea3cf901340e9 Mon Sep 17 00:00:00 2001 From: Paweł Redman Date: Sat, 16 Dec 2017 20:17:57 +0000 Subject: Rename aliens to spiders and humans to soldiers. --- src/game/game.cpp | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) (limited to 'src/game/game.cpp') diff --git a/src/game/game.cpp b/src/game/game.cpp index 35d66ec..51dca09 100644 --- a/src/game/game.cpp +++ b/src/game/game.cpp @@ -63,25 +63,25 @@ void entity_t::sleep(void) void state_t::start(void) { - human_t *human; - alien_t *alien; + unit_soldier_t *soldier; + unit_spider_t *spider; world.generator = worldgen; world.generator_data = (void*)this; - human = new human_t(this); - human->place(&world, v2f_t(0.5, 0.5)); - human = new human_t(this); - human->place(&world, v2f_t(1.5, 0.5)); - human = new human_t(this); - human->place(&world, v2f_t(2.5, 0.5)); + soldier = new unit_soldier_t(this); + soldier->place(&world, v2f_t(0.5, 0.5)); + soldier = new unit_soldier_t(this); + soldier->place(&world, v2f_t(1.5, 0.5)); + soldier = new unit_soldier_t(this); + soldier->place(&world, v2f_t(2.5, 0.5)); - alien = new alien_t(this); - alien->place(&world, v2f_t(15.5, -2.5)); - alien = new alien_t(this); - alien->place(&world, v2f_t(14.5, -2.5)); - alien = new alien_t(this); - alien->place(&world, v2f_t(13.5, -2.5)); + spider = new unit_spider_t(this); + spider->place(&world, v2f_t(15.5, -2.5)); + spider = new unit_spider_t(this); + spider->place(&world, v2f_t(14.5, -2.5)); + spider = new unit_spider_t(this); + spider->place(&world, v2f_t(13.5, -2.5)); } void state_t::stop(void) @@ -103,7 +103,7 @@ void state_t::select(rectf_t x) unit = (unit_t*)ent; - if (unit->type != unit_t::UNIT_HUMAN) + if (!unit->controllable) continue; if (!unit->dead && unit->selected != old_cookie) -- cgit