YesNoOk
avatar

Hit count not working correctly. (Read 2449 times)

Started by Sheng Long, October 03, 2012, 07:29:56 am
Share this topic:
Hit count not working correctly.
#1  October 03, 2012, 07:29:56 am
  • ******
  • Video Game Veteran
  • Can you do it? SUREYOUCAN!
    • USA
    • gcnmario.free.fr
Okay, regarding my previous problem that's now been fixed, it is now causing another problem for me. It seems that with the Helper using a hitdef, and the player using a hitdef, it counts as 2 hits. So what I did was give the helpers hitdef a numhits = 0 to resolve this.

Now the problem here is, when I combo a jump attack into the attack that needs the burn effect + hitdef, it does NOT add to the current combo count. For example, if a jump punch does 2 hits, and the second attack that uses the burn + hidef effect, it either remains 2 hits, or the count resets back to 0. Even using numhits = -1 does the same thing.

So I am wondering if there is a way for me to add to the combo counter ONCE instead of two times (roots hitdef, and helpers hitdef) only when I need it to? I've tried HitCount, UniqHitCount triggers. I've tried adding numhits into different hitdefs. They're all pretty much the same issue.



Also, this is somewhat related, but if a P2 summons a helper that can be thrown (or put into custom state) by P1, is there a way for the P1 to create & bind a burn effect onto P2's helper, but not on P2? An example of this is the Bonus KFM fight (the ones that drop out gems when you hit them. Don't know the author, harder to tell you, maybe better to show screen shot if needed.)

"You must defeat my flaming
dragon punch to stand a chance."
Re: Hit count not working correctly.
#2  October 03, 2012, 08:04:15 am
  • ******
  • Legendary XIII
  • I am the eye of the storm to come!
    • New Zealand
    • network.mugenguild.com/cyanide/
Numhits = 0 should be enough. I've used it before to achieve no hits from a single attack.

That should either be adding a single hit, or adding 2, not adding none whatsoever to the hit counter, something i can only attribute to something weird you have achieved in your troubleshooting. (if the helper destroyselfs too soon after the hit it may take the reset with it)

For the second issue. Yes, same as you've used from Mukai. If the helper is able to enter movetype = H without hitoverride (ie it CAN be thrown) then it's your target. You can ID it with playerID or target ID and place the burn accordingly.


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.
Re: Hit count not working correctly.
#3  October 03, 2012, 10:26:24 pm
  • ******
  • Video Game Veteran
  • Can you do it? SUREYOUCAN!
    • USA
    • gcnmario.free.fr
Well I don't want it to destroy when on contact. It'll be destroyed when the move is over. So will that affect your answer? The only option i can try is to NOT use the helper, and think of some other method to correct the combo hits count issue. :P

So as I've said, if a previous attack does 2 hits, then the burn hitdef should do a 3rd combo hit. but instead still displays as 2 hit combos (from the previous combo), not adding on to the combo count. That's the problem I'm trying to resolve.

"You must defeat my flaming
dragon punch to stand a chance."
Re: Hit count not working correctly.
#4  October 03, 2012, 10:47:27 pm
  • ******
  • Legendary XIII
  • I am the eye of the storm to come!
    • New Zealand
    • network.mugenguild.com/cyanide/
You have 2 attacks making contact. One should increase hitcount, one shouldn't. The only reason i can think of is that the helpers hit is overriding what your hitcounter is doing. ie breaking the combo. Try the other way around to test. Player's hit has numhits = 0 and the helper doesn't.

You could also go back to ONE hitdef and make use of changeanim

type = changeanim
trigger1 = helper, hitshakeover = 0
value = anim
elem = animelemno(0)

That'll freeze your frame. If you want to be super accurate on timing, split the anim up into 1-tick frames, or give the helper the same number of frames as the parent on the same timings and use the helpers timing to assign to the parent

elem = helper, animelemno(0)

I used that for omega destroyer.


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.
Re: Hit count not working correctly.
#5  October 03, 2012, 11:04:27 pm
  • ******
  • Video Game Veteran
  • Can you do it? SUREYOUCAN!
    • USA
    • gcnmario.free.fr
How will the other way around work? It's still the same issue either way. :-/

Does it make a difference that when NOT using numhits for any hidefs used here, that the combo still only does 2 hits despite any previous combo counts?

"You must defeat my flaming
dragon punch to stand a chance."
Re: Hit count not working correctly.
#6  October 03, 2012, 11:07:41 pm
  • ******
  • Legendary XIII
  • I am the eye of the storm to come!
    • New Zealand
    • network.mugenguild.com/cyanide/
The counter is either being broken, or p2 is leaving a movetype = H state. Ie for a short period he is not a target. If you have anything that puts him into movetype = I, that'll ruin the combo, if he leaves/recovers, that will break it too.

If you remove one hitdef or the other, does it increment hitcount? If the answer is no, above is your issue.


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.
Re: Hit count not working correctly.
#7  October 04, 2012, 12:07:21 am
  • ******
  • Video Game Veteran
  • Can you do it? SUREYOUCAN!
    • USA
    • gcnmario.free.fr
