
[Constants]
; ------- Sizes -------
kStudWidth=13 ;in pixels
kBrickHeight=16 ;in pixels

; ------- Bounding Boxes -------
;All bounding boxes are expressed as x, y, width, height
kBoundingBox_legoBro=40 29 20 63  ;WAS: 34 29 30 63 <-- this bounding box doesn't let his arms and legs collide, and is easier to click on
kBoundingBox_legoBro_click=27 16 45 76 
kBoundingBox_agent= 10 18 23 63 ; WAS 10 15 23 63; WAS: 6 8 27 70
kBoundingBox_captain=10 15 23 63
kBoundingBox_walkingHazard=7 13 19 15
kBoundingBox_movingSatellite=1 1 40 25
kBoundingBox_smartSatellite=17 23 39 30
kBoundingBox_goalPelletWalking=10 20 23 63; WAS 10 15 23 63 ; WAS 11 8 20 70 ; WAS 4 8 30 70
kBoundingBox_goalPelletScared=23 30 20 65 ; WAS 16 16 30 75
kBoundingBox_goalPellet=4 12 20 70
kBoundingBox_goalPelletCrouching=13 13 36 70
kBoundingBox_energyPellet=4 8 30 70

; ------- SCORING -------
kColorBombScore=5	;energy gained per brick destroyed
kBrickBombScore=100 ;flat amount gained for using
kNoMoreBricksBonus=100 ;flat amount gained for clearing screen

;Clump matching scores:
;# bricks --- 0 1 2 3  4  5  6   7   8   9   10  11  12  13  14  15  16  17  18  19  20+
kClumpScores= 0 0 0 10 20 60 80 100 120 140 160 180 200 220 240 260 280 300 320 340 360

kBrickGroupTextThreshold = 4 5 6 7 8 9 ;if you change this, change kMaxBrickGroupDescriptions. Each number is the number of bricks you need in order to get to the next level of text (astounding, exceptional!, etc.)
kMaxBrickGroupDescriptions = 6

;Clump chain multipliers: If you change this, modify kMaxGroupsInChain
;# matches ------------- 0 1 2 3 4 5 >=6
kClumpChainMultipliers = 0 1 5 8 12 15 16 
kMaxGroupsInChain = 6 

kClumpChainLength = 2.0 ;distance between matches (in seconds) to still be considered a chain
kTimeMachineScore=0 ;flat amount gained for using

; ------- Speeds -------
kColorDecreaseSpeed=4 ;in pixels per second
kColorIncreaseSpeed=75 ;in pixels per second
kAgentSpeed=0.03
kMinRandomSpeedModifier=-0.000
kMaxRandomSpeedModifier=0.000
kCaptainSpeed_slow=0.03
kCaptainSpeed_fast=0.03
kGoalPelletWalkingSpeed=0.02
kGoalPelletScaredSpeed=0.03
kMatchSlideSpeed=.35  ;moving a match 3 into the clump meter
kMatchSlideSmoothing=-2.0
kClumpMessageDisplayLength=2.0 ;how many seconds to display "tryForExpert" and "reachedExpert"
kClumpMeterGoalArrow_time=0.4 ;how many seconds to slide the arrows into position

;---------- Z indexes -------
k_z_elevatorBackground=-7000
k_z_rainbowShield=10000
kPelletLayer=9999 ;in front of everything
kPelletLayerRescued=-10000; in front of background only, behind bricks
k_z_levelIcon=90000 ;preview icons on level intro screen
k_z_brickGroupText=100001 ;outstanding!, etc.

;---------- Level Editor --------
kVerticalGridSpacing=13 ;in pixels
kHorizontalGridSpacing=13 ;in pixels

;---------- Jump Brick -----------
kJumpBrick_steepness= 0.017 ;this is the a parameter of the parabola. Increase it to make the jump higher. Must be > 0.
kJumpBrick_b=1 ; this is the b parameter of the parabola, probably can stay as is. Increase it to lower the height of the jump
kJumpBrick_distance=8.8 ;increase to jump farther and higher
kJumpBrick_arcPreviewSpacing = 0.5 ;increase to space out the arc preview

