103 objerror(
this,
"train_next: no next target");
104 this.
wait = targ.wait;
108 if(targ.platmovetype)
145 WriteHeader(MSG_ENTITY, ENT_CLIENT_TRAIN);
156 trigger_common_write(
this,
true);
160 WriteVector(MSG_ENTITY, this.
pos1);
161 WriteVector(MSG_ENTITY, this.
pos2);
163 WriteVector(MSG_ENTITY, this.
size);
165 WriteVector(MSG_ENTITY, this.
view_ofs);
167 WriteAngleVector(MSG_ENTITY, this.
mangle);
187 void train_link(
entity this)
197 if(trigger.target2 && trigger.target2 !=
"")
201 void func_train_find(
entity this)
204 this.
target = targ.target;
209 objerror(
this,
"func_train_find: no next target");
210 setorigin(
this, targ.origin -
this.view_ofs);
231 if (this.
noise !=
"")
235 objerror(
this,
"func_train without a target");
239 if (!InitMovingBrushTrigger(
this))
244 this.
use = train_use;
259 this.
message =
" was squished";
260 if(this.
dmg && (this.message2 ==
""))
261 this.message2 =
"was squished by";
274 void train_draw(
entity this)
282 float sf = ReadByte();
291 _setmodel(
this, this.
model);
293 trigger_common_read(
this,
true);
297 this.
pos1 = ReadVector();
298 this.
pos2 = ReadVector();
300 this.
size = ReadVector();
304 this.
mangle = ReadAngleVector();
306 this.
speed = ReadShort();
307 this.
height = ReadShort();
308 this.
lip = ReadByte();
309 this.
state = ReadByte();
310 this.
wait = ReadByte();
312 this.
dmg = ReadShort();
319 this.draw = train_draw;
321 this.entremove = trigger_remove_generic;
#define REGISTER_NET_LINKED(id)
const int SF_TRIGGER_INIT
bool autocvar_cl_projectiles_sloppy
ERASEABLE void RandomSelection_Init()
void train_next(entity this)
entity train_next_find(entity this)
void SUB_UseTargets(entity this, entity actor, entity trigger)
#define NET_HANDLE(id, param)
spawnfunc(info_player_attacker)
void SUB_CalcMove(entity this, vector tdest, float tspeedtype, float tspeed, void(entity this) func)
const int TRAIN_NEEDACTIVATION
#define RandomSelection_AddEnt(e, weight, priority)
ERASEABLE entity IL_PUSH(IntrusiveList this, entity it)
Push to tail.
void Movetype_Physics_MatchServer(entity this, bool sloppy)
entity RandomSelection_chosen_ent
const int SF_TRIGGER_RESET
const int CH_TRIGGER_SINGLE
vector(float skel, float bonenum) _skel_get_boneabs_hidden
void train_wait(entity this)
void InitializeEntity(entity e, void(entity this) func, int order)
#define _sound(e, c, s, v, a)
void SUB_CalcAngleMove(entity this, vector destangle, float tspeedtype, float tspeed, void(entity this) func)
void SUB_CalcMove_Bezier(entity this, vector tcontrol, vector tdest, float tspeedtype, float tspeed, void(entity this) func)
IntrusiveList g_drawables
void set_movetype(entity this, int mt)