News:

MFG's Character of the Month: October 2026 Nominations

Main Menu

[Solved] Soul Body

Started by DragonFaku, June 03, 2011, 04:48:46 PM

Previous topic - Next topic

DragonFaku

Did anyone knows how to make the Soul Body from Megaman X4?
http://www.youtube.com/watch?v=jbW-TiujiR0 minute 0:57
i have no idea how to do it.
Please help me.

Rajaa Retired

Show us what you came up with so far.

DragonFaku

Quote from: Assman on June 03, 2011, 05:01:45 PM
Show us what you came up with so far.
i don't have anything in coding, because i have no idea how to make something like that

Cyanide

Shall we start with the wall one then? Create a helper. Make it bindtoparent in front of you somewhere. Give it blue clsn boxes and a hitoverride that sends it to ANOTHER state where it plays a destruction animation and uses destroyself.

I am assuming you have some coding knowledge here, if you have none it's going to be a little while before you're at the point where you could code the above.


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.

DragonFaku

Quote from: Cyanide on June 04, 2011, 01:15:42 AM
Shall we start with the wall one then? Create a helper. Make it bindtoparent in front of you somewhere. Give it blue clsn boxes and a hitoverride that sends it to ANOTHER state where it plays a destruction animation and uses destroyself.

I am assuming you have some coding knowledge here, if you have none it's going to be a little while before you're at the point where you could code the above.

This is what i did of the code so far:

[Statedef 999]
type    = S
movetype= A
physics = S
juggle  = 8
ctrl = 0
poweradd = 25
velset = 0,0
anim = 1100

[State -2, Holo]
type = helper
trigger1 = AnimElem = 3
helpertype =normal
name ="test"
id =1000
stateno = 1000
pos = 50,0
postype = p1
sprpriority = 5
ownpal = 1

[State 210, 1]
type = PlaySnd
trigger1 = AnimElem = 3
value = 6,8

[State 202, 3]
type = ChangeState
trigger1 = animtime =0
value = 0
ctrl =1

[Statedef 1000]
type    = S
movetype= i
physics = S
juggle  = 8
ctrl = 0
velset = 0,0
anim = 3420
sprpriority = 4

[State -2, 1000]
type = BindToRoot
trigger1 = Parent, Stateno != [1500,1520]
time =-1
ID = 1000
pos = 55,0

[State -2, 1000]
type = BindToRoot
trigger1 = Parent, Stateno = [1500,1520]
time =-1
ID = 1000
pos = 55,0

[State -2, 1000]
type = turn
trigger1 = P2BodyDist x<=0

[State 370, Destroyed]
type = changestate
trigger1=Lose=1
trigger2 = Win=1
trigger3 =DrawGame=1
trigger4 = Parent, movetype = h
trigger4 = Parent, StateNo != [120,155]
trigger5 = time = 300
value = 1001

[Statedef 1001]
type    = s
movetype= i
physics = s
juggle  = 8
velset = 0,0
ctrl = 0
anim = 3421
sprpriority = 4

[State -2, 1001]
type = BindToRoot
trigger1 = Parent, Stateno != [1500,1520]
time =-1
ID = 1000
pos = 55,0

[State -2, 1001]
type = BindToRoot
trigger1 = Parent, Stateno = [1500,1520]
time =-1
ID = 1000
pos = 55,0

[State 1073,2]
type = DestroySelf
trigger1 = time = 12

I didn't add a HitOverride because the soul body doesn't get hit by projectiles or normal attacks.
Now i want the hologram to make the same moves i do (walk, jump, crouch, wall jump, dash)

Cyanide

Ok, that's an excellent start then.

For the changeanim. Note down which animations the parent uses for these attacks. Duplicate them on your helper and add 10000 to each one. So your version of Stand is anim 10000. Your version of walk is 10020 etc.

Then include the following.

type = changeanim
trigger1 = anim != root, anim + 10000
value = root, anim + 10000

Should work.


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.

DragonFaku

Quote from: Cyanide on June 04, 2011, 05:04:25 AM
Ok, that's an excellent start then.

For the changeanim. Note down which animations the parent uses for these attacks. Duplicate them on your helper and add 10000 to each one. So your version of Stand is anim 10000. Your version of walk is 10020 etc.

Then include the following.

type = changeanim
trigger1 = anim != root, anim + 10000
value = root, anim + 10000

Should work.
can you make a code example?, because im a little lost with that  :S

Cyanide

Err, that IS the example.

Read what it's doing. Taking walk as the example. In the parent, walk is animation 20. In your special helper, walk will be 10020. So what that bit of code does is checks if the anim currently in use is the same animation as the parent + 10000.

