Xonotic QuakeC
The free, fast arena FPS with crisp movement and a wide array of weapons
vengeance.qh File Reference
Include dependency graph for vengeance.qh:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  VengeanceBuff

Functions

float buff_Vengeance_CalculateDamage (float frag_damage)
void buff_Vengeance_DelayedDamage (entity this)
 REGISTER_BUFF (VENGEANCE, NEW(VengeanceBuff))

Variables

float autocvar_g_buffs_vengeance_damage_multiplier

Function Documentation

◆ buff_Vengeance_CalculateDamage()

float buff_Vengeance_CalculateDamage ( float frag_damage)

Definition at line 15 of file vengeance.qc.

16{
18}
float frag_damage
Definition sv_ctf.qc:2316
float autocvar_g_buffs_vengeance_damage_multiplier
Definition vengeance.qh:6

References autocvar_g_buffs_vengeance_damage_multiplier, and frag_damage.

Referenced by MUTATOR_HOOKFUNCTION().

◆ buff_Vengeance_DelayedDamage()

void buff_Vengeance_DelayedDamage ( entity this)

Definition at line 4 of file vengeance.qc.

5{
6 if (this.enemy)
7 {
8 Damage(this.enemy, this.owner, this.owner, this.dmg, DEATH_BUFF_VENGEANCE.m_id, DMG_NOWEP, this.enemy.origin, '0 0 0');
9 buff_Effect(this.owner, EFFECT_VENGEANCE, CENTER_OF_ENT(this.enemy), vec2(this.enemy.velocity), min(ceil(this.dmg), 50), false);
10 }
11
12 delete(this);
13 return;
14}
float dmg
Definition breakable.qc:12
entity owner
Definition main.qh:87
#define CENTER_OF_ENT(ent)
Definition util.qh:10
void Damage(entity targ, entity inflictor, entity attacker, float damage, int deathtype,.entity weaponentity, vector hitloc, vector force)
Definition damage.qc:484
#define DMG_NOWEP
Definition damage.qh:104
float ceil(float f)
float min(float f,...)
void buff_Effect(entity player, entity eff, vector eff_loc, vector eff_vel, int eff_cnt, bool hide)
Spawn effects on a player with a buff.
Definition sv_buffs.qc:103
entity enemy
Definition sv_ctf.qh:152
#define vec2(...)
Definition vector.qh:95

References buff_Effect(), ceil(), CENTER_OF_ENT, Damage(), dmg, DMG_NOWEP, enemy, entity(), min(), owner, and vec2.

Referenced by MUTATOR_HOOKFUNCTION().

◆ REGISTER_BUFF()

REGISTER_BUFF ( VENGEANCE ,
NEW(VengeanceBuff)  )

Variable Documentation

◆ autocvar_g_buffs_vengeance_damage_multiplier

float autocvar_g_buffs_vengeance_damage_multiplier

Definition at line 6 of file vengeance.qh.

Referenced by buff_Vengeance_CalculateDamage().