;--------- Positioning -------------
kGoalDisplay_x=486 ;align by top right
kGoalDisplay_y=6
kBrickQueue_x=9
kBrickQueue_y=535
kLevelPreview_x=520 ;align by top right
kLevelPreview_y=4
kLevelPreview_maxWidth=354
kClumpTimer_x=372
kClumpTimer_y=6
kClumpTimer_textOffset_x=93 ;align by top right
kClumpTimer_textOffset_y=5
kMoveCounter_x=475
kMoveCounter_y=10
kMoveCounter_textOffset_x=167 ;align by top right
kMoveCounter_textOffset_y=3
kMoveCounter_maxMovesTextOffset_x=43
kMoveCounter_maxMovesTextOffset_y=14
kClumpMeter_x=5 ;coordinate of bottom part of the flask
kClumpMeter_y=464
kClumpMeterButton_x=5
kClumpMeterButton_y=101
kClumpMeter_background_x=43 ;offset from kClumpMeter_x
kClumpMeter_background_y=0
kClumpMeterGoalArrow_x=27
kClumpMeterGoalArrow_y=-354
kClumpMeterGoalArrow_startY=0
kClumpMeterGoalTextOffset_x=72
kClumpMeterGoalTextOffset_y=9
kClumpMeter_sparkle_x=13
kClumpMeter_sparkle_y=-360
kClumpMeterRainbow_x=-5
kClumpMeterRainbow_y=21
kClumpMeter_bro_x=-5 ;offset from kClumpMeter_x
kClumpMeter_bro_y=-2
kClumpMeter_fill_x=28
kClumpMeter_fill_y=0
kClumpMeter_bottomFill_height=26 ;fillable portion of the bottom
kClumpMeter_topFill_height=7 ;fillable portion of the top
kClumpMeter_rainbowExplosion_x=-3;
kClumpMeter_rainbowExplosion_y=0;

kLevelIcon_y=186		; all icons, even the big one
kLevelIconWidth=63		; the spacing between the x coord of each icon
kAdjustCurrentLevelIcon = -9 -4  ;adjust for the enlarged icon


kMultiplierOffset_y=-40 ;so that multipliers don't overlap with text from big groups
kChaseMeter_x=7
kChaseMeter_y=534
kChaseMeter_fill_x=5
kChaseMeter_fill_y=26
kStageButtonSpacing_y=55 ;distance between clouds
kLevelSymbolSpacing = 4 ;horizontal distance between the symbols on the clouds
kLevelSymbolSpacing_bottom = -13 ;distance from bottom of symbol to bottom of button
kLevelButtonHighlightOffsetBig_x=-9
kLevelButtonHighlightOffsetBig_y=11
kLevelButtonHighlightOffsetSmall_x=-6
kLevelButtonHighlightOffsetSmall_y=14
kFeverSelectStart_x=20
kFeverSelectStart_y=36
kFeverSelectSpacing_x=70
kFeverSelectSpacing_y=43
kThumbOffset_x=7
kThumbOffset_y=7
kThumbOffset_bg_x=-15
kThumbOffset_bg_y=-12
kHintPopup_x=551
kHintPopup_y=50
kClumpWaveBottom_y=488
kClumpWaveTop_y=-38

kLaserBeam_left_adjust = 0 2 ;x, y
kLaserBeam_right_adjust = -8 2 ;x, y
kLaserBeam_up_adjust = 5 6 ;x, y
kLaserBeam_down_adjust = 4 -4 ;x, y

kLevelWinBro = 215 41	;x y
kLevelLoseBro = 276 41	;x y
kHitToEnergizeDest = 95 560 ;x y
kTeleporterEffectOffset = -18 -70
kCageAdjust = -16 0 ;x y
kIngredientOffset_x = 30
kIngredientOffset_y = 0
kTimeMachineStart= 370 400
kTimeMachineEnd= 285 -3 ;location of the clock

;--------- Tutorials ------
kTutorialEvilRainbow_x=50
kTutorialEvilRainbow_y=300
kTutorialEvilRainbow_offset=40

kTutorialJumpBrickComplete_x=-40
kTutorialJumpBrickComplete_y=-236
kTutorialJumpBrickComplete_offset=140

;--------- Fonts ------------
kFontClumpTimer=	"numbers_uni05_53_24"
kFontMoveCounter=	"numbers_uni05_53_18"
kFontMovesMax=		"uni05_63_6"
kFontLevelNumber=	"numbers_uni05_53_18"
kFontWorldName=		"uni05_63_6"

