18 const Matrix &orientationpos,
22 , ShipSpeed( shipspeed )
26 prev_position = cur_position;
40 (shipspeed+orientationpos.
getR()
44 q->
bolts[decal].push_back( *
this );
54 (shipspeed+orientationpos.
getR()
58 q->
balls[decal].push_back( *
this );
72 prev_position = cur_position;
74 ( ( ShipSpeed+drawmat.
getR()*speed
77 if (curdist > type->
Range) {
82 updated.
SetPosition( .5*(prev_position+cur_position) );
93 this->starSystem = ss;
94 this->collidemap = collidemap;
98 if (collidable.
radius < 0) {
110 template <
typename IT,
typename F >
144 Unit *affectedSubUnit;
145 if ( ( affectedSubUnit = target->
rayCollide( prev_position, cur_position, normal, distance ) ) ) {
147 if (target == owner)
return false;
150 static bool collideroids =
158 QVector tmp = (cur_position-prev_position).Normalize();
159 tmp = tmp.Scale( distance );
160 distance = curdist/this->type->Range;
161 GFXColor coltmp( this->type->r, this->type->g, this->type->b, this->type->a );
164 this->type->Damage*( (1-distance)+distance*this->type->Longrange ),
168 this->type->PhaseDamage*( (1-distance)+distance*this->type->Longrange ) );
207 vector< vector< Bolt > > *target;
212 vector< Bolt > *vec = &(*target)[decal];
213 if (&(*vec)[index] == whichbolt) {
214 unsigned int tsize = vec->size();
218 assert( index < tsize );
219 cm->
erase( (*vec)[index].location );
220 if ( index+1 != vec->size() )
221 (*vec)[
index] = vec->back();