12#define AS_ROUND_DELAY 5
24 target_objective_decrease_activate(it);
52 if(trigger.assault_sprite)
55 if(trigger.classname ==
"func_assault_destructible")
56 trigger.sprite =
NULL;
64 if (hlth - this.
dmg > 0.5)
75 if(this.
enemy.message)
87 if(this.enemy == NULL)
90 objerror(this,
"more than one objective as target - fix the map!");
95 objerror(
this,
"no objective as target - fix the map!");
112 if(it.assault_sprite !=
NULL)
115 if(it.classname ==
"func_assault_destructible")
120 spr.assault_decreaser =
this;
123 if(it.classname ==
"func_assault_destructible")
217 bprint(
"Starting second round...\n");
290 if (!
g_assault) {
delete(
this);
return; }
293 spawnfunc_info_player_deathmatch(
this);
298 if (!
g_assault) {
delete(
this);
return; }
301 spawnfunc_info_player_deathmatch(
this);
306 if (!
g_assault) {
delete(
this);
return; }
317 if (!
g_assault) {
delete(
this);
return; }
335 float true_limit = ((limit !=
RES_LIMIT_NONE) ? limit : targ.max_health);
337 if (hlth <= 0 || hlth >= true_limit)
351 if (!
g_assault) {
delete(
this);
return; }
367 if (!
g_assault) {
delete(
this);
return; }
370 _setmodel(
this, this.
mdl);
379 if (!
g_assault) {
delete(
this);
return; }
389 if (!
g_assault) {
delete(
this);
return; }
407 IL_EACH(g_assault_objectivedecreasers, it.targetname == destr.target,
409 float hlth = GetResource(it.enemy, RES_HEALTH);
410 if (hlth > 0 && hlth < ASSAULT_VALUE_INACTIVE)
420 vector p = 0.5 * (it.absmin + it.absmax);
431 if(checkpvs(it.origin, des))
434 if(it.cnt < bestvalue)
575 if(!turret.team || turret.team ==
FLOAT_MAX)
583 veh.nextthink =
time + 0.5;
598 return (frag_victim.classname ==
"func_assault_destructible");
625 switch(ent.classname)
627 case "info_player_team1":
628 case "info_player_team2":
629 case "info_player_team3":
630 case "info_player_team4":
void navigation_goalrating_start(entity this)
void navigation_goalrating_timeout_set(entity this)
bool navigation_goalrating_timeout(entity this)
void navigation_routerating(entity this, entity e, float f, float rangebias)
const int WAYPOINTFLAG_GENERATED
void navigation_goalrating_end(entity this)
float havocbot_role_timeout
#define MUTATOR_HOOKFUNCTION(...)
#define BIT(n)
Only ever assign into the first 24 bits in QC (so max is BIT(23)).
void func_breakable_setup(entity this)
void func_breakable_colormod(entity this)
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.
void TakeResource(entity receiver, Resource res_type, float amount)
Takes an entity some resource.
bool SetResourceExplicit(entity e, Resource res_type, float amount)
Sets the resource amount of an entity without calling any hooks.
#define autocvar_timelimit
const int INITPRIO_FINDTARGET
ERASEABLE string process_time(float outputtype, int seconds)
float checkpvs(vector viewpos, entity viewee)
ERASEABLE entity IL_PUSH(IntrusiveList this, entity it)
Push to tail.
#define IL_EACH(this, cond, body)
#define FOREACH_ENTITY_RADIUS(org, dist, cond, body)
#define FOREACH_ENTITY_STRING(fld, match, body)
void SUB_UseTargets(entity this, entity actor, entity trigger)
void Send_Notification(NOTIF broadcast, entity client, MSG net_type, Notification net_name,...count)
void WinningConditionHelper(entity this)
Sets the following results for the current scores entities.
float TeamScore_AddToTeam(int t, float scorefield, float score)
Adds a score to the given team.
void ReadyRestart_force(bool is_fake_round_start)
IntrusiveList g_saved_team
spawn_evalfunc_t spawn_evalfunc
void assault_new_round(entity this)
void assault_roundstart_use(entity this, entity actor, entity trigger)
void assault_roundstart_use_this(entity this)
void havocbot_role_ast_defense(entity this)
void assault_objective_use(entity this, entity actor, entity trigger)
void assault_setenemytoobjective(entity this)
void havocbot_role_ast_setrole(entity this, float role)
bool assault_turrets_teamswap_forbidden
bool assault_decreaser_sprite_visible(entity this, entity player, entity view)
void havocbot_ast_reset_role(entity this)
void assault_objective_decrease_use(entity this, entity actor, entity trigger)
void assault_wall_think(entity this)
void havocbot_goalrating_ast_targets(entity this, float ratingscale)
void target_assault_roundend_reset(entity this)
vector target_objective_spawn_evalfunc(entity this, entity player, entity spot, vector current)
void target_assault_roundend_use(entity this, entity actor, entity trigger)
void target_objective_decrease_activate(entity this)
void havocbot_role_ast_offense(entity this)
bool destructible_heal(entity targ, entity inflictor, float amount, float limit)
void assault_objective_reset(entity this)
int WinningCondition_Assault()
void target_objective_decrease_findtarget(entity this)
IntrusiveList g_assault_destructibles
const int ASSAULT_VALUE_INACTIVE
IntrusiveList g_assault_objectives
const int HAVOCBOT_AST_ROLE_OFFENSE
const int HAVOCBOT_AST_ROLE_DEFENSE
float havocbot_attack_time
IntrusiveList g_assault_objectivedecreasers
const int ST_ASSAULT_OBJECTIVES
int assault_attacker_team
void havocbot_goalrating_items(entity this, float ratingscale, vector org, float sradius)
void havocbot_goalrating_enemyplayers(entity this, float ratingscale, vector org, float sradius)
void GiveResourceWithLimit(entity receiver, Resource res_type, float amount, float limit)
Gives an entity some resource but not more than a limit.
#define GameRules_scoring_add_team(client, fld, value)
void turret_respawn(entity this)
entity TeamBalance_CheckAllowedTeams(entity for_whom)
Checks whether the player can join teams according to global configuration and mutator settings.
#define Team_ColoredFullName(teamid)
#define FOREACH_CLIENT(cond, body)
void WaypointSprite_UpdateSprites(entity e, entity _m1, entity _m2, entity _m3)
void WaypointSprite_UpdateMaxHealth(entity e, float f)
void WaypointSprite_UpdateHealth(entity e, float f)
entity WaypointSprite_SpawnFixed(entity spr, vector ofs, entity own,.entity ownfield, entity icon)
void WaypointSprite_Disown(entity wp, float fadetime)
void WaypointSprite_UpdateRule(entity e, float t, float r)
float waypointsprite_deadlifetime
const int SPRITERULE_TEAMPLAY
void SetWinners(.float field, float value)
void InitializeEntity(entity e, void(entity this) func, int order)
bool sv_ready_restart_after_countdown