5 #include <boost/assign/std/vector.hpp>
18 using namespace Radar;
43 currentTargetMarkerSize(0.0),
44 lastAnimationTime(0.0)
46 using namespace boost::assign;
47 explodeSequence += 0.0, 0.0001, 0.0009, 0.0036, 0.0100, 0.0225, 0.0441, 0.0784, 0.1296, 0.2025, 0.3025, 0.4356, 0.6084, 0.8281, 1.0, 0.8713, 0.7836, 0.7465, 0.7703, 0.8657, 1.0, 0.9340, 0.9595, 1.0, 0.9659, 1.0;
48 implodeSequence += 1.0, 0.9999, 0.9991, 0.9964, 0.9900, 0.9775, 0.9559, 0.9216, 0.8704, 0.7975, 0.6975, 0.5644, 0.3916, 0.1719, 0.0, 0.1287, 0.2164, 0.2535, 0.2297, 0.1343, 0.0, 0.0660, 0.0405, 0.0, 0.0341, 0.0;
59 for (ZoomSequence::size_type
i = 1;
i < sequence.size(); ++
i)
101 assert(frontSprite || rearSprite);
121 for (Sensor::TrackCollection::const_iterator it = tracks.begin(); it != tracks.end(); ++it)
123 if (it->GetPosition().z < 0)
155 position.z = -position.z;
157 float magnitude = position.Magnitude();
158 float scaleFactor = 0.0;
160 if (magnitude <= maxRange)
164 magnitude /= (1.0 - scaleFactor);
169 magnitude /= (1.0 - 0.04 *
Jitter(0.0, 1.0));
177 headColor.
a *= 0.2 + scaleFactor * (1.0 - 0.2);
181 if (dangerRate > 0.0)
207 if (isNebula || isEcmActive)
210 trackSize *=
Jitter(0.5, 1.0);
227 GFXVertex3f(position.x - xsize / 2, position.y - ysize, position.z);
228 GFXVertex3f(position.x - xsize, position.y - ysize / 2, position.z);
229 GFXVertex3f(position.x - xsize, position.y + ysize / 2, position.z);
230 GFXVertex3f(position.x - xsize / 2, position.y + ysize, position.z);
233 GFXVertex3f(position.x + xsize / 2, position.y - ysize, position.z);
234 GFXVertex3f(position.x + xsize, position.y - ysize / 2, position.z);
235 GFXVertex3f(position.x + xsize, position.y + ysize / 2, position.z);
236 GFXVertex3f(position.x + xsize / 2, position.y + ysize, position.z);
256 GFXVertex3f(center.x - xground, center.y - yground / 2, center.z);
257 GFXVertex3f(center.x - xground / 2, center.y - yground, center.z);
258 GFXVertex3f(center.x + xground / 2, center.y - yground, center.z);
259 GFXVertex3f(center.x + xground, center.y - yground / 2, center.z);
262 GFXVertex3f(center.x - xground, center.y + yground / 2, center.z);
263 GFXVertex3f(center.x - xground / 2, center.y + yground, center.z);
264 GFXVertex3f(center.x + xground / 2, center.y + yground, center.z);
265 GFXVertex3f(center.x + xground, center.y + yground / 2, center.z);