collapse

Author Topic: Guard Crush Recreated SyN style! (Newer, skill Lvl = Advanced)  (Read 1370 times)

0 Members and 1 Guest are viewing this topic.

Offline ClubSyN-X-TReME

  • Character and Interactive Stage Specialist
  • Club Syndicate Admin
  • *
  • Posts: 1641
  • Last Login:July 28, 2014, 06:54:54 AM
    • Club SyN -X-treme
[youtube=425,350]cYwfyd2AAWg[/youtube]

I originally was supposed to help out Shinra with his Sfa3 style guard meter but at the same time I was working on my custom version of a guard crush.

This is the code I did. This is meant for Shinra or others in that are familiar with mugen coding to understand. I have a basic guide in this section for the Novice Creators/coders.

Anyway here is my code.

;-------------------------------------------------------
;Guard Crush Meter
;-------------------------------------------------------
[State -3]
type = helper
;trigger1 = enemy,moveguarded && anim = [120,152]
trigger1 = 1 && !numhelper(19999994)
helpertype = Normal
id = 19999994
pos = 0,0
postype = p1
name = "Guard Crush Dummy Helper"
stateno = 19999994
supermovetime = 9999999999
pausemovetime = 9999999999
ignorehitpause = 1
ownpal = 0

[State -3, ChangeState]
type = ChangeState
triggerall = var(13) != [1,100]
triggerall = Statetype = S && roundstate = 2
trigger1 = var(13) < 1
value = 160
ctrl = 0
ignorehitpause = 1

[State -3, ChangeState]
type = ChangeState
triggerall = var(13) != [1,100]
triggerall = Statetype = C && roundstate = 2
trigger1 = var(13) < 1
value = 161
ctrl = 0
ignorehitpause = 1

[State -3, ChangeState]
type = ChangeState
triggerall = var(13) != [1,100]
triggerall = Statetype = A && roundstate = 2
trigger1 = var(13) < 1
value = 162
ctrl = 0
ignorehitpause = 1


The helper is a dummy where if I needed a var or an effect to be available at all times without the negative states abusing it, I always make a Fake helper for that reason.

The Changestates are for when my guard meter is empty and if the player is standing, crouching or air born, it will play the correct state corresponding to the characters current state.

Now in the common.cns or wherever you have the standing, crouching jumping blocking states, in stateder 150, 152, and 154, add these codes,

[State 0,VarAdd]
type = VarAdd
triggerall = enemy,hitdefattr = SCA,NA
trigger1 = time = 1
v = 13
value = -3

[State 0,VarAdd]
type = VarAdd
triggerall = enemy,hitdefattr = SCA,SA
trigger1 = time = 1
v = 13
value = -2

[State 0,VarAdd]
type = VarAdd
triggerall = enemy,hitdefattr = SCA,HA
trigger1 = time = 1
v = 13
value = -2

I have my meter set to decrease from full to empty as shown in the vid. so when i guard a basic hit, i lose three points of my meter, when I guard a special or hyper attack, I loose 2 points of my meter. I will add a dampener for those GODLIKE 100+ hit hypers etc.

Ok now for my Guard Crush helper states.

Ill paste my coding's below,

Code: [Select]
;--------------------------------------------------
;Player 1 and Player 2 Guard Crush States
;--------------------------------------------------
[Statedef 19999994]
type = s
movetype = i
physics = n
ignorehitpause = 1

[State 0, ]
type = AssertSpecial
trigger1 = 1
flag = noshadow
flag2 = invisible
ignorehitpause = 1

[State 0]
type = NotHitBy
trigger1 = 1
value = SCA
ignorehitpause = 1

[State 0, ParentVarSet];Sets meter on full
type = ParentVarSet
trigger1 = time = 0 || root,stateno = [160,162]
trigger2 = root,var(13) > 100; keeps meter from over flowing
v = 13
value = 100
ignorehitpause = 1