No moves are putting target into MoveType = I. I removed the burning hit helper, leaving the root with only 1 hitdef, and its not doing anything to the hit counter like the other moves are correct.

Although, I think I am using a TargetDrop code. That might be what the issue is. I'll check on it.

EDIT: Yup, that was causing the problem. TargetDrop.
Though I think I used targetdrop on the hit burn helper instead, since it has the numhits = 0 line in its hitdef. 

"You must defeat my flaming
dragon punch to stand a chance."
Last Edit: October 04, 2012, 12:12:39 am by N-Mario
Re: Hit count not working correctly.
#8  October 04, 2012, 12:28:13 am
  • ******
  • Legendary XIII
  • I am the eye of the storm to come!
    • New Zealand
    • network.mugenguild.com/cyanide/
You don't want or need to do that. Targetdrop is for when you want to actually lose your target for the purposes of state control or binding. If the helper retaining the target has no effect, don't bother dropping it.


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.
Re: Hit count not working correctly.
#9  October 04, 2012, 02:20:46 am
  • ******
  • Video Game Veteran
  • Can you do it? SUREYOUCAN!
    • USA
    • gcnmario.free.fr
Well, I actually may need targetdrop for the helper's hitdef. So here's the thing.

After the helper hits the opponent, the burn effect is applied like this:
Code:
;--------------------
; Opponent Burned
[State 10050, Helper]
type = Helper
trigger1 = MoveHit
trigger1 = NumTarget > 0
trigger1 = Target, MoveType = H
trigger1 = Target, StateTime <= 0
helpertype = normal
ignorehitpause = 1
name = "Burn"
id = 1050
pos = 0, 0
postype = P2
stateno = 1050
keyctrl = 0

[State 10050, Reset]
type = TargetDrop
trigger1 = MoveContact
trigger2 = NumTarget > 0
ignorehitpause = 1

[State 10050, Reset]
type = MoveHitReset
trigger1 = MoveContact
ignorehitpause = 1
;--------------------

Once I remove the TargetDrop from the helper, the helper only applies the burn effect on one opponent, instead of multiple opponents on contact like it's supposed to.


In theory, I already got my answer. Though I'm still trying to make it work on P2's helpers too. But I guess that's not as important as this, for this topic to be unsolved.

"You must defeat my flaming
dragon punch to stand a chance."
Re: Hit count not working correctly.
#10  October 04, 2012, 02:47:48 am
  • ******
  • Legendary XIII
  • I am the eye of the storm to come!
    • New Zealand
    • network.mugenguild.com/cyanide/
Stop using the target for the burn effect. Rely on enemynear(0) and enemynear(1) Establish their playerID's then you can use. target to confirm that you HAVE them as targets while creating the helpers if they are.

Once more, check out Mukai, he uses exactly this theory to create 2 stone break effects from his LDM hitting. The only real difference is he's the one doing all the hitting, you have a number of options around doing the same thing with your contact helper.


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.
Re: Hit count not working correctly.
#11  October 04, 2012, 03:55:06 am
  • ******
  • Video Game Veteran
  • Can you do it? SUREYOUCAN!
    • USA
    • gcnmario.free.fr
Not sure if I was using the right move of your Mukai, but the 'other' problem I am pointing out is this.


Notice on the left side, everything is working correctly because P2 is root player.
On the right side is a P2 using helpers that can be thrown. When your Mukai turns these helpers into stone, your stone effects are missing.


"You must defeat my flaming
dragon punch to stand a chance."
Re: Hit count not working correctly.
#12  October 04, 2012, 04:59:29 am
  • ******
  • Legendary XIII
  • I am the eye of the storm to come!
    • New Zealand
    • network.mugenguild.com/cyanide/
Helpers won't redirect enemynear. They don't count for that trigger. Check

target, !ishelper

If target, ishelper you need the playerID. I didn't account for that at all. Theory remains the same. It will begin to cause issues if you have managed to hit more than one helper of the same sort as you cannot really differentiate that far and you have to get into ID management with a number of variables.

Personally i'd be blowing up any helper that made its way into a custom state.


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.
Re: Hit count not working correctly.
#13  October 04, 2012, 05:30:59 am
  • ******
  • Video Game Veteran
  • Can you do it? SUREYOUCAN!
    • USA
    • gcnmario.free.fr
Well, I don't know who the author of these KFMS bonus stage is. But it seems to be an issue with the P2 root character spawning throw-able helpers + wrong type of ID's being identified by P1. So the error isn't just with my character and your Mukai. But generally any character that is supposed to spawn special FX on opponents, as i'm trying to show in the screen shots.


BTW, is there any way I can split this topic up into two? I already solved my hit count problem, as the topic subject says. The other problem we're talking about probably should have a topic of its own, since I haven't resolved it yet.

"You must defeat my flaming
dragon punch to stand a chance."
Re: Hit count not working correctly.
#14  October 04, 2012, 07:14:48 am
  • ******
  • Legendary XIII
  • I am the eye of the storm to come!
    • New Zealand
    • network.mugenguild.com/cyanide/
Make a new one defining it. You want to be able to display a special effect on your target no matter how many targets there are and whether they are helpers or not.


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.