165 W_SetupShot_ProjectileSize(actor, weaponentity,
'-3 -3 -3',
'3 3 3',
false, 4, SND_MORTAR_FIRE,
CH_WEAPON_A,
WEP_CVAR_PRI(WEP_MORTAR, damage), thiswep.
m_id);
170 entity gren =
new(grenade);
171 gren.owner = gren.realowner = actor;
172 gren.bot_dodge =
true;
173 gren.bot_dodgerating =
WEP_CVAR_PRI(WEP_MORTAR, damage);
178 gren.projectiledeathtype = thiswep.
m_id;
179 gren.weaponentity_fld = weaponentity;
181 setsize(gren,
'-3 -3 -3',
'3 3 3');
184 gren.nextthink =
time;
193 gren.damagedbycontents =
true;
216 W_SetupShot_ProjectileSize(actor, weaponentity,
'-3 -3 -3',
'3 3 3',
false, 4, SND_MORTAR_FIRE,
CH_WEAPON_A,
WEP_CVAR_SEC(WEP_MORTAR, damage), thiswep.
m_id |
HITTYPE_SECONDARY);
221 entity gren =
new(grenade);
222 gren.owner = gren.realowner = actor;
223 gren.bot_dodge =
true;
224 gren.bot_dodgerating =
WEP_CVAR_SEC(WEP_MORTAR, damage);
230 gren.weaponentity_fld = weaponentity;
232 setsize(gren,
'-3 -3 -3',
'3 3 3');
243 gren.damagedbycontents =
true;
267 if (!actor.bot_secondary_grenademooth)
273 actor.bot_secondary_grenademooth =
true;
282 actor.bot_secondary_grenademooth =
false;
308 thiswep.wr_reload(thiswep, actor, weaponentity);
324 bool nade_found =
false;
327 if (!it.gl_detonate_later)
329 it.gl_detonate_later = true;
366 return WEAPON_MORTAR_SUICIDE_BOUNCE;
368 return WEAPON_MORTAR_SUICIDE_EXPLODE;
374 return WEAPON_MORTAR_MURDER_BOUNCE;
376 return WEAPON_MORTAR_MURDER_EXPLODE;
398 PAR(_(
"The %s launches a grenade that explodes immediately on impact, dealing a medium amount of splash damage."),
COLORED_NAME(
this));
399 PAR(_(
"The secondary fire shoots a similar grenade that explodes shortly after bouncing."));
400 PAR(_(
"It consumes %s ammo for every grenade launched."),
COLORED_NAME(ITEM_Rockets));
401 PAR(_(
"The %s works best at close to medium ranges, but it's quite tricky to hit an enemy if they're airborne. "
402 "Since the secondary fire grenade bounces before exploding, it can be bounced against walls to damage enemies lurking around a corner."),
COLORED_NAME(
this));
bool bot_aim(entity this,.entity weaponentity, float shotspeed, float shotspeedupward, float maxshottime, float applygravity, bool shot_accurate)
IntrusiveList g_bot_dodge
#define MUTATOR_CALLHOOK(id,...)
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.
fields which are explicitly/manually set are marked with "M", fields set automatically are marked wit...
#define COLORED_NAME(this)
bool IsFlying(entity this)
#define PHYS_INPUT_BUTTON_ATCK(s)
#define PHYS_INPUT_BUTTON_ATCK2(s)
void UpdateCSQCProjectile(entity e)
void CSQCProjectile(entity e, float clientanimate, int type, float docull)
float RadiusDamage(entity inflictor, entity attacker, float coredamage, float edgedamage, float rad, entity cantbe, entity mustbe, float forceintensity, int deathtype,.entity weaponentity, entity directhitentity)
IntrusiveList g_damagedbycontents
const int HITTYPE_SECONDARY
#define pointparticles(effect, org, vel, howmany)
void Send_Effect(entity eff, vector eff_loc, vector eff_vel, int eff_cnt)
ERASEABLE entity IL_PUSH(IntrusiveList this, entity it)
Push to tail.
#define IL_EACH(this, cond, body)
void W_Mortar_Attack2(Weapon thiswep, entity actor,.entity weaponentity)
void W_Mortar_Grenade_Explode2(entity this, entity directhitentity)
void W_Mortar_Grenade_Damage(entity this, entity inflictor, entity attacker, float damage, int deathtype,.entity weaponentity, vector hitloc, vector force)
void W_Mortar_Grenade_Explode_use(entity this, entity actor, entity trigger)
void W_Mortar_Grenade_Think1(entity this)
void W_Mortar_Grenade_Touch2(entity this, entity toucher)
void W_Mortar_Grenade_Explode(entity this, entity directhitentity)
void W_Mortar_Grenade_Explode2_use(entity this, entity actor, entity trigger)
void W_Mortar_Attack(Weapon thiswep, entity actor,.entity weaponentity)
bool bot_secondary_grenademooth
void W_Mortar_Grenade_Touch1(entity this, entity toucher)
void set_movetype(entity this, int mt)
const int MOVETYPE_BOUNCE
void Send_Notification(NOTIF broadcast, entity client, MSG net_type, Notification net_name,...count)
entity Notification
always last
#define METHOD(cname, name, prototype)
const int PROJECTILE_GRENADE_BOUNCING
const int PROJECTILE_GRENADE
float health
Legacy fields for the resources. To be removed.
float W_CheckProjectileDamage(entity inflictor, entity projowner, int deathtype, float exception)
void W_PrepareExplosionByDamage(entity this, entity attacker, void(entity this) explode)
void adaptor_think2use_hittype_splash(entity this)
#define PROJECTILE_TOUCH(e, t)
IntrusiveList g_projectiles
#define PROJECTILE_MAKETRIGGER(e)
#define sound(e, c, s, v, a)
Sound SND_GRENADE_BOUNCE_RANDOM()
float spamsound(entity e, int chan, Sound samp, float vol, float _atten)
use this one if you might be causing spam (e.g.
#define PAR(...)
Adds an individually translatable paragraph to PAGE_TEXT without having to deal with strcat and sprin...
#define W_SetupProjVelocity_UP_PRI(ent, wep)
#define W_SetupShot_ProjectileSize(ent, wepent, mi, ma, antilag, recoil, snd, chan, maxdamage, deathtype)
#define W_SetupProjVelocity_UP_SEC(ent, wep)
string W_Guide_Keybinds(Weapon wep)
string W_Guide_DPS(string name, string pri, string sec)
void W_MuzzleFlash(Weapon thiswep, entity actor,.entity weaponentity, vector shotorg, vector shotdir)
#define WEP_CVAR_PRI(wep, name)
#define WEP_CVAR(wep, name)
#define WEP_CVAR_SEC(wep, name)
void W_DecreaseAmmo(Weapon wep, entity actor, float ammo_use,.entity weaponentity)
void W_Reload(entity actor,.entity weaponentity, float sent_ammo_min, Sound sent_sound)
void weapon_thinkf(entity actor,.entity weaponentity, WFRAME fr, float t, void(Weapon thiswep, entity actor,.entity weaponentity, int fire) func)
bool weapon_prepareattack(Weapon thiswep, entity actor,.entity weaponentity, bool secondary, float attacktime)
void w_ready(Weapon thiswep, entity actor,.entity weaponentity, int fire)
float weapon_load[REGISTRY_MAX(Weapons)]