YesNoOk
avatar

How to make opponent bounce after hitting with jump (neutral) like in MK9? (Read 3160 times)

Started by DosKillerFighterTrue, April 28, 2024, 01:08:27 am
Share this topic:
How to make opponent bounce after hitting with jump (neutral) like in MK9?
#1  April 28, 2024, 01:08:27 am
  • avatar
  • *
    • Argentina

  • Online
Hi, I'm modifying mk9's scorpion char (author Serega_Stryker) to be very similar to MK9...

I want to make it so that when making a jump (neutral), the opponent's effect will bounce after being hit.

But I don't know how to do it, so I show it.



and here the opponent effect bounces after being hit like MK9.

https://photos.app.goo.gl/xWNkdAXzdCDQeeox9

If anyone helps me I will appreciate it

(I apologize for my English, I use Google Translator)
Re: How to make opponent bounce after hitting with jump (neutral) like in MK9?
#2  April 28, 2024, 04:09:21 am
  • **
  • Super Gamers
  • Twins who play games.
    • Brazil
    • sites.google.com/view/gemeos-dos-jogos
Hello, how you are? You must create a Custom Hit State that makes your opponent bounce. You must use TargetState for this. Use "trigger1 = MoveHit = 1 && NumTarget" in you TargetState. We recommend one State for Hit Pause and the rest for the bounce action. See your Mugen's common1.cns to do this. Common1.cns is usually in the Data folder of your Mugen.
Re: How to make opponent bounce after hitting with jump (neutral) like in MK9?
#3  April 29, 2024, 05:20:24 am
  • avatar
  • *
    • Argentina

  • Online
OKAY! Sorry for not having responded sooner, I just saw it. I'll try it to see if it works (I'm still a beginner in mugen).
Last Edit: April 29, 2024, 05:24:26 am by DosKillerFighterTrue
Re: How to make opponent bounce after hitting with jump (neutral) like in MK9?
#4  April 29, 2024, 12:57:15 pm
  • *****
  • Shame on you!
    • USA
You should be able to do it without a custom hitstate. I didn't play MK9 enough to know exactly how p2 will react to the hit but,
something like

ground.type = Trip
ground.slidetime = 18
ground.hittime  = 25
ground.velocity = 0,-10
air.velocity = -1,-10

in the hitdef should trip p2 and send them upwards. It wont look like they're bouncing but they go right up into the air.
If you need it to bounce you could do like Gêmeos dos Jogos and send them into a copy of State 5100. just make sure the ChangeStates in your cloned states have SelfState instead of ChangeState.
vVv Ryuko718 Updated 10/31/22 vVv
Re: How to make opponent bounce after hitting with jump (neutral) like in MK9?
#5  April 30, 2024, 01:32:22 am
  • avatar
  • *
    • Argentina

  • Online
Thanks, but I have a problem, it doesn't bounce too much when I hit it.

He tried to copy and follow the steps. but it does not rise higher even though I modify an exaggerated number to check "
ground.velocity = 1990,-1990
air.velocity = -1990,-1990" or "ground.velocity = -1990,1990
air.velocity = 1990,1990".





;---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
; Jump Light Punch
; CNS difficulty: easy
[Statedef 610]
type    = A
movetype= A
physics = A
juggle  = 15
ctrl = 0
anim = 610



[State 200, 1]
type = HitDef
trigger1 = Time = 0
attr = A, NA
damage = 0
animtype = Light
guardflag = H
hitflag = MAF
priority = 3, Hit
pausetime = 8, 8
sparkno = S50+(random%4)
guard.sparkno = s54
sparkxy = -10, -40
hitsound = s0, 0
guardsound = s0, 3
ground.type = Trip
ground.slidetime = 18
ground.hittime  = 25
ground.velocity = 1990,1990
air.velocity = 1990,1990
airguard.velocity = -2.3,-.8
air.animtype = back
air.hittime = 20
getpower = 0
givepower = 10,10
fall.recover = 0
;air.fall = (ifelse((Enemynear,Hitfall = 1),1,0))

[State 0, TargetState]
type = SelfState
trigger1 = NumTarget = 1
trigger1 = Target,Ishelper = 0
trigger1= MoveHit = 1
value = 1
;---------------------------------------------------------------------------------------------------------------------------------------------------------

Excuse me if I haven't understood it well, it helps me understand a little, I'm still a beginner.
Re: How to make opponent bounce after hitting with jump (neutral) like in MK9?
#6  April 30, 2024, 09:24:14 pm
  • *****
  • Shame on you!
    • USA
Use this hitdef. I just threw it in my Ryu and it sends P2 upward with no bounce.

[State 200, 1]
type = HitDef
trigger1 = Time = 0
attr = A, NA
damage = 0
animtype = Light
guardflag = H
hitflag = MAF
priority = 3, Hit
pausetime = 8, 8
sparkno = S50+(random%4)
guard.sparkno = s54
sparkxy = -10, -40
hitsound = s0, 0
guardsound = s0, 3
ground.type = Trip
ground.slidetime = 18
ground.hittime  = 25
ground.velocity = 0,-10
air.velocity = 0,-10
airguard.velocity = -2.3,-.8
air.animtype = back
air.hittime = 20
getpower = 0
givepower = 10,10
fall.recover = 0
;air.fall = (ifelse((Enemynear,Hitfall = 1),1,0))

