YesNoOk
avatar

MegaMan Zero help: Power Bar, disable Up as jump completely, and more (Read 9788 times)

Started by RedDragonCats17, August 20, 2018, 03:41:51 am
Share this topic:
MegaMan Zero help: Power Bar, disable Up as jump completely, and more
New #1  August 20, 2018, 03:41:51 am
  • ***
    • USA
    • Skype - reddragoncats17
    • reddragoncats17.weebly.com/
Hi guys, I decided to get back to making MegaMan Zero and finish him. I got a good majority of normal Zero's special attacks down pact, such as his rising slash, sword beam, and rapid punch, I just need to add his air charge slash, his charged punch, and his downward thrust attack.

However I do need some help. You guys remember my thread about charge attacks using the power bar, right? Well, I wanna know how to keep the power bar at 0, because the charge attacks will interrupt the regular attacks and they'll execute automatically even if a button isn't pressed when the power bar is at max. How do I keep the power bar at 0 so that it's not much of a issue?

Also, Up is still not completely disabled. When I press up, Zero will walk in midair. How do I completely disable up?

Now Zero's downward thrust attack is going to be a bit of a doozy. I've had this attack before in the MegaMan Zero Collection cartridge I've had a long time ago, but I've lost that cartridge. I have completely forgotten how the move works, but I do believe that Zero goes straight down when he does the attack. How can I make Zero go straight down without having any problems?

Edit: I've completely forgot what else I was going to ask you, now it just hit me. It's Omega Zero's level 2 charge shot. You remember me saying that Omega Zero is going to function similarly to Model OX, right? Well I wanna know how to make the level 2 shot fire 2 projectiles instead of 1, like Model OX's OX buster and how it can fire 2 shots when fully charged. How do you code that?
Last Edit: October 22, 2018, 09:14:12 pm by RedDragonCats17
Re: MegaMan Zero help: Power Bar, disable Up as jump completely, and more
#2  August 22, 2018, 12:01:10 am
  • ***
    • USA
    • Skype - reddragoncats17
    • reddragoncats17.weebly.com/
Here's some videos of my power bar problem:



There's another problem I've completely forgot to address. It's the rising flame slash, I can spam the start of the slash every time it connects. Here's a video showing this:



Here's the code for the attack as well.

Code:
;---------------------------------------------------------------------------
;Rising Flame Slash
[Statedef 1400]
type = S
movetype = A
physics = S
juggle = 2
ctrl = 0
anim = 1400
sprpriority = 2

[State 1400, PlaySnd]
type = PlaySnd
trigger1 = !var(10) && animelem = 3
value = S1000,0
channel = 1

[State 1400, 1]
type = HitDef
trigger1 = AnimElem = 1
attr = S, NA
damage = 23, 0
animtype = Light
guardflag = MA                   ;Flags on how move is to be guarded against
hitflag = MAF                    ;Flags of conditions that move can hit
priority = 3, Hit                ;Attack priority: 0 (least) to 7 (most), 4 default
pausetime = 8, 8                 ;Time attacker pauses, time opponent shakes
sparkno = 0                      ;Spark anim no (Def: set above)
sparkxy = -10, -76               ;X-offset for the "hit spark" rel. to p2,
hitsound = S5, 0                  ;Sound to play on hit
guardsound = 6, 0                ;Sound to play on guard
ground.type = High               ;Type: High, Low, Trip (def: Normal)
ground.slidetime = 1             ;Time that the opponent slides back
ground.hittime  = 11             ;Time opponent is in hit state
ground.velocity = -4             ;Velocity at which opponent is pushed
airguard.velocity = -1.9,-.8
air.type = High
air.velocity = -1.4,-3
air.hittime = 15
getpower = 0,0
givepower = 0,0

[State 1400, ChangeState]
type = ChangeState
trigger1 = animtime = 0
value = 1401
ctrl = 0

[Statedef 1401]
type = A
movetype = A
physics = N
juggle = 1
ctrl = 0
anim = 1401
sprpriority = 2

[State 1401, VelSet]
type = VelSet
trigger1 = time = 1
x = 3
y = -4

