Infinity MUGEN Team

IMT Main => M.U.G.E.N Help => Topic started by: darkgeist on November 25, 2015, 12:37:33 PM

Title: Ricochet Shield Move For Captain America
Post by: darkgeist on November 25, 2015, 12:37:33 PM
(http://i68.servimg.com/u/f68/19/02/73/58/mugen012.jpg) (http://www.servimg.com/view/19027358/22)

This is an edited version of Buckus's Cap with new SFF and new ricochet move where projectiles bounce off Cap's shield. I made the move work fine but I have one problem. Everytime I perform the move the shield disapears then reappears when the move is over. Can anyone help me who knows knowledge on coding helpers, I've been looking online for months on how to fix but can seem to figure it out. Ireally want to release this as a Christmas Mugen present.  ???
Title: Re: Ricochet Shield Move For Captain America
Post by: MGMURROW on November 25, 2015, 01:36:17 PM
post the code of the move and the animation in the air file so we can have a look

MGMURROW
Title: Re: Ricochet Shield Move For Captain America
Post by: darkgeist on November 25, 2015, 04:00:26 PM
The shield is bound to all other attacks cap has but when i perform this one it flys off screen and when move is done comes back

So the code is here:

;-----------------------------------------------
[Statedef 1030]
type    = S
movetype= H
physics = N
juggle  = 1
velset = 0,0
poweradd = 0
ctrl = 0
sprpriority = 5

[State 0, ChangeAnim]<========I TRIED PUTTING THIS THINKING IT WOULD WORK SOMEHOW IDK =(
type = ChangeAnim
triggerall = !time
trigger1 = Helper(10000),stateno!=10000
value = 130;ifelse(Helper(10000),stateno=10000 ,222 ,220)))
ignorehitpause = 1
;persistent =


