A_FireShotgun

From ZDoom Wiki
Jump to: navigation, search

A_FireShotgun

(no parameters)


Performs Doom's shotgun attack, firing seven pellets each dealing 5 * 1d3 damage. This is a shortcut for calling A_FireBullets, A_PlaySound and A_GunFlash with predetermined hard-coded parameters.

This code is the equivalent of calling A_FireShotgun for 7 tics on the A frame of the SHTG sprite:

    SHTG A 0 A_FireBullets (5.6, 0, 7, 5, "BulletPuff")
    SHTG A 0 A_PlaySound ("weapons/shotgf", CHAN_WEAPON)
    SHTG A 7 A_GunFlash