X-Git-Url: http://git.xonotic.org/?a=blobdiff_plain;f=qcsrc%2Fcommon%2Fdeathtypes.qh;h=4f96f7500eb96fe1faa8a584bdfdbd34de932cf3;hb=72496c0c862f19ccf8607189c6dfd4ee7351a157;hp=48a269b1a3937271f6e4b10c297d20adac78f629;hpb=a00d7aad132a38ac48dc4a1cd0c49aa829a0b850;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/common/deathtypes.qh b/qcsrc/common/deathtypes.qh index 48a269b1a..4f96f7500 100644 --- a/qcsrc/common/deathtypes.qh +++ b/qcsrc/common/deathtypes.qh @@ -73,14 +73,12 @@ entity deathtypes[DT_MAX]; deathtypes[(name - DT_FIRST)] = deathent; \ deathent.classname = "deathtype"; \ deathent.nent_name = #name; \ - #if (msg_death != NO_MSG) \ + if (msg_death != NO_MSG) \ deathent.death_msgself = msg_multi_notifs[msg_death - 1]; \ - #endif \ - #if (msg_death_by != NO_MSG) \ + if (msg_death_by != NO_MSG) \ deathent.death_msgmurder = msg_multi_notifs[msg_death_by - 1]; \ - #endif \ } \ - ACCUMULATE_FUNCTION(RegisterDeathtypes, RegisterDeathtype_##name) + ACCUMULATE_FUNCTION(RegisterDeathtypes, RegisterDeathtype_##name); DEATHTYPES #undef DEATHTYPE @@ -98,16 +96,16 @@ string Deathtype_Name(float deathtype) if(DEATH_ISSPECIAL(deathtype)) { entity deathent = deathtypes[(deathtype - DT_FIRST)]; - if not(deathent) { backtrace("Deathtype_Name: Could not find deathtype entity!\n"); return ""; } + if (!deathent) { backtrace("Deathtype_Name: Could not find deathtype entity!\n"); return ""; } return deathent.nent_name; } else { return ftos(deathtype); } } -float DEATH_WEAPONMASK = 0xFF; -float DEATH_HITTYPEMASK = 0x1F00; // which is WAY below 10000 used for normal deaths -float HITTYPE_SECONDARY = 0x100; -float HITTYPE_SPLASH = 0x200; // automatically set by RadiusDamage -float HITTYPE_BOUNCE = 0x400; -float HITTYPE_RESERVED2 = 0x800; -float HITTYPE_RESERVED = 0x1000; // unused yet +const float DEATH_WEAPONMASK = 0xFF; +const float DEATH_HITTYPEMASK = 0x1F00; // which is WAY below 10000 used for normal deaths +const float HITTYPE_SECONDARY = 0x100; +const float HITTYPE_SPLASH = 0x200; // automatically set by RadiusDamage +const float HITTYPE_BOUNCE = 0x400; +const float HITTYPE_RESERVED2 = 0x800; +const float HITTYPE_RESERVED = 0x1000; // unused yet