Files
naddie-jump/src/config/game.config.js
AnRil 6f5b4d83f7 Phase B: new content — daily challenge, enemies, platform, settings, stats
B1 Seeded RNG + Daily Challenge
- utils/random.js wraps Phaser seedable RND (Between/frac are NOT seedable)
- All gameplay spawning (PlatformManager, Platform, Enemy) uses seeded rng
- GameScene reads mode/seed in init and seeds the run; daily shows a HUD badge
  and keeps a per-day best (daily_<YYYYMMDD>); MenuScene DAILY button;
  GameOver RETRY preserves mode and shows today's best
- Verified: same seed -> identical layout, different seed -> different

B2 New content
- Enemy mev_bot: homing chaser that eases toward the player (unlock >1500)
- Platform reorg: phantom, semi-transparent, vanishes shortly after landing
  (unlock >600); no power-ups on breaking/reorg; SPAWN_RATES + UNLOCK config
- Verified spawn distribution at high difficulty includes all new types

B3 Settings
- SoundManager gains volume (persisted); MenuScene SETTINGS overlay with
  volume stepper, particle-quality Low/High toggle, two-step reset progress

B4 Stats
- StatsManager tracks lifetime games/jumps/stomps/blocks/best combo, flushed
  at game over; MenuScene STATS overlay; hooks in GameScene/ScoreManager

B5 Difficulty tuning via UNLOCK thresholds and rebalanced spawn rates

Functionally verified in-browser via eval (no console errors, deterministic
daily, content spawns, particles emit). Visual screenshot unavailable in the
headless preview because the hidden tab pauses Phaser's loop.
2026-05-29 13:29:34 +07:00

69 lines
1.3 KiB
JavaScript

export const GAME_WIDTH = 480;
export const GAME_HEIGHT = 854;
export const GRAVITY = 1200;
export const JUMP_VELOCITY = -650;
export const SUPER_JUMP_VELOCITY = -1050;
export const ROCKET_VELOCITY = -1400;
export const PROPELLER_VELOCITY = -950;
export const PLAYER_SPEED = 300;
export const PLATFORM_GAP_MIN = 60;
export const PLATFORM_GAP_MAX = 120;
export const SPAWN_RATES = {
stable: 0.55,
moving: 0.18,
breaking: 0.12,
reorg: 0.10,
genesis: 0.05,
};
export const POWERUP_RATES = {
spring: 0.04,
propeller: 0.025,
rocket: 0.012,
};
export const ENEMY_RATES = {
bug: 0.10,
};
export const DIFFICULTY = {
initialGap: 100,
gapIncreasePer1000: 12,
maxGap: 160,
enemyIncreasePer1000: 0.015,
maxEnemyRate: 0.30,
};
// Height (px climbed) at which harder content starts appearing.
export const UNLOCK = {
reorg: 600,
failedTx: 800,
mevBot: 1500,
};
export const SCORE = {
basePoints: 10,
genesisBonus: 50,
genesisJumps: 5,
genesisMultiplier: 2,
stompBonus: 25,
comboStep: 0.1,
comboMax: 3,
fallResetDistance: 300,
};
export const PHYSICS = {
stompTolerance: 12,
landTolerance: 10,
maxFallSpeed: 950, // terminal velocity cap — prevents landing tunneling
};
export const POWERUP_DURATION = {
propeller: 3500,
rocket: 3000,
};