[State 1401, ChangeState]
type = ChangeState
trigger1 = time = 20
value = 1402
ctrl = 0

[Statedef 1402]
type = A
movetype = I
physics = N
ctrl = 0
anim = 1402
sprpriority = 2

[State 1402, VelSet]
type = VelSet
trigger1 = time = 1
x = .5
y = -.5

[State 1402, Gravity]
type = Gravity
trigger1 = animelemtime(1)>1

[State 1402, ChangeState]
type = ChangeState
trigger1 = pos Y >= 0 && vel Y > 0
value = 1403
ctrl = 0

[statedef 1403]
type = S
movetype = I
physics = S
velset = 0,0
poweradd = 0
anim = 47
ctrl = 0
sprpriority = 2

[State 1403, PosSet]
type = PosSet
trigger1 = 1
y = 0

[State 1403, 3]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

How do I fix this?
Re: MegaMan Zero help: Power Bar, disable Up as jump completely, and more
#3  August 22, 2018, 01:05:29 am
  • ***
    • Brazil
    • deathscythe.co.vu
Ok, I tried reading your post like 10 times but I didn't understand what you want to do with the power bar. Do you mind trying to explain it with more details?

For disabling the UP button, if you're using KFM as a template or anything like that, you'd have to overwrite the common1 states, creating your own jump code or something. I've never tried to do something like that, so this is just a guess. What I'd do is look at characters with the UP button disabled codes so you can have an idea. Jumps are almost always in states 40~49.

For the attack spam, check the CMD. Should have something like this there:
Code:
trigger1 = StateNo = 1400 && MoveHit ; or MoveContact
You can remove it and you won't be able to spam the attack anymore.
Re: MegaMan Zero help: Power Bar, disable Up as jump completely, and more
#4  August 22, 2018, 05:16:26 am
  • ***
    • USA
    • Skype - reddragoncats17
    • reddragoncats17.weebly.com/
Thanks for the code.

My idea is to use the power bar for the charge attacks. As long as now attacks are performed, the power bar stays at 0. But if you hold the attack buttons, such as Zero's Z Saber, the power bar will go up, letting go will drain the power bar back to 0.
Re: MegaMan Zero help: Power Bar, disable Up as jump completely, and more
#5  August 22, 2018, 06:01:36 am
  • ***
    • Brazil
    • deathscythe.co.vu
I think I got it now. If you don't want to gain power at all, put this in your states:

Code:
poweradd = 0

An example:
; Standing Light Punch
[Statedef 200]
type = S
physics = S
movetype = A
ctrl = 0
velset = 0, 0
sprpriority = 1
poweradd = 0
facep2 = 1

I remember that if you omit this line you still get some power when you enter the state. Not sure if this will solve, but give it a try.
Re: MegaMan Zero help: Power Bar, disable Up as jump completely, and more
#6  August 22, 2018, 06:08:53 am
  • ***
    • USA
    • Skype - reddragoncats17
    • reddragoncats17.weebly.com/
Here's the thing, I made a power add for the charge. When I let go, the power just stays.

Code:
[State -2, Saber Power]
type = PowerAdd
trigger1 = command = "hold_x"
value = 15

This will make the charged slash, which requires maximum, to interfere with the regular attacks.
Re: MegaMan Zero help: Power Bar, disable Up as jump completely, and more
#7  August 22, 2018, 08:12:49 am
  • ***
    • USA
    • Skype - reddragoncats17
    • reddragoncats17.weebly.com/
Alright, small update: I've added your piece of code to the command, as you can see, and he's still spamming the start of the slash.

Code:
;Rising Flame Slash
[State -1, Rising Flame Slash]
type = ChangeState
value = 1400
triggerall = !var(10)
triggerall = command = "x"
triggerall = command = "holdup"
trigger1 = statetype !=A
trigger2 = StateNo = 1400 && MoveContact

I made it a trigger2 because if I make it trigger1, he won't do the move at all. Got any other ideas?
Re: MegaMan Zero help: Power Bar, disable Up as jump completely, and more
#8  August 22, 2018, 06:21:28 pm
  • ***
    • Brazil
    • deathscythe.co.vu
