;Hyper DragonBall Z - Korin Tower Stage
;by HQ & XGargoyle


;--------------------------------------------------------
[Info]

name = "Korin's Tower"
displayname = "Korin's Tower" 
versiondate = 02,22,2017 
mugenversion = 1.0
author = "HQ, Daeron & XGargoyle"

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

[Camera]
startx = 0
starty = 0
boundleft = -310 
boundright = 310  
boundhigh = -300 ;-130  
boundlow = 0
verticalfollow = 0.75;0.2 
floortension = 90;0
tension = 50;50

 ;Number of pixels beyond the top and bottom of the screen that may
 ;be drawn.  Overdraw specifies the how much can be seen during an
 ;EnvShake.  Overdraw pixels will also be used when the screen aspect
 ;is taller than the stage aspect.
overdrawhigh = 0
overdrawlow = 0

 ;Number of pixels into the top and bottom of the screen that may be
 ;cut from drawing when the screen aspect is shorter than the stage
 ;aspect.  These parameters suggest a guideline, and the actual
 ;number of pixels cut depends on the difference in aspect.
cuthigh = 35
cutlow = 25

;--------------------------------------------------------
[PlayerInfo]
;--- Player 1 ---
p1startx = -70 ;-80          ;Starting x coordinates
p1starty = 0            ;Starting y coordinates
p1facing = 1            ;Direction player faces: 1=right, -1=left
;--- Player 2 ---
p2startx = 70 ;80
p2starty = 0
p2facing = -1
;--- Common ---
 ;Don't change these values.
leftbound  = -1000 ;Left bound (x-movement)
rightbound =  1000 ;Right bound

;--------------------------------------------------------
[Bound]
 ;Distance from left/right edge of screen that player can move to
 ;Typically 15
screenleft = 30    ;Dist from left of screen that player can move to
screenright = 30   ;Right edge


;--------------------------------------------------------
[StageInfo]
zoffset = 213
autoturn = 1
resetBG = 1
 ;Width and height of the local coordinate space of the stage.
localcoord = 320, 240
 ;Horizontal and vertical scaling factor for drawing.
xscale = 1
yscale = 1

;--------------------------------------------------------
[Shadow]
 ;This controls the darkness of the shadow. Valid values range
 ;from 0 (lightest) to 256 (darkest). Defaults to 128 if omitted.
intensity = 40

 ;This is the shadow color given in r,g,b. Valid values for each
 ;range from 0 (lightest) to 255 (darkest).
 ;Defaults to 0,0,0 if omitted.
 ;intensity and color's effects add up to give the final shadow
 ;result.
color = 20,10,10

 ;This is the scale factor of the shadow. Use a big scale factor
 ;to make the shadow longer. You can use a NEGATIVE scale factor
 ;to make the shadow fall INTO the screen.
 ;Defaults to 0.4 if omitted.
yscale = .4

 ;This parameter lets you set the range over which the shadow is
 ;visible. The first value is the high level, and the second is
 ;the middle level. Both represent y-coordinates of the player.
 ;A shadow is invisible if the player is above the high level,
 ;and fully visible if below the middle level. The shadow is
 ;faded in between the two levels. This gives an effect of the
 ;shadow fading away as the player gets farther away from the
 ;ground. If omitted, defaults to no level effects (shadow is
 ;always fully visible).
;fade.range = -400,-100
fade.range = 0,-50

;--------------------------------------------------------
[Reflection]
 ;Intensity of reflection (from 0 to 256). Set to 0 to have no
 ;reflection. Defaults to 0.
intensity = 0

;--------------------------------------------------------
[Music]
bgmusic = sound/stages/hdbz_korin.mp3
bgmvolume = 100

;looping points for hdbz_korin.mp3
bgmloopstart = 2034
bgmloopend = 2421116

;--------------------------------------------------------
[BGdef]
spr = hdbz_korin.sff
debugbg = 0

[BG sky 0a]
type  = normal
spriteno = 0,0
start = 0, 220

[BG sky 0b]
type = anim
actionno = 0
start = 0, 220


[BG sky 0c]
type = anim
actionno = 1
start = 0, 220


[BG sky 0d]
type  = normal
spriteno = 0,3
start = 0, 220
velocity = 0.05,0
tile = 1,0
mask = 1

[BG sky 0c L]
type = anim
actionno = 2
id = 2
start = 0, 230

[BG sky 0c M]
type = anim
actionno = 2
id = 3
start = 0, 230

[BG sky 0c R]
type = anim
actionno = 2
id = 4
start = 0, 230