;-------- Timing -------------
kClumpSaturationLength=.2  ;number of seconds it takes to move to the next level of saturation
kClumpPropFlipInitialDelay=.9	;at the end of a clump level, how much time (in seconds) between the actual win, and the flipping of the first prop
kClumpPropFlipSpacing=0.1       ;at the end of a clump level, how much time (in seconds) between each prop flipping
kClumpTimeMachineIncreaseSpacing=0.1 ;//how long it takes to increment the timer by 1 second when you activate the timer (probably should be the number of seconds rewarded / 1 second)
kClumpBrickGrowthSpacing=0.08	;how long between each growing brick when the clump initially grows or regenerates
kPuzzleWinSaturationLength=1.5  ;number of seconds it takes to transition from b&w to color
kBrickGrowthPopLength=.1	;how long it takes a new brick to grow to full size
kRainbowTransitionTime=0.07 ;time between each slice of the rainbow between levels
kBlackWipeTransitionTime=0.03 ;time between each slice of the black wipe between non-game screens
kLevelOutroSlideLength=0.25 ;how long it takes to slide in the non rainbow elements, in seconds
kLevelOutroTime=3.0 ;number of seconds before the level outro unwinds by itself
kLevelWinToOutroDelay=4.0; number of seconds to wait after winning the level, before switching to the outro screen
kBigBrickGroupTextDisplayLength=2.0; number of seconds to display "amazing!!" before deleting
kFlagRaiseTime=2.0 ;in seconds
kLevelEndPropFlipLength=2.0 ; number of seconds it takes to flip all remaining props
kRainbowCrossFadeLength= .5 ;time to switch from good to evil rainbow (and vice versa)
kStageSelectWaveSpeed=80.0 ;pixels/second
kLevelOutroWinAnimationLength=2.2 ; This should be the number of seconds it takes to complete all the hand waving animation
kLevelOutroLoseAnimationLength=2.0 ;UNUSED
kSpriteScaleTime=.5 ;used for scale up, fade and die tasks
kSpriteWaitTime=.2 ;used for scale up, fade and die tasks
kSpriteFadeTime=2.0  ;used for scale up, fade and die tasks
kSpriteSlideTime=.5 ;used for scale up, fade and die tasks (optional)
kSpriteDestDelay=5 ;used for scale up, fade and die tasks (optional)
kWorldBackgroundCrossfadeTime=2.0 ;at the end of a world in the story mode select
kTeleportTime=0.8 ;how long it takes to crossfade a character that's teleporting
kTimeMachineDelay=1.5 ;how long after the time machine hits the top before it dies
kTimeMachineMovementTime=1 ;how long it takes the time machine animation to move to the top of the screen

;-------- Window sliding -----------
kSlideOffLeftTime=0.4 ;time for a window to fly off the left side of screen
kSlideOffLeft_x=-740

;-------- Wave Overlay ---------
kWaveOverlaySpeedGood=100.0 ;pixels/second
kWaveOverlaySpeedEvil=100.0 ;WAS: 150.0 ;pixels/second
kWaveOverlaySpeedClump=70.0 ;pixels/second
kWaveOverlayAlignment=0.5 ;percent into this image where the color threshold line should intersect

;-------- Shield & pickaxe blinking -----------
kShieldBlinkTime=3.0	;how long before the end it should start blinking
kShieldBlinkCount=10	;how many times to blink
kShieldBlinkThreshold=0.5	;percentage of each blink that is invisible (.5 = 50/50 visible to invisible)
kShieldBlinkAlpha=0.2		;alpha of the shield when it's blinking

kPickaxeBlinkTime=4.0	;how long before the end it should start blinking
kPickaxeBlinkCount=10	;how many times to blink
kPickaxeBlinkThreshold=0.5	;percentage of each blink that is invisible (.5 = 50/50 visible to invisible)

;--- brick energy bursts -------
kBurstDistance_x = 50 ; pixels
kBurstDistance_y = 50 ; pixels
kBurstTime_expand = 0.3 ; seconds
kBurstTime_toDest = 0.9 ; seconds
kBurstTime_toMeter = 0.2 ; seconds


kBurstVariance = 200 200 ; x,y - how far the endpoints can deviate (doubled, ie a value of 20 ranges from -10 to 10)
kBurstClumpMeterOffset = 30 -365 ; x,y
kBurstEnergyMeterOffset = 100 20 ; x,y
kBurstDest = 20 -200	; x,y - how far to shoot up

;---- Stage Intro -------
kStageIntroHarry_loc		= 135 322
kStageIntroBubble_loc		= 57 152
kStageIntroHarryScaleDelay	= .5
kStageIntroHarryScaleTime	= .3
kStageIntroHarryScaleSmoothing = 1
kStageIntroBubbleScaleDelay	= .7
kStageIntroBubbleScaleTime	= .3
kStageIntroBubbleScaleSmoothing= 1
kStageIntroSlideTime		= 0.5 ;should probably stay the same as kStageIntroHarryScaleTime, since he pushes it over
kStageIntroSlideDistance	= 96
kStageIntroSlideSmoothing	=  -1.3 ;acellerate slightly
kStageIntroTextFadeDelay	= .9
kStageIntroTextFadeTime		= .5