Well, the idea was to REMOVE this code (if it was present, of course), not adding it. Now looking at how you coded it, try adding this:
Code:
triggerall = ctrl
And remove the other one you added.
Re: MegaMan Zero help: Power Bar, disable Up as jump completely, and more
#9  August 22, 2018, 07:22:11 pm
  • ***
    • USA
    • Skype - reddragoncats17
    • reddragoncats17.weebly.com/
I've added the code in and removed the other one like you told me, and Zero won't do the move at all.

Code:
;Rising Flame Slash
[State -1, Rising Flame Slash]
type = ChangeState
value = 1400
triggerall = !var(10)
triggerall = command = "x"
triggerall = command = "holdup"
triggerall = ctrl
trigger1 = statetype !=A
Re: MegaMan Zero help: Power Bar, disable Up as jump completely, and more
#10  August 22, 2018, 09:37:02 pm
  • ***
    • USA
    • Skype - reddragoncats17
    • reddragoncats17.weebly.com/
How about put our eyes on the power bar, shall we?

I tried using a power set, again, this time using trigger1 = 1. The power bar isn't charging when I hold the attack buttons.

I'm gonna try a few things, but do you guys have any ideas?

Update: Time = 1 almost did the job, so I'm getting close. I wanna use your ideas for good measure, though.
Last Edit: August 22, 2018, 09:58:39 pm by RedDragonCats17
Re: MegaMan Zero help: Power Bar, disable Up as jump completely, and more
#11  August 27, 2018, 08:26:35 am
  • ***
    • USA
    • Skype - reddragoncats17
    • reddragoncats17.weebly.com/
XGargoyle? Odb? Anybody?
Re: MegaMan Zero help: Power Bar, disable Up as jump completely, and more
#12  September 08, 2018, 12:04:18 am
  • *****
  • Shame on you!
    • USA
[State -1, Rising Flame Slash]
type = ChangeState
value = 1400
Isn't working when checking for control because mugen is trying to send you into a jump state. You're holding up so it's trying to switch states on you.
Use debug to see what state(s) you're being sent into when you press Up.

You have to remember this is a computer. They only do EXACTLY what you tell them to do. So if you're thinking it should do something because it's common sense, they have 0 of it.
    [State -2, Saber Power]
    type = PowerAdd
    trigger1 = command = "hold_x"
    value = 15
adds, but when you let the button go it just stays. That's exactly what you have there. If you want it to do something when you let the button go,
    [State -2, Saber Power Subtract]
    type = PowerAdd
    trigger1 = command != "hold_x"
    value = -1*Power
vVv Wheat Stage Released vVv
Re: MegaMan Zero help: Power Bar, disable Up as jump completely, and more
#13  September 08, 2018, 12:31:10 am
  • ***
    • USA
    • Skype - reddragoncats17
    • reddragoncats17.weebly.com/
It's sending me to State 40, the original one, not the one with command A.

Also, what's the *power for?

Update: So I'm trying your code out, and the power bar is going down after I release the button, the problem is that Zero isn't doing the attack.
Last Edit: September 08, 2018, 12:42:21 am by RedDragonCats17
Re: MegaMan Zero help: Power Bar, disable Up as jump completely, and more
#14  September 08, 2018, 02:49:55 am
  • ***
    • Brazil
    • deathscythe.co.vu
*power multiplies the value by the power.
For example, if you have 1500 power, -1*power would be -1 multiplied by 1500, which is -1500, this will make your power get subtracted by itself all the time.

Edit: try using this in your state 40 (jump state, if your character does not have state 40, create it or copy from common1.cns)
Code:
[State 40, ChangeState]
type = ChangeState
trigger1 = !Time
value = 0
ctrl = 1

This should make sure you never go to state 40 and still have ctrl.
Last Edit: September 08, 2018, 03:07:23 am by DeathScythe
Re: MegaMan Zero help: Power Bar, disable Up as jump completely, and more
#15  September 08, 2018, 03:54:43 am
  • ***
    • USA
    • Skype - reddragoncats17
    • reddragoncats17.weebly.com/
