Hi there. I was wondering if the regulars here could confirm some or all of the following, based on the DECORATE version of the Pistol code as listed on the ZDoom Wiki:
- When you press the button to fire the pistol, it first goes into 4 frames of "pre-fire", so that the gun doesn't fire straight away when you pres the button.
- After these 4 frames, the gun then fires the bullet, and displays the appropriate sprite for 6 frames, and then another sprite for 4 frames.
- At this point, it checks to see if you're still holding down the fire button. If you are, it goes through the {A4; Fire; B6; C4;} sequence again.
- If you aren't holding down the button when that check is made, then the gun goes into a "cool-down" state where you aren't able to fire again for an additional 5 frames.
- The code as shown does not account for the first bullet always being accurate.
Is there anything that I am understanding incorrectly?
Trying to understand the Pistol
Moderator: wildweasel
-
- Posts: 4
- Joined: Wed May 09, 2007 20:18
- Location: Bristol, UK
-
- DRD Team Admin (Inactive)
- Posts: 2132
- Joined: Wed Jun 29, 2005 22:00
- Location: the Admincave!
-
- Posts: 4
- Joined: Wed May 09, 2007 20:18
- Location: Bristol, UK
-
- DRD Team Admin (Inactive)
- Posts: 2132
- Joined: Wed Jun 29, 2005 22:00
- Location: the Admincave!
No, the shotgun page is also correct, as refire accuracy only applies to weapons that fire a single bullet per shot. If the bullet count in A_FireBullets is set to any number greater than 1, then it automatically turns it into a spread shot weapon. If the number is set to -1, only one bullet is fired, and that shot is never accurate.
-
- Posts: 4
- Joined: Wed May 09, 2007 20:18
- Location: Bristol, UK
-
- Posts: 397
- Joined: Tue Jul 19, 2005 4:14
- Location: Programmer's Room, talking to Will Harvey
-
- Posts: 364
- Joined: Sat Jul 09, 2005 4:25
-
- Posts: 1000
- Joined: Wed Jul 06, 2005 11:58
- Location: What's that fucking smell
-
- DRD Team Admin (Inactive)
- Posts: 2132
- Joined: Wed Jun 29, 2005 22:00
- Location: the Admincave!