[State 0, ParentVarAdd];regenerates meter by 2 point every 100 game ticks
type = ParentVarAdd
triggerall = root,var(13) != 100
triggerall = root,var(13) < 100 && root,anim != [120,152]
trigger1 = (gametime%100)=1
v = 13
value = 2
ignorehitpause = 1

[State -3]
type = helper
triggerall = teamside = 1
trigger1 = enemy,moveguarded && root,anim = [120,152]
trigger1 = 1 && !numhelper(19999995)
helpertype = Normal
id = 19999995
pos = 0,0
postype = p1
name = "Guard Crush P1"
stateno = 19999995
supermovetime = 9999999999
pausemovetime = 9999999999
ignorehitpause = 1
ownpal = 0

[State -3]
type = helper
triggerall = teamside = 2
trigger1 = enemy,moveguarded && root,anim = [120,152]
trigger1 = 1 && !numhelper(19999996)
helpertype = Normal
id = 19999996
pos = 0,0
postype = p1
facing = -1
name = "Guard Crush P2"
stateno = 19999996
supermovetime = 9999999999
pausemovetime = 9999999999
ignorehitpause = 1
ownpal = 0

[State -3]
type = helper
triggerall = Roundstate = 2
trigger1 = root,var(13) < 1
trigger1 = !numhelper(19999997)
helpertype = Normal
id = 19999997
pos = 0,0
postype = p1
name = "Guard Crush effects"
stateno = 19999997
supermovetime = 9999999999
pausemovetime = 9999999999
ignorehitpause = 1
ownpal = 1

;-------------------------------------------------------
;Guard Crush Meter p1
;-------------------------------------------------------
[Statedef 19999995]
type = s
movetype = i
physics = n
ignorehitpause = 1

[State 0, ]
type = AssertSpecial
trigger1 = 1
flag = noshadow
flag2 = invisible
ignorehitpause = 1

[State 0]
type = NotHitBy
trigger1 = 1
value = SCA
ignorehitpause = 1

[State 0, BindToRoot]
type = BindToRoot
trigger1 = 1
time = -1
pos = 0,-15
ignorehitpause = 1

[State 0, Explod]
type = Explod
trigger1 = 1 && !numexplod(19999993)
anim = 93133
ID = 19999993
pos = 0,0;55,218
postype = p1;left  ;p2,front,back,left,right
bindtime = -1
removetime = -1
supermovetime = -1
pausemovetime = -1
scale = .5,.5
sprpriority = 5
ontop = 1
ownpal = 1
removeongethit = 0
ignorehitpause = 1
persistent = 0

[State 0, RemoveExplod]
type = RemoveExplod
triggerall = root,anim != [120,152]
trigger1 = ishelper(19999995)
id = 19999993
ignorehitpause = 1
;----------<meter fill Start>-------------
[State 0, Explod]
type = Explod
trigger1 = time = 1
anim = 93132
ID = 199999940
pos = 28,0;55,218
postype = p1  ;p2,front,back,left,right
bindtime = -1
removetime = -1
supermovetime = -1
pausemovetime = -1
scale = .5,.5
sprpriority = 5
ontop = 1
ownpal = 1
ignorehitpause = 1
persistent = 0

[State 0, ModifyExplod]
type = ModifyExplod
trigger1 = numexplod(199999940)
id = 199999940
scale = (root,var(13))/200.0,.5
ignorehitpause = 1

[State 0, RemoveExplod]
type = RemoveExplod
triggerall = root,anim != [120,152]
trigger1 = ishelper(19999995)
id = 199999940
ignorehitpause = 1
;----------<meter fill end>-------------
[State 0, Explod]
type = Explod
trigger1 = root,var(13) > 25 && !numexplod(19999994)
anim = 93131
ID = 19999994
pos = 0,0;55,218
postype = p1  ;p2,front,back,left,right
bindtime = -1
removetime = -1
supermovetime = -1
pausemovetime = -1
scale = .5,.5
sprpriority = 5
ontop = 1
ownpal = 1
ignorehitpause = 1

