by D2JK » Wed Sep 17, 2014 5:44 am
Good that I saw this before submitting a duplicate request.
I agree this addition would be rather useful. For fast weapon switches, I currently use the "weave in zero-tic A_Lowers/Raises" method. Also, in lack of proper sprites, they're often useful for weapon reloads, cooldowns, etc (or to lower the gun when delivering a quick punch)... the default speed (6, as pointed out by OP) just isn't always desirable.
The Offset - keyword is another possibility, but it would simplify the decorate code if, instead of writing a great number of Offsets, you could just adjust the speed parameter in A_Lower/Raise instead, and loop it.
If you don't mind, I'll post a few illustrative examples.
Example 1:
Spoiler:
Code: Select all
Select:
WEAP A 1 A_Raise
WEAP A 0 A_Raise
Loop
Becomes:
Example 2:
Spoiler:
Code: Select all
Reload:
WEAP A 1 Offset(0,44)
WEAP A 1 Offset(0,54)
WEAP A 1 Offset(0,64)
WEAP A 1 Offset(0,74)
WEAP A 1 Offset(0,84)
WEAP A 1 Offset(0,94)
WEAP A 20 A_PlaySound("Reload")
WEAP A 1 Offset(0,84)
WEAP A 1 Offset(0,74)
WEAP A 1 Offset(0,64)
WEAP A 1 Offset(0,54)
WEAP A 1 Offset(0,44)
WEAP A 1 Offset(0,34)
Goto Ready
Becomes:
Code: Select all
Reload:
WEAP AAAAAA 1 A_Lower(10)
WEAP A 20 A_PlaySound("Reload")
WEAP AAAAAA 1 A_Raise(10)
Goto Ready
Good that I saw this before submitting a duplicate request.
I agree this addition would be rather useful. For fast weapon switches, I currently use the "weave in zero-tic A_Lowers/Raises" method. Also, in lack of proper sprites, they're often useful for weapon reloads, cooldowns, etc (or to lower the gun when delivering a quick punch)... the default speed (6, as pointed out by OP) just isn't always desirable.
The Offset - keyword is another possibility, but it would simplify the decorate code if, instead of writing a great number of Offsets, you could just adjust the speed parameter in A_Lower/Raise instead, and loop it.
If you don't mind, I'll post a few illustrative examples.
[b]Example 1:[/b]
[spoiler][code]
Select:
WEAP A 1 A_Raise
WEAP A 0 A_Raise
Loop
[/code]
[b]Becomes:[/b]
[code]
Select:
WEAP A 1 A_Raise(12)
Loop
[/code][/spoiler]
[b]Example 2:[/b]
[spoiler][code]
Reload:
WEAP A 1 Offset(0,44)
WEAP A 1 Offset(0,54)
WEAP A 1 Offset(0,64)
WEAP A 1 Offset(0,74)
WEAP A 1 Offset(0,84)
WEAP A 1 Offset(0,94)
WEAP A 20 A_PlaySound("Reload")
WEAP A 1 Offset(0,84)
WEAP A 1 Offset(0,74)
WEAP A 1 Offset(0,64)
WEAP A 1 Offset(0,54)
WEAP A 1 Offset(0,44)
WEAP A 1 Offset(0,34)
Goto Ready
[/code]
[b]Becomes:[/b]
[code]
Reload:
WEAP AAAAAA 1 A_Lower(10)
WEAP A 20 A_PlaySound("Reload")
WEAP AAAAAA 1 A_Raise(10)
Goto Ready
[/code][/spoiler]