diff options
author | Stijn Buys <ingar@osirion.org> | 2010-10-20 17:38:55 +0000 |
---|---|---|
committer | Stijn Buys <ingar@osirion.org> | 2010-10-20 17:38:55 +0000 |
commit | 08f0d0fb6a57f9c398bc03ed9a3cc9537a1f3e18 (patch) | |
tree | b7d67889e895b1fe5d7f70aab7b4296d77ff7e89 /src/game/base/jumppoint.cc | |
parent | 21e6267e3f998a467ca3b5ec225e6d03653aed97 (diff) |
docking functions cleanup, jumpgates work again
Diffstat (limited to 'src/game/base/jumppoint.cc')
-rw-r--r-- | src/game/base/jumppoint.cc | 16 |
1 files changed, 2 insertions, 14 deletions
diff --git a/src/game/base/jumppoint.cc b/src/game/base/jumppoint.cc index ae66262..283b607 100644 --- a/src/game/base/jumppoint.cc +++ b/src/game/base/jumppoint.cc @@ -105,20 +105,8 @@ void JumpGate::validate() } } -void JumpGate::dock(core::Entity *entity) +void JumpGate::func_dock(Ship *ship) { - if (entity->moduletype() != ship_enttype) - return; - - Ship * ship = static_cast<Ship *>(entity); - - if (math::distance(location(), ship->location()) > radius() + ship->radius()) { - if (ship->owner()) - ship->owner()->send("Jumpgate out of range"); - return; - } - - con_debug << name() << " received docking request from " << entity->name() << std::endl; if (target()) { if (activated()) { if (ship->owner()) @@ -144,7 +132,7 @@ void JumpGate::dock(core::Entity *entity) void JumpGate::activate() { - jumpgate_timer = 10.0f; + jumpgate_timer = jump_timer_delay; set_state(core::Entity::Normal); } |