Followup and Counter Followup

Followup
By Bloodbane  ;D

Intro: Probably most newbies aren't familiar with the title so let me describe it. Followup is automatic animation change effect which is triggered by attackbox which hit other entity. Examples are Abadede's ramming attack (Streets of Rage 2) and J-11's ramming attack (Ghost Chaser Densei). Both bosses have attack in which they charge forward while attacking. If their attack hits, they follow it up with combo attack, Abadede perform uppercut while J-11 perform flip then double kick. If their attack misses, they won't perform the combo at all.
Although above example is from enemies, followup can also be set for players too.

Procedure: 1st of all we need 2 animations, one is the attack animation which is going to have followup set and the other is the followup animation. The former could be any animations but the latter requires special animation named FOLLOW#. # is the number of follow animation.
Example:


Code:
anim grab
offset 40 121
bbox 39 20 21 102
delay 12
frame data/chars/joe/grab00.gif
frame data/chars/joe/grab03.gif
attack 68 40 33 33 8 0 1
frame data/chars/joe/grab04.gif
attack 0
delay 15
bbox 36 13 28 110
frame data/chars/joe/grab10.gif
This is Joe's grab animation. Say we want him to followup this attack with other grabattack. In order to do that, we need to use 2 commands: followanim and followcond.


followanim {value}
~Determines which FOLLOW animation played when followup condition is met or when counter condition is met.
~Accepted values are 1, 2, 3 and 4.
~Used together with 'followcond' or 'counterframe'.

