Hi everyone, what would be the mechanism of adding extra damage to a random bullet. Let's say 5% chance to make 20% more damage with a bullet.
This is what I'm using just now:
Code:
////
register_event("Damage", "on_damage", "b", "2!0", "3=0", "4!0");
///
public on_damage(victim)
{
if( !get_cvar_num("amx_vipscript") )
return;
static attacker, damage;
attacker = get_user_attacker(victim);
damage = read_data(2);
if( !attacker || !damage )
return;
if( menu_selected[victim] == 1 && IsPlayerVip(victim) )
{
set_hudmessage(200, 100, 0, 0.4, -1.0, 2, 0.1, 2.0, 0.02, 0.02, -1);
ShowSyncHudMsg(victim, g_MsgSync, "I wonder what has happened here %d", damage);
}
Cheers.