35 this.move_time =
time;
77 if(dist < 10240 && t != this.
team)
91 txt =
"gfx/vehicles/turret_moving";
93 txt =
"gfx/vehicles/turret_stationary";
100 if(dist > this.maxdistance)
103 string spriteimage = this.
netname;
110 else if(this.maxdistance > 0)
115 this.teamradar_color =
'1 0 1';
116 LOG_INFOF(
"WARNING: sprite of name %s has no color, using pink so you notice it", spriteimage);
123 if(this.helpme &&
time < this.helpme)
126 txt = sprintf(_(
"%s under attack!"), txt);
133 txt = strtoupper(txt);
182 if(draw_healthbar || draw_text)
221 setorigin(
this, this.
origin);
222 _setmodel(
this, tur.model);
223 _setmodel(this.
tur_head, tur.head_model);
226 setsize(
this, tur.m_mins, tur.m_maxs);
227 setsize(this.
tur_head,
'0 0 0',
'0 0 0');
229 if(this.
m_id == TUR_EWHEEL.m_id)
230 setattachment(this.
tur_head,
this,
"");
232 setattachment(this.
tur_head,
this,
"tag_head");
234 this.
tur_head.classname =
"turret_head";
249 this.teamradar_color =
'1 0 0';
258 tur.tr_setup(tur,
this);
290 for (
int j = 1; j < 5; j = j + 1)
302 gib =
new(turret_gib);
303 setorigin(gib, _from);
304 _setmodel(gib, _model);
305 gib.colormod = _cmod;
309 setsize(gib,
'-1 -1 -1',
'1 1 1');
320 setorigin(gib, _from);
323 gib.move_time =
time;
324 gib.damageforcescale = 1;
336 if(this.
m_id == TUR_EWHEEL.m_id)
338 else if (this.
m_id == TUR_WALKER.m_id)
340 else if (this.
m_id == TUR_TESLA.m_id)
356 headgib.angles = this.
tur_head.angles;
358 headgib.avelocity_y = headgib.avelocity_y * 5;
359 headgib.gravity = 0.5;
378 setorigin(
this, this.
origin);
394 this.
tur_head.angles_x = ReadShort();
395 this.
tur_head.angles_y = ReadShort();
404 this.
tur_head.avelocity_x = ReadShort();
405 this.
tur_head.avelocity_y = ReadShort();
411 setorigin(
this, this.
origin);
430 if(_tmp != this.
team)
438 if(_tmp == 0 && myhp != 0)
440 else if(myhp && myhp > _tmp)
442 else if(myhp && myhp < _tmp)
float frame1time
start time of framegroup animation
float frame
primary framegroup animation (strength = 1 - lerpfrac - lerpfrac3 - lerpfrac4)
var entity(vector mins, vector maxs,.entity tofield) findbox_tofield_OrFallback
float GetResource(entity e, Resource res_type)
Returns the current amount of resource the given entity has.
bool SetResourceExplicit(entity e, Resource res_type, float amount)
Sets the resource amount of an entity without calling any hooks.
void turret_changeteam(entity this)
void turret_gib_draw(entity this)
void turret_die(entity this)
void turret_remove(entity this)
void turret_draw(entity this)
entity turret_gibtoss(string _model, vector _from, vector _to, vector _cmod, float _explode)
void turret_draw2d(entity this)
void turret_construct(entity this, bool isnew)
void turret_gibboom(entity this)
void turret_head_draw(entity this)
float autocvar_cl_vehicles_crosshair_size
bool autocvar_cl_vehicles_hud_tactical
#define drawpic(position, pic, size, rgb, alpha, flag)
IntrusiveList g_drawables
const float ALPHA_MIN_VISIBLE
IntrusiveList g_drawables_2d
#define setmodel(this, m)
const float DRAWFLAG_NORMAL
const float MOVE_NOMONSTERS
vector drawgetimagesize(string pic)
#define pointparticles(effect, org, vel, howmany)
float autocvar_cl_gibs_ticrate
bool autocvar_cl_gibs_sloppy
float autocvar_cl_gibs_lifetime
float autocvar_hud_panel_fg_alpha
ERASEABLE entity IL_PUSH(IntrusiveList this, entity it)
Push to tail.
noref float vid_conheight
#define NET_HANDLE(id, param)
#define ReadAngleVector2D()
void Movetype_Physics_MatchTicrate(entity this, float tr, bool sloppy)
void set_movetype(entity this, int mt)
const int MOVETYPE_NOCLIP
const int MOVETYPE_BOUNCE
strcat(_("^F4Countdown stopped!"), "\n^BG", _("Teams are too unbalanced."))
float prandom()
Predictable random number generator (not seeded yet)
#define sound(e, c, s, v, a)
vector Team_ColorRGB(int teamid)
#define get_turretinfo(i)
vector project_3d_to_2d(vector vec)
vector drawsprite_TextOrIcon(bool is_text, vector o, float ang, float minwidth, vector rgb, float a, vector sz, string str)
void drawhealthbar(vector org, float rot, float h, vector sz, vector hotspot, float width, float theheight, float margin, float border, float align, vector rgb, float a, vector hrgb, float ha, float f)
vector drawspritearrow(vector o, float ang, vector rgb, float a, float t)
string spritelookuptext(entity this, string s)
vector spritelookupcolor(entity this, string s, vector def)
vector fixrgbexcess(vector rgb)
float spritelookupblinkvalue(entity this, string s)
const float SPRITE_HEALTHBAR_HEIGHT
float waypointsprite_alpha
bool autocvar_g_waypointsprite_uppercase
bool autocvar_g_waypointsprite_turrets_text
float waypointsprite_edgeoffset_left
float waypointsprite_scale
float waypointsprite_distancefadedistance
float waypointsprite_edgeoffset_top
float waypointsprite_distancealphaexponent
float waypointsprite_crosshairfadescale
const float SPRITE_HELPME_BLINK
float waypointsprite_normdistance
float waypointsprite_edgefadescale
float waypointsprite_edgeoffset_right
float waypointsprite_crosshairfadealpha
float waypointsprite_fadedistance
float waypointsprite_edgefadedistance
const float SPRITE_ARROW_SCALE
float waypointsprite_crosshairfadedistance
bool autocvar_cl_hidewaypoints
bool autocvar_g_waypointsprite_turrets_onlyhurt
float autocvar_g_waypointsprite_turrets_maxdist
const float SPRITE_HEALTHBAR_HEALTHALPHA
const float SPRITE_HEALTHBAR_BORDERALPHA
float waypointsprite_edgefadealpha
const float SPRITE_HEALTHBAR_WIDTH
const float SPRITE_HEALTHBAR_BORDER
float waypointsprite_distancefadealpha
bool autocvar_g_waypointsprite_turrets
float waypointsprite_distancefadescale
const float SPRITE_HEALTHBAR_MARGIN
float waypointsprite_fontsize
float waypointsprite_minalpha
float waypointsprite_edgeoffset_bottom