[State 0, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = 1030,(0+(random%4))
volume = 255
channel = -1



[State 1000, var initialize]
type = VarSet
var(4) = 1
trigger1 = time = 0

[State 1030, 1]
type = ChangeAnim
triggerall = PrevStateNo != 9000
trigger1 = time = 0
value = 1032

[State 1002, gethit colorize]
type = PalFX
add = 255,128,0
trigger1 = time = 0
trigger1 = var(4) > 1
time = 5

[State 1002, take damage]
type = LifeAdd
trigger1 = time = 0
var(4) > 1
value = -gethitvar(damage)
kill = 0



[State 0, HitOverride]
type = HitOverride
triggerall = PrevStateNo != 9000
trigger1 = 1 && statetype = S
attr = SCA,NP,SP,HP;,NT,ST,HT
stateno = 1031
slot = 5
ignorehitpause = 1

[State 0, HitOverride]
type = HitOverride
triggerall = PrevStateNo != 9000
trigger1 = 1 && statetype = S
attr = SCA,NA,SA,HA
stateno = 1033
slot = 6
ignorehitpause = 0



[State 1030, PalfX]
type = PalFX
trigger1 = time = 1
add = 100,100,100
mul = 256,256,256
time = 3
ignorehitpause = 1


[State 0, ChangeAnim]
type = ChangeAnim
trigger1 =  time =95
value = 1031
;elem = 1
;ignorehitpause =
;persistent =


[State 0, ChangeState]
type = ChangeState
trigger1 = time = 100
value = 0
ctrl = 1







;------------------------------------------
[StateDef 1031]
type = S
movetype = I
physics = S
anim = 1033
pos = 0,0
ctrl = 0
velset = 0,0
poweradd = 30

[State 1000, var increment]
type = VarAdd
var(4) = 1
trigger1 = 1


; [State 0, ChangeAnim]
; type = ChangeAnim
; triggerall = PrevStateNo != 9000
; trigger1 =  time = 0
; value = anim = 1033
; ;elem = 1
; ;ignorehitpause =
; ;persistent =


[State 0, HitOverride]
type = HitOverride
trigger1 = 1
attr = SCA,NP,SP,HP;,NT,ST,HT
stateno = 1032
time = 10
slot = 2
ignorehitpause = 0



[State 0, ChangeAnim]
type = ChangeAnim
trigger1 =  time = 20
value = 1031


[State 0, ChangeState]
type = ChangeState
trigger1 = time = 25
value = 0
ctrl = 1
;anim =
;ignorehitpause =
;persistent =


;-------------------------------
[StateDef 1032]
type = S
movetype = A
physics = N
ctrl = 0
velset = 0,0


[State 1032, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = 1000,1



[State 0, Projectile]
type = Projectile
triggerall = PrevStateNo != 9000
trigger1 = time = 0
ProjID = 2030
projanim = 2030
projhitanim = 8022
projremanim = 8022
projcancelanim = 8022
projscale = .5,.5
projremove = 1
projremovetime = -1
velocity = 16,-2 + random/225
remvelocity = 0,0
accel = 0,0
velmul = 1
projhits = 1
projmiss = 0
projpriority = 1
projsprpriority = 3
projedgebound = 40
projstagebound = 40
projheightbound = -240
offset = 0,-80
postype = p1         ;p2,front,back,left,right
attr = S,SP        ;SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
hitflag = MAF        ;HLAFD+-
guardflag = MA         ;HLA
animtype = light          ;light,medium,hard,back,up,diagup
air.animtype = light
priority = 2,Hit   ;Hit,Miss,Dodge
damage = 70,1
pausetime = 3,3
sparkno = 3
sparkxy = 30,0
hitsound = 0,0
guardsound = 0,0
ground.type = High      ;Low,Trip,None
ground.slidetime = 15
ground.hittime = 25
air.hittime = 20
ground.velocity = -3,0-2
air.velocity = -4,-3
fall = 1




[State 1030, VarSet]
type = ParentVarSet
trigger1 = movecontact
fv = 26
value = 1

[State 0, ChangeState]
type = ChangeState
trigger1 = time = 1
value = 1031
ctrl = 0

;-------------------------------

[StateDef 1033]
type = S
movetype= A
physics = S
juggle  = 1
velset = 0,0
pos = 0,0
ctrl = 0
anim = 1003
poweradd = 20
sprpriority = 1


[State 1000, var increment]
type = VarAdd
var(4) = 1
trigger1 = 1

[State 0, SuperPause]
type = SuperPause
trigger1 = time = 1
time = 13
anim = 30
sound = S10,0
pos = 0,0
movetime = 5
darken = 1
p2defmul = 0
poweradd = 0
unhittable = 1
;ignorehitpause =
;persistent =





[State 800, 1]
type = HitDef
Trigger1 = Time = 0
attr = S, ST
hitflag = M
priority = 1, Miss
sparkno = -1
sprpriority = 1
p1facing = 1;ifelse (command = "holdfwd", -1, 1)
p2facing = 1
p1stateno = 150
;p2stateno = 1042
fall = 1
guard.dist = 0




[State 0, ScreenBound]
type = ScreenBound
trigger1 = 1
value = 0
movecamera = 1,1
;ignorehitpause =
;persistent =



[State 1050, end]
type = ChangeState
triggerall = p2stateno != 1033
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;------------------------------------------------
;----------------------------------------------------------------------
[Statedef 1042]
type = A
movetype = H
physics = N
velset = 0,0

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

[State 0, SprPriority]
type = SprPriority
trigger1 = time = 1
value = 5
;ignorehitpause =
;persistent =


[State 0, Turn]
type = Turn
trigger1 =!animelemtime(3) && enemynear,var(13)=-1
ignorehitpause =1

;-------------------------------------


and here is animation


(http://i68.servimg.com/u/f68/19/02/73/58/help10.jpg) (http://www.servimg.com/view/19027358/23)

This is where the shield matches the animation

(http://i68.servimg.com/u/f68/19/02/73/58/help310.png) (http://www.servimg.com/view/19027358/24)

second part of attack

(http://i68.servimg.com/u/f68/19/02/73/58/help210.jpg) (http://www.servimg.com/view/19027358/25)

(http://i68.servimg.com/u/f68/19/02/73/58/help410.png) (http://www.servimg.com/view/19027358/26)

Buckus codes shield attack like this

(http://i68.servimg.com/u/f68/19/02/73/58/help510.png) (http://www.servimg.com/view/19027358/27)

sorry if its alot

Title: Re: Ricochet Shield Move For Captain America
Post by: Cyanide on November 26, 2015, 12:28:11 AM
1032+10000=11032, not 10032

Your issue appears to be maths rather than anything strictly wrong with the code.
SimplePortal 2.3.5 © 2008-2012, SimplePortal