Problem with cornerpush.

Started by Niitris, November 15, 2011, 07:50:04 AM

Previous topic - Next topic

Niitris

I notice that mugen doesn't do cornerpush the way the source games do. I'm stuck on how to get the variables right to get it close enough to the source games. Its the only thing holding me back right now.  :???:

Cyanide

when target backedgebodydist <= 0 you should inherit target's current velocity for the slidetime left over. Which bit is currently NOT working for you? Is it the vel you inherit, the time you should slide for??


In M.U.G.E.N there is no magic button

They say a little knowledge is a dangerous thing, but it's not one half so bad as a lot of ignorance.

Niitris

Kind of both. I have no problem when the enemy is right on the corner, but when they're 10 or 20 pixels away from the edge, the velocity is too low.

Cyanide

well it working when p2 is right in the corner is because mugen's cornerpush is actually in effect. Now, i've never bothered doing this so you can either use what i'm going to invent right now, or you could look through the code library which will have the details you want as well.

In the attack
slidetime = var(1) : value of time

velset
trigger1 = target, backedgebodydist <= 5
x = target, vel X

physics should be N while var(1) is greater than 0.

State -2 must contain a varadd to decrease the slidetime variable while it's > 0. Need trigger1 = numtarget >= 1 and target, gethitvar(hitshakeover) so p2 is no longer paused and slidetime can actually decrease.

This will need much tweaking as you'll need to apply friction to p1 as well and you'll want to use displaytoclipboard just to confirm you're getting the same vel as p2 when you should be. That's really fast so, use the code library, or try out what i've given you and come back with problems.


In M.U.G.E.N there is no magic button

They say a little knowledge is a dangerous thing, but it's not one half so bad as a lot of ignorance.