I see. Then maybe I should put the power charge and power discharge in the moves themselves. Or do you have any alternatives?

On the Rising Slash: This is interesting, in his Omega mode, Zero does the rising slash after he does his 3rd auto combo slash.
Last Edit: September 08, 2018, 03:58:19 am by RedDragonCats17
Re: MegaMan Zero help: Power Bar, disable Up as jump completely, and more
#16  September 08, 2018, 02:39:58 pm
  • *****
  • Shame on you!
    • USA
If there's a way that the power should go away without using the move, set up the triggers to look for that exact set up.
If the power should only go away when he does the move, you can set that right in the Statedef.

poweradd = -Power ;This should work, otherwise use -1*Power
vVv Wheat Stage Released vVv
Re: MegaMan Zero help: Power Bar, disable Up as jump completely, and more
#17  September 08, 2018, 10:39:50 pm
  • ***
    • USA
    • Skype - reddragoncats17
    • reddragoncats17.weebly.com/
I'm holding the button while trying both, and the power doesn't go up. Is there a alternative for a different trigger? trigger1 = command != "hold_x" is the only one I have in mind, since this'll trigger when you release the button.
Re: MegaMan Zero help: Power Bar, disable Up as jump completely, and more
#18  September 09, 2018, 08:52:56 am
  • *****
  • Shame on you!
    • USA
So the power should go away while holding the button down in the state that charges it?
I'm asking you if you want the power to reset, and you say you want it to reset but wonder why it's not charging. I'm not sure what your issue is at this point.
vVv Wheat Stage Released vVv
Re: MegaMan Zero help: Power Bar, disable Up as jump completely, and more
#19  September 09, 2018, 03:17:57 pm
  • ***
    • USA
    • Skype - reddragoncats17
    • reddragoncats17.weebly.com/
Aight, here’s my idea. Originally, I intended on using the power bar for charge attacks. The attacks require a certain level of power to trigger, right? What if you don’t reach that level? The power bar will go back down to 0.

I want it to go back down to 0 so that the charge attacks don’t interfere with the normal ones.
Re: MegaMan Zero help: Power Bar, disable Up as jump completely, and more
#20  September 10, 2018, 01:51:01 am
  • *****
  • Shame on you!
    • USA
I'm holding the button while trying both, and the power doesn't go up. Is there a alternative for a different trigger? trigger1 = command != "hold_x" is the only one I have in mind, since this'll trigger when you release the button.
You're telling my you're trying two different methods to get power to cancel out but the opposite isn't working. Why you'd expect the opposite of what you're doing to happen is beyond me. I'm not sure what trigger you want an alt for. You never actually say.
I know your overall idea. I get it. I'm not here to guess what your code is. I'm not here to guess what could be the problem. I try to answer specific questions. At this point I dont think your charging is working. Right? You said the power isn't going up. So work on that problem first.

I cant stress this enough. If you have multiple questions because you have unrelated problems, make multiple threads. The spamming the move is a CMD problem.

Here's the thing, I made a power add for the charge. When I let go, the power just stays.
This will make the charged slash, which requires maximum, to interfere with the regular attacks.
You dont say what the problem is. Or if this is THE problem, you dont ask or say how you'd like it to be. I dont see an actual point to this post. When you say things we dont know if it's a problem or what you want. Say how it is, say how you want it. This will help clear up a lot of confusion.

The main problem I'm getting is you need to learn to work the CMD file a little better. Getting power and having a second move wont interfere with a second move if you do the cmd properly.

I want it to go back down to 0 so that the charge attacks don’t interfere with the normal ones.
This should never be an issue. Ever. Put your charge attacks above the normal attacks in the cmd and add extra trigger checks. That's all you'd ever need for them to not mess with each other.
I honestly dont know how having power could possibly affect the normal attacks, unless you code it to. Did you code it to mess with them?? If not there's zero problem.

If you have a charge move that can charge only in 1 state, all the info goes into that 1 state.
If you have a charge move that can charge in any state, all the info goes into state -2.
Is this the problem?

vVv Wheat Stage Released vVv