{
//print("normal arc line failed, trying to find new pos...");
WarpZone_TraceLine(to, targpos, MOVE_NOMONSTERS, flag);
- targpos = (trace_endpos + FLAG_PASS_ARC_OFFSET);
+ targpos = (trace_endpos + eZ * FLAG_PASS_ARC_OFFSET_Z);
WarpZone_TraceLine(flag.origin, targpos, MOVE_NOMONSTERS, flag);
if(trace_fraction < 1) { targpos = to; /* print(" ^1FAILURE^7, reverting to original direction.\n"); */ }
/*else { print(" ^3SUCCESS^7, using new arc line.\n"); } */
{
this.velocity = this.velocity * 0.5;
- if(pointcontents(midpoint + FLAG_FLOAT_OFFSET) == CONTENT_WATER)
+ if (pointcontents(midpoint + eZ * FLAG_FLOAT_OFFSET_Z) == CONTENT_WATER)
{ this.velocity_z = autocvar_g_ctf_flag_dropped_floatinwater; }
else
{ set_movetype(this, MOVETYPE_FLY); }
const vector FLAG_CARRY_OFFSET = ('-16 0 8');
#define FLAG_SPAWN_OFFSET ('0 0 1' * (PL_MAX_CONST.z - 13))
const vector FLAG_WAYPOINT_OFFSET = ('0 0 64');
-const vector FLAG_FLOAT_OFFSET = ('0 0 32');
-const vector FLAG_PASS_ARC_OFFSET = ('0 0 -10');
+const int FLAG_FLOAT_OFFSET_Z = 32;
+const int FLAG_PASS_ARC_OFFSET_Z = -10;
const vector VEHICLE_FLAG_OFFSET = ('0 0 96');
const float VEHICLE_FLAG_SCALE = 1.0;