[2.6.1] ScriptedMarine shotgun fire

Bugs that have been investigated and resolved somehow.

Moderator: GZDoom Developers

Forum rules
Please don't bump threads here if you have a problem - it will often be forgotten about if you do. Instead, make a new thread here.
Post Reply
mi123645
Posts: 19
Joined: Thu Aug 16, 2012 3:51 pm

[2.6.1] ScriptedMarine shotgun fire

Post by mi123645 »

The Shotgun marine fires a little too fast for using a pump action shotgun. I suggest a delay of 20 tics at the end of the shotgun fire state, as well as a delay of 40 tics for the SSG marine.
User avatar
Ed the Bat
Posts: 3060
Joined: Thu May 03, 2012 1:18 pm
Graphics Processor: nVidia with Vulkan support
Location: Maryland, US
Contact:

Re: [2.6.1] ScriptedMarine shotgun fire

Post by Ed the Bat »

mi123645 wrote:I suggest...
Then shouldn't this be in Feature Suggestions? Not that I support this anyway. Doesn't it already roughly match up with the possessed sergeant's pump shotgun?
mi123645
Posts: 19
Joined: Thu Aug 16, 2012 3:51 pm

Re: [2.6.1] ScriptedMarine shotgun fire

Post by mi123645 »

The amount of tics was a suggestion. The point is that there should be a delay so that it's like the player's shotgun, or at least the shotgun guy's ROF. And no, it doesn't match up with the Shotgun guy's ROF.
User avatar
Ed the Bat
Posts: 3060
Joined: Thu May 03, 2012 1:18 pm
Graphics Processor: nVidia with Vulkan support
Location: Maryland, US
Contact:

Re: [2.6.1] ScriptedMarine shotgun fire

Post by Ed the Bat »

Hm. I don't work much with scripted marines since they're only really intended for scripted events, like cutscenes (hence the name). Even still, it looks like it takes him 34 tics between shots, which is identical to the player's shotgun.
mi123645
Posts: 19
Joined: Thu Aug 16, 2012 3:51 pm

Re: [2.6.1] ScriptedMarine shotgun fire

Post by mi123645 »

I should have posted the states in the beginning to illustrate my point, my bad. Here is the comparison:

Code: Select all

ScriptedMarine:

Missile.Shotgun:
    PLAY E 3 A_M_CheckAttack
    PLAY F 7 Bright A_M_FireShotgun
    Goto See
  Missile.SSG:
    PLAY E 3 A_M_CheckAttack
    PLAY F 7 Bright A_M_FireShotgun2
    Goto See

Code: Select all

ShotgunGuy:

Missile:
    SPOS E 10 A_FaceTarget
    SPOS F 10 Bright A_SPosAttackUseAtkSound
    SPOS E 10
    Goto See

Code: Select all

Shotgun:
Fire:
    SHTG A 3
    SHTG A 7 A_FireShotgun
    SHTG BC 5
    SHTG D 4
    SHTG CB 5
    SHTG A 3
    SHTG A 7 A_ReFire
    Goto Ready
So we know the total amount of tics is 10 in the ScriptedMarine's shotgun attack (3+7). The total amount of tics in the ShotgunGuy's missile state is 30. And the total amount of tics in the fire state of the shotgun is 34.

Since the ScriptedMarine's attack is only 10 tics, its going to return to it's See state faster than that of the ShotgunGuy and the player. The SSG marine has the same amount of tics for his attack, which definitely doesn't make sense.

If we add a delay at the end of the missile state, the ScriptedMarine won't enter his See state so quickly.
User avatar
Ed the Bat
Posts: 3060
Joined: Thu May 03, 2012 1:18 pm
Graphics Processor: nVidia with Vulkan support
Location: Maryland, US
Contact:

Re: [2.6.1] ScriptedMarine shotgun fire

Post by Ed the Bat »

You didn't account for the 27 tic points added to Special1 when A_M_FireShotgun is called. Since it takes 7 tics to animate the firing (not counting the 3 while he's aiming), and 7 + 27 = 34, this is equal to the 34 from a player's shotgun. So that's faithful to a player character.

Entering his See state shouldn't be an issue. There's no reason a player can't start walking around when firing his gun, so this makes the scripted marine actually about 10 tics slower on that.
mi123645
Posts: 19
Joined: Thu Aug 16, 2012 3:51 pm

Re: [2.6.1] ScriptedMarine shotgun fire

Post by mi123645 »

I see that it adds tic points to Special1, but in-game, I seem to see both of them sometimes firing faster than usual. Maybe I just need sleep :P

Moderators can trash this thread.
Post Reply

Return to “Closed Bugs [GZDoom]”