Project::OSiRiON - Git repositories
Project::OSiRiON
News . About . Screenshots . Downloads . Forum . Wiki . Tracker . Git
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'src/game/base/ship.cc')
-rw-r--r--src/game/base/ship.cc22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/game/base/ship.cc b/src/game/base/ship.cc
index 0fdfd3f..574d66c 100644
--- a/src/game/base/ship.cc
+++ b/src/game/base/ship.cc
@@ -73,7 +73,7 @@ void Ship::impulse()
}
entity_eventstate = core::Entity::ImpulseInitiate;
- if (Base::instance()->g_devel->value()) {
+ if (Base::g_devel->value()) {
entity_timer = 0;
} else {
entity_timer = 3;
@@ -88,7 +88,7 @@ void Ship::impulse()
void Ship::jump(std::string const &args)
{
// devel mode provides instant jump access to arbitrary systems
- if (Base::instance()->g_devel->value() && (args.size())) {
+ if (Base::g_devel->value() && (args.size())) {
core::Zone *jumptargetzone = 0;
std::string target;
@@ -130,7 +130,7 @@ void Ship::jump(std::string const &args)
return;
} else {
- if (!jumpdrive() && !Base::instance()->g_devel->value()) {
+ if (!jumpdrive() && !Base::g_devel->value()) {
core::server()->send(owner(), "This ship is not equiped with a hyperspace drive!");
return;
@@ -150,7 +150,7 @@ void Ship::jump(std::string const &args)
}
entity_eventstate = core::Entity::JumpInitiate;
- if (Base::instance()->g_devel->value()) {
+ if (Base::g_devel->value()) {
entity_timer = 0;
} else {
entity_timer = 8;
@@ -179,7 +179,7 @@ JumpPoint * Ship::find_closest_jumppoint()
}
if (jumppoint && jumppoint->target()) {
- if (Base::instance()->g_jumppointrange->value() < d) {
+ if (Base::g_jumppointrange->value() < d) {
core::server()->send(owner(), "Jumppoint out of range!");
return 0;
} else {
@@ -274,8 +274,8 @@ void Ship::frame(float seconds)
entity_timer -= 1.0f;
if (entity_timer <= 0) {
- actual_maxspeed = Base::instance()->g_impulsespeed->value();
- actual_acceleration = Base::instance()->g_impulseacceleration->value();
+ actual_maxspeed = Base::g_impulsespeed->value();
+ actual_acceleration = Base::g_impulseacceleration->value();
entity_eventstate = core::Entity::Impulse;
entity_timer = 0;
entity_dirty = true;
@@ -301,8 +301,8 @@ void Ship::frame(float seconds)
math::clamp(target_roll, -1.0f, 1.0f);
math::clamp(target_direction, -1.0f, 1.0f);
target_afterburner = 0.0f;
- actual_maxspeed = Base::instance()->g_impulsespeed->value();
- actual_acceleration = Base::instance()->g_impulseacceleration->value();
+ actual_maxspeed = Base::g_impulsespeed->value();
+ actual_acceleration = Base::g_impulseacceleration->value();
actual_turnspeed *= 0.5;
} else if (entity_eventstate == core::Entity::Normal) {
@@ -315,7 +315,7 @@ void Ship::frame(float seconds)
math::clamp(target_afterburner, -1.0f, 1.0f);
if (speed() > actual_maxspeed * 1.15f) {
- actual_acceleration = Base::instance()->g_impulseacceleration->value();
+ actual_acceleration = Base::g_impulseacceleration->value();
actual_turnspeed *= 0.5;
}
@@ -443,7 +443,7 @@ void Ship::frame(float seconds)
}
if (fabs(current_target_strafe) > MIN_DELTA) {
- entity_location += entity_axis.left() * (current_target_strafe * Base::instance()->g_strafespeed->value());
+ entity_location += entity_axis.left() * (current_target_strafe * Base::g_strafespeed->value());
}
entity_movement = target_thrust;