So if anim (that's 10000 at this point) is not = to the roots anim of 20+10000 then it will change to root anim + 10000, and become 10020. Really, just try it and see what it does. Things like root, anim are redirects, so it's checking what the character is doing and applying it to it's own code. Aside from needing the [state ] bit, what's there is functional.


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.

DragonFaku

Quote from: Cyanide on June 04, 2011, 06:35:29 AM
Err, that IS the example.

Read what it's doing. Taking walk as the example. In the parent, walk is animation 20. In your special helper, walk will be 10020. So what that bit of code does is checks if the anim currently in use is the same animation as the parent + 10000.

So if anim (that's 10000 at this point) is not = to the roots anim of 20+10000 then it will change to root anim + 10000, and become 10020. Really, just try it and see what it does. Things like root, anim are redirects, so it's checking what the character is doing and applying it to it's own code. Aside from needing the [state ] bit, what's there is functional.

Oops, my mistake, sorry  :P

Anyways, i maded the +10000 anims, and it works really well, but there is one single issue.
The hologram doesn't turn. For example, i am facing the opponent, i use the hologram, i walk to the other side, but when i turn to the other side, the hologram faces to me


Cyanide

turn
trigger1 = facing != root, facing


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.

DragonFaku

I was testing the code a little while, and the wall jump hologram doesn't show up


BTW, how can i make the hologram dissapear like in the game?
In the game the hologram blinks a little bit and then it disappears

Cyanide

Figure out when it's meant to blink, then simply use the flag invisible, from assertspecial to apply it. If you use persistent = 2 or whatever on the controller it'll vanish every 2 ticks.

As for on wall jump, you have that animation? Press ctrl+C to see if the helper is on or off screen, it may be bound on the wrong side.


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.

DragonFaku

#12
this is the new code for the helper
[Statedef 1000]
type    = S
movetype= i
physics = S
juggle  = 8
ctrl = 0
velset = 0,0
anim = 3420
sprpriority = 4

[State -2, 1000]
type = BindToRoot
trigger1 = Parent, Stateno != [1500,1520]
time =-1
ID = 1000
pos = 55,0

[State -2, 1000]
type = BindToRoot
trigger1 = Parent, Stateno = [1500,1520]
time =-1
ID = 1000
pos = 55,0

[State -2, 1000]
type = turn
trigger1 = facing != root, facing

[State 370, Destroyed]
type = Destroyself
trigger1=Lose=1
trigger2 = Win=1
trigger3 =DrawGame=1
trigger4 = Parent, movetype = h
trigger4 = Parent, StateNo != [120,155]
trigger5 = time = 300

[State 0, AssertSpecial]
type = AssertSpecial
trigger1 = time = 300
flag = invisible
persistent = 2

[State 0, ChangeAnim]
type = changeanim
trigger1 = anim != root, anim + 10000
value = root, anim + 10000


and i can't make him blink.

BTW, yes, i checked the wall jump anims, but, i think the hologram it's in the oposite side of the screen, i mean, when you are doing the wall jump, the hologram goes to the wall instead of facing outside

EDIT: i fixed that by fixing the X axis in the .AIR

Cyanide



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.

DragonFaku

still not blinking

Cyanide

Missed that, you destroy it on time = 300 as well, so it'll just vanish without ever doing the assertspecial. Have the assert earlier, or the destroyself later.


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.

DragonFaku

Quote from: Cyanide on June 05, 2011, 12:15:19 AM
Missed that, you destroy it on time = 300 as well, so it'll just vanish without ever doing the assertspecial. Have the assert earlier, or the destroyself later.
yeah, i figured that out a little while ago, but now i am trying the helper to go to pos = 0,0 when it's time = 290

LaQuak

You can try:

type = PosSet
trigger1 = Time >= 290
pos = 0,0

Cyanide

Posset takes X and Y, not pos =

He needs to turn off the bindtoparent from 290 onwards.


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.

DragonFaku

#19
Quote from: Cyanide on June 05, 2011, 03:29:32 AM
Posset takes X and Y, not pos =

He needs to turn off the bindtoparent from 290 onwards.
i did this in the code

[State -2, 1000]
type = BindToRoot
trigger1 = Parent, Stateno != [1500,1520]
time = 290
ID = 1000
pos = 0,0

but that makes the helper to go into pos = 0,0 from the beginning
EDIT: i tested the hitdef, but doesn't hit anything

[State 35, 1]
type = HitDef
trigger1 = 1
attr = S, SP
damage = 15,2
animtype = Medium
guardflag = MA
pausetime = 0,0
sparkno = s75
guard.sparkno = s85
hitsound   = s5000,0
guardsound = s120,0
ground.type = High
ground.slidetime = 22
ground.hittime  = 22
ground.velocity = -1
air.velocity = -1,-5
givepower = 2,1
getpower = 3,1

and i added the red boxes in all the anims