• Welcome, Guest. Please login.
 
November 27, 2024, 01:33:56 AM

News:

If you have problems logging in, contact an administrator.


Healing

Started by Websta, April 21, 2013, 06:38:21 AM

Previous topic - Next topic

Websta

I've run into a little bit of trouble, and hoping somebody can help me out with this.

If you had an attack which is supposed to heal an opponent or give them power, how would you code that? Also, the opponent's state must not change at all.

Jesuszilla

TargetLifeAdd, TargetPowerAdd, or in the hitdef you could use givepower and use negative damage values.


Just try to keep things peaceful.

Websta

April 21, 2013, 03:10:06 PM #2 Last Edit: April 21, 2013, 03:15:16 PM by Websta
Lifeadd requires a custom state
Hitdef changes P2 to state 5000 even if the stun is set to 0
TargetLifeAdd requires a target, target becomes available if p2 is hit

I can get it to work. However I don't want P2 to be interrupted at all. God forbid the sort of glitches that can cause.

KoopaKoot

You'll probably have to affect them for just a moment then send them back to neutral or their previous state.

[Statedef N]
physics = N
ctrl = 0

[State N]
type = SelfState/Destroyself
trigger1 = IsHelper
value = prevstateno ;or remove this if it's destroyself

[State N]
type = SelfState
trigger1 = !IsHelper
value = 0/prevstateno
ctrl = 1


Click Here.

Websta

Makes sense, but some characters might go haywire if they're interrupted in the middle of a state.

Jesuszilla

April 24, 2013, 03:27:48 PM #5 Last Edit: April 24, 2013, 03:31:01 PM by Jesuszilla
Really depends, actually. If it's an attack, then they should have based most triggers on AnimTime or AnimElemTime in the first place. Otherwise, as long as you're not changing their animation in the custom state, it will not disrupt playback... until they re-enter their state, in which case, yeah, the animation will most likely restart.

What you could do is have the hit (as through a helper) persist until they are back to a neutral state (stateNo = [0,20]) and have it only hit then.


Just try to keep things peaceful.

Websta

That's a really clever idea. But what if that attack state gets canceled into... A ranbu attack? The heal would kick nearly 5 seconds after the heal was supposed to happen. And god forbid that ranbu is dreamcanceled or some sh1t into another ranbu.

Jesuszilla

Yes, it will delay the timing of the heal, but it won't matter. There are 2 cases:


  • The partner is in a ranbu in which they are invincible after successful connect. The ranbu finishes, and the partner returns to an idle state.
  • The partner is in a ranbu in which they are still vulnerable even after successful connect. This one is the main issue. The partner is hit out of the ranbu. If the opponent sucks, then after the hurt state, they should return to idle state unless it results in a KO. If they're caught in a combo, then that also complicates things.

For case 2, I think MUGEN will reset the hittime and fuck up the opponent's combo if you decide to heal them even when moveType = H. It's possible that you could cover it up by claiming, "HYPER HEAL!"


Just try to keep things peaceful.

Websta

Thanks you guys, for taking the time to reply to this topic. Fuck this healing move.

DivineWolf

Lol! Well, that's one way to solve it all. I was actually interested in this topic myself. Due to some things I may have wanted to do in the future. It was pretty informative.