YesNoOk
avatar

SOLVED Charactor won't punch (Read 594 times)

Started by Continuity, June 19, 2009, 03:42:04 am
Share this topic:
SOLVED Charactor won't punch
New #1  June 19, 2009, 03:42:04 am
  • ***
  • 我が名は 「ハクメン」、押して参る!
So I just started to code an attack, I started with a stand light punch, here's the state[mcode][Statedef 200]
type    = S                      ;State-type: S-stand, C-crouch, A-air, L-liedown
movetype= A                      ;Move-type: A-attack, I-idle, H-gethit
physics = S                      ;Physics: S-stand, C-crouch, A-air
juggle  = 1                      ;Number of air juggle points move takes
;Commonly-used controllers:
velset = 0,0                     ;Set velocity (x,y) (Def: no change)
ctrl = 0                         ;Set ctrl (Def: no change)
anim = 200                       ;Change animation (Def: no change)
poweradd = 20                    ;Power to add (Def: 0)
sprpriority = 2                  ;Set p1's sprite layering priority to 2 (in front)

[State 200, 1]
type = HitDef
trigger1 = AnimElem = 3
attr = S, NA                     ;Attribute: Standing, Normal Attack
damage = 23, 0                   ;Damage that move inflicts, guard damage
animtype = Light                 ;Animation type: Light, Medium, Heavy, Back (def: 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
;Hit/Miss/Dodge type (Def: Hit)
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,
;Y-offset for the spark rel. to p1
hitsound = 5, 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 = 5             ;Time that the opponent slides back
ground.hittime  = 10             ;Time opponent is in hit state
ground.velocity = -4             ;Velocity at which opponent is pushed
airguard.velocity = -1.9,-.8     ;Guard velocity in air (def: (air.xvel*1.5, air.yvel/2))
air.type = High                  ;Type: High, Low, Trip (def: same as ground.type)
air.velocity = -1.4,-3           ;X-velocity at which opponent is pushed,
;Y-velocity at which opponent is pushed
air.hittime = 12                 ;Time before opponent regains control in air

[State 200, 1]
type = PlaySnd
trigger1 = Time = 1
value = 0, 0

[State 200, 7]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1[/mcode]

And this is my cmd code [mcode][state -1]
type = ChangeState
triggerall = command = "a"
triggerall = command! = "holddown"
trigger1 = ctrl = 1
trigger1 = statetype = s
value = 200[/mcode]

during the test when I inputed the command the charactor didn't punch, what did I do wrong? thank you ???
Last Edit: June 20, 2009, 05:21:26 am by juggernaut117
Re: Charactor won't punch
#2  June 19, 2009, 03:47:39 am
  • ****
  • PSN: Cloudius12
    • www.twitter.com/Cloudius12
Did you by any chance do his AIR file yet? He wont punch  or perform animation number 200 if it doesnt exist
Re: Charactor won't punch
#3  June 19, 2009, 04:28:21 am
  • ***
  • 我が名は 「ハクメン」、押して参る!
yes I did, I tried using other charators' cns and it worked, so I don't see why my one doesn't
Re: Charactor won't punch
#4  June 19, 2009, 06:08:22 am
  • ****
  • Coder and Voice Actor
    • USA
    • Skype - byakuyaownsyou
    • www.youtube.com/vicmigderpaderp

  • Online
Change the ctrl 0 at the top to 1 that should solve your problem 

Re: Charactor won't punch
#5  June 19, 2009, 06:27:53 am
  • ***
  • 我が名は 「ハクメン」、押して参る!
Oh...never mind I erased the command!=holddown line in the cmd and it works, but I don't really understand why.... --;
Last Edit: June 19, 2009, 06:33:36 am by juggernaut117
Re: Charactor won't punch
#6  June 19, 2009, 08:17:32 am
  • ******
  • Legendary XIII
  • I am the eye of the storm to come!
    • New Zealand
    • network.mugenguild.com/cyanide/
Change the ctrl 0 at the top to 1 that should solve your problem 


For the record. This suggestion is utterly wrong. Ctrl in an attacking state should almost always be 0, you shouldn't have ctrl unless there's a really specific reason for it, and there aren't many of those.

Oh...never mind I erased the command!=holddown line in the cmd and it works, but I don't really understand why.... --;
That, is interesting. Unless mugen wasn't reading it correctly the way you had it spaced. Does

triggerall = command != "holddown"

Function?


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: Charactor won't punch
#7  June 19, 2009, 09:33:49 am
  • ****
  • Coder and Voice Actor
    • USA
    • Skype - byakuyaownsyou
    • www.youtube.com/vicmigderpaderp

  • Online
Change the ctrl 0 at the top to 1 that should solve your problem  


For the record. This suggestion is utterly wrong. Ctrl in an attacking state should almost always be 0, you shouldn't have ctrl unless there's a really specific reason for it, and there aren't many of those.

Oh...never mind I erased the command!=holddown line in the cmd and it works, but I don't really understand why.... --;
That, is interesting. Unless mugen wasn't reading it correctly the way you had it spaced. Does

triggerall = command != "holddown"

Function?

Sorry I'm still learning  :P
 any tips on how to make a combo system btw?
Re: Charactor won't punch
#8  June 19, 2009, 10:26:15 am
  • ******
Yeah. Make another topic. And read the docs.
If I struggled to the end of my determination, to the end of my way of life with my followers, if the result is ruin, then this ruin is inevitable. Grieve. Shed tears. But you cannot regret.
Re: Charactor won't punch
#9  June 19, 2009, 03:41:55 pm
  • ***
  • 我が名は 「ハクメン」、押して参る!

That, is interesting. Unless mugen wasn't reading it correctly the way you had it spaced. Does

triggerall = command != "holddown"

Function?
You mean the code? When I hold down the "a" button, the charactor only punched once, so if the trigger means "not holddown", then yes, it does work ???
Re: Charactor won't punch
#10  June 19, 2009, 04:58:15 pm
  • ******
holddown means hold the "down" direction key, not hold down the A button. And this trigger should be there.
If I struggled to the end of my determination, to the end of my way of life with my followers, if the result is ruin, then this ruin is inevitable. Grieve. Shed tears. But you cannot regret.
Re: Charactor won't punch
#11  June 19, 2009, 05:24:47 pm
  • ***
  • 我が名は 「ハクメン」、押して参る!
Oh~~I got it, I had a space between the ! and =, that's why it didn't function, I added this line back now
triggerall = command!= "holddown"
The charactor is punching normally now, but I'm not sure how to see whether the trigger works or not...
Re: Charactor won't punch
#12  June 20, 2009, 12:11:03 am
  • ******
  • Legendary XIII
  • I am the eye of the storm to come!
    • New Zealand
    • network.mugenguild.com/cyanide/
Quote
That, is interesting. Unless mugen wasn't reading it correctly the way you had it spaced. Does

triggerall = command != "holddown"

Function?
Goddammit. I POSTED that.


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.