News:

MFG's Character of the Month: October 2026 Nominations

Main Menu

Stuck in a Loop

Started by Dylan Hlava, June 29, 2013, 08:42:01 AM

Previous topic - Next topic

Dylan Hlava

Sometimes with my character, if I keep doing an attack over and over, they get stuck in a loop repeating the animation doing no damage and being unable to move unless they are attacked.

I don't know what it is because no errors show up when I test the character.

Rajaa Retired

Which attack repeats itself? Post the code connected to that attack.

Dylan Hlava

Quote from: Rajaa on June 29, 2013, 09:53:10 AM
Which attack repeats itself? Post the code connected to that attack.

I'm not sure exactly which ones, I know there's more but the most common one is The Light Punch.

; Stand Light Punch
[Statedef 200]
type    = S                     
movetype= A                 
physics = S                   
juggle  = 1                   
velset = 0,0                   
ctrl = 0                         
anim = 200               
poweradd = 20                   
sprpriority = 2                 

[State 200, 1]
type = HitDef
trigger1 = AnimElem = 2
attr = S, NA                     
damage = 23, 0                 
animtype = Light                 
guardflag = MA                   
hitflag = MAF                   
priority = 3, Hit               

pausetime = 8, 8               
sparkno = 0                     
sparkxy = -10, -76               
hitsound = 5, 0                 
guardsound = 6, 0               
ground.type = High             
ground.slidetime = 5             
ground.hittime  = 10         
ground.velocity = -4             
airguard.velocity = -1.9,-.8   
air.type = High                 
air.velocity = -1.4,-3           
air.hittime = 12                 

[State 200, 1]
type = PlaySnd
trigger1 = Time = 1
value = 0, 0

[State 200, 7]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

Seravy

Turn on debug mode.
Look for the debug messages when it happens.

I expect you to see "invalid state" and a number there.  When you enter an invalid state, the character will keep doing the previous animation, and in general nothing changes. If you enter an invalid state without having control, you'll never get it back (unless you get hit), and since the state doesn't exist, it won't contain anything that would actually make an attack to go along with the animation. So find the changestate that puts you into that state and fix it.

In short, you most likely have an attack you can cancel other attacks into, that has an invalid state number set in your cmd file.

Odb718

The animation can also have a loop set in it. Animtime = 0 wont ever activate then.
vVv Gouken718 vVv SabreTooth718 vVv


Basara Bogard

Quote from: Metasponge64 on June 29, 2013, 07:52:24 PM
Quote from: Rajaa on June 29, 2013, 09:53:10 AM
Which attack repeats itself? Post the code connected to that attack.

I'm not sure exactly which ones, I know there's more but the most common one is The Light Punch.
It looks normal, so the problem could be in AIR or CMD. Can you post them too to see where's the problem??