diff options
author | Stijn Buys <ingar@osirion.org> | 2014-11-22 21:55:57 +0000 |
---|---|---|
committer | Stijn Buys <ingar@osirion.org> | 2014-11-22 21:55:57 +0000 |
commit | 667a4741169bb0c2a6273434efb0ed37460b2cf0 (patch) | |
tree | 3a1ee66d5a930055c667e3a6e4591c67f74249fc /src | |
parent | 67727f0ad5b5cd9902b6b5e6369eba16cc48cf9e (diff) |
Send a message when adding a wingman.
Diffstat (limited to 'src')
-rw-r--r-- | src/game/base/game.cc | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/game/base/game.cc b/src/game/base/game.cc index 23ea90c..fda1d70 100644 --- a/src/game/base/game.cc +++ b/src/game/base/game.cc @@ -687,9 +687,7 @@ void Game::func_wingmen(core::Player *player, const std::string &args) return; } - if (player->control()->moduletype() != ship_enttype) - return; - + assert(player->control()->moduletype() == ship_enttype); Ship * ship = static_cast<Ship *>(player->control()); std::istringstream is(args); @@ -699,7 +697,9 @@ void Game::func_wingmen(core::Player *player, const std::string &args) aux::to_label(str); if (str.compare("add") == 0) { - NPC::add_wingman(ship); + if (NPC::add_wingman(ship)) { + player->send("Wingman standing by!"); + } } } |