YesNoOk
avatar

Power Bar through the roof (Read 648 times)

Started by DNZRX768, July 13, 2011, 05:52:23 pm
Share this topic:
Power Bar through the roof
#1  July 13, 2011, 05:52:23 pm
  • *****
  • Hug Pikachus!
    • USA
Ok, so I updated the Pikachus to v 1.0.

Everything was fine until the play testing:



The Power Bar is way too high and the life bar is way too low.

I have not changed anything other than adding in what is needed for playability in 1.0.

What is going on?
Hug the Pikachus!

Hug A Pikachu Today!
Re: Power Bar through the roof
#2  July 13, 2011, 06:22:25 pm
  • ****
  • Target Acquired.
    • Ukraine
    • mugencoder.com
Check the [Data] section in your CNS. Make sure that you have "life" and "power" at feasible values.

-[Все слова это только слова.]-
Re: Power Bar through the roof
#3  July 13, 2011, 06:42:17 pm
  • *****
  • Hug Pikachus!
    • USA
The life and power sections are ok.

But the problem persists.
Hug the Pikachus!

Hug A Pikachu Today!
Re: Power Bar through the roof
#4  July 13, 2011, 07:24:19 pm
  • ****
  • English fluency I am swear!
    • Canada
Possible font problem with the life bars?

Try it using different life bars and see if that changes anything.
Quote
And "Reality" is unveiled.
What did it want . . .
What did it see . . .
What did it hear . . .
What did it think . . .
What did it do . . .
Re: Power Bar through the roof
#5  July 13, 2011, 07:40:29 pm
  • *****
  • Hug Pikachus!
    • USA
Possible font problem with the life bars?

Try it using different life bars and see if that changes anything.

Used a different life bar, same problem.

Maybe something having to do with Pikachu?

EDIT: So here is the code for Pikachu.

Maybe the problem is in here:
Code:
; Pikachu's constants.
;-| Revision by Mr,Funny A.K.A. XRedDragonClawsX |--------------------------

[Data]
life = 1000
power = 3000
attack = 100
defence = 100
fall.defence_up = 50
liedown.time = 60
airjuggle = 25
sparkno = 2
guard.sparkno = 40
KO.echo = 0
volume = 0
IntPersistIndex = 60
FloatPersistIndex = 40

[Size]
xscale = 1
yscale = 1
ground.back = 15
ground.front = 13
air.back = 12
air.front = 12
height = 30
attack.dist = 160
proj.attack.dist = 90
proj.doscale = 1
head.pos = 0, -39
mid.pos = -14, -15
shadowoffset = 0
draw.offset = 0,0

[Velocity]
walk.fwd  = 6.3
walk.back = -6.2
run.fwd  = 9.6, 0
run.back = -7.5,-3.8
jump.neu = 0,-10.5
jump.back = -5
jump.fwd = 5
runjump.back = -2.55,-8.1
runjump.fwd = 4,-8.1
airjump.neu = 0,-8.1
airjump.back = -2.55,-8.1
airjump.fwd = 2.5,-8.1

[Movement]
airjump.num = 1
airjump.height = 35
yaccel = .55
stand.friction = .5
crouch.friction = .5
air.gethit.groundrecover = -.15,-3.5  ;Velocity for ground recovery state (x, y) **MUGEN 1.0**
air.gethit.airrecover.mul = .5,.2     ;Multiplier for air recovery velocity (x, y) **MUGEN 1.0**
air.gethit.airrecover.add = 0,-4.5    ;Velocity offset for air recovery (x, y) **MUGEN 1.0**
air.gethit.airrecover.back = -1       ;Extra x-velocity for holding back during air recovery **MUGEN 1.0**
air.gethit.airrecover.fwd = 0         ;Extra x-velocity for holding forward during air recovery **MUGEN 1.0**
air.gethit.airrecover.up = -2         ;Extra y-velocity for holding up during air recovery **MUGEN 1.0**
air.gethit.airrecover.down = 1.5      ;Extra y-velocity for holding down during air recovery **MUGEN 1.0**

stand.friction.threshold = 2          ;If player's speed drops below this threshold while standing, stop his movement **MUGEN 1.0**
crouch.friction.threshold = .05       ;If player's speed drops below this threshold while crouching, stop his movement **MUGEN 1.0**
air.gethit.groundlevel = 25           ;Y-position at which a falling player is considered to hit the ground **MUGEN 1.0**
air.gethit.groundrecover.ground.threshold = -20 ;Y-position below which falling player can use the recovery command **MUGEN 1.0**
air.gethit.groundrecover.groundlevel = 10   ;Y-position at which player in the ground recovery state touches the ground **MUGEN 1.0**
air.gethit.airrecover.threshold = -1  ;Y-velocity above which player may use the air recovery command **MUGEN 1.0**
air.gethit.airrecover.yaccel = .35    ;Vertical acceleration for player in the air recovery state **MUGEN 1.0**
air.gethit.trip.groundlevel = 15      ;Y-position at which player in the tripped state touches the ground **MUGEN 1.0**
down.bounce.offset = 0,0            ;Offset for player bouncing off the ground (x, y) **MUGEN 1.0**
down.bounce.yaccel = .4               ;Vertical acceleration for player bouncing off the ground **MUGEN 1.0**
down.bounce.groundlevel = 12          ;Y-position at which player bouncing off the ground touches the ground again **MUGEN 1.0**
down.friction.threshold = .05         ;If the player's speed drops below this threshold while lying down, stop his movement **MUGEN 1.0**

;---------------------------------------------------------------------------
;=| Basic Information |=======================================================
;---------------------------------------------------------------------------
;OverRide of Statedef 100
; RUN_FWD
[Statedef 100]
type    = S
physics = S
anim = 100
sprpriority = 1

[State 100, 1]
type = VelSet
trigger1 = 1
x = const(velocity.run.fwd.x)

[State 100, 2] ;Prevent run from canceling into walk
type = AssertSpecial
trigger1 = 1
flag = NoWalk

[State 100, 3] ;Prevent from turning
type = AssertSpecial
trigger1 = 1
flag = NoAutoTurn

;[State 100, 1]
;type = ChangeAnim
;trigger1 = Time = 0
;value = 100

[State 100, 2]
type = AfterImage
trigger1 = Time = 1
time = 2
PalContrast = 220, 220, 120
PalAdd = 100, 100, -64
PalMul = .75, .75, .45

[State 100, 2]
type = AfterImageTime
trigger1 = Time = [2,10000]
time = 2

[State 100, 3]
type = ChangeState
trigger1 = command != "holdfwd"
value = 0

;---------------------------------------------------------------------------
;Override of Statedef 105
; RUN_BACK
[Statedef 105]
type    = A
physics = A
ctrl = 0
anim = 105
sprpriority = 1

[State 105, 1]
type = VelSet
trigger1 = Time = 0
x = const(velocity.run.back.x)
y = const(velocity.run.back.y)

;[State 105, 1]
;type = CtrlSet
;trigger1 = Time = 0
;value = 0

[State 105, 2]
type = AfterImage
trigger1 = Time = 1
time = 2
PalContrast = 220, 220, 120
PalAdd = 100, 100, -64
PalMul = .75, .75, .45

[State 105, 2]
type = AfterImageTime
trigger1 = Time = [2,10000]
time = 2

[State 105, 3]
type = CtrlSet
trigger1 = Time = 2
value = 1

[State 105, 4]
type = ChangeState
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 0
value = 0

;---------------------------------------------------------------------------
; Lose by Time Over
[Statedef 170]
type = S
ctrl = 0
anim = 170
velset = 0,0

[State 170, AssertSpecial]
type = AssertSpecial
trigger1 = Time = [0,210]
flag = roundnotover

[State 170, 1]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1

;---------------------------------------------------------------------------
; Win state decider
[Statedef 180]
type = S

[State 180, 2]
type = ChangeState
trigger1 = Life <= 50
value = 182

[State 180, 1]
type = ChangeState
trigger1 = Time = 0
value = 181

;---------------------------------------------------------------------------
; Win pose 1
[Statedef 181]
type = S
ctrl = 0
anim = 180
velset = 0,0

[State 181, AssertSpecial]
type = AssertSpecial
trigger1 = Time = [0,210]
flag = roundnotover

[State 181, 1]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1

;---------------------------------------------------------------------------
;Win pose 2
[Statedef 182]
type = S
ctrl = 0
anim = 181
velset = 0,0

[State 182, AssertSpecial]
type = AssertSpecial
trigger1 = Time = [0,180]
flag = roundnotover

[State 182, 1]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1

;---------------------------------------------------------------------------
;Preintro: Override of Statedef 190
[Statedef 190]
type = S
ctrl = 0
velset = 0,0

[State 190]
type = VarSet
trigger1 = time = 0
v = 9
value = 1

[State 190, Opponent is Psyduck] ;If opponent is Psyduck, go to alternate intro
type = ChangeState
triggerall = Time = 0
trigger1 = P2Name = "Psyduck"
trigger2 = P4Name = "Psyduck"
value = 192

[State 190, Opponent is Jigglypuff] ;If opponent is Jigglypuff, go to alternate intro
type = ChangeState
triggerall = Time = 0
trigger1 = P2Name = "Jigglypuff"
trigger2 = P4Name = "Jigglypuff"
value = 193

[State 191, Opponent is Pikachu] ;If opponent is Pikachu, go to alternate intro
type = ChangeState
triggerall = Time = 0
trigger1 = P2Name = "Pikachu"
trigger2 = P4Name = "Pikachu"
value = 194

[State 191, Normal Introduction]
type = ChangeState
trigger1 = Time = 0
value = 191

;---------------------------------------------------------------------------
; Introduction
[Statedef 191]
type = S
ctrl = 0
anim = 190
velset = 0,0

[State 191, 1] ;Freeze animation until PreIntro is over
type = ChangeAnim
trigger1 = RoundState = 0
value = 190

[State 191, 2] ;Assert this until you want "round 1, fight" to begin
type = AssertSpecial
trigger1 = 1
flag = Intro

[State 191, 3] ;Change to stand state when done
type = ChangeState
trigger1 = AnimTime = 0
value = 0

;---------------------------------------------------------------------------
; INTRO versus Psyduck
[Statedef 192]
type = S
ctrl = 0
anim = 191
velset = 2, 0 ;3, 0 ;4.4, 0

[State 192, 1] ;Assert this until you want "round 1, fight" to begin
type = AssertSpecial
trigger1 = Time = [0, 300] ;[0,128]
flag = Intro

[State 192, 1.01]
type = ScreenBound
trigger1 = time >= 0
value = 0
movecamera = 0,0

[State 192, 1.1]
type = ChangeAnim
trigger1 = Time = 0
value = 191

[State 192, 1.2]
Type = Posset
trigger1 = time = 0
X = -225 ;-250 ;-300 ;-400

[State 192, 1.5]
Type = Velset
trigger1 = Pos X >= -70
X = 0
persistent = 0

[State 192, 1.7]
type = Posset
trigger1 = Pos X >= -70
trigger1 = Vel X = 0
X = -70
persistent = 0

[State 192, 1.8] ;dizzy
type = ChangeAnim
trigger1 = Pos X = -70
value = 170 ;191
persistent = 0

