A_FireCGun

From ZDoom Wiki
Jump to navigation Jump to search

A_FireCGun

DoomWiki.org
For more information on this article, visit the A_FireCGun page on the Doom Wiki.


(no parameters)

Usage

Does the standard Chaingun attack. It plays the sound "weapons/chngun", runs the flash state, and fires one bullet similar to A_FirePistol.

If vertical bullet spread for weapons is enabled, the function applies vertical spread in addition to the horizontal one.

Examples

This code is equivalent to A_FireCGun.

  Fire:
     CHGG A 0 A_PlaySound("weapons/chngun", CHAN_WEAPON)
     CHGG A 0 A_GunFlash
     CHGG A 4 A_FireBullets(5.6, 0, 1, 5, "BulletPuff")
     CHGG B 0 A_PlaySound("weapons/chngun", CHAN_WEAPON)
     CHGG B 0 A_GunFlash("Flash2")
     CHGG B 4 A_FireBullets(5.6, 0, 1, 5, "BulletPuff")
     CHGG B 0 A_ReFire
     Goto Ready
  Flash:
     CHGF A 4 Bright A_Light1
     Goto LightDone
  Flash2:
     CHGF B 4 Bright A_Light2
     Goto LightDone