[BG floor]
type  = normal
spriteno = 1,0
start = 0, 220
mask = 1

[BG roof_fence]
type  = normal
spriteno = 2,0
start = 0, 220
mask = 1

[BG new roof]
type  = normal
spriteno = 2,1
start = 0, 220
mask = 1

[BG pillars]
type  = normal
spriteno = 3,0
start = 0, 220
mask = 1

[BG barrels shadow]
type  = normal
spriteno = 4,1
start = 0, 220
trans = add1
mask = 1

[BG barrels]
type  = normal
spriteno = 4,0
start = 0, 220
mask = 1

[BG Korin A] ;behind statue
type = anim
actionno = 60
id = 6
start = 0, 220

[BG statue shadow]
type  = normal
spriteno = 5,1
start = 0, 220
trans = add1
mask = 1

[BG statue]
type  = normal
spriteno = 5,0
start = 0, 220
mask = 1

[BG Korin B] ;beans
type = anim
actionno = 70
id = 7
start = 0, 220

[BG Korin C] ;in front of statue
type = anim
actionno = 80
id = 8
start = 0, 220

[BG Korin D] ;on rail
type = anim
actionno = 90
id = 9
start = 0, 220

[BG Korin E] ;sitting on statue
type = anim
actionno = 100
id = 10
start = 0, 220

[BG Korin F] ;on top of barrel
type = anim
actionno = 110
id = 11
start = 0, 220

[BG Korin G] ;looking at the horizon
type = anim
actionno = 120
id = 12
start = 0, 220


;-------------------------------------------
; SKY
[BGCtrlDef sky]
looptime = 1538 ;769
ctrlID = 2,3,4
[BGCtrl sky L]
type = Posset
x = -769
ctrlid = 2
[BGCtrl sky M]
type = Posset
x = 0
ctrlid = 3
[BGCtrl sky R]
type = Posset
x = 769
ctrlid = 4
[BGCtrl sky]
type = velset
x = 0.5 ;1
time = 0,0, 769
ctrlid = 2,3,4
[Begin Action 0]
0,1,0,0,-1, ,AS256D10
[Begin Action 1]
0,2,0,0,-1, ,AS0D256
[Begin Action 2]
0,4,0,0,-1, ,AS128D128


;Korin A - Behind statue
[BGCtrlDef Korin A] ;behind statue
looptime = 2550
ctrlID = 6
[BGCtrl OFF]
type = Enable
value = 0
time = 0
[BGCtrl ON]
type = Enable
value = 1
time = 800
[BGCtrl appear]
type = Anim
value = 60
time = 800
[BGCtrl idle]
type = Anim
value = 61
time = 832
[BGCtrl disappear]
type = Anim
value = 62
time = 1192
[BGCtrl OFF]
type = Enable
value = 0
time = 1220
[Begin Action 60] ;appear
-1,0,0,0,8
6,6,0,0,8
6,5,0,0,8
6,4,0,0,8
[Begin Action 61] ;idle
6,0,0,0,8
6,1,0,0,8
6,2,0,0,8
6,3,0,0,8
[Begin Action 62] ;disappear
6,4,0,0,8
6,5,0,0,8
6,6,0,0,8
-1,0,0,0,8

;-------------------------------------------
;Korin B - Beans
[BGCtrlDef Korin B] ;beans
looptime = 2550
ctrlID = 7
[BGCtrl OFF]
type = Enable
value = 0
time = 0
[BGCtrl ON]
type = Enable
value = 1
time = 1300
[BGCtrl appear]
type = Anim
value = 70
time = 1300
[BGCtrl search]
type = Anim
value = 71
time = 1332
[BGCtrl throw]
type = Anim
value = 72
time = 1428
[BGCtrl disappear]
type = Anim
value = 73
time = 1444
[BGCtrl OFF]
type = Enable
value = 0
time = 1475
[Begin Action 70] ;appear
-1,0,0,0,8
7,6,0,0,8
7,5,0,0,8
7,4,0,0,8
[Begin Action 71] ;search beans
7,0,0,0,8
7,1,0,0,8
[Begin Action 72] ;throw
7,2,0,0,8
7,3,0,0,8
[Begin Action 73] ;disappear
7,4,0,0,8
7,5,0,0,8
7,6,0,0,8
-1,0,0,0,8