[State 192, 2]
type = Playsnd
trigger1 = Pos X = -70
value = 1,2
persistent = 0

[State 192, 3]
type = Changestate
trigger1 = Time > 121
value = 0

;---------------------------------------------------------------------------
; INTRO versus Jigglypuff
[Statedef 193]
type = S
ctrl = 0
anim = 192
velset = 4.4, 0

[State 193, 1] ;Assert this until you want "round 1, fight" to begin
type = AssertSpecial
trigger1 = Time = [0,128]
flag = Intro

[State 193, 1.01]
type = ScreenBound
trigger1 = time >= 0
value = 0
movecamera = 0,0

[State 193, 1.1]
type = ChangeAnim
trigger1 = Time = 0
value = 193 ;191

[State 193, 1.2]
Type = Posset
trigger1 = time = 0
X = -400

[State 193, 1.5]
Type = Velset
trigger1 = Pos X >= -70
X = 0
persistent = 0

[State 193, 1.7]
type = Posset
trigger1 = Pos X >= -70
trigger1 = Vel X = 0
X = -70
persistent = 0

[State 193, 1.71]
type = ChangeAnim
trigger1 = Pos X = -70
value = 193
persistent = 0

[State 193, Explod]
type = Explod
trigger1 = Pos X = -70
anim = 30
pos = 0,-14

[State 193, 2]
type = Playsnd
trigger1 = Pos X = -70
value = 7, 2 ;1,2
persistent = 0

[State 193, 3]
type = Changestate
trigger1 = Time > 121
value = 0

;---------------------------------------------------------------------------
; INTRO versus Pikachu
[Statedef 194]
type = S
physics = S
ctrl = 0
anim = 192
velset = 0,0

[State 193, 1] ;Intro not yet over
type = AssertSpecial
trigger1 = Time = [0,108]
flag = Intro

[State 193, 3]
type = ChangeState
trigger1 = AnimTime = -10
value = 0

;---------------------------------------------------------------------------
; Taunt
;[Statedef 195]
;type = S
;ctrl = 0
;anim = 195
;velset = 0,0
;movetype = I
;physics = S
;sprpriority = 2

;[State 195, 1]
;type = CtrlSet
;trigger1 = Time = 40
;value = 1

;[State 195, 2]
;type = ChangeState
;trigger1 = AnimTime = 0
;value = 0
;ctrl = 1

;---------------------------------------------------------------------------
;=| Other Information |=====================================================
;---------------------------------------------------------------------------
; STAND_A
[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)

[State 200, 1]
type = HitDef
trigger1 = AnimElem = 3
attr = S, NA                     ;Attribute: Standing, Normal Attack
damage    = 23,0                   ;Damage that move inflicts
animtype = Light                 ;Animation type: Light, Medium, Heavy, Back (def: Light)
getpower = 30,15                 ;Power to get on hit, on guard
                                 ;(Def Hit: 0)  (Def Guard: 1/2 of hit power)
givepower = 15,8                 ;Power to give opponent on hit, on guard
                                 ;(Def Hit: 0)  (Def Guard: 1/2 of hit power)
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 = 7,8                  ;Time attacker pauses, time victim shakes
numhits = 1                      ;Number of hits to count as (Def: 1)
sparkno = 0                   ;Spark image group and no (Def: set above)
sparkxy = -10,-70                ;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
; mindist  = 0,0,0                 ;Min distance of p2 from p1 when hit
; maxdist  = 0,0,0                 ;Max distance of p2 from p1 when hit
; snap = 0,0,0                     ;Snaps p2 to position rel to p1
ground.type = High                 ;Type: High, Low, Trip (def: Normal)
ground.slidetime = 5             ;Time that the victim slides back
ground.hittime  = 11             ;Time victim is in hit state
ground.velocity = -4,0             ;Velocity at which victim is pushed
; guard.slidetime = 5              ;Values for guarded attack (def: ground.slidetime)
; guard.hittime  = 15              ; (def: ground.hittime)
; guard.velocity = -4              ; (def: ground.velocity)
; guard.ctrltime = 7               ;Time to regain control after guard (def: guard.slidetime)
airguard.velocity = -1.9,-.8     ;Guard velocity in air (def: (air.xvel*1.5, air.yvel/2))
; airguard.ctrltime = 7            ;Time to regain control after air guard (def: ground.ctrltime)
; air.type = High                  ;Type: High, Low, Trip (def: same as ground.type)
air.velocity = -1.3,-3           ;X-velocity at which victim is pushed,
                                 ;Y-velocity at which victim is pushed
;air.hittime = 20                  ;Time before oppoment regains control in air
; attack.width = 3, 3              ;Override default attack width
; fall = 0                         ;1 to cause opponent to fall (def: 0)
; fall.damage = 0                  ;Damage opponent takes on fall
; fall.velocity = n/a,-4.5         ;X, Y-velocity after bouncing off ground
; fall.animtype = Back             ;Animation type for falling people (def: Back)
; air.fall = 0                     ;1 to cause opponent to fall if in air (def: same as fall)
; down.velocity = ?,?              ;Velocity for opponents lying down (def: same as air.velocity)
; down.hittime = 20                ;Time opponent is stunned on ground (only for down.y-velocity = 0) (def: 20)
; down.bounce = 0                  ;Set to 1 for opponent to bounce on ground (def: 0)

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

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

;---------------------------------------------------------------------------
; STAND_B
[Statedef 210]
type    = S
movetype= A
physics = S
juggle  = 4
poweradd= 60
ctrl = 0
velset = 0,0
anim = 210

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

[State 210, 2]
type = HitDef
trigger1 = AnimElem = 2
trigger2 = AnimElem = 3
attr = S, NA
animtype  = Medium
damage    = 55,0
guardflag = MA
pausetime = 11,11
sparkxy = -10,-70
hitsound   = 5,1
guardsound = 6,0
ground.type = High
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -5,0
air.velocity = -2.2,-3.2

[State 210, 3]
type = PosAdd
trigger1 = AnimElem = 3
x = 20 ;15