You may want to read up on the HitDef. When I was new at all this I struggled and struggled. When I just took the 5 minutes to read the hitdef it cleared up so much. https://mugenguild.com/forum/topics/hitdef-sctrls-169450.0.html
Like the value you had set would send P2 downward. it needs to be a negative number to send p2 up. You also have it shooting to behind p1. the value should be 0,somethingNegative to send it straight up.
This is a bunch of general knowledge http://mugenguild.com/forum/topics/mugen-101-things-you-need-know-169758.0.html
and this is a quick way to learn about Variables. https://mugenguild.com/forum/topics/var-and-fvar-triggers-169438.0.html
this link is in the mugen 101. So you can follow the blue lines of text to what it's talking about if that's something you need/want more info about.


The selfstate at the end should be a changestate. a SelfState is when P2 is under your control and it needs to become itself again. Like P2 starts to use P1's state, so it's not it's self. You use ChangeState for P1 to change the state your character needs to go to.
vVv Ryuko718 Updated 10/31/22 vVv
Re: How to make opponent bounce after hitting with jump (neutral) like in MK9?
#7  May 01, 2024, 04:19:46 am
  • avatar
  • *
    • Argentina

  • Online
Thank you very much, but I don't understand why the p2 doesn't raise more, I have modified it and it doesn't work. I don't understand why, it's not because I have
"[Size]
xscale = 0.375
yscale = 0.375" or "localcoord = 400.254" from scorpion, it just doesn't raise any higher



I have no idea why it is...
Last Edit: May 01, 2024, 10:43:41 am by DosKillerFighterTrue
Re: How to make opponent bounce after hitting with jump (neutral) like in MK9?
New #8  May 03, 2024, 08:16:17 am
  • avatar
  • *
    • Argentina

  • Online
Use this hitdef. I just threw it in my Ryu and it sends P2 upward with no bounce.

[State 200, 1]
type = HitDef
trigger1 = Time = 0
attr = A, NA
damage = 0
animtype = Light
guardflag = H
hitflag = MAF
priority = 3, Hit
pausetime = 8, 8
sparkno = S50+(random%4)
guard.sparkno = s54
sparkxy = -10, -40
hitsound = s0, 0
guardsound = s0, 3
ground.type = Trip
ground.slidetime = 18
ground.hittime  = 25
ground.velocity = 0,-10
air.velocity = 0,-10
airguard.velocity = -2.3,-.8
air.animtype = back
air.hittime = 20
getpower = 0
givepower = 10,10
fall.recover = 0
;air.fall = (ifelse((Enemynear,Hitfall = 1),1,0))

You may want to read up on the HitDef. When I was new at all this I struggled and struggled. When I just took the 5 minutes to read the hitdef it cleared up so much. https://mugenguild.com/forum/topics/hitdef-sctrls-169450.0.html
Like the value you had set would send P2 downward. it needs to be a negative number to send p2 up. You also have it shooting to behind p1. the value should be 0,somethingNegative to send it straight up.
This is a bunch of general knowledge http://mugenguild.com/forum/topics/mugen-101-things-you-need-know-169758.0.html
and this is a quick way to learn about Variables. https://mugenguild.com/forum/topics/var-and-fvar-triggers-169438.0.html
this link is in the mugen 101. So you can follow the blue lines of text to what it's talking about if that's something you need/want more info about.


The selfstate at the end should be a changestate. a SelfState is when P2 is under your control and it needs to become itself again. Like P2 starts to use P1's state, so it's not it's self. You use ChangeState for P1 to change the state your character needs to go to.

I'm sure the problem is that Mortal Kombat chars can't go higher if it's in ground.type = Trip. I tried it with another 2D scorpion char, and I copied it, and that was the problem. and as you said in the previous answer


 It wont look like they're bouncing but they go right up into the air.
If you need it to bounce you could do like Gêmeos dos Jogos and send them into a copy of State 5100. just make sure the ChangeStates in your cloned states have SelfState instead of ChangeState.

maybe i have to do that. Now I have to do the bounce effect, Someday I'll read it all to clear my head. https://mugenguild.com/forum/topics/hitdef-sctrls-169450.0.html , the reason I couldn't read it all is because Google Translate doesn't translate it correctly or translates the codes meaning in Spanish, as "Light" translates it "Debil" or "Medium" it "Medio" and so on, and it got to the point where I didn't understand anything. I could only understand a little bit like statetype, hitflag, guardflag, animtype, air.animtype, fall.animtype, damage, pausetime, sparkno, sparkxy, hitsound, and guardsound, and ground.type, air.type, ground.slidetime, air. hittime, guard.dist, yaccel ground, velocity guard.velocity, air.velocity, airguard.velocity and p1facing.
Last Edit: May 03, 2024, 05:42:58 pm by DosKillerFighterTrue