;-------------------------------------------
;Korin C - in front
[BGCtrlDef Korin C] ;in front
looptime = 2550
ctrlID = 8
[BGCtrl ON]
type = Enable
value = 1
time = 0
[BGCtrl appear]
type = Anim
value = 80
time = 0
[BGCtrl move tail]
type = Anim
value = 81
time = 32
[BGCtrl disappear]
type = Anim
value = 82
time = 392
[BGCtrl OFF]
type = Enable
value = 0
time = 432
[Begin Action 80];appear
-1,0,0,0,8
8,11,0,0,8
8,10,0,0,8
8,9,0,0,8
[Begin Action 81];move tail
8,8,0,0,8
8,0,0,0,8
8,1,0,0,8
8,2,0,0,8
8,3,0,0,8
8,4,0,0,8
8,5,0,0,8
8,6,0,0,8
8,7,0,0,8
[Begin Action 82];disappear
8,8,0,0,8
8,9,0,0,8
8,10,0,0,8
8,11,0,0,8
-1,0,0,0,8

;-------------------------------------------
;Korin D - on rail
[BGCtrlDef Korin D] ;on rail
looptime = 2550
ctrlID = 9
[BGCtrl OFF]
type = Enable
value = 0
time = 0
[BGCtrl ON]
type = Enable
value = 1
time = 1800
[BGCtrl appear]
type = Anim
value = 90
time = 1800
[BGCtrl move tail]
type = Anim
value = 91
time = 1832
[BGCtrl disappear]
type = Anim
value = 92
time = 2056
[BGCtrl OFF]
type = Enable
value = 0
time = 2095
[Begin Action 90];appear
-1,0,0,0,8
9,6,0,0,8
9,5,0,0,8
9,4,0,0,8
[Begin Action 91];move tail
9,3,0,0,8
9,0,0,0,8
9,1,0,0,8
9,2,0,0,8
[Begin Action 92];disappear
9,3,0,0,8
9,4,0,0,8
9,5,0,0,8
9,6,0,0,8
-1,0,0,0,8

;-------------------------------------------
;Korin E - on top
[BGCtrlDef Korin E] ;on top
looptime = 2550
ctrlID = 10
[BGCtrl OFF]
type = Enable
value = 0
time = 0
[BGCtrl ON]
type = Enable
value = 1
time = 1500
[BGCtrl appear]
type = Anim
value = 100
time = 1500
[BGCtrl move tail]
type = Anim
value = 101
time = 1532
[BGCtrl disappear]
type = Anim
value = 102
time = 1692
[BGCtrl OFF]
type = Enable
value = 0
time = 1723
[Begin Action 100];appear
-1,0,0,0,8
10,6,0,0,8
10,5,0,0,8
10,4,0,0,8
[Begin Action 101];move tail
10,3,0,0,8
10,0,0,0,8
10,1,0,0,8
10,2,0,0,8
[Begin Action 102];disappear
10,4,0,0,8
10,5,0,0,8
10,6,0,0,8
-1,0,0,0,8
;-------------------------------------------
;Korin F - barrel top
[BGCtrlDef Korin E] ;barrel top
looptime = 2550
ctrlID = 11
[BGCtrl OFF]
type = Enable
value = 0
time = 0
[BGCtrl ON]
type = Enable
value = 1
time = 500
[BGCtrl appear]
type = Anim
value = 110
time = 500
[BGCtrl move tail]
type = Anim
value = 111
time = 532
[BGCtrl disappear]
type = Anim
value = 112
time = 692
[BGCtrl OFF]
type = Enable
value = 0
time = 723
[Begin Action 110];appear
-1,0,0,0,8
11,3,0,0,8
11,2,0,0,8
11,1,0,0,8
[Begin Action 111];idle
11,0,0,0,8
[Begin Action 112];disappear
11,1,0,0,8
11,2,0,0,8
11,3,0,0,8
-1,0,0,0,8

;-------------------------------------------
;Korin G - horizon
[BGCtrlDef Korin G] ;horizon
looptime = 2550
ctrlID = 12
[BGCtrl OFF]
type = Enable
value = 0
time = 0
[BGCtrl ON]
type = Enable
value = 1
time = 2200
[BGCtrl appear]
type = Anim
value = 120
time = 2200
[BGCtrl move tail]
type = Anim
value = 121
time = 2232
[BGCtrl disappear]
type = Anim
value = 122
time = 2448
[BGCtrl OFF]
type = Enable
value = 0
time = 2479
[Begin Action 120];appear
-1,0,0,0,8
12,5,0,0,8
12,4,0,0,8
12,3,0,0,8
[Begin Action 121];move tail
12,0,0,0,8
12,1,0,0,8
12,2,0,0,8
[Begin Action 122];disappear
12,3,0,0,8
12,4,0,0,8
12,5,0,0,8
-1,0,0,0,8