22#ifdef EWHEEL_FANCYPATH
68 if (this.
tur_head.spawnshieldtime < 1)
73 else if (this.
tur_head.spawnshieldtime < 2)
116 LOG_TRACE(
"Initital waypoint for ewheel does NOT exist, fix your map!");
120 if (e.classname !=
"turret_checkpoint")
125#ifdef EWHEEL_FANCYPATH
142 vector wish_angle, real_angle;
144 float vz = it.velocity.z;
152 real_angle = wish_angle - it.angles;
155 it.tur_head.spawnshieldtime =
fabs(real_angle.y);
157 float f = it.tur_head.aim_speed *
frametime;
158 real_angle.y =
bound(-f, real_angle.y, f);
159 it.angles.y += real_angle.y;
163 else if (it.pathcurrent)
176 it.velocity =
'0 0 0';
178#ifdef EWHEEL_FANCYPATH
182 it.pathcurrent =
NULL;
189 it.velocity =
'0 0 0';
192 setorigin(it, it.pos1);
198 it.iscreature =
true;
200 if (!it.damagedbycontents)
202 it.damagedbycontents =
true;
206 it.idle_aim =
'0 0 0';
211 it.tur_head.frame = 1;
223 this.move_time =
time;
252 PAR(_(
"The %s is a mobile turret that rolls around, attacking its targets when they enter its line of sight."),
COLORED_NAME(
this));
253 PAR(_(
"It attacks by shooting laser beams similar to those of the %s, from both of its two cannons."),
COLORED_NAME(WEP_BLASTER));
ERASEABLE float anglemods(float v)
ERASEABLE vector shortangle_vxy(vector ang1, vector ang2)
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.
#define COLORED_NAME(this)
const int INITPRIO_FINDTARGET
const float SOLID_SLIDEBOX
IntrusiveList g_damagedbycontents
const int ewheel_anim_stop
void ewheel_findtarget(entity this)
float autocvar_g_turrets_unit_ewheel_speed_slow
void ewheel_move_path(entity this)
float autocvar_g_turrets_unit_ewheel_turnrate
float autocvar_g_turrets_unit_ewheel_speed_stop
float autocvar_g_turrets_unit_ewheel_speed_slower
float autocvar_g_turrets_unit_ewheel_speed_fast
const int ewheel_anim_bck_fast
void ewheel_move_enemy(entity this)
const int ewheel_anim_fwd_slow
void ewheel_move_idle(entity this)
void ewheel_draw(entity this)
const int ewheel_anim_fwd_fast
const int ewheel_anim_bck_slow
ERASEABLE entity IL_PUSH(IntrusiveList this, entity it)
Push to tail.
void movelib_brake_simple(entity this, float force)
#define movelib_move_simple(e, newdir, velo, blendrate)
void set_movetype(entity this, int mt)
const int MOVETYPE_BOUNCE
#define METHOD(cname, name, prototype)
void pathlib_deletepath(entity start)
entity pathlib_astar(entity this, vector from, vector to)
vector steerlib_arrive(entity this, vector point, float maximal_distance)
Pull toward a point, The further away, the stronger the pull.
vector steerlib_attract2(entity this, vector point, float min_influense, float max_distance, float max_influense)
#define PAR(...)
Adds an individually translatable paragraph to PAGE_TEXT without having to deal with strcat and sprin...
bool turret_closetotarget(entity this, vector targ, float range)
bool turret_initialize(entity this, Turret tur)
void turrets_setframe(entity this, float _frame, float client_only)
const int TELEPORT_NORMAL
const int TFL_TARGETSELECT_TEAMCHECK
don't attack teammates
const int TFL_TARGETSELECT_PLAYERS
target players
const int TFL_TARGETSELECT_RANGELIMITS
limit target selection range
const int TFL_AMMO_ENERGY
uses power
const int TFL_TARGETSELECT_LOS
require line of sight to find targets
const int TFL_AMMO_RECHARGE
regenerates ammo
const int TFL_AMMO_RECIEVE
can recieve ammo from support units
void InitializeEntity(entity e, void(entity this) func, int order)