[State 0, RemoveExplod]
type = RemoveExplod
triggerall = root,anim != [120,152]
trigger1 = root,var(13) <= 25
trigger2 = ishelper(19999995)
id = 19999994
ignorehitpause = 1

[State 0, Explod]
type = Explod
trigger1 = root,var(13) <= 25 && !numexplod(199999941)
anim = 993131
ID = 199999941
pos = 0,0;55,218
postype = p1  ;p2,front,back,left,right
bindtime = -1
removetime = -1
supermovetime = -1
pausemovetime = -1
scale = .5,.5
sprpriority = 5
ontop = 1
ownpal = 1
ignorehitpause = 1

[State 0, RemoveExplod]
type = RemoveExplod
triggerall = root,anim != [120,152]
trigger1 = root,var(13) > 25
trigger2 = ishelper(19999995)
id = 199999941
ignorehitpause = 1

[State 0, Destroyself]
type = Destroyself
trigger1 = root,anim != [120,152]
ignorehitpause = 1

;-------------------------------------------------------
;Guard Crush Meter p2
;-------------------------------------------------------
[Statedef 19999996]
type = s
movetype = i
physics = n
ignorehitpause = 1

[State 0, ]
type = AssertSpecial
trigger1 = 1
flag = noshadow
flag2 = invisible
ignorehitpause = 1

[State 0]
type = NotHitBy
trigger1 = 1
value = SCA
ignorehitpause = 1

[State 0, BindToRoot]
type = BindToRoot
trigger1 = 1
time = -1
pos = 0,-15
ignorehitpause = 1

[State 0, Explod]
type = Explod
trigger1 = 1 && !numexplod(19999993)
anim = 93133
ID = 19999993
pos = 0,0;55,218
postype = p1;left  ;p2,front,back,left,right
bindtime = -1
removetime = -1
supermovetime = -1
pausemovetime = -1
scale = .5,.5
sprpriority = 5
ontop = 1
ownpal = 1
removeongethit = 0
ignorehitpause = 1
persistent = 0

[State 0, RemoveExplod]
type = RemoveExplod
triggerall = root,anim != [120,152]
trigger1 = ishelper(19999996)
id = 19999993
ignorehitpause = 1
;----------<meter fill Start>-------------
[State 0, Explod]
type = Explod
trigger1 = time = 1
anim = 93134
ID = 93134
pos = -29,0;55,218
postype = p1  ;p2,front,back,left,right
bindtime = -1
removetime = -1
supermovetime = -1
pausemovetime = -1
scale = .481,.5
sprpriority = 5
ontop = 1
ownpal = 1
ignorehitpause = 1
persistent = 0

[State 0, ModifyExplod]
type = ModifyExplod
trigger1 = numexplod(93134)
id = 93134
scale = (root,var(13))/200.0,.5
ignorehitpause = 1

[State 0, RemoveExplod]
type = RemoveExplod
triggerall = root,anim != [120,152]
trigger1 = ishelper(19999996)
id = 93134
ignorehitpause = 1
;----------<meter fill end>-------------
[State 0, Explod]
type = Explod
trigger1 = root,var(13) > 25 && !numexplod(19999994)
anim = 93131
ID = 19999994
pos = -1,0;55,218
postype = p1  ;p2,front,back,left,right
bindtime = -1
removetime = -1
supermovetime = -1
pausemovetime = -1
scale = .5,.5
sprpriority = 5
ontop = 1
ownpal = 1
ignorehitpause = 1

[State 0, RemoveExplod]
type = RemoveExplod
triggerall = root,anim != [120,152]
trigger1 = root,var(13) <= 25
trigger2 = ishelper(19999996)
id = 19999994
ignorehitpause = 1

[State 0, Explod]
type = Explod
trigger1 = root,var(13) <= 25 && !numexplod(199999941)
anim = 993131
ID = 199999941
pos = -1,0;55,218
postype = p1  ;p2,front,back,left,right
bindtime = -1
removetime = -1
supermovetime = -1
pausemovetime = -1
scale = .5,.5
sprpriority = 5
ontop = 1
ownpal = 1
ignorehitpause = 1