[State 210, 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
;CROUCH_A
[Statedef 400]
type    = C
movetype= A
physics = C
juggle  = 6
poweradd= 15
ctrl = 0
anim = 400

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

[State 400, 2]
type = HitDef
trigger1 = Time = 0
attr = C, NA
damage    = 23,0
animtype  = Light
getpower  = 10,0
givepower = 8,0
hitflag = MAFD
guardflag = L
pausetime = 10,12
sparkxy = -2,-41
hitsound   = 5,0
guardsound = 6,0
ground.type = Low
ground.slidetime = 4
ground.hittime  = 15
ground.velocity = -4,0
air.velocity = -1.3,-3
down.velocity = -4,0
down.hittime = 20

[State 400, 3]
type = CtrlSet
trigger1 = Time = 4
value = 1

[State 400, 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 11

;---------------------------------------------------------------------------
;CROUCH_B
[Statedef 410]
type    = C
movetype= A
physics = C
juggle  = 7
poweradd= 70
ctrl = 0
anim = 410

[State 410, 2]
type = PlaySnd
trigger1 = Time = 2
channel = 0
value = 5, 0 ;0, 2

[State 410, StateTypeSet]
type = StateTypeSet
trigger1 = AnimElem = 2
statetype = S       ;S,A,C,L
movetype = A        ;I,A,H
physics = N         ;A,C,S,N

[State 410, VelSet]
type = VelSet
trigger1 = AnimElem = 2
x = 16

[State 410, VelSet]
type = Veladd
trigger1 = vel X > 0
trigger1 = AnimElem = 2,>= 0
x = -2

[State 410, 4]
type = HitDef
trigger1 = Time = 0
trigger2 = AnimElem = 2
trigger3 = AnimElem = 3
attr = C, NA
damage    = 70,0
getpower  = 40,0
givepower = 40,0
hitflag = MAFD
guardflag = L
pausetime = 12,12
sparkxy = -5,-10
sparkno = 1
hitsound   = 5,2
guardsound = 6,0
ground.type = Trip
ground.slidetime = 10
ground.hittime  = 15
ground.velocity = -1.5,-2
air.velocity = -1.2,-3
guard.velocity = -5
fall = 1

[State 410, 5]
type = ChangeState
trigger1 = AnimTime = 0
value = 11
ctrl = 1

;---------------------------------------------------------------------------
;JUMP_A
[Statedef 600]
type    = A
movetype= A
physics = A
juggle  = 2
poweradd= 11
ctrl = 0
anim = 600

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

[State 600, 2]
type = HitDef
trigger1 = Time = 0
attr = A, NA
damage    = 12,0
getpower  = 10,0
givepower = 10,0
guardflag = HA
priority = 3
pausetime = 7,8
sparkxy = -10,-58
hitsound   = 5,0
guardsound = 6,0
ground.type = High
ground.slidetime = 5
ground.hittime  = 5
ground.velocity = -4,0
air.velocity = -1.3,-3

[State 600, 3]
type = CtrlSet
trigger1 = Time = 17
value = 1

[State 600, 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 50

;---------------------------------------------------------------------------
;JUMP_B
[Statedef 610]
type    = A
movetype= A
physics = A
juggle  = 3
poweradd= 55
ctrl = 0
anim = 610

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

[State 610, 3]
type = HitDef
trigger1 = Time = 0
attr = A, NA
damage    = 70,0
getpower  = 50,0
givepower = 25,0
guardflag = HA
priority = 3
pausetime = 9,10
sparkxy = -10,-51
hitsound   = 5,2
guardsound = 6,0
ground.type = High
ground.slidetime = 9
ground.hittime  = 9
ground.velocity = -4,0
air.velocity = -1.3,-3

[State 610, 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 50
ctrl = 1

;---------------------------------------------------------------------------
;FIREBALL_X
[Statedef 1000]
type    = S
movetype= A
physics = S
poweradd= 100
ctrl = 0
anim = 1000
velset = 0

[State 1000, 1]
type = PlaySnd
trigger1 = Time = 6
channel = 0
value = 0, 2

[State 1000, 4]
type = Projectile
trigger1 = AnimElem = 8
projanim = 1005         ;Action id 1005 is Shinobu's fireball animation
projhitanim = 1006      ;Action id when fireball hits
offset = -57, -80 ;-70, -80   ;Creation offset from player (x,y)
velocity = 3.5, 0       ;Speed fireball moves (x,y) (optional)
velmul = 1.01, 1
; HitDef part of projectile info
attr = S, SP
damage    = 72,4
getpower  = 60,0
givepower = 40,0
guardflag = MA
pausetime = 0,12
sparkno = 2
sparkxy = 0, 0
hitsound   = 5,4
guardsound = 6,0
ground.type = High
ground.slidetime = 15
ground.hittime  = 20
ground.velocity = -8,0
airguard.velocity = -3.5,-2.75
air.velocity = -2.5,-5.5
air.juggle = 3
air.fall = 1

[State 1000, 6]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
;FIREBALL_Y
[Statedef 1010]
type    = S
movetype= A
physics = S
poweradd= 100
ctrl = 0
anim = 1000
velset = 0

[State 1010, 1]
type = PlaySnd
trigger1 = Time = 6
channel = 0
value = 7, 1 ;0, 2

[State 1010, 4]
type = Projectile
trigger1 = AnimElem = 8
projanim = 1005         ;Action id 1005 is Shinobu's fireball animation
projhitanim = 1006      ;Action id when fireball hits
offset = -57, -88 ;-70, -88     ;Creation offset from player (x,y)
velocity = 3.5, -3.5       ;Speed fireball moves (x,y) (optional)
velmul = 1.01, 1
; HitDef part of projectile info
attr = S, SP
damage    = 72,4
getpower  = 60,0
givepower = 40,0
guardflag = MA
pausetime = 0,12
sparkno = 2
sparkxy = 0, 0
hitsound   = 5,4
guardsound = 6,0
ground.type = High
ground.slidetime = 15
ground.hittime  = 20
ground.velocity = -8,0
airguard.velocity = -3.5,-2.75
air.velocity = -2.5,-5.5
air.juggle = 3
air.fall = 1

[State 1010, 6]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
; SUPERWAZA A
[Statedef 3000]
type    = S
movetype= A
physics = S
juggle  = 4
velset = 0,0
anim = 3000
ctrl = 0

[State 3000, Super A]
type = SuperPause
trigger1 = AnimElem = 1,=0
anim = -1
unhittable = 1

[State 3000, Explod]
type = Explod
trigger1 = AnimElem = 1,=0
anim = F100
pos = 18,-29
supermovetime = 999
pausemovetime = 999
ontop = 1

[State 3000, Explod]
type = Explod
trigger1 = AnimElem = 1,=0
anim = F100
pos = -3,-29
supermovetime = 999
pausemovetime = 999
ontop = 1

[State 3000, Super B]
type = PlaySnd
trigger1 = AnimElem = 1,=0
value = F20, 0 ;Play fight sound of super

[State 3000, Super C]
type = PowerAdd
trigger1 = AnimElem = 1,=0
value = -1000

[State 3000, Super D]
type = AfterImage
trigger1 = AnimElem = 1,=0
time = 2

[State 3000, Super E]
type = AfterImageTime
trigger1 = Time = [0,66]
time = 2

[State 3000, NotHitBy]
type = NotHitBy
trigger1 = AnimElem = 1,=0
value = SCA
time = 72

[State 3000, 1]
type = PlaySnd
trigger1 = AnimElem = 5
trigger2 = AnimElem = 11
trigger3 = AnimElem = 17
channel = 0
value = 5, 0 ;0, 2

[State 3000, StateTypeSet]
type = StateTypeSet
trigger1 = AnimElem = 1,=1
statetype = S       ;S,A,C,L
movetype = A        ;I,A,H
physics = N         ;A,C,S,N

[State 3000, VelSet]
type = VelSet
trigger1 = AnimELem = 1,=1
trigger2 = AnimElem = 7,=1
trigger3 = AnimELem = 13,=1
x = 6

[State 3000, VelSet]
type = VelAdd
trigger1 = AnimELem = 3,=1
trigger2 = AnimElem = 9,=1
trigger3 = AnimELem = 15,=1
x = -3

[State 3000, VelSet]
type = VelSet
trigger1 = AnimELem = 6,=1
trigger2 = AnimELem = 12,=1
trigger3 = AnimElem = 18,=1
x = 0

[State 3000, 5]
type = HitDef
trigger1 = AnimElem = 4
trigger2 = AnimElem = 5
trigger3 = AnimElem = 10
trigger4 = AnimElem = 11
trigger5 = AnimElem = 16
attr = S, HA
animtype  = Hard
damage    = 40,4
getpower  = 0,0
priority  = 6
guardflag = L
pausetime = 5, 5 ;15,15
sparkxy = -10,-60
hitsound   = 5,4
guardsound = 6,0
ground.type = Low
ground.slidetime = 22
ground.hittime  = 26;22
ground.velocity = 1,0;-6,0
air.velocity = 2,2;-3,-3
fall.animtype = Hard
fall = 0;1
;fall.recover = 0

[State 3000, 6]
type = HitDef
trigger1 = AnimElem = 17
attr = S, HA
animtype  = Hard
damage    = 75,7
getpower  = 0,0
priority  = 6
guardflag = L
pausetime = 15,15
sparkxy = -10,-60
hitsound   = 5,4
guardsound = 6,0
ground.type = Low
ground.slidetime = 25
ground.hittime  = 25
ground.velocity = -5, -4
guard.velocity = -9
air.velocity = -5,-4
airguard.velocity = -3,-3
fall.animtype = Hard
fall = 1
fall.recover = 0

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

;---------------------------------------------------------------------------
; Begin Shield
[Statedef 6000]
type    = S
movetype= A
physics = S
velset = 0,0
poweradd = -3000
juggle = 0
ctrl = 0
anim = 6000

[State 6000, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1

[State 6000, 2]
type = AfterImage
trigger1 = Time = 1
time = 2

[State 6000, 2]
type = AfterImageTime
trigger1 = Time = [2,10000]
time = 2

[State 6000, Super B]
type = PlaySnd
trigger1 = Time = 0
channel = 0
value = 7, 0 ;F20, 0 ;Play fight sound of super

[State 6000, 1]
type = SuperPause
trigger1 = AnimElem = 3
time = 40
pos = 5, -40 ;7,-140
anim = 100

[State 6000, 1]
type = PlaySnd
trigger1 = AnimElem = 2
value = 6000, 0

[State 6000, 1]
type = VarSet
trigger1 = AnimElem = 4
v = 1
value = 1

[State 6000, Helper]
type = Helper
trigger1 = AnimElem = 4
helpertype = normal
name = "Shock Shield"
ID = 6900
stateno = 6900
pos = 0,-70
postype = p1    ;p2,front,back,left,right
facing = 1
keyctrl = 0
ownpal = 1
supermovetime = 0
pausemovetime = 0
ignorehitpause = 1
persistent = 0

[State 6000, 8]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
;Shock Shield
[Statedef 6900]
type    = S
movetype= A
physics = S
poweradd= 0
ctrl = 1
anim = 6900 ;1000
velset = 0

[State 6900, BindToParent]
type = BindToParent
trigger1 = 1
time = 1
facing = 1
pos = 0,-70
ignorehitpause = 1

[State 6900, 1]
type = PlaySnd
trigger1 = Time = 6
channel = 0
value = 0, 2

[State 6900, 4]
type = HitDef
;trigger1 = AnimElem = 2
;trigger2 = AnimElem = 3
trigger1 = Time >=0
attr = S, NA
animtype  = Medium
damage    = 20,0;55,0
guardflag = MA
pausetime = 0,0 ;11,11
sparkxy = -10,-70
hitsound   = 5,1
guardsound = 6,0
ground.type = High
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -5,0
air.velocity = -2.2,-3.2
persistent = 20

[State 6900, DestroySelf]
type = DestroySelf
trigger1 = Parent, var(3) > 80
trigger2 = Parent, Stateno = 7000

;---------------------------------------------------------------------------
 ;Dizzy
[Statedef 7000]
type    = C
movetype= A
physics = S
velset = 0,0
poweradd = 0
juggle = 0
ctrl = 0
anim = 5300

[State 7000, 1]
type = VarSet
trigger1 = Time = 0
v = 3
value = 0

[State 7000, 2]
type = PlaySnd
trigger1 = Time = 2 ;50
channel = 0
value = 7, 1 ;0, 2 ;9,0

[State 7000, 8]
type = ChangeState
trigger1 = Time = 280
value = 11
ctrl = 1

;---------------------------------------------------------------------------
; Override common states (use same number to override) :
;---------------------------------------------------------------------------
;Changed Win = 0 to Lose
;Note: Realized that was so friggen' stoopidz x)

[Statedef -2]

;Used as a counter
[State -2, 1]
type = varadd
trigger1 = var(1) > 0
v = 1
value = 1

;Activated the shield explode effect every 8 ticks
[State -2, 2]
type = varadd
trigger1 = var(1) = 8
v = 2
value = 1

;read above
[State -2, 4]
type = varset
trigger1 = var(1) > 8
v = 2
value = 0

;Counter 'til shield expires
[State -2, 4]
type = varadd
trigger1 = var(1) > 8
v = 3
value = 1

;resets var(1)
[State -2, 3]
type = varset
trigger1 = var(1) > 8
v = 1
value = 1

;---------------
[State -2, 5]
type = null;explod
trigger1 = var(2) = 1
anim = 6900
pos = 0,-70
postype = p1
sprpriority = -1
bindtime = 13
ignorehitpause = 1
ownpal = 1
;---------------

[State -2, 4]
type = palfx
trigger1 = var(1) = 1
add = 100,100,100
blink = 1
time = 3

[State -2, 4]
type = veladd
triggerall = var(1) > 0
triggerall = vel X > 0
trigger1 = stateno = 20 ; walk
trigger2 = stateno = 50 ; jump
trigger2 = time = 1
trigger3 = stateno = 100 ; run
x = 1

[State -2, 4]
type = veladd
triggerall = var(1) > 0
triggerall = vel X < 0
trigger1 = stateno = 20 ;walk
trigger2 = stateno = 50 ; jump
trigger2 = time = 1
trigger3 = stateno = 105 ; run
trigger3 = time = 1
x = -1

[State -2, 4]
type = PowerSet
trigger1 = var(1) > 0
trigger1 = Power > 0
value = 0

[State -2, 4]
type = varset
trigger1 = var(3) > 80
trigger1 = Win = 0
v = 1
value = 0

[State -2, 4]
type = varset
trigger1 = var(3) > 80
trigger1 = Win = 0
v = 2
value = 0

[State -2, 4]
type = veladd
trigger1 = var(3) > 80
trigger1 = stateno != 5050
trigger1 = Win = 0
x = -3
y = -3

[State -2, 4]
type = ChangeState
trigger1 = var(3) > 80
trigger1 = stateno != 5050
trigger1 = stateno != 905
trigger1 = Win = 0
value = 5050

[State -2, 4]
type = varset
trigger1 = var(3) > 80
trigger1 = Win = 0
v = 3
value = 1

[State -2, 4]
type = ChangeState
triggerall = var(3) = 1
triggerall = var(1) = 0
triggerall = ctrl = 1
trigger1 = statetype = S
trigger2 = statetype = C
value = 7000

;[Statedef -3]







Hug the Pikachus!

Hug A Pikachu Today!
Last Edit: July 13, 2011, 08:41:57 pm by DNZRX768
Re: Power Bar through the roof
#6  July 13, 2011, 11:00:08 pm
  • ****
  • Target Acquired.
    • Ukraine
    • mugencoder.com
Are there any more CNS files associated with your character, or is this the only one? Hmm, after looking through the code, I don't see anything that looks out of place that could cause something like that to happen. You said you're converting Pikachu from WinMUGEN to MUGEN 1.0. Dumb question, but I have to ask: Are you testing him on MUGEN 1.0 or maybe mistakenly still on WinMUGEN?

-[Все слова это только слова.]-
Re: Power Bar through the roof
#7  July 13, 2011, 11:05:33 pm
  • *****
  • Hug Pikachus!
    • USA
All in MUGEN 1.0 last time I checked.

And there was a common1.cns file. Do you think there is a problem in that?

Code:
; Common state file for M.U.G.E.N beta 2002.04.14
;
; System variables usage
; ----------------------
; Var name    Type   Purpose
; --------    ----   -------
; sysvar(0)   Temp   Set by state 5081 (HITL_SLIDE) to 1 to prevent
;                    showing ground hit frame in state 5110 (HIT_LIEDOWN).
;                    Used by guarding states.
; sysvar(1)   Temp   Used by state 40 (Jump Start) amd 45 (Air Jump Start)
;                    to keep track of which way to jump.
;                    Used by state 5100 and 5110 to remember downward
;                    velocity of player just before hitting the ground.
;                    Used in state 5080 for storing the anim # to display.

; The following states have special handling within MUGEN, and should be
; overridden with caution:
; Jump Start (40): airjumping bookkeeping at time = 0
; All guard states (120-155): guard handling throughout state
; Hit_trip, shaking (5070): defence increases at time = 0
; Hit_bounce (5100): defence increases at time = 0, player becomes
;                    invincible if within 10 ticks of getting up
; Hit_liedown (5110): player changes to get-up state (5120) when ready
; Hit_getup (5120): player's defence is restored to normal at time = 0
; Hitfall_recover (5200): player's defence is restored at time = 0
; Hitfall_airrecover (5210): player's defence is restored at time = 0

;---------------------------------------------------------------------------
; Stand
[Statedef 0]
type = S
physics = S
sprpriority = 0

[State 0, 1]
type = ChangeAnim
trigger1 = Anim != 0 && Anim != 5
trigger2 = Anim = 5 && AnimTime = 0 ;Turn anim over
value = 0

[State 0, 2]
type = VelSet
trigger1 = Time = 0
y = 0

[State 0, 3] ;Stop moving if low velocity or 4 ticks pass
type = VelSet
trigger1 = abs(vel x) < 2
trigger2 = Time = 4
x = 0

[State 0, 4] ;Are you dead?
type = ChangeState
trigger1 = !alive
value = 5050

;---------------------------------------------------------------------------
; Stand to Crouch
[Statedef 10]
type    = C
physics = C
anim = 10

[State 10, 1]
type = VelMul
trigger1 = Time = 0
x = .75

[State 10, 2]
type = ChangeState
trigger1 = AnimTime = 0
value = 11

;---------------------------------------------------------------------------
; Crouching
[Statedef 11]
type    = C
physics = C
anim = 11
sprpriority = 0

[State 11, 1] ;Change from turning animation
type = ChangeAnim
trigger1 = Anim = 6 && AnimTime = 0
value = 11

;---------------------------------------------------------------------------
; Crouch to Stand
[Statedef 12]
type    = S
physics = S
anim = 12

[State 12, 1]
type = ChangeState
trigger1 = AnimTime = 0
value = 0

;---------------------------------------------------------------------------
; Walk
[Statedef 20]
type    = S
physics = S
sprpriority = 0

[State 20, 1]
type = VelSet
trigger1 = command = "holdfwd"
x = const(velocity.walk.fwd.x)

[State 20, 2]
type = VelSet
trigger1 = command = "holdback"
x = const(velocity.walk.back.x)

[State 20, 3]
type = ChangeAnim
triggerall = vel x > 0
trigger1 = Anim != 20 && Anim != 5
trigger2 = Anim = 5 && AnimTime = 0
value = 20

[State 20, 4]
type = ChangeAnim
triggerall = vel x < 0
trigger1 = Anim != 21 && Anim != 5
trigger2 = Anim = 5 && AnimTime = 0
value = 21

;---------------------------------------------------------------------------
; Jump Start
[Statedef 40]
type    = S
physics = S
anim = 40
ctrl = 0
sprpriority = 1

[State 40, 1]
type = VarSet
trigger1 = Time = 0
sysvar(1) = 0

[State 40, 2]
type = VarSet
trigger1 = command = "holdfwd"
sysvar(1) = 1

[State 40, 3]
type = VarSet
trigger1 = command = "holdback"
sysvar(1) = -1

[State 40, 4]
type = VelSet
trigger1 = AnimTime = 0
x = ifelse(sysvar(1)=0, const(velocity.jump.neu.x), ifelse(sysvar(1)=1, const(velocity.jump.fwd.x), const(velocity.jump.back.x)))
y = const(velocity.jump.y)

[State 40, 5]
type = VelSet
trigger1 = AnimTime = 0
trigger1 = prevstateno = 100 ;RUN_FWD
trigger1 = sysvar(1) = 1
x = const(velocity.runjump.fwd.x)

[State 40, 6]
type = ChangeState
trigger1 = AnimTime = 0
value = 50
ctrl = 1

;---------------------------------------------------------------------------
; AirJump Start
[Statedef 45]
type    = A
physics = N
ctrl = 0
velset = 0,0

[State 45, 1]
type = ChangeAnim
trigger1 = SelfAnimExist(44)
value = 44

[State 45, 2]
type = ChangeAnim
trigger1 = !SelfAnimExist(44)
value = 41

[State 45, 3]
type = VarSet
trigger1 = Time = 0
sysvar(1) = 0

[State 45, 4]
type = VarSet
trigger1 = command = "holdfwd"
sysvar(1) = 1

[State 45, 5]
type = VarSet
trigger1 = command = "holdback"
sysvar(1) = -1

[State 45, 6]
type = VelSet
trigger1 = Time = 2
x = ifelse(sysvar(1)=0, const(velocity.airjump.neu.x), ifelse(sysvar(1)=1, const(velocity.airjump.fwd.x), const(velocity.airjump.back.x)))
y = const(velocity.airjump.y)

[State 45, 7]
type = ChangeState
trigger1 = Time = 2
value = 50
ctrl = 1

;---------------------------------------------------------------------------
; Jump Up
[Statedef 50]
type    = A
physics = A

[State 50, 1]
type = VarSet
trigger1 = Time = 0
sysvar(1) = 0

[State 50, 2]
type = ChangeAnim
trigger1 = Time = 0
value = ifelse((vel x)=0, 41, ifelse((vel x)>0, 42, 43))

[State 50, 3]
type = ChangeAnim
trigger1 = Vel y > -2
trigger1 = SelfAnimExist(anim + 3)
persistent = 0
value = Anim + 3

;---------------------------------------------------------------------------
; Jump Down (empty state for compatibility)
[Statedef 51]
type    = A
physics = A

[State 51, 1]
type = Null
trigger1 = 1

;---------------------------------------------------------------------------
; Jump Land
[Statedef 52]
type    = S
physics = S
ctrl = 0
anim = 47

[State 52, 1]
type = VelSet
trigger1 = Time = 0
y = 0

[State 52, 2]
type = PosSet
trigger1 = Time = 0
y = 0

[State 52, 3]
type = CtrlSet
trigger1 = Time = 3
value = 1

[State 52, 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
; RUN_FWD
[Statedef 100]
type    = S
physics = S
anim = 100
sprpriority = 1

[State 100, 1]
type = VelSet
trigger1 = 1
x = const(velocity.run.fwd.x)

[State 100, 2] ;Prevent run from canceling into walk
type = AssertSpecial
trigger1 = 1
flag = NoWalk

[State 100, 3] ;Prevent from turning
type = AssertSpecial
trigger1 = 1
flag = NoAutoTurn

[State 100, 4]
type = ChangeState
trigger1 = command != "holdfwd"
value = 0

;---------------------------------------------------------------------------
; RUN_BACK
[Statedef 105]
type    = A
physics = A
ctrl = 0
anim = 105
sprpriority = 1

[State 105, 1]
type = VelSet
trigger1 = Time = 0
x = const(velocity.run.back.x)
y = const(velocity.run.back.y)

[State 105, 2]
type = CtrlSet
trigger1 = Time = 2
value = 1

[State 105, 3]
type = ChangeState
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 0
value = 106

;---------------------------------------------------------------------------
; RUN_BACK2 (land)
[Statedef 106]
type    = S
physics = S
ctrl = 0
anim = 47

[State 106, 1]
type = VelSet
trigger1 = Time = 0
y = 0

[State 106, 2]
type = PosSet
trigger1 = Time = 0
y = 0

[State 106, 3]
type = MakeDust
trigger1 = Time = 2
pos = -5,-2
spacing = 1

[State 106, 4]
type = ChangeState
trigger1 = Time = 7
value = 0
ctrl = 1

;---------------------------------------------------------------------------
; RUN_UP
[Statedef 110]
type    = S
physics = N

[State 110, 0]
type = CtrlSet
trigger1 = Time = 0
value = 0

[State 110, 1]
type = ChangeAnim
trigger1 = Time = 0
value = 110

[State 110, 2]
type = HitBy
trigger1 = Time = 0
value = SCA, NT, ST, HT
time = 30

[State 110, 3]
type = VelSet
trigger1 = Time = 0
x = 0
z = -7

[State 110, 4]
type = VelMul
trigger1 = 1
z = 0.8

[State 110, 5]
type = VelSet
trigger1 = AnimTime = -8
z = 0

[State 110, 7]
type = CtrlSet
trigger1 = AnimTime = 0
value = 1

[State 110, 8]
type = ChangeState
trigger1 = AnimTime = 0
value = 0

;---------------------------------------------------------------------------
; RUN_DOWN
[Statedef 115]
type    = S
physics = N

[State 115, 0]
type = CtrlSet
trigger1 = Time = 0
value = 0

[State 115, 1]
type = ChangeAnim
trigger1 = Time = 0
value = 110

[State 115, 2]
type = HitBy
trigger1 = Time = 0
value = SCA, NT, ST, HT
time = 30

[State 115, 3]
type = VelSet
trigger1 = Time = 0
x = 0
z = 7

[State 115, 4]
type = VelMul
trigger1 = 1
z = 0.8

[State 115, 5]
type = VelSet
trigger1 = AnimTime = -8
z = 0

[State 115, 7]
type = CtrlSet
trigger1 = AnimTime = 0
value = 1

[State 115, 8]
type = ChangeState
trigger1 = AnimTime = 0
value = 0

;---------------------------------------------------------------------------
; GUARD (start)
[Statedef 120]
type = U    ;Leave state type unchanged
physics = U ;Leave physics unchanged

[State 120, 1]
type = ChangeAnim
trigger1 = Time = 0
value = 120 + (statetype = C) + (statetype = A)*2

[State 120, 2]
type = StateTypeSet
trigger1 = Time = 0 && statetype = S
physics = S

[State 120, 3]
type = StateTypeSet
trigger1 = Time = 0 && statetype = C
physics = C

[State 120, 4]
type = StateTypeSet
trigger1 = Time = 0 && statetype = A
physics = A

[State 120, Hi to Lo]
type = StateTypeSet
trigger1 = statetype = S && command = "holddown"
statetype = C
physics = C

[State 120, Lo to Hi]
type = StateTypeSet
trigger1 = statetype = C && command != "holddown"
statetype = S
physics = S

[State 120, 5]
type = ChangeState
trigger1 = AnimTime = 0
value = 130 + (statetype = C) + (statetype = A)*2

[State 120, Stop Guarding]
type = ChangeState
trigger1 = command != "holdback"
trigger2 = !inguarddist
value = 140

;---------------------------------------------------------------------------
; STAND GUARD (guarding)
[Statedef 130]
type    = S
physics = S

[State 130, 1]
type = ChangeAnim
trigger1 = Anim != 130
value = 130

[State 130, Hi to Lo]
type = ChangeState
trigger1 = command = "holddown"
value = 131

[State 130, Stop Guarding]
type = ChangeState
trigger1 = command != "holdback"
trigger2 = !inguarddist
value = 140

;---------------------------------------------------------------------------
; CROUCH GUARD (guarding)
[Statedef 131]
type    = C
physics = C

[State 131, 1]
type = ChangeAnim
trigger1 = Anim != 131
value = 131

[State 131, Lo to Hi]
type = ChangeState
trigger1 = command != "holddown"
value = 130

[State 131, Stop Guarding]
type = ChangeState
trigger1 = command != "holdback"
trigger2 = !inguarddist
value = 140

;---------------------------------------------------------------------------
; AIR GUARD (guarding)
[Statedef 132]
type    = A
physics = N

[State 132, 1]
type = ChangeAnim
trigger1 = Anim != 132
value = 132

[State 132, 2]
type = VelAdd
trigger1 = 1
y = Const(movement.yaccel)

[State 132, 3]
type = VarSet
trigger1 = 1
sysvar(0) = (pos y >= 0) && (vel y > 0)

[State 132, 4]
type = VelSet
trigger1 = sysvar(0)
y = 0

[State 132, 5]
type = PosSet
trigger1 = sysvar(0)
y = 0

[State 132, 6]
type = ChangeState
trigger1 = sysvar(0)
trigger1 = command = "holdback"
trigger1 = inguarddist
value = 130

[State 132, 7]
type = ChangeState
trigger1 = sysvar(0)
value = 52

[State 132, Stop Guarding]
type = ChangeState
trigger1 = command != "holdback"
trigger2 = !inguarddist
value = 140

;---------------------------------------------------------------------------
; GUARD (end)
[Statedef 140]
type = U    ;Leave state type unchanged
physics = U ;Leave physics unchanged
ctrl = 1

[State 140, 1]
type = ChangeAnim
trigger1 = Time = 0
value = 140 + (statetype = C) + (statetype = A)*2

[State 140, 2]
type = StateTypeSet
trigger1 = Time = 0 && statetype = S
physics = S

[State 140, 3]
type = StateTypeSet
trigger1 = Time = 0 && statetype = C
physics = C

[State 140, 4]
type = StateTypeSet
trigger1 = Time = 0 && statetype = A
physics = A

[State 140, Hi to Lo]
type = StateTypeSet
trigger1 = statetype = S && command = "holddown"
statetype = C
physics = C

[State 140, Lo to Hi]
type = StateTypeSet
trigger1 = statetype = C && command != "holddown"
statetype = S
physics = S

;[State 140, 5] ;Implemented within engine
;type = ChangeState
;trigger1 = AnimTime = 0
;value = (statetype = C)*11 + (statetype = A)*51

;---------------------------------------------------------------------------
; SGUARDHIT (shaking)
[Statedef 150]
type    = S
movetype= H
physics = N
velset = 0,0

[State 150, 1]
type = ChangeAnim
trigger1 = 1
value = 150

[State 150, 2]
type = ChangeState
trigger1 = HitShakeOver
value = 151 + 2*(command = "holddown")

[State 150, Hi to Lo]
type = StateTypeSet
trigger1 = statetype = S && command = "holddown"
statetype = C
physics = C

[State 150, Lo to Hi]
type = StateTypeSet
trigger1 = statetype = C && command != "holddown"
statetype = S
physics = S

[State 150, 3]
type = ForceFeedback
trigger1 = time = 0
waveform = square
time = 3

;---------------------------------------------------------------------------
; SGUARDHIT2 (knocked back)
[Statedef 151]
type    = S
movetype= H
physics = S
anim = 150

[State 151, 1]
type = HitVelSet
trigger1 = Time = 0
x = 1

[State 151, 2]
type = VelSet
trigger1 = Time = GetHitVar(slidetime)
trigger2 = HitOver
x = 0

[State 151, 3]
type = CtrlSet
trigger1 = Time = GetHitVar(ctrltime)
value = 1

[State 151, Hi to Lo]
type = StateTypeSet
trigger1 = statetype = S && command = "holddown"
statetype = C
physics = C

[State 151, Lo to Hi]
type = StateTypeSet
trigger1 = statetype = C && command != "holddown"
statetype = S
physics = S

[State 151, 4]
type = ChangeState
trigger1 = HitOver
value = 130
ctrl = 1

;---------------------------------------------------------------------------
; CGUARDHIT (shaking)
[Statedef 152]
type    = C
movetype= H
physics = N
velset = 0,0

[State 152, 1]
type = ChangeAnim
trigger1 = 1
value = 151

[State 152, 3]
type = ChangeState
trigger1 = HitShakeOver
value = 151 + 2*(command = "holddown")

[State 152, Hi to Lo]
type = StateTypeSet
trigger1 = statetype = S && command = "holddown"
statetype = C
physics = C

[State 152, Lo to Hi]
type = StateTypeSet
trigger1 = statetype = C && command != "holddown"
statetype = S
physics = S

[State 152, 4]
type = ForceFeedback
trigger1 = time = 0
waveform = square
time = 4

;---------------------------------------------------------------------------
; CGUARDHIT2 (knocked back)
[Statedef 153]
type    = C
movetype= H
physics = C
anim = 151

[State 153, 1]
type = HitVelSet
trigger1 = Time = 0
x = 1

[State 153, 2]
type = VelSet
trigger1 = Time = GetHitVar(slidetime)
trigger2 = HitOver
x = 0

[State 153, 3]
type = CtrlSet
trigger1 = Time = GetHitVar(ctrltime)
value = 1

[State 153, Hi to Lo]
type = StateTypeSet
trigger1 = statetype = S && command = "holddown"
statetype = C
physics = C

[State 153, Lo to Hi]
type = StateTypeSet
trigger1 = statetype = C && command != "holddown"
statetype = S
physics = S

[State 153, 4]
type = ChangeState
trigger1 = HitOver
value = 131
ctrl = 1

;---------------------------------------------------------------------------
; AGUARDHIT (shaking)
[Statedef 154]
type    = A
movetype= H
physics = N
velset = 0,0

[State 154, 1]
type = ChangeAnim
trigger1 = 1
value = 152

[State 154, 2]
type = ChangeState
trigger1 = HitShakeOver
value = 155 ;AGUARDHIT2

[State 154, 3]
type = ForceFeedback
trigger1 = time = 0
waveform = square
time = 4

;---------------------------------------------------------------------------
; AGUARDHIT2 (knocked away)
[Statedef 155]
type    = A
movetype= H
physics = N
anim = 152

[State 155, 1]
type = HitVelSet
trigger1 = Time = 0
x = 1
y = 1

[State 155, 2]
type = VelAdd
trigger1 = 1
y = Const(movement.yaccel)

[State 155, 3]
type = CtrlSet
trigger1 = Time = GetHitVar(ctrltime)
value = 1

[State 155, 4]
type = VarSet
trigger1 = 1
sysvar(0) = (pos y >= 0) && (vel y > 0)

[State 155, 5]
type = VelSet
trigger1 = sysvar(0)
y = 0

[State 155, 6]
type = PosSet
trigger1 = sysvar(0)
y = 0

[State 155, 6]
type = ChangeState
trigger1 = sysvar(0)
trigger1 = command = "holdback"
trigger1 = inguarddist
value = 130

[State 155, 7]
type = ChangeState
trigger1 = sysvar(0)
value = 52

;---------------------------------------------------------------------------
; LOSE (Time over)
[Statedef 170]
type = S
ctrl = 0
anim = 170
velset = 0,0

[State 170, 1]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1

;---------------------------------------------------------------------------
; DRAWGAME (Time over)
[Statedef 175]
type = S
ctrl = 0
velset = 0,0

[State 175, 1] ; If no anim, use go to lose state.
type = ChangeState
trigger1 = Time = 0
trigger1 = !SelfAnimExist(175)
value = 170

[State 175, 2]
type = ChangeAnim
trigger1 = Time = 0
value = 175

[State 175, 3]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1

;---------------------------------------------------------------------------
; PREINTRO
[Statedef 190]
type = S
ctrl = 0
velset = 0,0

[State 190, 1]
type = ChangeAnim
trigger1 = SelfAnimExist(190)
value = 190

[State 190, 2] ;Go straight to intro.
type = ChangeState
trigger1 = Time = 0
value = 191

;---------------------------------------------------------------------------
; INTRO (override this state to give character an intro)
[Statedef 191]
type = S
ctrl = 0

[State 191, 1]
type = ChangeState
trigger1 = Time = 0
value = 0

;---------------------------------------------------------------------------
; HITG_SHAKE
[Statedef 5000]
type    = S
movetype= H
physics = N
velset = 0,0

[State 5000, 1] ;Anim for HIT_LIGHT to HIT_HARD
type = ChangeAnim
trigger1 = Time = 0
trigger1 = GetHitVar(animtype) != [3,5]
value = ifelse((GetHitVar(groundtype) = 1),5000,5010) + GetHitVar(animtype)

[State 5000, 2] ;Anim for HIT_BACK
type = ChangeAnim
trigger1 = Time = 0
trigger1 = GetHitVar(animtype) = [3,5]
value = 5030

[State 5000, 3] ;Anim for HIT_UP/HIT_DIAGUP (only if it exists)
type = ChangeAnim
trigger1 = Time = 0
trigger1 = (GetHitVar(animtype) = [4,5]) && (SelfAnimExist(5047 + GetHitVar(animtype)))
value = 5047 + GetHitVar(animtype) ;5051 - 4 + type

[State 5000, 4] ;Freeze anim
type = ChangeAnim
trigger1 = Time > 0
value = anim

[State 5000, 5] ;State type gets set to aerial if getting hit up
type = StateTypeSet
trigger1 = Time = 0
trigger1 = GetHitVar(yvel) != 0 || GetHitVar(fall)
trigger2 = Pos Y != 0
statetype = a

[State 5000, 6]
type = ChangeState
trigger1 = HitShakeOver
trigger1 = GetHitVar(yvel) = 0 && !GetHitVar(fall)
value = 5001 ;HITG_SLIDE

[State 5000, 7]
type = ChangeState
trigger1 = HitShakeOver
value = 5030

[State 5000, FFB Light]
type = ForceFeedback
trigger1 = anim = 5000
trigger2 = anim = 5010
persistent = 0
time = 6
waveform = square

[State 5000, FFB Medium]
type = ForceFeedback
trigger1 = anim = 5001
trigger2 = anim = 5011
persistent = 0
time = 8
waveform = sinesquare
ampl = 110,-1,-.3

[State 5000, FFB Hard]
type = ForceFeedback
trigger1 = anim = 5012
trigger2 = anim = 5002
trigger3 = anim = 5030
persistent = 0
time = 15
waveform = sinesquare
ampl = 140

;---------------------------------------------------------------------------
; HITG_SLIDE
[Statedef 5001]
type    = S
movetype= H
physics = S

[State 5001, 1]
type = HitVelSet
trigger1 = Time = 0
x = 1

[State 5001, 2]
type = ChangeAnim
trigger1 = AnimTime = 0
value = 5005 + GetHitVar(animtype) + (GetHitVar(groundtype)=2)*10

[State 5001, 3] ;Stop sliding back
type = VelMul
trigger1 = Time >= GetHitVar(slidetime)
x = .6

[State 5001, 4]
type = VelSet
trigger1 = HitOver
x = 0

[State 5001, 5]
type = DefenceMulSet
trigger1 = HitOver
value = 1

[State 5001, 6]
type = ChangeState
trigger1 = HitOver
value = 0
ctrl = 1

;---------------------------------------------------------------------------
; HITC_SHAKE
[Statedef 5010]
type    = C
movetype= H
physics = N
velset = 0,0

[State 5010, 1] ;Anim for HIT_LIGHT to HIT_HARD
type = ChangeAnim
trigger1 = Time = 0
trigger1 = GetHitVar(animtype) != [3,5]
value = 5020 + GetHitVar(animtype)

[State 5010, 2] ;Anim for HIT_BACK
type = ChangeAnim
trigger1 = Time = 0
trigger1 = GetHitVar(animtype) = [3,5]
value = 5030

[State 5010, 3] ;Anim for HIT_UP/HIT_DIAGUP (only if it exists)
type = ChangeAnim
trigger1 = Time = 0
trigger1 = (GetHitVar(animtype) = [4,5]) && (SelfAnimExist(5047 + GetHitVar(animtype)))
value = 5047 + GetHitVar(animtype) ;5051 - 4 + type

[State 5010, 4] ;Freeze anim
type = ChangeAnim
trigger1 = Time > 0
value = anim

[State 5010, 5] ;State type gets set to aerial if getting hit up
type = StateTypeSet
triggerall = Time = 0
trigger1 = GetHitVar(yvel) != 0 || GetHitVar(fall)
trigger2 = Pos Y != 0
statetype = a

[State 5010, 6]
type = ChangeState
trigger1 = HitShakeOver
trigger1 = GetHitVar(yvel) = 0 && !GetHitVar(fall)
value = 5011 ;HITC_SLIDE

[State 5010, 7]
type = ChangeState
trigger1 = HitShakeOver
value = 5030

[State 5010, FFB Light]
type = ForceFeedback
trigger1 = anim = 5020
persistent = 0
time = 6
waveform = square

[State 5010, FFB Medium]
type = ForceFeedback
trigger1 = anim = 5021
persistent = 0
time = 8
waveform = sinesquare
ampl = 110,-1,-.3

[State 5010, FFB Hard]
type = ForceFeedback
trigger1 = anim = 5022
persistent = 0
time = 15
waveform = sinesquare
ampl = 140

;---------------------------------------------------------------------------
; HITC_SLIDE
[Statedef 5011]
type    = C
movetype= H
physics = C

[State 5011, 1]
type = HitVelSet
trigger1 = Time = 0
x = 1

[State 5011, 2]
type = ChangeAnim
trigger1 = AnimTime = 0
value = 5025 + GetHitVar(animtype)

[State 5011, 3] ;Stop sliding back
type = VelMul
trigger1 = Time >= GetHitVar(slidetime)
x = .6

[State 5011, 4]
type = VelSet
trigger1 = HitOver
x = 0

[State 5011, 5]
type = DefenceMulSet
trigger1 = HitOver
value = 1

[State 5011, 6]
type = ChangeState
trigger1 = HitOver
value = 11
ctrl = 1


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

[State 5020, 1] ;Anim for HIT_LIGHT to HIT_HARD
type = ChangeAnim
trigger1 = Time = 0
trigger1 = GetHitVar(animtype) != [3,5]
value = ifelse((GetHitVar(airtype) = 1),5000,5010) + GetHitVar(animtype)

[State 5020, 2] ;Anim for HIT_BACK
type = ChangeAnim
trigger1 = Time = 0
trigger1 = GetHitVar(animtype) = [3,5]
value = 5030

[State 5020, 3] ;Anim for HIT_UP/HIT_DIAGUP (only if it exists)
type = ChangeAnim
trigger1 = Time = 0
trigger1 = (GetHitVar(animtype) = [4,5]) && (SelfAnimExist(5047 + GetHitVar(animtype)))
value = 5047 + GetHitVar(animtype) ;5051 - 4 + type

[State 5020, 4] ;Freeze anim
type = ChangeAnim
trigger1 = Time > 0
value = anim

[State 5020, 5]
type = ChangeState
trigger1 = HitShakeOver
value = 5030

[State 5020, FFB Light]
type = ForceFeedback
trigger1 = anim = 5000
trigger2 = anim = 5010
persistent = 0
time = 6
waveform = square

[State 5020, FFB Medium]
type = ForceFeedback
trigger1 = anim = 5001
trigger2 = anim = 5011
persistent = 0
time = 8
waveform = sinesquare
ampl = 110,-1,-.3

[State 5020, FFB Hard]
type = ForceFeedback
trigger1 = anim = 5012
trigger2 = anim = 5002
trigger3 = anim = 5030
trigger4 = anim = [5051,5059]
persistent = 0
time = 15
waveform = sinesquare
ampl = 140

;---------------------------------------------------------------------------
; HITA_UP (initial going up)
[Statedef 5030]
type    = A
movetype= H
physics = N
ctrl = 0

[State 5030, 1]
type = VelAdd;Gravity
trigger1 = 1
y = GetHitVar(yaccel)

[State 5030, 2]
type = HitVelSet
trigger1 = Time = 0
x = 1
y = 1

[State 5030, 3]
type = ChangeState
triggerall = !HitFall
trigger1 = HitOver
trigger2 = Vel Y > 0    ;Hit ground
trigger2 = Pos Y >= 10  ;.
value = 5040 ;HITA_RECOV

[State 5030, 4]
type = ChangeState
triggerall = HitFall
trigger1 = HitOver
trigger2 = Vel Y > 0    ;Hit ground
trigger2 = Pos Y >= 10  ;.
value = 5050 ;HITA_FALL

[State 5030, 5]
type = ChangeState
trigger1 = AnimTime = 0
value = 5035 ;HITA_UP (transition)

;---------------------------------------------------------------------------
; HITA_UP_T (transition)
[Statedef 5035]
type    = A
movetype= H
physics = N

[State 5035, 1]
type = ChangeAnim
trigger1 = Time = 0
trigger1 = SelfAnimExist(5035)
trigger1 = Anim != [5051,5059] ;Not if in hit up anim
trigger1 = Anim != 5090 ;Not if hit off ground anim
value = 5035

[State 5035, 2]
type = VelAdd
trigger1 = 1
y = GetHitVar(yaccel)

[State 5035, 3]
type = ChangeState
triggerall = !HitFall
trigger1 = HitOver  ;Hit is over
trigger2 = AnimTime = 0 ;Animation over
trigger3 = Vel Y > 0    ;Hit ground
trigger3 = Pos Y >= 10  ;.
trigger4 = Time = 0     ;No transition anim
trigger4 = Anim != 5035 ;.
value = 5040 ;HITA_RECOV

[State 5035, 4]
type = ChangeState
triggerall = HitFall
trigger1 = HitOver  ;Hit is over
trigger2 = AnimTime = 0 ;Anim is over
trigger3 = Vel Y > 0    ;Hit ground
trigger3 = Pos Y >= 10  ;.
trigger4 = Time = 0     ;No transition anim
trigger4 = Anim != 5035 ;.
value = 5050 ;HITA_FALL

;---------------------------------------------------------------------------
; HITA_RECOV (recovering in air, not falling)
[Statedef 5040]
type    = A
movetype= H
physics = N

[State 5040, 1]
type = ChangeState
trigger1 = !Alive
value = 5050

[State 5040, 2]
type = ChangeAnim
trigger1 = AnimTime = 0
trigger1 = Anim != 5040
trigger2 = Time = 0
trigger2 = Anim != 5035
value = 5040

[State 5040, 3]
type = CtrlSet
trigger1 = HitOver
value = 1

[State 5040, 4]
type = StateTypeSet
trigger1 = HitOver
movetype = I

[State 5040, 5]
type = VelAdd
trigger1 = 1
y = GetHitVar(yaccel)

[State 5040, 6]
type = ChangeState
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 0
value = 52 ;JUMPLAND

;---------------------------------------------------------------------------
; HITA_FALL (knocked up, falling)
[Statedef 5050]
type    = A
movetype= H
physics = N

[State 5050, 1] ;Change anim when done with transition
type = ChangeAnim
trigger1 = AnimTime = 0
trigger1 = Anim = 5035
trigger2 = Time = 0     ;If no transition anim
trigger2 = Anim != 5035
trigger2 = (Anim != [5051, 5059]) && (Anim != [5061, 5069])
trigger2 = Anim != 5090 ;Not if hit off ground anim
value = 5050

[State 5050, 2] ;Coming down anim
type = ChangeAnim
trigger1 = anim = [5050,5059]
trigger1 = Vel Y >= ifelse(anim = 5050, 1, -2)
trigger1 = SelfAnimExist(anim+10)
value = anim+10
persistent = 0

[State 5050, 3] ;Gravity
type = VelAdd
trigger1 = 1
y = GetHitVar(yaccel)

[State 5050, 4] ;Recover near ground
type = ChangeState
triggerall = Vel Y > 0
triggerall = Pos Y >= -20
triggerall = alive
triggerall = CanRecover
trigger1 = Command = "recovery"
value = 5200 ;HITFALL_RECOVER

[State 5050, 5]; Recover in mid air
type = ChangeState
triggerall = Vel Y > -1
triggerall = alive
triggerall = CanRecover
trigger1 = Command = "recovery"
value = 5210 ;HITFALL_AIRRECOVER

[State 5050, 6]
type = ChangeState
trigger1 = Vel Y > 0
trigger1 = Pos Y >= ifelse((anim = [5051,5059]) || (anim = [5061,5069]), 0, 25)
value = 5100 ;HIT_BOUNCE

;---------------------------------------------------------------------------
; HIT_TRIP (shaking)
[Statedef 5070]
type    = A
movetype= H
physics = N
velset = 0,0

[State 5070, 1]
type = ChangeAnim
trigger1 = 1
value = 5070

[State 5070, 2]
type = ChangeState
trigger1 = HitShakeOver
value = 5071

[State 5070, 3]
type = ForceFeedback
trigger1 = time = 0
time = 12
waveform = sinesquare
ampl = 140

;---------------------------------------------------------------------------
; HIT_TRIP2 (fall through air)
[Statedef 5071]
type    = A
movetype= H
physics = N

[State 5071, 1]
type = HitVelSet
trigger1 = Time = 0
x = 1
y = 1

[State 5071, 2] ;Acceleration
type = VelAdd
trigger1 = 1
y = GetHitVar(yaccel)

[State 5071, 3] ;Hit ground
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 15
type = ChangeState
value = 5110

;---------------------------------------------------------------------------
; HITL_SHAKE
[Statedef 5080]
type    = L
movetype= H
physics = N
velset = 0,0

[State 5080, 1] ;Set default anim
type = VarSet
trigger1 = time = 0
sysvar(2) = ifelse (GetHitVar(yvel) = 0, 5080, 5090)

[State 5080, 2]
type = VarAdd
trigger1 = time = 0
trigger1 = (anim = [5081,5089]) || (anim = [5111,5119])
trigger1 = SelfAnimExist(sysvar(2) + (anim % 10))
sysvar(2) = anim % 10

[State 5080, 3] ;If 5090 doesn't exist, default to 5030
type = VarSet
trigger1 = time = 0
trigger1 = sysvar(2) = 5090
trigger1 = !SelfAnimExist(5090)
sysvar(2) = 5030

[State 5080, 3] ;Freeze
type = ChangeAnim
trigger1 = 1
value = sysvar(2)

[State 5080, 4]
type = ChangeState
trigger1 = HitShakeOver
trigger1 = GetHitVar(yvel) = 0
value = 5081 ;HITL_SLIDE

[State 5080, 5]
type = ChangeState
trigger1 = HitShakeOver
trigger1 = GetHitVar(yvel) != 0
value = 5030 ;HITA_UP

;---------------------------------------------------------------------------
; HITL_SLIDE
[Statedef 5081]
type    = L
movetype= H
physics = C

[State 5081, 1]
type = HitVelSet
trigger1 = Time = 0
x = 1

[State 5081, 2]
type = VelSet
trigger1 = HitOver
x = 0

[State 5081, 3] ;Don't show hit ground frame
type = VarSet
trigger1 = Time = 0
sysvar(0) = 1

[State 5081, 4]
type = ChangeState
trigger1 = HitOver
value = 5110 ;HIT_LIEDOWN

;---------------------------------------------------------------------------
; HIT_BOUNCE (hit ground)
[Statedef 5100]
type    = L
movetype= H
physics = N

[State 5100, 1]
type = VelSet
trigger1 = Time = 0
trigger1 = GetHitVar(fall.yvel) = 0
trigger1 = vel x > 1
x = 1

[State 5100, EnvShake]
type = FallEnvShake
trigger1 = Time = 0

[State 5100, Var] ;Save fall velocity
type = VarSet
trigger1 = Time = 0
sysvar(1) = floor(vel y)

[State 5100, 2] ;Hit ground anim (normal)
type = ChangeAnim
triggerall = time = 0
trigger1 = (anim != [5051,5059]) && (anim != [5061,5069])
trigger2 = !SelfAnimExist(5100 + (anim % 10))
value = 5100

[State 5100, 3] ;Hit ground anim (for hit up)
type = ChangeAnim
trigger1 = time = 0
trigger1 = (anim = [5051,5059]) || (anim = [5061,5069])
trigger1 = SelfAnimExist(5100 + (anim % 10))
value = 5100 + (anim % 10)

[State 5100, 4]
type = PosSet
trigger1 = Time = 0
y = 0

[State 5100, 5]
type = VelSet
trigger1 = Time = 0
y = 0

[State 5100, 6] ;Reduce speed
type = VelMul
trigger1 = Time = 0
x = 0.75

[State 5100, 7]
type = ChangeState
trigger1 = Time = 0
trigger1 = GetHitVar(fall.yvel) = 0
value = 5110 ;HIT_LIEDOWN

[State 5100, 8]
type = GameMakeAnim
trigger1 = Time = 1
value = 60 + (sysvar(1) > 5) + (sysvar(1) > 14)
pos = 0, 0
under = sysvar(1) <= 14

[State 5100, 9]
type = HitFallDamage
trigger1 = Time = 3

[State 5100, 10]
type = PlaySnd
trigger1 = Time = 1
value = F7, (sysvar(1) > 5) + (sysvar(1) > 14)

[State 5100, 11]
type = PosFreeze
trigger1 = 1

[State 5100, 12]
type = ChangeState
trigger1 = AnimTime = 0
value = 5101

[State 5100, 13]
type = ForceFeedback
trigger1 = Time = 0
waveform = sinesquare
ampl = 128,-3,-.2,.005
time = 20

;---------------------------------------------------------------------------
; HIT_BOUNCE (bounce into air)
[Statedef 5101]
type    = L
movetype= H
physics = N

[State 5101, 1] ;Coming hit ground anim (normal)
type = ChangeAnim
triggerall = time = 0
trigger1 = anim != [5101,5109]
trigger2 = !SelfAnimExist(5160 + (anim % 10))
value = 5160

[State 5101, 2] ;Coming hit ground anim (for hit up)
type = ChangeAnim
triggerall = time = 0
trigger1 = anim = [5101,5109]
trigger1 = SelfAnimExist(5160 + (anim % 10))
value = 5160 + (anim % 10)

[State 5101, 3]
type = HitFallVel
trigger1 = Time = 0

[State 5101, 4]
type = PosSet
trigger1 = Time = 0
y = 20

[State 5101, 5] ;Acceleration
type = VelAdd
trigger1 = 1
y = .4

[State 5101, 6] ;Hit ground
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 12
type = ChangeState
value = 5110

;---------------------------------------------------------------------------
; HIT_LIEDOWN
[Statedef 5110]
type    = L
movetype= H
physics = N

[State 5110, EnvShake]
type = FallEnvShake
trigger1 = Time = 0

[State 5110, 1] ;For hit up/up-diag type (from state 5081)
type = ChangeAnim
persistent = 0
trigger1 = SelfAnimExist(5110 + (anim % 10))
trigger1 = anim = [5081,5089]
value = 5110 + (anim % 10)

[State 5110, 2] ;Hit ground anim (normal)
type = ChangeAnim
triggerall = time = 0
triggerall = anim != [5110,5119] ;Not already changed anim
trigger1 = anim != [5161,5169]
trigger2 = !SelfAnimExist(5170 + (anim % 10))
value = 5170

[State 5110, 3] ;Hit ground anim (for hit up)
type = ChangeAnim
triggerall = time = 0
triggerall = anim != [5110,5119] ;Not already changed anim
trigger1 = anim = [5161,5169]
trigger1 = SelfAnimExist(5170 + (anim % 10))
value = 5170 + (anim % 10)

[State 5110, 4]
type = HitFallDamage
trigger1 = Time = 0

[State 5110, 5]
type = PosSet
trigger1 = Time = 0
y = 0

[State 5110, Var] ;Get fall velocity
type = VarSet
trigger1 = Time = 0
trigger1 = GetHitVar(fall.yvel) != 0
sysvar(1) = floor(vel y)

[State 5110, 6]
type = PlaySnd
trigger1 = Time = 0
trigger1 = !SysVar(0)
value = F7, (sysvar(1) > 5) + (sysvar(1) > 14)

[State 5110, 7]
type = GameMakeAnim
trigger1 = Time = 0
trigger1 = !SysVar(0)
value = 60 + (sysvar(1) > 5) + (sysvar(1) > 14)
pos = 0, 0
under = sysvar(1) <= 14

[State 5110, 8]
type = VelSet
trigger1 = Time = 0
y = 0

[State 5110, 9] ;For hit up type
type = ChangeAnim
persistent = 0
triggerall = anim = [5171,5179]
triggerall = SelfAnimExist(5110 + (anim % 10))
trigger1 = AnimTime = 0
trigger2 = SysVar(0) ;SysVar(0) = 1 avoids hit ground anim
value = 5110 + (anim % 10)

[State 5110, 10] ;For normal
type = ChangeAnim
persistent = 0
triggerall = Anim != [5111,5119]
trigger1 = AnimTime = 0
trigger2 = SysVar(0) ;SysVar(0) = 1 avoids hit ground frame
value = 5110

[State 5110, 11] ;If just died
type = ChangeState
triggerall = !alive
trigger1 = AnimTime = 0
trigger2 = SysVar(0) ;SysVar(0) = 1 avoids hit ground frame
trigger3 = Anim = [5110,5119]
value = 5150

[State 5110, 12]
type = VarSet
trigger1 = SysVar(0)
trigger1 = Time = 0
sysvar(0) = 0

[State 5110, 13] ;Friction
type = VelMul
trigger1 = 1
x = 0.85

[State 5110, 14]
type = ForceFeedback
trigger1 = alive
trigger1 = Time = 0
time = 8
ampl = 240
waveform = sine

[State 5110, 15]
type = ForceFeedback
trigger1 = !alive
trigger1 = Time = 0
ampl = 200, 7, -.467
time = 30
waveform = sine

;---------------------------------------------------------------------------
; HIT_GETUP
[Statedef 5120]
type    = L
movetype= I
physics = N

[State 5120, 1a] ;Get up anim (normal)
type = ChangeAnim
triggerall = time = 0
trigger1 = anim != [5111,5119]
trigger2 = !SelfAnimExist(5120 + (anim % 10))
value = 5120

[State 5120, 1b] ;Get up anim (for hit up/diag-up)
type = ChangeAnim
triggerall = time = 0
trigger1 = anim = [5111,5119]
trigger1 = SelfAnimExist(5120 + (anim % 10))
value = 5120 + (anim % 10)

[State 5120, 2]
type = VelSet
trigger1 = Time = 0
x = 0

[State 5120, 3]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1

[State 5120, 4]
type = HitFallSet
trigger1 = AnimTime = 0
value = 1

[State 5120, 5] ;Can't be thrown right after getting up
type = NotHitBy
trigger1 = AnimTime = 0
value = , NT,ST,HT
time = 12

[State 5120, 6] ;Can't be hit right after getting up (short time)
type = NotHitBy
trigger1 = AnimTime = 0
value2 = SCA
time = 3

[State 5120, 7]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
; HIT_LIEDEAD
[Statedef 5150]
type    = L
movetype= H
physics = N
sprpriority = -3

[State 5150, 1] ;Normal anim
type = ChangeAnim
triggerall = Time = 0
triggerall = SelfAnimExist(5140)
trigger1 = (anim != [5111,5119]) && (anim != [5171,5179])
trigger2 = !SelfAnimExist(5140 + (anim % 10))
value = 5140

[State 5150, 3] ;Hit up type anim
type = ChangeAnim
trigger1 = Time = 0
trigger1 = (anim = [5111,5119]) || (anim = [5171,5179])
trigger1 = SelfAnimExist(5140 + (anim % 10))
value = 5140 + (anim % 10)

[State 5150, 4] ;Match over anim
type = ChangeAnim
persistent = 0
;trigger1 = Time = 0
trigger1 = MatchOver = 1
trigger1 = Anim = [5140,5149]
trigger1 = SelfAnimExist(anim+10)
value = anim+10

[State 5150, 5] ;Switch to 5110 if liedead anim does not exist
type = ChangeAnim
trigger1 = Time = 0
trigger1 = Anim != [5140,5159]
trigger1 = Anim != [5110,5119]
value = 5110

[State 5150, 6] ;Friction
type = VelMul
trigger1 = 1
x = 0.85

[State 5150, 7] ;Friction
type = VelSet
trigger1 = Vel x < .05
persistent = 0
x = 0

[State 5150, 8]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1

;---------------------------------------------------------------------------
; HIT_FALLRECOVER (still falling)
[Statedef 5200]
type    = A
movetype= H
physics = N

[State 5200, 1] ;Change anim if done with transition
type = ChangeAnim
trigger1 = Anim = 5035
trigger1 = AnimTime = 0
value = 5050

[State 5200, 2]
type = VelAdd
trigger1 = 1
y = GetHitVar(yaccel)

[State 5200, 3]
type = SelfState
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 10
value = 5201

;---------------------------------------------------------------------------
; HIT_FALLRECOVER (on the ground)
[Statedef 5201]
type    = A
movetype= H
physics = A
anim = 5200

[State 5201, 1] ;Turn if not facing opponent
type = Turn
trigger1 = Time = 0
trigger1 = p2dist X < -5

[State 5201, 2]
type = VelSet
trigger1 = Time = 0
x = -.15
y = -3.5

[State 5201, 3]
type = PosSet
trigger1 = Time = 0
y = 0

[State 5201, 4]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1

[State 5201, 5] ;Blink white
type = PalFX
trigger1 = Time = 0
time = 3
add = 128,128,128 ;256,256,256

[State 5201, 6]
type = GameMakeAnim
trigger1 = Time = 1
value = 60
pos = 0, 0
under = 1

;---------------------------------------------------------------------------
; HIT_AIRFALLRECOVER
[Statedef 5210]
type    = A
movetype= I
physics = N
anim = 5210
ctrl = 0

[State 5210, 1] ;Blink white
type = PalFX
trigger1 = Time = 0
time = 3
add = 128,128,128 ;256,256,256

[State 5210, 1]
type = PosFreeze
trigger1 = Time = 0
value = 4

[State 5210, 2] ;Turn if not facing opponent
type = Turn
trigger1 = Time = 0
trigger1 = p2dist X < -20

[State 5210, 1]
type = VelMul
trigger1 = Time = 4
x = .8
y = .8

[State 5210, 1]
type = VelAdd
trigger1 = Time = 4
y = -4.5

[State 5210, 1]
type = VelMul
trigger1 = Time = 4
trigger1 = Vel Y > 0
y = .5

[State 5210, 1]
type = VelAdd
trigger1 = Time = 4
trigger1 = Vel Y > -3
y = -2

[State 5210, 1]
type = VelAdd
trigger1 = Time = 4
trigger1 = Vel Y > -2
y = -1

[State 5210, 2] ;Go up
type = VelAdd
trigger1 = Time = 4
trigger1 = Command = "holdup"
y = -2

[State 5210, 2] ;Go down
type = VelAdd
trigger1 = Time = 4
trigger1 = Command = "holddown"
y = 1.5

[State 5210, 2] ;Go fwd
type = VelMul
trigger1 = Time = 4
trigger1 = Command = "holdfwd"
x = 1

[State 5210, 2] ;Go back
type = VelAdd
trigger1 = Time = 4
trigger1 = Command = "holdback"
x = -1

[State 5210, 3]
type = NotHitBy
trigger1 = Time = 0
value = SCA
time = 15

[State 5210, 4]
type = CtrlSet
trigger1 = Time = 20
value = 1

[State 5210, 5]
type = VelAdd;Gravity
trigger1 = Time >= 4
y = .35

[State 5210, 5] ;Land on ground
type = ChangeState
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 0
value = 52 ;JUMP_LAND
ctrl = 1

;---------------------------------------------------------------------------
; Continue?
[Statedef 5500]
type = S
ctrl = 0
anim = 5300
velset = 0,0

[State 5500, 1] ;Use continue animation if available
type = ChangeAnim
trigger1 = time = 0
trigger1 = SelfAnimExist(5500)
value = 5500

;---------------------------------------------------------------------------
; Initialize (at the start of the round)
[Statedef 5900]
type = S

[State 5900, 1] ;Clear all int variables
type = VarRangeSet
trigger1 = roundsexisted = 0
value = 0

[State 5900, 2] ;Clear all float variables
type = VarRangeSet
trigger1 = roundsexisted = 0
fvalue = 0

[State 5900, 3] ;Intro for round 1
type = ChangeState
trigger1 = roundno = 1
value = 190
Hug the Pikachus!

Hug A Pikachu Today!
Re: Power Bar through the roof
#8  July 13, 2011, 11:27:45 pm
  • ****
  • Target Acquired.
    • Ukraine
    • mugencoder.com
That could be an issue. That common1.cns looks like it's for WinMUGEN whereas MUGEN 1.0 uses a newer, better file. Was anything changed in this file from the original that you know of, or is it a direct copy and past from WinMUGEN's data folder? If you've changed anything to make your character work, I suggest adding them to a copy of the new common1.cns for you character. If nothing has changed and it's just a direct copy and paste, then you can remove the file from your character's folder all together and it will default to using the one found in common1.cns. 90% of the time this is what you want to do.

-[Все слова это только слова.]-
Re: Power Bar through the roof
#9  July 14, 2011, 12:53:40 am
  • *****
  • Hug Pikachus!
    • USA
So, I removed the common1.cns file from the character's folder.

However, the problem remained.

I do not understand why is this happening.
Hug the Pikachus!

Hug A Pikachu Today!
Re: Power Bar through the roof
#10  July 14, 2011, 01:32:51 am
  • ****
  • Target Acquired.
    • Ukraine
    • mugencoder.com
Can you send me the character (via PM so as not to make it public)? I'll see if I can find out what the problem is. It will also tell us whether there's something wrong with your screen pack or MUGEN game.

-[Все слова это только слова.]-
Last Edit: July 14, 2011, 01:38:28 am by kenshinx0
Re: Power Bar through the roof
#11  July 14, 2011, 08:50:35 am
  • ******
  • Legendary XIII
  • I am the eye of the storm to come!
    • New Zealand
    • network.mugenguild.com/cyanide/
Please post the contents of the .def file. Mugen 1.0 for some reason has a weird problem with buffering the name text. Basically, if name is long, or author, or whatever. Mugen has some odd effects. The above is possibly one of them.


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: Power Bar through the roof
#12  July 14, 2011, 08:53:47 am
  • ******
  • I hang out tough. I'm a real boss.
    • USA
    • litotichues.com/
Just tested that, long names make the powerbar go crazy. o_O
Re: Power Bar through the roof
#13  July 14, 2011, 08:59:40 am
  • ******
  • Legendary XIII
  • I am the eye of the storm to come!
    • New Zealand
    • network.mugenguild.com/cyanide/
I've also seen it do insta kills, deplete the lifebar but not power bar. And the last one is really odd, doubling the graphics of the power bar itself, so you had 2.

I don't know when it kicks in though, never counted up the characters.


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: Power Bar through the roof
#14  July 14, 2011, 09:13:17 am
  • ******
  • I hang out tough. I'm a real boss.
    • USA
    • litotichues.com/
I don't see the correlation between names an any of that stuff. That's ridiculously weird.

And I don't understand why Pikachu would have an unusually large name, anyway. :P
Re: Power Bar through the roof
#15  July 14, 2011, 09:16:00 am
  • ******
  • Legendary XIII
  • I am the eye of the storm to come!
    • New Zealand
    • network.mugenguild.com/cyanide/
Could be the authorname field. Or even the name field being oldschool. I know he's edited someone elses character

name = "Pikachu by Gargoyle and dnzrx798" would probably break it.


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.

2OS

Re: Power Bar through the roof
#16  July 14, 2011, 12:54:44 pm
  • ****
  • Ich schicke dich zur HOELLE ! ¡ ! ¡
    • Egypt
    • deuceovspadez.webs.com/


[ 052012 ] Inazumachi 181/256  /  deviantART   /  2OS Grafphicsxz  Dead Anims ( Orochi/Mizuchi )  /  608's FX Volume 3
Re: Power Bar through the roof
#17  July 14, 2011, 02:46:00 pm
  • *****
  • Hug Pikachus!
    • USA
The .def is as follows

Code:
; Definition file for Pikachu
; Contains all the filenames needed for the character

; Player information
[Info]
name ="Pikachu by XGargoyle (Revised and Updated by XRedDragonClawsX   A.K.A. Mr,Funny)"
displayname ="Pikachu"
versiondate =04,14,2002 - Updated and Revised: 7-6-2008
mugenversion =1.0
author ="XGargoyle (Edited/Updated by XRedDragonClawsX)"
pal.defaults =1, 2, 3, 4
localcoord = 320,240

; Files for the player
[Files]
cmd     =RDC_Pikachu.cmd
cns     =RDC_Pikachu.cns
st      =RDC_Pikachu.cns
stcommon =common1.cns
sprite  =RDC_Pikachu.sff
anim    =RDC_Pikachu.air
sound   =RDC_Pikachu.snd
pal1=RDC_Pikachu1.act
pal2=RDC_Pikachu2.act
pal3=RDC_Pikachu3.act
pal4=RDC_Pikachu4.act
;pal5    = pika5.act  ;
;pal6    = pika6.act  ;

[Arcade]
intro.storyboard=
ending.storyboard=

[Palette Keymap]
a = 1
b = 2
c = 3
x = 4
y = 5
z = 6
a2 = 7
b2 = 8
c2 = 9
x2 = 10
y2 = 11
z2 = 12

Still, I would think the .def would not interfere with gameplay, least of all the name.
Hug the Pikachus!

Hug A Pikachu Today!
Re: Power Bar through the roof
#18  July 14, 2011, 02:53:29 pm
  • ******
  • I hang out tough. I'm a real boss.
    • USA
    • litotichues.com/
It is definitely the name. Shorten the name. It doesn't make sense, but that's the problem.

Just use "Pikachu" and give credit in the readme or something.
Re: Power Bar through the roof
#19  July 14, 2011, 02:54:35 pm
  • *****
  • Hug Pikachus!
    • USA
Ok, so I just modified the name field and author field into something more reasonable.

And it worked!

Although it is really odd that the name or author of a characters would cause the game to go haywire.

Maybe we should tell this to Elecbyte...
Hug the Pikachus!

Hug A Pikachu Today!
Re: Power Bar through the roof
#20  July 15, 2011, 01:55:06 am
  • ****
  • Target Acquired.
    • Ukraine
    • mugencoder.com
Y'know what's strange though? I tested this Pikachu and renamed him to something smaller in length. It didn't seem to make a difference for me so I was convinced that it couldn't be the problem. So how is it that when DNZRX768 makes the name smaller it works? I find that very weird.

Anyways, Glad you got it working.

-[Все слова это только слова.]-
Re: Power Bar through the roof
#21  July 15, 2011, 02:02:13 am
  • avatar
  • ****
are you using the same screen pack as DNZRX768. I know this might not have anything to do with it but the older version the anarchy screen pack gave me a few problems that I didn't have with other screen packs. I can't remember what it was since I deleted it.
Re: Power Bar through the roof
#22  July 15, 2011, 02:11:42 am
  • ****
  • Target Acquired.
    • Ukraine
    • mugencoder.com
Nope, I'm just using the default MUGEN 1.0 motif, so screenpack issues aren't the a problem here. It honestly doesn't matter too much, since I'd never name any of my characters with a String of that length, which is probably why I'd never seen anything like this before. I just found it a bit strange that same fix didn't work for the version of this Pikachu that was sent to me for testing.

-[Все слова это только слова.]-
Re: Power Bar through the roof
#23  July 15, 2011, 08:32:09 am
  • ******
  • Legendary XIII
  • I am the eye of the storm to come!
    • New Zealand
    • network.mugenguild.com/cyanide/
It manifests itself differently for everyone. There was one person who said they had this problem, i tried it and got an empty lifebar instead.

Elecbyte is also aware of this.


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: Power Bar through the roof
#24  July 15, 2011, 04:38:12 pm
  • ****
  • Target Acquired.
    • Ukraine
    • mugencoder.com
Well that's certainly good to know. Thanks Cyanide. Note to anyone making any MUGEN characters (myself included) : Don't name you characters with extensively long names or weird shit like this will happen.  :sugoi:

-[Все слова это только слова.]-