diff options
author | Stijn Buys <ingar@osirion.org> | 2013-11-09 20:36:48 +0000 |
---|---|---|
committer | Stijn Buys <ingar@osirion.org> | 2013-11-09 20:36:48 +0000 |
commit | 553c7b9bf9b477544f28123eaeb2ea5714495086 (patch) | |
tree | b020a1795e788ac97e9825ae9fc7863bebba744f /src/game/base/patrol.cc | |
parent | 2218c7094ad6dc40b200274ebffdc9fb4c1a8e0c (diff) |
Moved profile definition from NPC to Patrol.
Diffstat (limited to 'src/game/base/patrol.cc')
-rw-r--r-- | src/game/base/patrol.cc | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/game/base/patrol.cc b/src/game/base/patrol.cc index f3cfa07..fbe02df 100644 --- a/src/game/base/patrol.cc +++ b/src/game/base/patrol.cc @@ -62,7 +62,7 @@ Patrol::Patrol() : core::Entity() patrol_faction = 0; - patrol_profile = NPC::ProfilePatrol; + patrol_profile = ProfilePatrol; patrol_waypoint_current == patrol_waypoints.end(); @@ -98,7 +98,7 @@ Patrol::~Patrol() patrol_members.clear(); } -void Patrol::set_profile(const NPC::Profile profile) +void Patrol::set_profile(const Profile profile) { patrol_profile = profile; } @@ -302,7 +302,8 @@ void Patrol::frame(const unsigned long elapsed) for (size_t i = 0; i < nbships; i++) { // add NPC - NPC *npc = new NPC(patrol_profile, npctype->shipmodel()); + NPC *npc = new NPC(npctype->shipmodel()); + npc->set_mood(NPC::MoodFormation); // set NPC name if (npctype->name().size()) { |