[State 0, RemoveExplod]
type = RemoveExplod
triggerall = root,anim != [120,152]
trigger1 = root,var(13) > 25
trigger2 = ishelper(19999996)
id = 199999941
ignorehitpause = 1

[State 0, Destroyself]
type = Destroyself
trigger1 = root,anim != [120,152]
ignorehitpause = 1

;-------------------------------------------------------
;Guard Crush effects
;-------------------------------------------------------
[Statedef 19999997]
type = s
movetype = i
physics = n
ignorehitpause = 1

[State 0, ]
type = AssertSpecial
trigger1 = 1
flag = noshadow
flag2 = invisible
flag3 = nobardisplay
ignorehitpause = 1

[State 0]
type = NotHitBy
trigger1 = 1
value = SCA
ignorehitpause = 1

[State 0, Explod]
type = Explod
trigger1 = time = 3
anim = 99315
ID = 99315
pos = 170,140;55,218
postype = left  ;p2,front,back,left,right
bindtime = -1
removetime = 40
supermovetime = -1
pausemovetime = -1
scale = .5,.5
sprpriority = 6
ontop = 1
ownpal = 0
ignorehitpause = 1
persistent = 0

[State 0, PlaySnd]
type = PlaySnd
trigger1 = time = 1
value = S3,4
volume = 255
channel = -1

[State 0, PalFXWiz]
type = BGPalFX
trigger1 = time = 0
time = 25
add = 0,0,0
mul = 256,256,256
sinadd = 256,256,256,50
invertall = 0
color = 256
ignorehitpause = 1

[State 0, PalFXWiz]
type = PalFX
trigger1 = time = 26
time = 25
add = 0,0,0
mul = 256,256,256
sinadd = 256,256,256,-50
invertall = 0
color = 256
ignorehitpause = 1

[State 0, Explod]
type = Explod
trigger1 = time = 35
anim = 99316
ID = 99316
pos = 160,50
postype = left  ;p2,front,back,left,right
removetime = 69
supermovetime = -1
pausemovetime = -1
bindtime = -1
scale = .5,.5
sprpriority = 5
ontop = 1
ownpal = 1
persistent = 0
ignorehitpause = 1

[State 0, PlaySnd]
type = PlaySnd
trigger1 = time = 28
value = S3,3
volume = 255
channel = -1

[State 0, DestroySelf]
type = DestroySelf
trigger1 = time = 100
ignorehitpause = 1

;-------------------------------------------------------------
;Character Guard Crush states
;-------------------------------------------------------------
[statedef 160];Defence Broken while Standing
type = s
movetype = i
physics = s
anim = 160
ctrl = 0

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

;----------------------------------------------
[statedef 161];Defence Broken while Crouching
type = c
movetype = i
physics = c
anim = 161
ctrl = 0

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

;---------------------------------------------
[statedef 162];Defence Broken while in the air
type = a
movetype = i
physics = a
anim = 162
ctrl = 0

[State 0, ChangeState]
type = ChangeState
trigger1 = time = 50
value = 699
ctrl = 1
ignorehitpause = 1

Statedef 19999994 is the helper state from the helper thats activated in statedef -3.
There I have my variable set at var(13) = 100. I am using var 13 for my guard crush btw. all of the others below are used for something else.

These two block below,

[State 0, ParentVarSet];Sets meter on full
type = ParentVarSet
trigger1 = time = 0 || root,stateno = [160,162]
trigger2 = root,var(13) > 100; keeps meter from over flowing
v = 13
value = 100
ignorehitpause = 1

[State 0, ParentVarAdd];regenerates meter by 2 point every 100 game ticks
type = ParentVarAdd
triggerall = root,var(13) != 100
triggerall = root,var(13) < 100 && root,anim != [120,152]
trigger1 = (gametime%100)=1
v = 13
value = 2
ignorehitpause = 1

