1 #include "sv_controlpoint.qh"
5 bool cpicon_send(entity this, entity to, int sf)
7 WriteHeader(MSG_ENTITY, ENT_CLIENT_CONTROLPOINT_ICON);
10 WriteByte(MSG_ENTITY, sf);
13 WriteCoord(MSG_ENTITY, this.origin_x);
14 WriteCoord(MSG_ENTITY, this.origin_y);
15 WriteCoord(MSG_ENTITY, this.origin_z);
17 WriteByte(MSG_ENTITY, this.health);
18 WriteByte(MSG_ENTITY, this.max_health);
19 WriteByte(MSG_ENTITY, this.count);
20 WriteByte(MSG_ENTITY, this.team);
21 WriteByte(MSG_ENTITY, this.owner.iscaptured);
26 WriteByte(MSG_ENTITY, this.team);
29 WriteByte(MSG_ENTITY, 0);
31 WriteByte(MSG_ENTITY, ceil((this.health / this.max_health) * 255));
37 void onslaught_controlpoint_icon_link(entity e, void(entity this) spawnproc)
39 Net_LinkEntity(e, true, 0, cpicon_send);
40 setthink(e, spawnproc);
41 e.nextthink = time * sys_frametime;