Project::OSiRiON - Git repositories
Project::OSiRiON
News . About . Screenshots . Downloads . Forum . Wiki . Tracker . Git
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/game/base/game.cc7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/game/base/game.cc b/src/game/base/game.cc
index 438154d..ad6a28c 100644
--- a/src/game/base/game.cc
+++ b/src/game/base/game.cc
@@ -1156,6 +1156,12 @@ void Game::func_drop(core::Player *player, const std::string &args)
if (labelstr.compare("mine") == 0) {
// drop a mine
+ // cannot drop items while jumping
+ if ((ship->state() == core::Entity::Impulse) || (ship->state() == core::Entity::ImpulseInitiate)) {
+ player->send("^WCan not drop mines on impulse speed");
+ return;
+ }
+
// find a mine in inventory
const Weapon *weapon = 0;
core::Item *item = 0;
@@ -1194,6 +1200,7 @@ void Game::func_drop(core::Player *player, const std::string &args)
if (item->amount() == 0) {
ship->inventory()->erase(item->id());
}
+ ship->inventory()->set_dirty();
}
}