;------- Main Menu-------
kMainMenuParticleFadeTime = .42
kMainMenuButtonParticleFadeTime = .42 ;so it doesn't line up with the background ones
kMainMenuParticleFadeSmoothing = 0.0

; -------  Misc ------- 
kPropThreshold=1.0 ;percentage of prop which must be passed by the color threshold before it's flipped
kBrickBombRadius=6 ;in studs
kIngredientScale=1.0 ;x and y scaling for the brick in a recipe
kPropTransitionShrinkSpinSpeed=1.7 ; higher = faster. How fast to spin and shrink
kDebug=0 ;set to 1 to display extra debug info, set to 0 to turn off
kColorDecreaseSpeed=6 ;in pixels per second
kDisplayActualMiniMap=0 ;set to 1 to show an actual preview, 0 to show prerendered bitmap
kLevelPreviewFlagTolerance=18; how much distance between the flag and the end of the level
kClumpMeter_emptyRate=300 ;how many pixels per second to empty from the clump meter
kMaxFlaskHeight=482 ;maximum height of clumpmeter
kScaredGoalToBroProximity=100 ;in pixels, how far before scared person starts running
kSummonOnLeftClick=1 ;set to 1 to allow summoning when left click is over nothing else
kLockToStudModifierLeft=-16 ;adjust this so that the walk cycle snaps to the grid appropriately (horizontally) //-11 to -13 fits studs well
kLockToStudModifierRight=-12
kBricksWrapAround=1 ;set to 1 to make bricks fall back to the top of the screen in clump
kDrawGhostBrick=1
kColorThresholdAdjust=-25 ;number of pixels added to the color threshold
kAllowPlacementBetweenBricks=1 ;1=on, 0=off - allows placement where you wouldn't normally be able to fit a lego brick
kMouseThreshold_x=3	;WAS 7 ;how far the mouse must move before updating carried or ghost bricks
kMouseThreshold_y=2	;WAS 7 
kColorEmergencyThreshold=50 ;minimum x coordinate for the color line to recede to before the emergency warning plays
kFreeColorThresholdTime=1.25 ;WAS:1.5 ;Twice the number of seconds after lego bro stops moving forward that the color line starts receding. I don't know why it's twice!
kDistanceToLooseBricks=100; How close (in pixels) you need to be to the center of a loose brick to grab it
kChaseMeter_maxEnergy=100
kLevelEndRecedeSpeed=100 ;how fast the color threshold should recede after the bro dies in chase
kLastGoalWarningThreshold=100; how close to the left side of the screen a goal needs to be to prompt a warning
kMaxStageYAdjust=-6 ;adjust the line of the bottom cloud button by this amount
kMaxBrick_halfView_y=510 ;if greater than this, and part of the playfield, only the top face is drawn
kMaxBrick_y=526		 ;if greater than this, and part of the playfield, nothing is drawn. This is also the point at which halfdrawn bricks get cut off
kPlayableGrid_min = 2  ; inclusive, the minimum grid value that you are allowed to put a brick
kPlayableGrid_max = 31 ; inclusive, the maximum grid value that you are allowed to put a brick
kColoredAreaAfterRainbow = 600 ;how much color is drawn, 
kStartScrollAdjust = -600 ;used to determine how far to scroll at the beginning of the level
kSlideBrickLengthLeft = 1 ;used to determine stepping on left facing slide bricks
kShadowStart_x = 24;
kShadowWidth = 39;
kShadowAdjustLeft = -16
kShadowAdjustRight = 2
kHideBro = 0 ;set to 1 to hide bro
kPropSoundWorld = 4 ;Which sound set to use (4=western, 5=space)
kSmallTransitionOverlayWidth=150 ;if a prop is smaller than this, use the small overlay
kTitleSlideWait=0.15 ; wait this long to slide down the title on the losing level outro screen
kTitleSlideTime=.6 ;should be the same as the time it takes to play the level end lego bro animation
kTitleSlide_y=250
kMarqueeDelay=0.2
kMinGhostBrick_y=45
kMaxGhostBrick_y=525
kInkSplatFadeTime=0.75
kAtmosSoundChance=.6 ;chance that a world specific sound is played when a prop flips
kCaptainHaltTime=.25 ;this should be aligned with the captain's shock animation timing
kJumpBrickCoolDownTime=.9 ;a single jump brick can only fire this often (in seconds)
kMusicFadeOutTime = 1.5
kMusicFadeInTime = 1.5
kSlideRatioLeft=1
kSlideRatioRight=1
kTurnaroundLimitTime=.1 ;seconds required after a turnaround, before a manual turnaround