YesNoOk
avatar

P2 can't attack after custom state (Read 944 times)

Started by MrGiang, February 15, 2018, 03:06:21 am
Share this topic:
P2 can't attack after custom state
#1  February 15, 2018, 03:06:21 am
  • avatar
  • *
    • Vietnam
I'm having a problem with this character as after being in custom state (being thrown state), P2 is unable to attack or dash.
Here is the grab code (the custom state for P2 is 820)
Code:
[Statedef 800]
type    = S
movetype= A
physics = S
juggle  = 0
velset = 0,0
ctrl = 0
anim = 800
sprpriority = 2


[State 210, 1]
type = PlaySnd
trigger1 = Time = 2
value = 48, 0


[State 210, 1]
type = PlaySnd
trigger1 = Time = 1
value = 12, 1




[State 800, 1]
type = HitDef
Trigger1 = Time = 0
attr = S, NT
hitflag = M-
priority = 1, Miss
sparkno = -1
p1sprpriority = 1

p1facing = 1
p2facing = 1
p1stateno = 810
p2stateno = 820
guard.dist = 0
fall = 1

[State 800, 2]
type = ChangeState
Trigger1 = AnimTime = 0
value = 0
ctrl = 1

















[Statedef 810]
type    = S
movetype= A
physics = N
anim = 810
poweradd = 0




[State 810, Holding fwd?]
type = VarSet
trigger1 = Time = 0
var(2) = command = "holdfwd"

[State 810, Grab Sound]
type = PlaySnd
trigger1 = AnimElem = 4
value = 61, 0

[State 810, Throw Sound]
type = PlaySnd
trigger1 = AnimElem = 11
value = 54, 0

[State 810, Bind 1]
type = TargetBind
trigger1 = AnimElemTime(2) < 0
pos = 36.333, 0

[State 810, Width 2-11]
type = Width
trigger1 = AnimElemTime(2) >= 0 && AnimElemTime(12) < 0
edge = 60,0

[State 810, Bind 2-4]
type = TargetBind
trigger1 = AnimElemTime(2) >= 0 && AnimElemTime(5) < 0
pos = 33.000, 0

[State 810, Bind 5]
type = TargetBind
trigger1 = AnimElemTime(5) >= 0 && AnimElemTime(6) < 0
pos = 41.667, 0












[State 810, holdfwd - Turn Target 6]
type = TargetFacing
trigger1 = var(2)
trigger1 = AnimElem = 6
value = -1

[State 810, Bind 6]
type = TargetBind
trigger1 = AnimElemTime(6) >= 0 && AnimElemTime(7) < 0
pos = 51.667, 0

[State 810, Bind 7]
type = TargetBind
trigger1 = AnimElemTime(7) >= 0 && AnimElemTime(8) < 0
pos = 52, 0.667

[State 810, Bind 8]
type = TargetBind
trigger1 = AnimElemTime(8) >= 0 && AnimElemTime(9) < 0
pos = 49, 0

[State 810, Bind 9]
type = TargetBind
trigger1 = AnimElemTime(9) >= 0 && AnimElemTime(10) < 0
pos = -1.667, -116.667

[State 810, Bind 10]
type = TargetBind
trigger1 = AnimElemTime(10) >= 0 && AnimElemTime(11) < 0
pos = -2.333, -100.000

[State 810, Bind 11]
type = TargetBind
trigger1 = AnimElemTime(11) >= 0 && AnimElemTime(12) < 0
pos = -85.000, -98.000

[State 810, Hurt 11]
type = TargetLifeAdd
trigger1 = AnimElem = 12
value = -78

[State 810, Throw 11]
type = TargetState
trigger1 = AnimElem = 12
value = 5110

[State 810, Bind 12]
type = TargetBind
trigger1 = AnimElem = 12
pos = -71.667, -2.000

[State 810, Envshake]
type = EnvShake
trigger1 = AnimElem = 11
freq = 120
time = 20

[State 2018, Dust Effect]
type = Explod
trigger1 = AnimElem = 11
Anim = 10001
Pos = -120,-20
sprpriority = 10
removeongethit = 1


Pos= 0,0

SuperMove = 1
scale = 1
trans=addalpha
alpha=200,75






[State 810, Pos 15]
type = PosAdd
trigger1 = AnimElem = 15
x = -10

[State 810, State End]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1












[Statedef 820]
type    = A
movetype= H
physics = N
velset = 0,0

[State 820, 1]
type = ChangeAnim2
Trigger1 = Time = 0
value = 820



[State 820, 2]
type = SelfState
trigger1 = !gethitvar(isbound)
value = 5050
Is it possible to fix this though?
Re: P2 can't attack after custom state
#2  February 15, 2018, 09:15:29 am
  • ******
  • Legendary XIII
  • I am the eye of the storm to come!
    • New Zealand
    • network.mugenguild.com/cyanide/
You have a targetstate applying on animelem 12 that sends him to 5110. Thats overriding state 820 and losing access to the selfstate you have


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: P2 can't attack after custom state
#3  February 15, 2018, 05:12:16 pm
  • avatar
  • *
    • Vietnam
Oh, I totally missed that one there. I have deleted it and everything works perfectly. Thanks a lot!