class_name Params ## Game tuning values, ported from the cocos2d-x params.h. # Ball const BALL_RADIUS := 15.0 const THROW_ANGLE := 20.0 # degrees either side of straight up const INITIAL_SPEED := 500.0 const BALL_BOUNCE := 1.005 # every bounce speeds the ball up a little const BALL_GRAVITY := 250.0 # px/s², pulls sideways-bouncing balls back to the paddle # Core const CORE_RADIUS := 50.0 # Paddle const PADDLE_WIDTH := 120.0 const PADDLE_HEIGHT := 10.0 const PADDLE_ALTITUDE := 90.0 # distance from the bottom of the screen # Colors const COLOR_PINK := Color("#f92672") const COLOR_BLUE := Color("#66d9ef") const COLOR_GREEN := Color("#a6e22e") const COLOR_ORANGE := Color("#fd971f") const COLOR_GREY := Color("#787878") const COLOR_RED := Color(0.988, 0.147, 0.030) # Physics layers (bit values) const LAYER_WALLS := 1 const LAYER_PADDLE := 2 const LAYER_BLOCKS := 4 const LAYER_BALLS := 8 const LAYER_POWER_UPS := 16 # Power-up drop chances, rolled every POWER_UP_INTERVAL seconds const DROP_LEVEL_SAVE := 0.03 const DROP_TRIPLE_BALL := 0.06 # multiplied by seconds since a ball last touched anything const DROP_PADDLE_BALL := 0.05 const DROP_SUPER_BALL := 0.03 const POWER_UP_INTERVAL := 2.5 const POWER_UP_PADDLE_SECONDS := 10.0 # Hours without playing before the saved level drops by one const LOSE_HOURS := 12 # Text const MSG_TRIPLE_BALLS := "Triple Balls!" const MSG_LEVEL_SAVED := "Level Saved!" const MSG_OVER := "Game Over..." const MSG_DOUBLE_PADDLE := "Doubled paddle!" const MSG_HALF_PADDLE := "Half paddle :(" const MSG_LEVEL_BACK := "You are at level %d. In %.1f hour(s) you will regrow a level." const MSG_NEXT_LEVEL := "Next Level" const MSG_RESTART := "Restart" const MSG_SUPER_BALL := "Super Ball!"