Call of Duty bo3: Damage types and MeansOfDeath

From COD Modding & Mapping Wiki
Jump to: navigation, search
This is a list of available damage types and MeansOfDeath (MOD)
Name Description
MOD_DROWN When the player drowns
MOD_HIT_BY_OBJECT Hit by an object
MOD_MELEE_WEAPON_BUTT Killed by being hit with the end of a weapon.
MOD_BAYONET Injured or killed by Bayonet
MOD_BURNED Burned with flamethrower or molotov
MOD_CRUSH Run over by a tank
MOD_EXPLOSIVE Damage received by explosive type weapon
MOD_FALLING Fall damage
MOD_GRENADE Grenade launcher impact, molotov direct hit, satchel detonation (if stuck to a vehicle for instance)
MOD_GRENADE_SPLASH Grenade and satchel explosion
MOD_HEAD_SHOT Headshot death
MOD_IMPACT Direct impact of flares, grenades etc.
MOD_MELEE Knife attack
MOD_PISTOL_BULLET Pistols and shotguns
MOD_PROJECTILE Projectile type weapon
MOD_PROJECTILE_SPLASH Projectile explosion
MOD_SUICIDE Self murder (e.g. carried out by an anti-camping script)
MOD_TELEFRAG Telefragged (entity spawned into another kills the first entity)
MOD_TRIGGER_HURT Injured by a trigger_hurt
MOD_UNKNOWN Misc. type (undefined MOD)

Code examples


self waittill( "damage", damage, attacker, direction, point, type, modelName, tagName, partname, weapon, flags, inflictor, chargeLevel );

[[level.callbackPlayerDamage]]( eInflictor, eAttacker, iDamage, iDFlags, sMeansOfDeath, weapon, vPoint, vDir, sHitLoc, vDamageOrigin, psOffsetTime, 
boneIndex, vSurfaceNormal );
eInflictor The entity that causes the damage (e.g. a turret)
eAttacker The entity that is attacking
iDamage Integer specifying the amount of damage done
iDFlags Integer specifying flags that are to be applied to the damage
sMeansOfDeath Integer specifying the method of death
sWeapon The weapon number of the weapon used to inflict the damage
vPoint The point the damage is from?
vDir The direction of the damage
sHitLoc The location of the hit
psOffsetTime The time offset for the damage


level.iDFLAGS_NOFLAG                            = 0;
level.iDFLAGS_RADIUS                            = 1;        // damage was indirect
level.iDFLAGS_NO_ARMOR                          = 2;        // armor does not protect from this damage
level.iDFLAGS_NO_KNOCKBACK                      = 4;        // do not affect velocity, just view angles
level.iDFLAGS_PENETRATION                       = 8;        // damage occurred after one or more penetrations
level.iDFLAGS_DESTRUCTIBLE_ENTITY               = 16;       // force the destructible system to do damage to the entity
level.iDFLAGS_SHIELD_EXPLOSIVE_IMPACT           = 32;       // missile impacted on the front of the victim's shield
level.iDFLAGS_SHIELD_EXPLOSIVE_IMPACT_HUGE      = 64;       // ...and was from a projectile with "Big Explosion" checked on.
level.iDFLAGS_SHIELD_EXPLOSIVE_SPLASH           = 128;      // explosive splash, somewhat deflected by the victim's shield
level.iDFLAGS_HURT_TRIGGER_ALLOW_LASTSTAND      = 256;      // The trigger that applied the damage will ignore laststand
level.iDFLAGS_DISABLE_RAGDOLL_SKIP              = 512;      // Don't go to ragdoll if got damage while playing death animation

// script-defined:
level.iDFLAGS_NO_TEAM_PROTECTION                = 1024;
level.iDFLAGS_NO_PROTECTION                     = 2048;
level.iDFLAGS_PASSTHRU                          = 4096;


level.player waittill( "death", attacker, cause, weaponName );

[[level.callbackPlayerKilled]](eInflictor, eAttacker, iDamage, sMeansOfDeath, sWeapon, vDir, sHitLoc, timeOffset, deathAnimDuration);
deathAnimDuration Length of the death animation

(see above for the rest)