}
bool WarpZone_Teleported_Send(entity to, int sf)
-{
+{SELFPARAM();
WriteByte(MSG_ENTITY, ENT_CLIENT_WARPZONE_TELEPORTED);
WriteCoord(MSG_ENTITY, self.angles.x);
WriteCoord(MSG_ENTITY, self.angles.y);
}
void WarpZone_Touch (void)
-{
+{SELFPARAM();
entity oldself;
if(other.classname == "trigger_warpzone")
}
bool WarpZone_Send(entity to, int sendflags)
-{
+{SELFPARAM();
WriteByte(MSG_ENTITY, ENT_CLIENT_WARPZONE);
// we must send this flag for clientside to match properly too
}
bool WarpZone_Camera_Send(entity to, int sendflags)
-{
+{SELFPARAM();
int f = 0;
WriteByte(MSG_ENTITY, ENT_CLIENT_WARPZONE_CAMERA);
#ifdef WARPZONELIB_KEEPDEBUG
float WarpZone_CheckProjectileImpact(entity player)
-{
+{SELFPARAM();
vector o0, v0;
o0 = player.origin + player.view_ofs;
#endif
float WarpZone_Projectile_Touch()
-{
+{SELFPARAM();
if(other.classname == "trigger_warpzone")
return true;
}
void WarpZone_InitStep_FindOriginTarget()
-{
+{SELFPARAM();
if(self.killtarget != "")
{
self.aiment = find(world, targetname, self.killtarget);
}
void WarpZonePosition_InitStep_FindTarget()
-{
+{SELFPARAM();
if(self.target == "")
{
error("Warp zone position with no target");
}
void WarpZoneCamera_Think(void)
-{
+{SELFPARAM();
if(self.warpzone_save_origin != self.origin
|| self.warpzone_save_angles != self.angles
|| self.warpzone_save_eorigin != self.enemy.origin
}
void WarpZoneCamera_InitStep_FindTarget()
-{
+{SELFPARAM();
entity e;
float i;
if(self.target == "")
}
void WarpZone_InitStep_UpdateTransform()
-{
+{SELFPARAM();
vector org, ang, norm, point;
float area;
vector tri, a, b, c, n;
}
void WarpZone_InitStep_ClearTarget()
-{
+{SELFPARAM();
if(self.enemy)
self.enemy.enemy = world;
self.enemy = world;
entity warpzone_first; .entity warpzone_next;
void WarpZone_InitStep_FindTarget()
-{
+{SELFPARAM();
float i;
entity e, e2;
void WarpZone_Think();
void WarpZone_InitStep_FinalizeTransform()
-{
+{SELFPARAM();
if(!self.enemy || self.enemy.enemy != self)
{
error("Invalid warp zone detected. Killed.");
entity warpzone_camera_first;
.entity warpzone_next;
void spawnfunc_misc_warpzone_position(void)
-{
+{SELFPARAM();
// "target", "angles", "origin"
self.warpzone_next = warpzone_position_first;
warpzone_position_first = self;
spawnfunc_misc_warpzone_position();
}
void spawnfunc_trigger_warpzone(void)
-{
+{SELFPARAM();
// warp zone entities must have:
// "killtarget" pointing to a target_position with a direction arrow
// that points AWAY from the warp zone, and that is inside
warpzone_first = self;
}
void spawnfunc_func_camera(void)
-{
+{SELFPARAM();
if(!self.scale)
self.scale = self.modelscale;
if(!self.scale)
warpzone_camera_first = self;
}
void WarpZones_Reconnect()
-{
+{SELFPARAM();
entity e;
e = self;
for(self = warpzone_first; self; self = self.warpzone_next)
}
void WarpZone_Think()
-{
+{SELFPARAM();
if(self.warpzone_save_origin != self.origin
|| self.warpzone_save_angles != self.angles
|| self.warpzone_save_eorigin != self.enemy.origin
}
void WarpZone_StartFrame()
-{
+{SELFPARAM();
entity e;
if(warpzone_initialized == 0)
{
return 0;
}
void trigger_warpzone_reconnect_use()
-{
+{SELFPARAM();
entity e;
e = self;
// NOTE: this matches for target, not targetname, but of course
}
void spawnfunc_trigger_warpzone_reconnect()
-{
+{SELFPARAM();
self.use = trigger_warpzone_reconnect_use;
}
}
void WarpZone_PlayerPhysics_FixVAngle(void)
-{
+{SELFPARAM();
#ifndef WARPZONE_DONT_FIX_VANGLE
if(IS_REAL_CLIENT(self))
if(self.v_angle.z <= 360) // if not already adjusted