]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/deathtypes.qh
Fix compilation with gmqcc.
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / deathtypes.qh
index 48a269b1a3937271f6e4b10c297d20adac78f629..cc7154d4b6a8713de9236413ecdb01adcf2d0db1 100644 (file)
@@ -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
@@ -104,10 +102,10 @@ string Deathtype_Name(float deathtype)
        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