starts the meter on full and resets the meter when the players guard is broken. Also it also restors the meter bit by bit when not guardinf every second and its set to keep the meter from over flowing.

Now I have three helper blocks in in this state. two of them are place holders for player 1 and player 2's meter and the other is for some special effects I did.

now to properly make the meter scale (thanks to Rednavis help a few weeks back) is to properly place the fill bar in the sff file. If you want the meter to scale from left to right, place the fill meter on the left side of the axis where the right end meets the left side of the actual axis.

To make the meter scale from right to left, do the opposite of the above.

Now its on you code code everything in the proper position and if using an Explod for your meter Like I have, you will need a modify explod with the correct math value and var activation to make it scale from full to empty or vice versa.

here is a sample from the code above,

[State 0, Explod]
type = Explod
trigger1 = time = 1
anim = 93132
ID = 199999940
pos = 28,0;55,218
postype = p1  ;p2,front,back,left,right
bindtime = -1
removetime = -1
supermovetime = -1
pausemovetime = -1
scale = .5,.5
sprpriority = 5
ontop = 1
ownpal = 1
ignorehitpause = 1
persistent = 0

[State 0, ModifyExplod]
type = ModifyExplod
trigger1 = numexplod(199999940)
id = 199999940
scale = (root,var(13))/200.0,.5
ignorehitpause = 1

This is an explod for my meter fill sprite and I want it to scale down when guarding an attack. Just make a normal explod and then in the modifyexplod, I made it register with the guard crushed variable and its actually doubled in size, but since my value is 100, it will fit directly into my guard cruch place holder. Now when blocking, it will decrease like it should bit by bit.

This is also set up the same way for player 2 but I placed the fill meter in the opposite side of the axis.

Now in the guard crush states I have three states, 160, 161, 162

Remember the changestates I have in statedef - 3? Thats what those states below are for. When the players guard is broken, the player will go into its guard break states.

Thats basically it. I just have my meter set up to be visible when blocking and vanish when you are not blocking, its a personal preference of mines, well after having an discussion with Vyn the other night. :P

Anyway Enjoy, hopefully this can help you out.



« Last Edit: May 13, 2008, 07:51:12 PM by |mmö®†åL -$yN- »



Tags:
 


* IMT Facebook

Help us by Donating!

IMT Discord

Join us at our Discord! Click the image below!

* IMT Shoutbox

Sorry, this shoutbox does not exist.

* Recent Posts

D2TD VS Showcase Thread by D2TD
[Today at 09:12:03 AM]


Marvel vs. Capcom: Eternity of Heroes REMAKE Game Update 1.3.0 - N.A.O.H. by LightFlare
[November 21, 2024, 09:44:09 PM]


Terrordrome: Rise of the Boogeymen Extended Version ( jeepers creepers) version by leonardo
[November 19, 2024, 10:22:47 PM]


Hill of the Nameless(1.1 Only) by Vegaz by LightFlare
[November 19, 2024, 10:50:39 AM]


Golden Axe Returns by gokudo99
[November 19, 2024, 03:59:31 AM]


Barkley Shut Up and Jam! Stages by Vegaz by LightFlare
[November 12, 2024, 11:26:21 AM]


[BOR] _Avengers United Battle Force_ by O Ilusionista
[November 11, 2024, 12:35:24 PM]


Eternal Lament Stage 1.1 & 1.0 by O Ilusionista
[November 11, 2024, 12:34:54 PM]


MatreroG's Stages W.I.P. Concepts by MatreroG
[November 11, 2024, 07:00:56 AM]


Spooky House(1.1 Only/AIGS) by Vegaz by LightFlare
[October 31, 2024, 11:31:36 AM]

* IMT Calendar

November 2024
Sun Mon Tue Wed Thu Fri Sat
1 2
3 4 5 6 7 8 9
10 11 12 13 14 15 16
17 18 19 20 21 22 23
[24] 25 26 27 28 29 30

SimplePortal 2.3.5 © 2008-2012, SimplePortal