summaryrefslogtreecommitdiffhomepage
path: root/Stars45/StarshipAI.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Stars45/StarshipAI.cpp')
-rw-r--r--Stars45/StarshipAI.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/Stars45/StarshipAI.cpp b/Stars45/StarshipAI.cpp
index 3057f1d..5a32391 100644
--- a/Stars45/StarshipAI.cpp
+++ b/Stars45/StarshipAI.cpp
@@ -66,7 +66,7 @@ StarshipAI::StarshipAI(SimObject* s)
tactical = new(__FILE__,__LINE__) StarshipTacticalAI(this);
}
- sub_select_time = Game::GetInstance()->GameTime() + (DWORD) Random(0, 2000);
+ sub_select_time = Game::GetInstance()->GetClock()->GameTime() + (DWORD) Random(0, 2000);
point_defense_time = sub_select_time;
}
@@ -639,7 +639,7 @@ StarshipAI::FireControl()
System*
StarshipAI::SelectSubtarget()
{
- if (Game::GetInstance()->GameTime() - sub_select_time < 2345)
+ if (Game::GetInstance()->GetClock()->GameTime() - sub_select_time < 2345)
return subtarget;
subtarget = 0;
@@ -656,7 +656,7 @@ StarshipAI::SelectSubtarget()
double dist = 50e3;
Point svec = ship->Location() - tgt_ship->Location();
- sub_select_time = Game::GetInstance()->GameTime();
+ sub_select_time = Game::GetInstance()->GetClock()->GameTime();
// first pass: turrets
ListIter<WeaponGroup> g_iter = tgt_ship->Weapons();
@@ -727,7 +727,7 @@ StarshipAI::SelectSubtarget()
bool
StarshipAI::AssessTargetPointDefense()
{
- if (Game::GetInstance()->GameTime() - point_defense_time < 3500)
+ if (Game::GetInstance()->GetClock()->GameTime() - point_defense_time < 3500)
return tgt_point_defense;
tgt_point_defense = false;
@@ -743,7 +743,7 @@ StarshipAI::AssessTargetPointDefense()
Weapon* subtgt = 0;
Point svec = ship->Location() - tgt_ship->Location();
- point_defense_time = Game::GetInstance()->GameTime();
+ point_defense_time = Game::GetInstance()->GetClock()->GameTime();
// first pass: turrets
ListIter<WeaponGroup> g_iter = tgt_ship->Weapons();