followcond {value}
~This command is to make the entity performs FOLLOW{#} if an attackbox in the animation hits.
~value determines the condition requirements before FOLLOW{#} is played.
1 = this animation will followup as long as it hits an entity.
2 = this animation will followup as long as it hits an enemy (Or player if an enemy uses it).
3 = this animation will followup as long as it hits an enemy and the target does not get killed or block the attack.
4 = this animation will followup as long as it hits an enemy, and the target is not killed, does not block the attack, and is not set to be ungrabbable.
~Which FOLLOW animation played is determined by 'followanim'.

Let's pick FOLLOW1 for followup animation and pick 3rd condition. So the grab animation becomes:


anim grab
followanim 1
followcond 3
offset 40 121
bbox 39 20 21 102
delay 12
frame data/chars/joe/grab00.gif
frame data/chars/joe/grab03.gif
attack 68 40 33 33 8 0 1# <--------
frame data/chars/joe/grab04.gif
attack 0
delay 15
bbox 36 13 28 110
frame data/chars/joe/grab10.gif

anim follow1
delay 12
offset 40 121
bbox 39 20 21 102
attack 68 40 33 33 8 0 1
frame data/chars/joe/grab04.gif
attack 0
frame data/chars/joe/grab03.gif
frame data/chars/joe/grab00.gif
frame data/chars/joe/grab03.gif
attack 68 40 33 33 8 0 1
frame data/chars/joe/grab04.gif
attack 0
delay 15
bbox 36 13 28 110
frame data/chars/joe/grab10.gif
When attackbox pointed by arrow above hits player, GRAB animation is stopped and Joe playes FOLLOW1 immediately. Notice that FOLLOW1 is started from frame with attackbox pointed by arrow in GRAB. That's to make animation change smooth.

Issue: As explained before, followup is activated if attackbox hits other entity and conditions are met. And above example starts FOLLOW animation in attacking frame. Now what if the attack animation has 2 or more attackboxes? at which frame FOLLOW animation should start for smooth animation change? That's the issue for using followup. It can be avoided by using only one attackbox in attack animation.
Still, script can solve this issue.

Extra: Followups can be set cascading meaning FOLLOW animation can have 'followanim' and 'followcond' to accept follow. Example:

Code:
anim grab
followanim 1
followcond 3
offset 40 121
bbox 39 20 21 102
delay 12
frame data/chars/joe/grab00.gif
frame data/chars/joe/grab03.gif
attack 68 40 33 33 8 0 1
frame data/chars/joe/grab04.gif
attack 0
delay 15
bbox 36 13 28 110
frame data/chars/joe/grab10.gif

anim follow1
delay 12
followanim 2
followcond 3
offset 40 121
bbox 39 20 21 102
attack 68 40 33 33 8 0 1
frame data/chars/joe/grab04.gif
attack 0
frame data/chars/joe/grab03.gif
frame data/chars/joe/grab00.gif
frame data/chars/joe/grab03.gif
attack 68 40 33 33 8 0 1
frame data/chars/joe/grab04.gif
attack 0
delay 15
bbox 36 13 28 110
frame data/chars/joe/grab10.gif

anim follow2
delay 12
jumpframe 4 1 0
offset 40 121
bbox 39 20 21 102
attack 68 40 33 33 8 0 1
frame data/chars/joe/grab04.gif
attack 0
frame data/chars/joe/grab03.gif
frame data/chars/joe/grab00.gif
delay 20
frame data/chars/joe/grab07.gif
delay 13
bbox 44 13 28 110
attack 63 32 33 33 14 1 1
frame data/chars/joe/grab08.gif
frame data/chars/joe/grab09.gif
attack 0
delay 15
bbox 36 13 28 110
frame data/chars/joe/grab10.gif
Another extra stuff is followup can also be trigger if entity is hit by other entity instead. To set this, 'counterframe' is used instead of 'followcond'. Details are explained in next section.

Read more: http://openbor.boards.net/index.cgi?board=tutorials&action=display&thread=15#ixzz2FGi8Jw1E
 
Counter Followup

Intro: If you have read previous section, you should have understand meaning of followup and how to set one. This tutorial explains how to set followup which is triggered by getting hit instead of hitting other entity.

Procedure: The requirements are same, attack animation and follow animation. Followanim is used to determine which FOLLOW animation to play but this time we used it together with 'counterframe' instead.


counterframe {frame} {cond} {damaged}
~This command is to make entity performs FOLLOW{#} if the entity is hit in set frame.
~frame determines at which frame if entity is hit, FOLLOW{#} would be played.
~cond determines the condition requirements before FOLLOW{#} is played.
1: The counter will always be used.
2: The counter will be used as long as the attacker was an enemy (Or a player if an enemy uses it).
3: The counter will be used as long as the attacker was an enemy, the attack was not unblockable, hits the user from the front, and was not a FREEZE attack.
~damaged determines whether the entity will receive damage from the hit or not.
0: the damage won't be taken
1: the damage will be taken
Edit: use counterrange instead, check the next post.

Here's an example:

Code:
anim attack2
range 0 100
rangez -25 25
delay 100
followanim 1
counterframe 1 1 0
offset 30 115
bbox 20 10 30 105
frame data/chars/enemy/decoy1.gif
frame data/chars/enemy/decoy2.gif
frame data/chars/enemy/decoy1.gif

anim follow1
delay 5
offset 30 115
frame data/chars/enemy/counter1.gif
delay 50
attack 30 30 70 80 20 1 1
frame data/chars/enemy/counter2.gif
delay 5
frame data/chars/enemy/counter1.gif
If enemy is hit while performing ATTACK2 and in 2nd frame (decoy2.gif), enemy will stop ATTACK2 animation and immediately play FOLLOW1. Enemy won't lose any health at all because of 'counterframe' setting.

Limitation: As you can see, we can only set one frame to receive hit. That means we can't use more frames to make 'countering' animation smoother. Edit: use counterrange instead, check the next post.

Script: Like before, there's no direct function to replicate above effects. The best way to do it is by using 'takedamagescript' which is played when entity is hit by an attack. The script checks the conditions (could be more than just defined by 'counterframe'above), if they are sufficient, script changes entity's animation to other animation (could be FOLLOW or any animations).

Read more: http://openbor.boards.net/index.cgi?board=tutorials&action=display&thread=15#ixzz2FGiEvYAo
 
Just an update:
Now you can use Counterrange to set in how many frames the counter is active:

counterrange {start} {end} {condition} {damage}

~Animation header. Replaces Counterframe and works identically except where noted.
~{start} Start of frame range when counter may trigger.
~{end} End of frame range when counter may trigger.
 
Back
Top Bottom