Jump to content
  • 0

Why do you float?


wicloud

Question

Im not sure why but in some fights while im fighting or the AI is fighting I encounter characters who get stuck up in the air.

 

What causes this? Can it be fixed or can i use a debug key to fix it? 

 

I press CTRL + I hoping that might do something and sometimes it does. The character's AI will jump down but other times it'll stand there and try to hit the opponent. This is never an issue while im not recording but it's a problem while i am. 

 

Floating is sometimes caused by the following: Countering Grapples, Grappled during Pausetime, initiating Pausetime moves while user or opponent is jumping/launched into the air and using pausetime as part of a counter attack.

 

I know it's never just a random mishap, some characters may have missing states/sprites and others are just interrupted during certain actions at the wrong time. If anyone knows how I may be able to fix this let me know. It could occur by certain characters causing different situations.

 

Pill by Robo<---has a move that pauses time and uses it at any time. She causes floating on herself and her opponents so I'll see if I can get her fixed and use the helpful advice on any future floaters. She's my main focus since she does it a lot.

 

 

Link to comment
Share on other sites

5 answers to this question

Recommended Posts

  • 0

If something forces you into statedef 0, mugen doesn't defaultly have a means by which to make you fall down.
 
I modified my common1.cns to have this and it not only seems to fix that, but also makes characters work on Mario Stage
 

; Stand
[Statedef 0]
type = S
physics = S
sprpriority = 0

[State 0, 1]
type = ChangeAnim
trigger1 = Anim != 0 && Anim != 5
trigger2 = Anim = 5 && AnimTime = 0 ;Turn anim over
value = 0

[State 0, 2]
type = VelSet
trigger1 = Time = 0
y = 0

[State 0, 3] ;Stop moving if low velocity or 4 ticks pass
type = VelSet
trigger1 = abs(vel x) < Const(movement.stand.friction.threshold)
trigger2 = Time = 4
x = 0

[State 0, 4] ;Are you dead?
type = ChangeState
trigger1 = !alive
value = 5050

[State 0, 5] ;Are you floating?
type = ChangeState
triggerall = pos y < 0
trigger1 = time > 1
value = 50
Link to comment
Share on other sites

  • 0

i think this may be caused by pause times being to high or even having a custom state that is causing the character to float, or even the value of the changestate could be zero instead of 52. I'm still new to coding so i'm not sure if what i am saying is correct, so if someone see's this and i am wrong, please correct me with the correct info

Link to comment
Share on other sites

  • 0

 

If something forces you into statedef 0, mugen doesn't defaultly have a means by which to make you fall down.

 

I modified my common1.cns to have this and it not only seems to fix that, but also makes characters work on Mario Stage

 

; Stand
[Statedef 0]
type = S
physics = S
sprpriority = 0

[State 0, 1]
type = ChangeAnim
trigger1 = Anim != 0 && Anim != 5
trigger2 = Anim = 5 && AnimTime = 0 ;Turn anim over
value = 0

[State 0, 2]
type = VelSet
trigger1 = Time = 0
y = 0

[State 0, 3] ;Stop moving if low velocity or 4 ticks pass
type = VelSet
trigger1 = abs(vel x) < Const(movement.stand.friction.threshold)
trigger2 = Time = 4
x = 0

[State 0, 4] ;Are you dead?
type = ChangeState
trigger1 = !alive
value = 5050

[State 0, 5] ;Are you floating?
type = ChangeState
triggerall = pos y < 0
trigger1 = time > 1
value = 50

I'll give the "are you floating" code a try on Pill and see if it'll work on her. 

Link to comment
Share on other sites

  • 0

 

If something forces you into statedef 0, mugen doesn't defaultly have a means by which to make you fall down.

 

I modified my common1.cns to have this and it not only seems to fix that, but also makes characters work on Mario Stage

 

; Stand
[Statedef 0]
type = S
physics = S
sprpriority = 0

[State 0, 1]
type = ChangeAnim
trigger1 = Anim != 0 && Anim != 5
trigger2 = Anim = 5 && AnimTime = 0 ;Turn anim over
value = 0

[State 0, 2]
type = VelSet
trigger1 = Time = 0
y = 0

[State 0, 3] ;Stop moving if low velocity or 4 ticks pass
type = VelSet
trigger1 = abs(vel x) < Const(movement.stand.friction.threshold)
trigger2 = Time = 4
x = 0

[State 0, 4] ;Are you dead?
type = ChangeState
trigger1 = !alive
value = 5050

[State 0, 5] ;Are you floating?
type = ChangeState
triggerall = pos y < 0
trigger1 = time > 1
value = 50

Thanks! It works to a good extent! however she still floats a tiny bit when throwing/attempting attacks. However the code forces her back down rather quickly instead of allowing her to float forever.

Link to comment
Share on other sites

  • 0

There can be several different causes for this.  If it is an old v01,01,2000 coded character then it will be missing the 5070 states which means the 'fall down' states after getting hit are missing.  Also can be a coding error where a throw or such is returning a player to state 0 instead of state 52.  State 52 returns the p;ayer to the ground whereas state 0 doesn't.  Caused by the physics parameter because if physics is S (stand) or C (crouch) then no velocities, but if physics is set to A (air) the the player will return to the ground afterwards.  A good idea might be to turn on 'debug mode' to see what comes up when the character gets stuck.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...