#include "spawnpoints.qh"
-#include "_all.qh"
-#include "mutators/mutators_include.qh"
+#include "mutators/all.qh"
#include "g_world.qh"
#include "race.qh"
#include "../common/constants.qh"
#include "../common/teams.qh"
+#include "../common/triggers/subs.qh"
#include "../common/util.qh"
-#include "../warpzonelib/util_server.qh"
+#include "../lib/warpzone/common.qh"
+#include "../lib/warpzone/util_server.qh"
-float SpawnPoint_Send(entity to, int sf)
-{SELFPARAM();
+bool SpawnPoint_Send(entity this, entity to, int sf)
+{
WriteByte(MSG_ENTITY, ENT_CLIENT_SPAWNPOINT);
WriteByte(MSG_ENTITY, self.team);
return true;
}
-float SpawnEvent_Send(entity to, int sf)
-{SELFPARAM();
+bool SpawnEvent_Send(entity this, entity to, int sf)
+{
float send;
WriteByte(MSG_ENTITY, ENT_CLIENT_SPAWNEVENT);
return send;
}
+.vector spawnpoint_prevorigin;
+void spawnpoint_think()
+{
+ self.nextthink = time + 0.1;
+ if(self.origin != self.spawnpoint_prevorigin)
+ {
+ self.spawnpoint_prevorigin = self.origin;
+ self.SendFlags |= 1;
+ }
+}
+
void spawnpoint_use()
{SELFPARAM();
if(teamplay)
}
self.use = spawnpoint_use;
+ self.think = spawnpoint_think;
+ self.nextthink = time + 0.5 + random() * 2; // shouldn't need it for a little second
self.team_saved = self.team;
if (!self.cnt)
self.cnt = 1;
Keys: "angle" viewing angle when spawning. */
spawnfunc(info_player_team1)
{
- if(g_assault) { remove(this); return; }
-
this.team = NUM_TEAM_1; // red
spawnfunc_info_player_deathmatch(this);
}
Keys: "angle" viewing angle when spawning. */
spawnfunc(info_player_team2)
{
- if(g_assault) { remove(this); return; }
-
this.team = NUM_TEAM_2; // blue
spawnfunc_info_player_deathmatch(this);
}
Keys: "angle" viewing angle when spawning. */
spawnfunc(info_player_team3)
{
- if(g_assault) { remove(this); return; }
-
this.team = NUM_TEAM_3; // yellow
spawnfunc_info_player_deathmatch(this);
}
Keys: "angle" viewing angle when spawning. */
spawnfunc(info_player_team4)
{
- if(g_assault) { remove(this); return; }
-
this.team = NUM_TEAM_4; // purple
spawnfunc_info_player_deathmatch(this);
}