Hi, i've ran into an issue where spawning headless_hatman, eyeball_boss, merasmus, tf_zombie entities seem to cause some sort of random collision damage. It just happens randomly, right now i have the entities hooked on SDK_OnTakeDamagePost and setting damage to 0.0.
PHP Code:
public Action OnBossDamaged(int victim, int &attacker, int &inflictor, float &damage, int &damagetype) {
//For some reason, bosses take damage randomly from DMG_CRUSH
PrintToChatAll("victim: %d | attacker: %d | damage: %f | type: %d", victim, attacker, damage, damagetype);
if(damagetype & DMG_CRUSH || damagetype & DMG_VEHICLE) {
damage = 0.0;
return Plugin_Changed;
}
return Plugin_Continue;
}
Also DMG_CRUSH seems to always do 10000.0 damage and DMG_VEHICLE always do 1000.0 damage. I'm stumped to why this even occurs.
Is there any other way to prevent the collision damage in the first place?
__________________