react-native-games 0.3.0 → 0.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +134 -130
- package/lib/module/games/balloon-blaster/BalloonBlaster.js +116 -343
- package/lib/module/games/balloon-blaster/BalloonBlaster.js.map +1 -1
- package/lib/module/games/balloon-blaster/BalloonBlasterConstants.js +182 -0
- package/lib/module/games/balloon-blaster/BalloonBlasterConstants.js.map +1 -0
- package/lib/module/games/balloon-blaster/BalloonBlasterService.js +123 -101
- package/lib/module/games/balloon-blaster/BalloonBlasterService.js.map +1 -1
- package/lib/module/games/balloon-blaster/BalloonBlasterStore.js +119 -92
- package/lib/module/games/balloon-blaster/BalloonBlasterStore.js.map +1 -1
- package/lib/module/games/balloon-blaster/components/BalloonComponent.js +123 -113
- package/lib/module/games/balloon-blaster/components/BalloonComponent.js.map +1 -1
- package/lib/module/games/balloon-blaster/components/GameArea.js +137 -23
- package/lib/module/games/balloon-blaster/components/GameArea.js.map +1 -1
- package/lib/module/games/balloon-blaster/components/GameBackground.js +8 -83
- package/lib/module/games/balloon-blaster/components/GameBackground.js.map +1 -1
- package/lib/module/games/balloon-blaster/components/ScoreBoard.js +15 -22
- package/lib/module/games/balloon-blaster/components/ScoreBoard.js.map +1 -1
- package/lib/module/games/balloon-blaster/components/index.js +0 -4
- package/lib/module/games/balloon-blaster/components/index.js.map +1 -1
- package/lib/module/games/fruit-ninja/FruitNinja.js +143 -0
- package/lib/module/games/fruit-ninja/FruitNinja.js.map +1 -0
- package/lib/module/games/fruit-ninja/FruitNinjaConstants.js +148 -0
- package/lib/module/games/fruit-ninja/FruitNinjaConstants.js.map +1 -0
- package/lib/module/games/{fruit-slicer/FruitSlicerService.js → fruit-ninja/FruitNinjaService.js} +43 -21
- package/lib/module/games/fruit-ninja/FruitNinjaService.js.map +1 -0
- package/lib/module/games/fruit-ninja/FruitNinjaStore.js +191 -0
- package/lib/module/games/fruit-ninja/FruitNinjaStore.js.map +1 -0
- package/lib/module/games/{fruit-slicer → fruit-ninja}/components/FruitComponent.js +1 -1
- package/lib/module/games/fruit-ninja/components/FruitComponent.js.map +1 -0
- package/lib/module/games/fruit-ninja/components/GameArea.js +215 -0
- package/lib/module/games/fruit-ninja/components/GameArea.js.map +1 -0
- package/lib/module/games/{fruit-slicer → fruit-ninja}/components/GameBackground.js +250 -304
- package/lib/module/games/fruit-ninja/components/GameBackground.js.map +1 -0
- package/lib/module/games/{fruit-slicer → fruit-ninja}/components/ScoreBoard.js +17 -47
- package/lib/module/games/fruit-ninja/components/ScoreBoard.js.map +1 -0
- package/lib/module/games/fruit-ninja/components/index.js +7 -0
- package/lib/module/games/fruit-ninja/components/index.js.map +1 -0
- package/lib/module/games/maze-runner/MazeRunner.js +184 -169
- package/lib/module/games/maze-runner/MazeRunner.js.map +1 -1
- package/lib/module/games/maze-runner/MazeRunnerConstants.js +100 -0
- package/lib/module/games/maze-runner/MazeRunnerConstants.js.map +1 -0
- package/lib/module/games/maze-runner/MazeRunnerService.js +37 -14
- package/lib/module/games/maze-runner/MazeRunnerService.js.map +1 -1
- package/lib/module/games/maze-runner/components/EnhancedBallComponent.js +5 -4
- package/lib/module/games/maze-runner/components/EnhancedBallComponent.js.map +1 -1
- package/lib/module/games/maze-runner/components/EnhancedGameArea.js +20 -15
- package/lib/module/games/maze-runner/components/EnhancedGameArea.js.map +1 -1
- package/lib/module/games/maze-runner/components/GameBackground.js +151 -192
- package/lib/module/games/maze-runner/components/GameBackground.js.map +1 -1
- package/lib/module/games/maze-runner/components/ScoreBoard.js +15 -25
- package/lib/module/games/maze-runner/components/ScoreBoard.js.map +1 -1
- package/lib/module/games/maze-runner/components/WallComponent.js +3 -2
- package/lib/module/games/maze-runner/components/WallComponent.js.map +1 -1
- package/lib/module/games/maze-runner/components/index.js +0 -2
- package/lib/module/games/maze-runner/components/index.js.map +1 -1
- package/lib/module/games/popit-fidget/PopitFidget.js +294 -0
- package/lib/module/games/popit-fidget/PopitFidget.js.map +1 -0
- package/lib/module/games/popit-fidget/PopitFidgetConstants.js +113 -0
- package/lib/module/games/popit-fidget/PopitFidgetConstants.js.map +1 -0
- package/lib/module/games/popit-fidget/PopitFidgetService.js +132 -0
- package/lib/module/games/popit-fidget/PopitFidgetService.js.map +1 -0
- package/lib/module/games/popit-fidget/PopitFidgetStore.js +163 -0
- package/lib/module/games/popit-fidget/PopitFidgetStore.js.map +1 -0
- package/lib/module/games/popit-fidget/components/BubbleComponent.js +198 -0
- package/lib/module/games/popit-fidget/components/BubbleComponent.js.map +1 -0
- package/lib/module/games/popit-fidget/components/FidgetGrid.js +165 -0
- package/lib/module/games/popit-fidget/components/FidgetGrid.js.map +1 -0
- package/lib/module/games/popit-fidget/components/GameBackground.js +177 -0
- package/lib/module/games/popit-fidget/components/GameBackground.js.map +1 -0
- package/lib/module/games/popit-fidget/components/ScoreBoard.js +75 -0
- package/lib/module/games/popit-fidget/components/ScoreBoard.js.map +1 -0
- package/lib/module/games/popit-fidget/components/index.js +7 -0
- package/lib/module/games/popit-fidget/components/index.js.map +1 -0
- package/lib/module/games/space-fighter/SpaceFighter.js +169 -0
- package/lib/module/games/space-fighter/SpaceFighter.js.map +1 -0
- package/lib/module/games/space-fighter/SpaceFighterConstants.js +108 -0
- package/lib/module/games/space-fighter/SpaceFighterConstants.js.map +1 -0
- package/lib/module/games/{space-traveller/SpaceTravellerService.js → space-fighter/SpaceFighterService.js} +48 -21
- package/lib/module/games/space-fighter/SpaceFighterService.js.map +1 -0
- package/lib/module/games/space-fighter/SpaceFighterStore.js +195 -0
- package/lib/module/games/space-fighter/SpaceFighterStore.js.map +1 -0
- package/lib/module/games/{space-traveller → space-fighter}/components/AsteroidComponent.js +7 -5
- package/lib/module/games/space-fighter/components/AsteroidComponent.js.map +1 -0
- package/lib/module/games/space-fighter/components/GameArea.js +295 -0
- package/lib/module/games/space-fighter/components/GameArea.js.map +1 -0
- package/lib/module/games/{space-traveller → space-fighter}/components/GameBackground.js +10 -65
- package/lib/module/games/space-fighter/components/GameBackground.js.map +1 -0
- package/lib/module/games/{space-traveller → space-fighter}/components/ScoreBoard.js +20 -26
- package/lib/module/games/space-fighter/components/ScoreBoard.js.map +1 -0
- package/lib/module/games/{space-traveller → space-fighter}/components/Spacecraft3D.js +72 -111
- package/lib/module/games/space-fighter/components/Spacecraft3D.js.map +1 -0
- package/lib/module/games/space-fighter/components/SpacecraftPath.js +52 -0
- package/lib/module/games/space-fighter/components/SpacecraftPath.js.map +1 -0
- package/lib/module/games/{space-traveller → space-fighter}/components/index.js +0 -4
- package/lib/module/games/space-fighter/components/index.js.map +1 -0
- package/lib/module/games/whack-a-mole/WhackAMole.js +263 -0
- package/lib/module/games/whack-a-mole/WhackAMole.js.map +1 -0
- package/lib/module/games/whack-a-mole/WhackAMoleConstants.js +115 -0
- package/lib/module/games/whack-a-mole/WhackAMoleConstants.js.map +1 -0
- package/lib/module/games/whack-a-mole/WhackAMoleService.js +120 -0
- package/lib/module/games/whack-a-mole/WhackAMoleService.js.map +1 -0
- package/lib/module/games/whack-a-mole/WhackAMoleStore.js +172 -0
- package/lib/module/games/whack-a-mole/WhackAMoleStore.js.map +1 -0
- package/lib/module/games/{cat-popper → whack-a-mole}/components/GameBackground.js +31 -91
- package/lib/module/games/whack-a-mole/components/GameBackground.js.map +1 -0
- package/lib/module/games/whack-a-mole/components/GameGrid.js +97 -0
- package/lib/module/games/whack-a-mole/components/GameGrid.js.map +1 -0
- package/lib/module/games/{cat-popper → whack-a-mole}/components/GameHole.js +67 -54
- package/lib/module/games/whack-a-mole/components/GameHole.js.map +1 -0
- package/lib/module/games/{cat-popper/components/CatCharacter.js → whack-a-mole/components/MoleCharacter.js} +75 -115
- package/lib/module/games/whack-a-mole/components/MoleCharacter.js.map +1 -0
- package/lib/module/games/{cat-popper → whack-a-mole}/components/ScoreBoard.js +13 -17
- package/lib/module/games/whack-a-mole/components/ScoreBoard.js.map +1 -0
- package/lib/module/games/{cat-popper → whack-a-mole}/components/index.js +1 -3
- package/lib/module/games/whack-a-mole/components/index.js.map +1 -0
- package/lib/module/index.js +4 -3
- package/lib/module/index.js.map +1 -1
- package/lib/module/services/GamesConstants.js +41 -519
- package/lib/module/services/GamesConstants.js.map +1 -1
- package/lib/module/services/GamesService.js +35 -23
- package/lib/module/services/GamesService.js.map +1 -1
- package/lib/module/services/HapticsService.js +77 -0
- package/lib/module/services/HapticsService.js.map +1 -0
- package/lib/module/services/SoundsService.js +171 -0
- package/lib/module/services/SoundsService.js.map +1 -0
- package/lib/module/shared/helpers/AnimationFrame.js +120 -0
- package/lib/module/shared/helpers/AnimationFrame.js.map +1 -0
- package/lib/module/shared/helpers/AnimationTracker.js +89 -0
- package/lib/module/shared/helpers/AnimationTracker.js.map +1 -0
- package/lib/module/shared/helpers/ErrorHandler.js +269 -0
- package/lib/module/shared/helpers/ErrorHandler.js.map +1 -0
- package/lib/module/shared/helpers/GameControlButton.js +219 -0
- package/lib/module/shared/helpers/GameControlButton.js.map +1 -0
- package/lib/module/{games/balloon-blaster/components → shared/helpers}/GameOverModal.js +25 -17
- package/lib/module/shared/helpers/GameOverModal.js.map +1 -0
- package/lib/module/shared/helpers/GameSettingsModal.js +287 -0
- package/lib/module/shared/helpers/GameSettingsModal.js.map +1 -0
- package/lib/module/shared/helpers/ParticleBlast.js +133 -0
- package/lib/module/shared/helpers/ParticleBlast.js.map +1 -0
- package/lib/module/shared/helpers/ResponsiveScoreBoard.js +81 -0
- package/lib/module/shared/helpers/ResponsiveScoreBoard.js.map +1 -0
- package/lib/module/shared/helpers/index.js +12 -0
- package/lib/module/shared/helpers/index.js.map +1 -0
- package/lib/typescript/src/games/balloon-blaster/BalloonBlaster.d.ts +2 -14
- package/lib/typescript/src/games/balloon-blaster/BalloonBlaster.d.ts.map +1 -1
- package/lib/typescript/src/games/balloon-blaster/BalloonBlasterConstants.d.ts +144 -0
- package/lib/typescript/src/games/balloon-blaster/BalloonBlasterConstants.d.ts.map +1 -0
- package/lib/typescript/src/games/balloon-blaster/BalloonBlasterService.d.ts +1 -1
- package/lib/typescript/src/games/balloon-blaster/BalloonBlasterService.d.ts.map +1 -1
- package/lib/typescript/src/games/balloon-blaster/BalloonBlasterStore.d.ts +12 -2
- package/lib/typescript/src/games/balloon-blaster/BalloonBlasterStore.d.ts.map +1 -1
- package/lib/typescript/src/games/balloon-blaster/components/BalloonComponent.d.ts.map +1 -1
- package/lib/typescript/src/games/balloon-blaster/components/GameArea.d.ts +1 -15
- package/lib/typescript/src/games/balloon-blaster/components/GameArea.d.ts.map +1 -1
- package/lib/typescript/src/games/balloon-blaster/components/GameBackground.d.ts.map +1 -1
- package/lib/typescript/src/games/balloon-blaster/components/ScoreBoard.d.ts +1 -7
- package/lib/typescript/src/games/balloon-blaster/components/ScoreBoard.d.ts.map +1 -1
- package/lib/typescript/src/games/balloon-blaster/components/index.d.ts +0 -4
- package/lib/typescript/src/games/balloon-blaster/components/index.d.ts.map +1 -1
- package/lib/typescript/src/games/fruit-ninja/FruitNinja.d.ts +4 -0
- package/lib/typescript/src/games/fruit-ninja/FruitNinja.d.ts.map +1 -0
- package/lib/typescript/src/games/fruit-ninja/FruitNinjaConstants.d.ts +112 -0
- package/lib/typescript/src/games/fruit-ninja/FruitNinjaConstants.d.ts.map +1 -0
- package/lib/typescript/src/games/{fruit-slicer/FruitSlicerService.d.ts → fruit-ninja/FruitNinjaService.d.ts} +13 -5
- package/lib/typescript/src/games/fruit-ninja/FruitNinjaService.d.ts.map +1 -0
- package/lib/typescript/src/games/{fruit-slicer/FruitSlicerStore.d.ts → fruit-ninja/FruitNinjaStore.d.ts} +13 -4
- package/lib/typescript/src/games/fruit-ninja/FruitNinjaStore.d.ts.map +1 -0
- package/lib/typescript/src/games/{fruit-slicer → fruit-ninja}/components/FruitComponent.d.ts +1 -1
- package/lib/typescript/src/games/fruit-ninja/components/FruitComponent.d.ts.map +1 -0
- package/lib/typescript/src/games/fruit-ninja/components/GameArea.d.ts +3 -0
- package/lib/typescript/src/games/fruit-ninja/components/GameArea.d.ts.map +1 -0
- package/lib/typescript/src/games/fruit-ninja/components/GameBackground.d.ts.map +1 -0
- package/lib/typescript/src/games/fruit-ninja/components/ScoreBoard.d.ts +3 -0
- package/lib/typescript/src/games/fruit-ninja/components/ScoreBoard.d.ts.map +1 -0
- package/lib/typescript/src/games/fruit-ninja/components/index.d.ts +5 -0
- package/lib/typescript/src/games/fruit-ninja/components/index.d.ts.map +1 -0
- package/lib/typescript/src/games/maze-runner/MazeRunner.d.ts +2 -16
- package/lib/typescript/src/games/maze-runner/MazeRunner.d.ts.map +1 -1
- package/lib/typescript/src/games/maze-runner/MazeRunnerConstants.d.ts +41 -0
- package/lib/typescript/src/games/maze-runner/MazeRunnerConstants.d.ts.map +1 -0
- package/lib/typescript/src/games/maze-runner/MazeRunnerService.d.ts +4 -2
- package/lib/typescript/src/games/maze-runner/MazeRunnerService.d.ts.map +1 -1
- package/lib/typescript/src/games/maze-runner/components/EnhancedBallComponent.d.ts.map +1 -1
- package/lib/typescript/src/games/maze-runner/components/EnhancedGameArea.d.ts.map +1 -1
- package/lib/typescript/src/games/maze-runner/components/GameBackground.d.ts +2 -1
- package/lib/typescript/src/games/maze-runner/components/GameBackground.d.ts.map +1 -1
- package/lib/typescript/src/games/maze-runner/components/ScoreBoard.d.ts.map +1 -1
- package/lib/typescript/src/games/maze-runner/components/WallComponent.d.ts.map +1 -1
- package/lib/typescript/src/games/maze-runner/components/index.d.ts +0 -2
- package/lib/typescript/src/games/maze-runner/components/index.d.ts.map +1 -1
- package/lib/typescript/src/games/popit-fidget/PopitFidget.d.ts +5 -0
- package/lib/typescript/src/games/popit-fidget/PopitFidget.d.ts.map +1 -0
- package/lib/typescript/src/games/popit-fidget/PopitFidgetConstants.d.ts +45 -0
- package/lib/typescript/src/games/popit-fidget/PopitFidgetConstants.d.ts.map +1 -0
- package/lib/typescript/src/games/popit-fidget/PopitFidgetService.d.ts +33 -0
- package/lib/typescript/src/games/popit-fidget/PopitFidgetService.d.ts.map +1 -0
- package/lib/typescript/src/games/popit-fidget/PopitFidgetStore.d.ts +36 -0
- package/lib/typescript/src/games/popit-fidget/PopitFidgetStore.d.ts.map +1 -0
- package/lib/typescript/src/games/popit-fidget/components/BubbleComponent.d.ts +12 -0
- package/lib/typescript/src/games/popit-fidget/components/BubbleComponent.d.ts.map +1 -0
- package/lib/typescript/src/games/popit-fidget/components/FidgetGrid.d.ts +12 -0
- package/lib/typescript/src/games/popit-fidget/components/FidgetGrid.d.ts.map +1 -0
- package/lib/typescript/src/games/popit-fidget/components/GameBackground.d.ts +9 -0
- package/lib/typescript/src/games/popit-fidget/components/GameBackground.d.ts.map +1 -0
- package/lib/typescript/src/games/popit-fidget/components/ScoreBoard.d.ts +8 -0
- package/lib/typescript/src/games/popit-fidget/components/ScoreBoard.d.ts.map +1 -0
- package/lib/typescript/src/games/popit-fidget/components/index.d.ts +5 -0
- package/lib/typescript/src/games/popit-fidget/components/index.d.ts.map +1 -0
- package/lib/typescript/src/games/space-fighter/SpaceFighter.d.ts +4 -0
- package/lib/typescript/src/games/space-fighter/SpaceFighter.d.ts.map +1 -0
- package/lib/typescript/src/games/space-fighter/SpaceFighterConstants.d.ts +71 -0
- package/lib/typescript/src/games/space-fighter/SpaceFighterConstants.d.ts.map +1 -0
- package/lib/typescript/src/games/{space-traveller/SpaceTravellerService.d.ts → space-fighter/SpaceFighterService.d.ts} +7 -4
- package/lib/typescript/src/games/space-fighter/SpaceFighterService.d.ts.map +1 -0
- package/lib/typescript/src/games/{space-traveller/SpaceTravellerStore.d.ts → space-fighter/SpaceFighterStore.d.ts} +12 -4
- package/lib/typescript/src/games/space-fighter/SpaceFighterStore.d.ts.map +1 -0
- package/lib/typescript/src/games/space-fighter/components/AsteroidComponent.d.ts +8 -0
- package/lib/typescript/src/games/space-fighter/components/AsteroidComponent.d.ts.map +1 -0
- package/lib/typescript/src/games/space-fighter/components/GameArea.d.ts +3 -0
- package/lib/typescript/src/games/space-fighter/components/GameArea.d.ts.map +1 -0
- package/lib/typescript/src/games/space-fighter/components/GameBackground.d.ts.map +1 -0
- package/lib/typescript/src/games/space-fighter/components/ScoreBoard.d.ts +3 -0
- package/lib/typescript/src/games/space-fighter/components/ScoreBoard.d.ts.map +1 -0
- package/lib/typescript/src/games/{space-traveller → space-fighter}/components/Spacecraft3D.d.ts +1 -1
- package/lib/typescript/src/games/space-fighter/components/Spacecraft3D.d.ts.map +1 -0
- package/lib/typescript/src/games/space-fighter/components/SpacecraftPath.d.ts.map +1 -0
- package/lib/typescript/src/games/{space-traveller → space-fighter}/components/index.d.ts +0 -4
- package/lib/typescript/src/games/space-fighter/components/index.d.ts.map +1 -0
- package/lib/typescript/src/games/whack-a-mole/WhackAMole.d.ts +4 -0
- package/lib/typescript/src/games/whack-a-mole/WhackAMole.d.ts.map +1 -0
- package/lib/typescript/src/games/whack-a-mole/WhackAMoleConstants.d.ts +79 -0
- package/lib/typescript/src/games/whack-a-mole/WhackAMoleConstants.d.ts.map +1 -0
- package/lib/typescript/src/games/whack-a-mole/WhackAMoleService.d.ts +33 -0
- package/lib/typescript/src/games/whack-a-mole/WhackAMoleService.d.ts.map +1 -0
- package/lib/typescript/src/games/whack-a-mole/WhackAMoleStore.d.ts +41 -0
- package/lib/typescript/src/games/whack-a-mole/WhackAMoleStore.d.ts.map +1 -0
- package/lib/typescript/src/games/whack-a-mole/components/GameBackground.d.ts.map +1 -0
- package/lib/typescript/src/games/{cat-popper → whack-a-mole}/components/GameGrid.d.ts +2 -2
- package/lib/typescript/src/games/whack-a-mole/components/GameGrid.d.ts.map +1 -0
- package/lib/typescript/src/games/{cat-popper → whack-a-mole}/components/GameHole.d.ts +3 -2
- package/lib/typescript/src/games/whack-a-mole/components/GameHole.d.ts.map +1 -0
- package/lib/typescript/src/games/whack-a-mole/components/MoleCharacter.d.ts +7 -0
- package/lib/typescript/src/games/whack-a-mole/components/MoleCharacter.d.ts.map +1 -0
- package/lib/typescript/src/games/whack-a-mole/components/ScoreBoard.d.ts.map +1 -0
- package/lib/typescript/src/games/whack-a-mole/components/index.d.ts +6 -0
- package/lib/typescript/src/games/whack-a-mole/components/index.d.ts.map +1 -0
- package/lib/typescript/src/index.d.ts +4 -3
- package/lib/typescript/src/index.d.ts.map +1 -1
- package/lib/typescript/src/services/GamesConstants.d.ts +61 -340
- package/lib/typescript/src/services/GamesConstants.d.ts.map +1 -1
- package/lib/typescript/src/services/GamesService.d.ts +21 -3
- package/lib/typescript/src/services/GamesService.d.ts.map +1 -1
- package/lib/typescript/src/services/HapticsService.d.ts +16 -0
- package/lib/typescript/src/services/HapticsService.d.ts.map +1 -0
- package/lib/typescript/src/services/SoundsService.d.ts +154 -0
- package/lib/typescript/src/services/SoundsService.d.ts.map +1 -0
- package/lib/typescript/src/shared/helpers/AnimationFrame.d.ts +41 -0
- package/lib/typescript/src/shared/helpers/AnimationFrame.d.ts.map +1 -0
- package/lib/typescript/src/shared/helpers/AnimationTracker.d.ts +45 -0
- package/lib/typescript/src/shared/helpers/AnimationTracker.d.ts.map +1 -0
- package/lib/typescript/src/shared/helpers/ErrorHandler.d.ts +124 -0
- package/lib/typescript/src/shared/helpers/ErrorHandler.d.ts.map +1 -0
- package/lib/typescript/src/shared/helpers/GameControlButton.d.ts +17 -0
- package/lib/typescript/src/shared/helpers/GameControlButton.d.ts.map +1 -0
- package/lib/typescript/src/{games/cat-popper/components → shared/helpers}/GameOverModal.d.ts +5 -0
- package/lib/typescript/src/shared/helpers/GameOverModal.d.ts.map +1 -0
- package/lib/typescript/src/shared/helpers/GameSettingsModal.d.ts +9 -0
- package/lib/typescript/src/shared/helpers/GameSettingsModal.d.ts.map +1 -0
- package/lib/typescript/src/shared/helpers/ParticleBlast.d.ts +12 -0
- package/lib/typescript/src/shared/helpers/ParticleBlast.d.ts.map +1 -0
- package/lib/typescript/src/shared/helpers/ResponsiveScoreBoard.d.ts +42 -0
- package/lib/typescript/src/shared/helpers/ResponsiveScoreBoard.d.ts.map +1 -0
- package/lib/typescript/src/shared/helpers/index.d.ts +13 -0
- package/lib/typescript/src/shared/helpers/index.d.ts.map +1 -0
- package/package.json +9 -6
- package/lib/module/games/balloon-blaster/components/GameControls.js +0 -229
- package/lib/module/games/balloon-blaster/components/GameControls.js.map +0 -1
- package/lib/module/games/balloon-blaster/components/GameOverModal.js.map +0 -1
- package/lib/module/games/balloon-blaster/components/ParticleSystem.js +0 -52
- package/lib/module/games/balloon-blaster/components/ParticleSystem.js.map +0 -1
- package/lib/module/games/balloon-blaster/components/SliceTrail.js +0 -58
- package/lib/module/games/balloon-blaster/components/SliceTrail.js.map +0 -1
- package/lib/module/games/cat-popper/CatPopper.js +0 -230
- package/lib/module/games/cat-popper/CatPopper.js.map +0 -1
- package/lib/module/games/cat-popper/CatPopperService.js +0 -100
- package/lib/module/games/cat-popper/CatPopperService.js.map +0 -1
- package/lib/module/games/cat-popper/CatPopperStore.js +0 -113
- package/lib/module/games/cat-popper/CatPopperStore.js.map +0 -1
- package/lib/module/games/cat-popper/components/CatCharacter.js.map +0 -1
- package/lib/module/games/cat-popper/components/GameBackground.js.map +0 -1
- package/lib/module/games/cat-popper/components/GameControls.js +0 -230
- package/lib/module/games/cat-popper/components/GameControls.js.map +0 -1
- package/lib/module/games/cat-popper/components/GameGrid.js +0 -66
- package/lib/module/games/cat-popper/components/GameGrid.js.map +0 -1
- package/lib/module/games/cat-popper/components/GameHole.js.map +0 -1
- package/lib/module/games/cat-popper/components/GameOverModal.js +0 -131
- package/lib/module/games/cat-popper/components/GameOverModal.js.map +0 -1
- package/lib/module/games/cat-popper/components/ScoreBoard.js.map +0 -1
- package/lib/module/games/cat-popper/components/index.js.map +0 -1
- package/lib/module/games/fruit-slicer/FruitSlicer.js +0 -411
- package/lib/module/games/fruit-slicer/FruitSlicer.js.map +0 -1
- package/lib/module/games/fruit-slicer/FruitSlicerService.js.map +0 -1
- package/lib/module/games/fruit-slicer/FruitSlicerStore.js +0 -156
- package/lib/module/games/fruit-slicer/FruitSlicerStore.js.map +0 -1
- package/lib/module/games/fruit-slicer/components/FruitComponent.js.map +0 -1
- package/lib/module/games/fruit-slicer/components/GameArea.js +0 -50
- package/lib/module/games/fruit-slicer/components/GameArea.js.map +0 -1
- package/lib/module/games/fruit-slicer/components/GameBackground.js.map +0 -1
- package/lib/module/games/fruit-slicer/components/GameControls.js +0 -230
- package/lib/module/games/fruit-slicer/components/GameControls.js.map +0 -1
- package/lib/module/games/fruit-slicer/components/GameOverModal.js +0 -189
- package/lib/module/games/fruit-slicer/components/GameOverModal.js.map +0 -1
- package/lib/module/games/fruit-slicer/components/ParticleSystem.js +0 -52
- package/lib/module/games/fruit-slicer/components/ParticleSystem.js.map +0 -1
- package/lib/module/games/fruit-slicer/components/ScoreBoard.js.map +0 -1
- package/lib/module/games/fruit-slicer/components/SliceTrail.js +0 -58
- package/lib/module/games/fruit-slicer/components/SliceTrail.js.map +0 -1
- package/lib/module/games/fruit-slicer/components/index.js +0 -11
- package/lib/module/games/fruit-slicer/components/index.js.map +0 -1
- package/lib/module/games/maze-runner/components/GameControls.js +0 -129
- package/lib/module/games/maze-runner/components/GameControls.js.map +0 -1
- package/lib/module/games/maze-runner/components/GameOverModal.js +0 -134
- package/lib/module/games/maze-runner/components/GameOverModal.js.map +0 -1
- package/lib/module/games/space-traveller/SpaceTraveller.js +0 -393
- package/lib/module/games/space-traveller/SpaceTraveller.js.map +0 -1
- package/lib/module/games/space-traveller/SpaceTravellerService.js.map +0 -1
- package/lib/module/games/space-traveller/SpaceTravellerStore.js +0 -139
- package/lib/module/games/space-traveller/SpaceTravellerStore.js.map +0 -1
- package/lib/module/games/space-traveller/components/AsteroidComponent.js.map +0 -1
- package/lib/module/games/space-traveller/components/GameArea.js +0 -75
- package/lib/module/games/space-traveller/components/GameArea.js.map +0 -1
- package/lib/module/games/space-traveller/components/GameBackground.js.map +0 -1
- package/lib/module/games/space-traveller/components/GameControls.js +0 -177
- package/lib/module/games/space-traveller/components/GameControls.js.map +0 -1
- package/lib/module/games/space-traveller/components/GameOverModal.js +0 -182
- package/lib/module/games/space-traveller/components/GameOverModal.js.map +0 -1
- package/lib/module/games/space-traveller/components/ParticleComponent.js +0 -34
- package/lib/module/games/space-traveller/components/ParticleComponent.js.map +0 -1
- package/lib/module/games/space-traveller/components/ScoreBoard.js.map +0 -1
- package/lib/module/games/space-traveller/components/SettingsModal.js +0 -222
- package/lib/module/games/space-traveller/components/SettingsModal.js.map +0 -1
- package/lib/module/games/space-traveller/components/Spacecraft3D.js.map +0 -1
- package/lib/module/games/space-traveller/components/SpacecraftPath.js +0 -37
- package/lib/module/games/space-traveller/components/SpacecraftPath.js.map +0 -1
- package/lib/module/games/space-traveller/components/index.js.map +0 -1
- package/lib/module/shared/settings/GameSettings.js +0 -295
- package/lib/module/shared/settings/GameSettings.js.map +0 -1
- package/lib/module/shared/settings/SettingsService.js +0 -119
- package/lib/module/shared/settings/SettingsService.js.map +0 -1
- package/lib/typescript/src/games/balloon-blaster/components/GameControls.d.ts +0 -10
- package/lib/typescript/src/games/balloon-blaster/components/GameControls.d.ts.map +0 -1
- package/lib/typescript/src/games/balloon-blaster/components/GameOverModal.d.ts +0 -9
- package/lib/typescript/src/games/balloon-blaster/components/GameOverModal.d.ts.map +0 -1
- package/lib/typescript/src/games/balloon-blaster/components/ParticleSystem.d.ts +0 -8
- package/lib/typescript/src/games/balloon-blaster/components/ParticleSystem.d.ts.map +0 -1
- package/lib/typescript/src/games/balloon-blaster/components/SliceTrail.d.ts +0 -11
- package/lib/typescript/src/games/balloon-blaster/components/SliceTrail.d.ts.map +0 -1
- package/lib/typescript/src/games/cat-popper/CatPopper.d.ts +0 -13
- package/lib/typescript/src/games/cat-popper/CatPopper.d.ts.map +0 -1
- package/lib/typescript/src/games/cat-popper/CatPopperService.d.ts +0 -32
- package/lib/typescript/src/games/cat-popper/CatPopperService.d.ts.map +0 -1
- package/lib/typescript/src/games/cat-popper/CatPopperStore.d.ts +0 -21
- package/lib/typescript/src/games/cat-popper/CatPopperStore.d.ts.map +0 -1
- package/lib/typescript/src/games/cat-popper/components/CatCharacter.d.ts +0 -7
- package/lib/typescript/src/games/cat-popper/components/CatCharacter.d.ts.map +0 -1
- package/lib/typescript/src/games/cat-popper/components/GameBackground.d.ts.map +0 -1
- package/lib/typescript/src/games/cat-popper/components/GameControls.d.ts +0 -10
- package/lib/typescript/src/games/cat-popper/components/GameControls.d.ts.map +0 -1
- package/lib/typescript/src/games/cat-popper/components/GameGrid.d.ts.map +0 -1
- package/lib/typescript/src/games/cat-popper/components/GameHole.d.ts.map +0 -1
- package/lib/typescript/src/games/cat-popper/components/GameOverModal.d.ts.map +0 -1
- package/lib/typescript/src/games/cat-popper/components/ScoreBoard.d.ts.map +0 -1
- package/lib/typescript/src/games/cat-popper/components/index.d.ts +0 -8
- package/lib/typescript/src/games/cat-popper/components/index.d.ts.map +0 -1
- package/lib/typescript/src/games/fruit-slicer/FruitSlicer.d.ts +0 -16
- package/lib/typescript/src/games/fruit-slicer/FruitSlicer.d.ts.map +0 -1
- package/lib/typescript/src/games/fruit-slicer/FruitSlicerService.d.ts.map +0 -1
- package/lib/typescript/src/games/fruit-slicer/FruitSlicerStore.d.ts.map +0 -1
- package/lib/typescript/src/games/fruit-slicer/components/FruitComponent.d.ts.map +0 -1
- package/lib/typescript/src/games/fruit-slicer/components/GameArea.d.ts +0 -17
- package/lib/typescript/src/games/fruit-slicer/components/GameArea.d.ts.map +0 -1
- package/lib/typescript/src/games/fruit-slicer/components/GameBackground.d.ts.map +0 -1
- package/lib/typescript/src/games/fruit-slicer/components/GameControls.d.ts +0 -10
- package/lib/typescript/src/games/fruit-slicer/components/GameControls.d.ts.map +0 -1
- package/lib/typescript/src/games/fruit-slicer/components/GameOverModal.d.ts +0 -9
- package/lib/typescript/src/games/fruit-slicer/components/GameOverModal.d.ts.map +0 -1
- package/lib/typescript/src/games/fruit-slicer/components/ParticleSystem.d.ts +0 -8
- package/lib/typescript/src/games/fruit-slicer/components/ParticleSystem.d.ts.map +0 -1
- package/lib/typescript/src/games/fruit-slicer/components/ScoreBoard.d.ts +0 -9
- package/lib/typescript/src/games/fruit-slicer/components/ScoreBoard.d.ts.map +0 -1
- package/lib/typescript/src/games/fruit-slicer/components/SliceTrail.d.ts +0 -11
- package/lib/typescript/src/games/fruit-slicer/components/SliceTrail.d.ts.map +0 -1
- package/lib/typescript/src/games/fruit-slicer/components/index.d.ts +0 -9
- package/lib/typescript/src/games/fruit-slicer/components/index.d.ts.map +0 -1
- package/lib/typescript/src/games/maze-runner/components/GameControls.d.ts +0 -10
- package/lib/typescript/src/games/maze-runner/components/GameControls.d.ts.map +0 -1
- package/lib/typescript/src/games/maze-runner/components/GameOverModal.d.ts +0 -11
- package/lib/typescript/src/games/maze-runner/components/GameOverModal.d.ts.map +0 -1
- package/lib/typescript/src/games/space-traveller/SpaceTraveller.d.ts +0 -17
- package/lib/typescript/src/games/space-traveller/SpaceTraveller.d.ts.map +0 -1
- package/lib/typescript/src/games/space-traveller/SpaceTravellerService.d.ts.map +0 -1
- package/lib/typescript/src/games/space-traveller/SpaceTravellerStore.d.ts.map +0 -1
- package/lib/typescript/src/games/space-traveller/components/AsteroidComponent.d.ts +0 -9
- package/lib/typescript/src/games/space-traveller/components/AsteroidComponent.d.ts.map +0 -1
- package/lib/typescript/src/games/space-traveller/components/GameArea.d.ts +0 -17
- package/lib/typescript/src/games/space-traveller/components/GameArea.d.ts.map +0 -1
- package/lib/typescript/src/games/space-traveller/components/GameBackground.d.ts.map +0 -1
- package/lib/typescript/src/games/space-traveller/components/GameControls.d.ts +0 -10
- package/lib/typescript/src/games/space-traveller/components/GameControls.d.ts.map +0 -1
- package/lib/typescript/src/games/space-traveller/components/GameOverModal.d.ts +0 -9
- package/lib/typescript/src/games/space-traveller/components/GameOverModal.d.ts.map +0 -1
- package/lib/typescript/src/games/space-traveller/components/ParticleComponent.d.ts +0 -8
- package/lib/typescript/src/games/space-traveller/components/ParticleComponent.d.ts.map +0 -1
- package/lib/typescript/src/games/space-traveller/components/ScoreBoard.d.ts +0 -8
- package/lib/typescript/src/games/space-traveller/components/ScoreBoard.d.ts.map +0 -1
- package/lib/typescript/src/games/space-traveller/components/SettingsModal.d.ts +0 -9
- package/lib/typescript/src/games/space-traveller/components/SettingsModal.d.ts.map +0 -1
- package/lib/typescript/src/games/space-traveller/components/Spacecraft3D.d.ts.map +0 -1
- package/lib/typescript/src/games/space-traveller/components/SpacecraftPath.d.ts.map +0 -1
- package/lib/typescript/src/games/space-traveller/components/index.d.ts.map +0 -1
- package/lib/typescript/src/shared/settings/GameSettings.d.ts +0 -36
- package/lib/typescript/src/shared/settings/GameSettings.d.ts.map +0 -1
- package/lib/typescript/src/shared/settings/SettingsService.d.ts +0 -32
- package/lib/typescript/src/shared/settings/SettingsService.d.ts.map +0 -1
- /package/lib/typescript/src/games/{cat-popper → fruit-ninja}/components/GameBackground.d.ts +0 -0
- /package/lib/typescript/src/games/{fruit-slicer → space-fighter}/components/GameBackground.d.ts +0 -0
- /package/lib/typescript/src/games/{space-traveller → space-fighter}/components/SpacecraftPath.d.ts +0 -0
- /package/lib/typescript/src/games/{space-traveller → whack-a-mole}/components/GameBackground.d.ts +0 -0
- /package/lib/typescript/src/games/{cat-popper → whack-a-mole}/components/ScoreBoard.d.ts +0 -0
|
@@ -1,20 +1,22 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
import {
|
|
3
|
+
import { SPACE_FIGHTER_GAME_CONFIG as GAME_CONFIG, SPACE_FIGHTER_COLORS as COLORS } from "./SpaceFighterConstants.js";
|
|
4
4
|
|
|
5
|
-
// Constants now imported from
|
|
5
|
+
// Constants now imported from SpaceFighterConstants.ts
|
|
6
6
|
// Re-export for backward compatibility
|
|
7
7
|
export { GAME_CONFIG, COLORS };
|
|
8
8
|
|
|
9
9
|
// Asteroid Types (space obstacles)
|
|
10
10
|
|
|
11
11
|
// Game Service Class
|
|
12
|
-
class
|
|
12
|
+
class SpaceFighterGameService {
|
|
13
13
|
gameTimer = null;
|
|
14
14
|
asteroidSpawnTimer = null;
|
|
15
15
|
physicsTimer = null;
|
|
16
16
|
particles = [];
|
|
17
17
|
lastCollisionTime = 0;
|
|
18
|
+
currentAsteroidSpeed = GAME_CONFIG.ASTEROID_SPEED;
|
|
19
|
+
currentSpawnInterval = GAME_CONFIG.ASTEROID_SPAWN_INTERVAL;
|
|
18
20
|
constructor(screenWidth, screenHeight) {
|
|
19
21
|
this.width = screenWidth;
|
|
20
22
|
this.height = screenHeight;
|
|
@@ -45,16 +47,22 @@ class SpaceTravellerGameService {
|
|
|
45
47
|
startGameTimer(decrementTime) {
|
|
46
48
|
this.gameTimer = setInterval(decrementTime, 1000);
|
|
47
49
|
}
|
|
50
|
+
|
|
51
|
+
// Method to update difficulty settings
|
|
52
|
+
updateDifficultySettings(asteroidSpeed, spawnInterval) {
|
|
53
|
+
this.currentAsteroidSpeed = asteroidSpeed;
|
|
54
|
+
this.currentSpawnInterval = spawnInterval;
|
|
55
|
+
}
|
|
48
56
|
startAsteroidSpawning(spawnAsteroid) {
|
|
49
57
|
// Spawn first asteroid pair immediately
|
|
50
58
|
const initialAsteroids = this.generateAsteroidPair();
|
|
51
59
|
spawnAsteroid(initialAsteroids);
|
|
52
60
|
|
|
53
|
-
// Then continue spawning at regular intervals
|
|
61
|
+
// Then continue spawning at regular intervals using dynamic spawn interval
|
|
54
62
|
this.asteroidSpawnTimer = setInterval(() => {
|
|
55
63
|
const asteroids = this.generateAsteroidPair();
|
|
56
64
|
spawnAsteroid(asteroids);
|
|
57
|
-
},
|
|
65
|
+
}, this.currentSpawnInterval);
|
|
58
66
|
}
|
|
59
67
|
startPhysicsLoop(updateSpacecraft, updateAsteroid, removeAsteroid, getSpacecraft, getAsteroids) {
|
|
60
68
|
this.physicsTimer = setInterval(() => {
|
|
@@ -106,7 +114,8 @@ class SpaceTravellerGameService {
|
|
|
106
114
|
...spacecraft
|
|
107
115
|
};
|
|
108
116
|
|
|
109
|
-
// Spacecraft never moves vertically - Y position is always locked
|
|
117
|
+
// Spacecraft never moves vertically - Y position is always locked to initial position
|
|
118
|
+
newSpacecraft.y = this.height * 0.70; // Force Y position to always be at correct location (higher up)
|
|
110
119
|
newSpacecraft.velocityY = 0;
|
|
111
120
|
|
|
112
121
|
// Only allow horizontal movement when being controlled
|
|
@@ -125,13 +134,17 @@ class SpaceTravellerGameService {
|
|
|
125
134
|
newSpacecraft.velocityX = 0;
|
|
126
135
|
}
|
|
127
136
|
|
|
128
|
-
// Y position
|
|
137
|
+
// Y position is always forced to correct position - never changes
|
|
129
138
|
|
|
130
139
|
updateSpacecraft(newSpacecraft);
|
|
131
140
|
|
|
132
|
-
// Update asteroids - move vertically from top to bottom
|
|
133
|
-
|
|
134
|
-
|
|
141
|
+
// Update asteroids - move vertically from top to bottom using dynamic speed
|
|
142
|
+
// Optimized: Use for-loop instead of forEach for better performance
|
|
143
|
+
for (let i = 0; i < asteroids.length; i++) {
|
|
144
|
+
const asteroid = asteroids[i];
|
|
145
|
+
if (!asteroid) continue; // Safety check for undefined asteroid
|
|
146
|
+
|
|
147
|
+
const newY = asteroid.y + this.currentAsteroidSpeed;
|
|
135
148
|
if (newY > this.height) {
|
|
136
149
|
removeAsteroid(asteroid.id);
|
|
137
150
|
} else {
|
|
@@ -139,7 +152,7 @@ class SpaceTravellerGameService {
|
|
|
139
152
|
y: newY
|
|
140
153
|
});
|
|
141
154
|
}
|
|
142
|
-
}
|
|
155
|
+
}
|
|
143
156
|
|
|
144
157
|
// Update particles
|
|
145
158
|
this.updateParticles();
|
|
@@ -207,11 +220,16 @@ class SpaceTravellerGameService {
|
|
|
207
220
|
// Scoring - Updated for horizontal asteroids moving vertically
|
|
208
221
|
checkAsteroidPass(spacecraft, asteroids) {
|
|
209
222
|
const passedAsteroids = [];
|
|
210
|
-
|
|
223
|
+
|
|
224
|
+
// Optimized: Use for-loop instead of forEach for better performance
|
|
225
|
+
for (let i = 0; i < asteroids.length; i++) {
|
|
226
|
+
const asteroid = asteroids[i];
|
|
227
|
+
if (!asteroid) continue; // Safety check for undefined asteroid
|
|
228
|
+
|
|
211
229
|
if (!asteroid.passed && spacecraft.y > asteroid.y + asteroid.height) {
|
|
212
230
|
passedAsteroids.push(asteroid.pairId);
|
|
213
231
|
}
|
|
214
|
-
}
|
|
232
|
+
}
|
|
215
233
|
return passedAsteroids;
|
|
216
234
|
}
|
|
217
235
|
|
|
@@ -254,13 +272,21 @@ class SpaceTravellerGameService {
|
|
|
254
272
|
}
|
|
255
273
|
}
|
|
256
274
|
updateParticles() {
|
|
257
|
-
|
|
275
|
+
// Optimized: Use for-loop with manual filtering for better performance
|
|
276
|
+
const activeParticles = [];
|
|
277
|
+
for (let i = 0; i < this.particles.length; i++) {
|
|
278
|
+
const particle = this.particles[i];
|
|
279
|
+
if (!particle) continue; // Safety check for undefined particle
|
|
280
|
+
|
|
258
281
|
particle.x += particle.velocityX;
|
|
259
282
|
particle.y += particle.velocityY;
|
|
260
283
|
particle.velocityY += 0.2; // gravity
|
|
261
284
|
particle.life -= 16;
|
|
262
|
-
|
|
263
|
-
|
|
285
|
+
if (particle.life > 0) {
|
|
286
|
+
activeParticles.push(particle);
|
|
287
|
+
}
|
|
288
|
+
}
|
|
289
|
+
this.particles = activeParticles;
|
|
264
290
|
}
|
|
265
291
|
getParticles() {
|
|
266
292
|
return this.particles;
|
|
@@ -279,12 +305,13 @@ class SpaceTravellerGameService {
|
|
|
279
305
|
return Math.max(0, GAME_CONFIG.COLLISION_COOLDOWN - elapsed);
|
|
280
306
|
}
|
|
281
307
|
|
|
282
|
-
// Initial Spacecraft Position - Centered horizontally, positioned
|
|
308
|
+
// Initial Spacecraft Position - Centered horizontally, positioned at bottom above start button
|
|
283
309
|
getInitialSpacecraft() {
|
|
284
310
|
return {
|
|
285
311
|
x: this.width / 2,
|
|
286
312
|
// Ensure exact center
|
|
287
|
-
y: this.height * 0.
|
|
313
|
+
y: this.height * 0.70,
|
|
314
|
+
// Position higher up for better gameplay
|
|
288
315
|
velocityX: 0,
|
|
289
316
|
velocityY: 0,
|
|
290
317
|
size: GAME_CONFIG.SPACECRAFT_SIZE,
|
|
@@ -292,7 +319,7 @@ class SpaceTravellerGameService {
|
|
|
292
319
|
};
|
|
293
320
|
}
|
|
294
321
|
}
|
|
295
|
-
export const
|
|
296
|
-
return new
|
|
322
|
+
export const createSpaceFighterService = (width, height) => {
|
|
323
|
+
return new SpaceFighterGameService(width, height);
|
|
297
324
|
};
|
|
298
|
-
//# sourceMappingURL=
|
|
325
|
+
//# sourceMappingURL=SpaceFighterService.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["SPACE_FIGHTER_GAME_CONFIG","GAME_CONFIG","SPACE_FIGHTER_COLORS","COLORS","SpaceFighterGameService","gameTimer","asteroidSpawnTimer","physicsTimer","particles","lastCollisionTime","currentAsteroidSpeed","ASTEROID_SPEED","currentSpawnInterval","ASTEROID_SPAWN_INTERVAL","constructor","screenWidth","screenHeight","width","height","startGame","cleanup","clearInterval","startGameTimer","decrementTime","setInterval","updateDifficultySettings","asteroidSpeed","spawnInterval","startAsteroidSpawning","spawnAsteroid","initialAsteroids","generateAsteroidPair","asteroids","startPhysicsLoop","updateSpacecraft","updateAsteroid","removeAsteroid","getSpacecraft","getAsteroids","updatePhysics","pairId","Date","now","Math","random","minGapX","maxGapX","ASTEROID_GAP","gapX","leftAsteroid","id","x","y","ASTEROID_WIDTH","type","passed","spawnTime","rightAsteroid","spacecraft","newSpacecraft","velocityY","isControlled","velocityX","size","i","length","asteroid","newY","updateParticles","controlSpacecraft","targetX","_targetY","minX","maxX","constrainedX","max","min","releaseSpacecraft","checkCollision","currentTime","COLLISION_COOLDOWN","collision","spacecraftAsteroidCollision","asteroidId","spacecraftLeft","spacecraftRight","spacecraftTop","spacecraftBottom","asteroidLeft","asteroidRight","asteroidTop","asteroidBottom","checkAsteroidPass","passedAsteroids","push","createCollisionParticles","particle","color","SPACECRAFT","life","maxLife","bigParticle","activeParticles","getParticles","isInCollisionImmunity","getRemainingImmunityTime","elapsed","getInitialSpacecraft","SPACECRAFT_SIZE","createSpaceFighterService"],"sourceRoot":"../../../../src","sources":["games/space-fighter/SpaceFighterService.ts"],"mappings":";;AAAA,SACEA,yBAAyB,IAAIC,WAAW,EACxCC,oBAAoB,IAAIC,MAAM,QACzB,4BAAyB;;AAEhC;AACA;AACA,SAASF,WAAW,EAAEE,MAAM;;AAE5B;;AAkCA;AACA,MAAMC,uBAAuB,CAAC;EAGpBC,SAAS,GAA0C,IAAI;EACvDC,kBAAkB,GAA0C,IAAI;EAChEC,YAAY,GAA0C,IAAI;EAC1DC,SAAS,GAAe,EAAE;EAC1BC,iBAAiB,GAAW,CAAC;EAC7BC,oBAAoB,GAAWT,WAAW,CAACU,cAAc;EACzDC,oBAAoB,GAAWX,WAAW,CAACY,uBAAuB;EAE1EC,WAAWA,CAACC,WAAmB,EAAEC,YAAoB,EAAE;IACrD,IAAI,CAACC,KAAK,GAAGF,WAAW;IACxB,IAAI,CAACG,MAAM,GAAGF,YAAY;EAC5B;;EAEA;EACAG,SAASA,CAAA,EAAG;IACV,IAAI,CAACC,OAAO,CAAC,CAAC;EAChB;EAEAA,OAAOA,CAAA,EAAG;IACR,IAAI,IAAI,CAACf,SAAS,EAAE;MAClBgB,aAAa,CAAC,IAAI,CAAChB,SAAS,CAAC;MAC7B,IAAI,CAACA,SAAS,GAAG,IAAI;IACvB;IACA,IAAI,IAAI,CAACC,kBAAkB,EAAE;MAC3Be,aAAa,CAAC,IAAI,CAACf,kBAAkB,CAAC;MACtC,IAAI,CAACA,kBAAkB,GAAG,IAAI;IAChC;IACA,IAAI,IAAI,CAACC,YAAY,EAAE;MACrBc,aAAa,CAAC,IAAI,CAACd,YAAY,CAAC;MAChC,IAAI,CAACA,YAAY,GAAG,IAAI;IAC1B;IACA,IAAI,CAACC,SAAS,GAAG,EAAE;IACnB,IAAI,CAACC,iBAAiB,GAAG,CAAC,CAAC,CAAC;EAC9B;;EAEA;EACAa,cAAcA,CAACC,aAAyB,EAAE;IACxC,IAAI,CAAClB,SAAS,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O,GAAG3B,WAAW,GAAG,IAAI,CAACtE,iBAAiB;IACpD,OAAOkC,IAAI,CAACgC,GAAG,CAAC,CAAC,EAAE1E,WAAW,CAAC+E,kBAAkB,GAAG0B,OAAO,CAAC;EAC9D;;EAEA;EACAC,oBAAoBA,CAAA,EAAe;IACjC,OAAO;MACLxD,CAAC,EAAE,IAAI,CAAClC,KAAK,GAAG,CAAC;MAAE;MACnBmC,CAAC,EAAE,IAAI,CAAClC,MAAM,GAAG,IAAI;MAAE;MACvB4C,SAAS,EAAE,CAAC;MACZF,SAAS,EAAE,CAAC;MACZG,IAAI,EAAE9D,WAAW,CAAC2G,eAAe;MACjC/C,YAAY,EAAE;IAChB,CAAC;EACH;AACF;AAEA,OAAO,MAAMgD,yBAAyB,GAAGA,CAAC5F,KAAa,EAAEC,MAAc,KAAK;EAC1E,OAAO,IAAId,uBAAuB,CAACa,KAAK,EAAEC,MAAM,CAAC;AACnD,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,195 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { create } from 'zustand';
|
|
4
|
+
import { subscribeWithSelector } from 'zustand/middleware';
|
|
5
|
+
import { Dimensions } from 'react-native';
|
|
6
|
+
import { GAME_CONFIG } from "./SpaceFighterService.js";
|
|
7
|
+
import { immerMiddleware } from "../../services/GamesService.js";
|
|
8
|
+
const {
|
|
9
|
+
width,
|
|
10
|
+
height
|
|
11
|
+
} = Dimensions.get('window');
|
|
12
|
+
// Optimized store with selective subscriptions for low-end devices
|
|
13
|
+
export const useSpaceFighterStore = create()(subscribeWithSelector(immerMiddleware((set, _get) => ({
|
|
14
|
+
// Initial state
|
|
15
|
+
score: 0,
|
|
16
|
+
timeLeft: 60,
|
|
17
|
+
// Fixed 60 seconds regardless of difficulty
|
|
18
|
+
isPlaying: false,
|
|
19
|
+
gameOver: false,
|
|
20
|
+
lives: 3,
|
|
21
|
+
asteroids: [],
|
|
22
|
+
spacecraft: {
|
|
23
|
+
x: width / 2,
|
|
24
|
+
// Center horizontally
|
|
25
|
+
y: height * 0.78,
|
|
26
|
+
// Position at bottom above start button (moved up)
|
|
27
|
+
velocityX: 0,
|
|
28
|
+
velocityY: 0,
|
|
29
|
+
size: GAME_CONFIG.SPACECRAFT_SIZE,
|
|
30
|
+
isControlled: false
|
|
31
|
+
},
|
|
32
|
+
spacecraftPath: [],
|
|
33
|
+
isControllingSpacecraft: false,
|
|
34
|
+
// Actions
|
|
35
|
+
startGame: _gameDuration => {
|
|
36
|
+
// Always use fixed duration regardless of difficulty or passed duration
|
|
37
|
+
const duration = 60;
|
|
38
|
+
set(draft => {
|
|
39
|
+
draft.score = 0;
|
|
40
|
+
draft.timeLeft = duration;
|
|
41
|
+
draft.isPlaying = true;
|
|
42
|
+
draft.gameOver = false;
|
|
43
|
+
draft.lives = 3;
|
|
44
|
+
draft.asteroids = [];
|
|
45
|
+
draft.spacecraftPath = [];
|
|
46
|
+
draft.isControllingSpacecraft = false;
|
|
47
|
+
// Reset spacecraft to initial position
|
|
48
|
+
draft.spacecraft = {
|
|
49
|
+
x: width / 2,
|
|
50
|
+
// Center horizontally
|
|
51
|
+
y: height * 0.70,
|
|
52
|
+
// Position higher up for better gameplay
|
|
53
|
+
velocityX: 0,
|
|
54
|
+
velocityY: 0,
|
|
55
|
+
size: GAME_CONFIG.SPACECRAFT_SIZE,
|
|
56
|
+
isControlled: false
|
|
57
|
+
};
|
|
58
|
+
});
|
|
59
|
+
},
|
|
60
|
+
stopGame: () => {
|
|
61
|
+
set(draft => {
|
|
62
|
+
draft.score = 0;
|
|
63
|
+
draft.timeLeft = 60; // Fixed 60 seconds
|
|
64
|
+
draft.isPlaying = false;
|
|
65
|
+
draft.gameOver = false;
|
|
66
|
+
draft.lives = 3;
|
|
67
|
+
draft.asteroids = [];
|
|
68
|
+
draft.spacecraftPath = [];
|
|
69
|
+
draft.isControllingSpacecraft = false;
|
|
70
|
+
// Reset spacecraft to initial position
|
|
71
|
+
draft.spacecraft = {
|
|
72
|
+
x: width / 2,
|
|
73
|
+
// Center horizontally
|
|
74
|
+
y: height * 0.70,
|
|
75
|
+
// Position higher up for better gameplay
|
|
76
|
+
velocityX: 0,
|
|
77
|
+
velocityY: 0,
|
|
78
|
+
size: GAME_CONFIG.SPACECRAFT_SIZE,
|
|
79
|
+
isControlled: false
|
|
80
|
+
};
|
|
81
|
+
});
|
|
82
|
+
},
|
|
83
|
+
resetGame: () => {
|
|
84
|
+
set(draft => {
|
|
85
|
+
draft.score = 0;
|
|
86
|
+
draft.timeLeft = 60; // Fixed 60 seconds
|
|
87
|
+
draft.isPlaying = false;
|
|
88
|
+
draft.gameOver = false;
|
|
89
|
+
draft.lives = 3;
|
|
90
|
+
draft.asteroids = [];
|
|
91
|
+
draft.spacecraftPath = [];
|
|
92
|
+
draft.isControllingSpacecraft = false;
|
|
93
|
+
// Reset spacecraft to initial position
|
|
94
|
+
draft.spacecraft = {
|
|
95
|
+
x: width / 2,
|
|
96
|
+
// Center horizontally
|
|
97
|
+
y: height * 0.70,
|
|
98
|
+
// Position higher up for better gameplay
|
|
99
|
+
velocityX: 0,
|
|
100
|
+
velocityY: 0,
|
|
101
|
+
size: GAME_CONFIG.SPACECRAFT_SIZE,
|
|
102
|
+
isControlled: false
|
|
103
|
+
};
|
|
104
|
+
});
|
|
105
|
+
},
|
|
106
|
+
updateScore: points => {
|
|
107
|
+
set(draft => {
|
|
108
|
+
draft.score = draft.score + points;
|
|
109
|
+
});
|
|
110
|
+
},
|
|
111
|
+
decrementTime: () => {
|
|
112
|
+
set(draft => {
|
|
113
|
+
const newTimeLeft = draft.timeLeft - 1;
|
|
114
|
+
if (newTimeLeft <= 0) {
|
|
115
|
+
draft.timeLeft = 0;
|
|
116
|
+
draft.isPlaying = false;
|
|
117
|
+
draft.gameOver = true;
|
|
118
|
+
} else {
|
|
119
|
+
draft.timeLeft = newTimeLeft;
|
|
120
|
+
}
|
|
121
|
+
});
|
|
122
|
+
},
|
|
123
|
+
addAsteroids: asteroids => {
|
|
124
|
+
set(draft => {
|
|
125
|
+
draft.asteroids.push(...asteroids);
|
|
126
|
+
});
|
|
127
|
+
},
|
|
128
|
+
removeAsteroid: asteroidId => {
|
|
129
|
+
set(draft => {
|
|
130
|
+
draft.asteroids = draft.asteroids.filter(a => a.id !== asteroidId);
|
|
131
|
+
});
|
|
132
|
+
},
|
|
133
|
+
updateAsteroid: (asteroidId, updates) => {
|
|
134
|
+
set(draft => {
|
|
135
|
+
// Optimized: Use for-loop instead of find for better performance
|
|
136
|
+
for (let i = 0; i < draft.asteroids.length; i++) {
|
|
137
|
+
if (draft.asteroids[i].id === asteroidId) {
|
|
138
|
+
Object.assign(draft.asteroids[i], updates);
|
|
139
|
+
break;
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
});
|
|
143
|
+
},
|
|
144
|
+
updateSpacecraft: spacecraft => {
|
|
145
|
+
set(draft => {
|
|
146
|
+
draft.spacecraft = spacecraft;
|
|
147
|
+
});
|
|
148
|
+
},
|
|
149
|
+
setSpacecraftPath: path => {
|
|
150
|
+
set(draft => {
|
|
151
|
+
draft.spacecraftPath = path;
|
|
152
|
+
});
|
|
153
|
+
},
|
|
154
|
+
setIsControllingSpacecraft: isControlling => {
|
|
155
|
+
set(draft => {
|
|
156
|
+
draft.isControllingSpacecraft = isControlling;
|
|
157
|
+
});
|
|
158
|
+
},
|
|
159
|
+
markAsteroidPassed: pairId => {
|
|
160
|
+
set(draft => {
|
|
161
|
+
// Optimized: Use for-loop instead of forEach for better performance
|
|
162
|
+
for (let i = 0; i < draft.asteroids.length; i++) {
|
|
163
|
+
if (draft.asteroids[i].pairId === pairId) {
|
|
164
|
+
draft.asteroids[i].passed = true;
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
draft.score = draft.score + 10; // 10 points per asteroid pair passed
|
|
168
|
+
});
|
|
169
|
+
},
|
|
170
|
+
loseLife: () => {
|
|
171
|
+
set(draft => {
|
|
172
|
+
const newLives = draft.lives - 1;
|
|
173
|
+
|
|
174
|
+
// Reset spacecraft to initial position after collision
|
|
175
|
+
draft.spacecraft = {
|
|
176
|
+
x: width / 2,
|
|
177
|
+
// Center horizontally
|
|
178
|
+
y: height * 0.70,
|
|
179
|
+
// Position higher up for better gameplay
|
|
180
|
+
velocityX: 0,
|
|
181
|
+
velocityY: 0,
|
|
182
|
+
size: GAME_CONFIG.SPACECRAFT_SIZE,
|
|
183
|
+
isControlled: false
|
|
184
|
+
};
|
|
185
|
+
if (newLives <= 0) {
|
|
186
|
+
draft.lives = 0;
|
|
187
|
+
draft.isPlaying = false;
|
|
188
|
+
draft.gameOver = true;
|
|
189
|
+
} else {
|
|
190
|
+
draft.lives = newLives;
|
|
191
|
+
}
|
|
192
|
+
});
|
|
193
|
+
}
|
|
194
|
+
}))));
|
|
195
|
+
//# sourceMappingURL=SpaceFighterStore.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["create","subscribeWithSelector","Dimensions","GAME_CONFIG","immerMiddleware","width","height","get","useSpaceFighterStore","set","_get","score","timeLeft","isPlaying","gameOver","lives","asteroids","spacecraft","x","y","velocityX","velocityY","size","SPACECRAFT_SIZE","isControlled","spacecraftPath","isControllingSpacecraft","startGame","_gameDuration","duration","draft","stopGame","resetGame","updateScore","points","decrementTime","newTimeLeft","addAsteroids","push","removeAsteroid","asteroidId","filter","a","id","updateAsteroid","updates","i","length","Object","assign","updateSpacecraft","setSpacecraftPath","path","setIsControllingSpacecraft","isControlling","markAsteroidPassed","pairId","passed","loseLife","newLives"],"sourceRoot":"../../../../src","sources":["games/space-fighter/SpaceFighterStore.ts"],"mappings":";;AAAA,SAASA,MAAM,QAAQ,SAAS;AAChC,SAASC,qBAAqB,QAAQ,oBAAoB;AAC1D,SAASC,UAAU,QAAQ,cAAc;AAEzC,SAASC,WAAW,QAAQ,0BAAuB;AACnD,SAASC,eAAe,QAAQ,gCAA6B;AAE7D,MAAM;EAAEC,KAAK;EAAEC;AAAO,CAAC,GAAGJ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AAM;IACdjD,GAAG,CAAEqB,KAAU,IAAK;MAClB,MAAM6B,QAAQ,GAAG7B,KAAK,CAACf,KAAK,GAAG,CAAC;;MAEhC;MACAe,KAAK,CAACb,UAAU,GAAG;QACjBC,CAAC,EAAEb,KAAK,GAAG,CAAC;QAAE;QACdc,CAAC,EAAEb,MAAM,GAAG,IAAI;QAAE;QAClBc,SAAS,EAAE,CAAC;QACZC,SAAS,EAAE,CAAC;QACZC,IAAI,EAAEnB,WAAW,CAACoB,eAAe;QACjCC,YAAY,EAAE;MAChB,CAAC;MAED,IAAImC,QAAQ,IAAI,CAAC,EAAE;QACjB7B,KAAK,CAACf,KAAK,GAAG,CAAC;QACfe,KAAK,CAACjB,SAAS,GAAG,KAAK;QACvBiB,KAAK,CAAChB,QAAQ,GAAG,IAAI;MACvB,CAAC,MAAM;QACLgB,KAAK,CAACf,KAAK,GAAG4C,QAAQ;MACxB;IACF,CAAC,CAAC;EACJ;AACF,CAAC,CAAC,CAAC,CAAC,CAAC","ignoreList":[]}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
import React from 'react';
|
|
4
4
|
import { View } from 'react-native';
|
|
5
5
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
6
|
-
export const AsteroidComponent = ({
|
|
6
|
+
export const AsteroidComponent = /*#__PURE__*/React.memo(({
|
|
7
7
|
asteroid
|
|
8
8
|
}) => {
|
|
9
9
|
// Use regular View instead of Animated.View to avoid worklet issues
|
|
@@ -104,8 +104,10 @@ export const AsteroidComponent = ({
|
|
|
104
104
|
}
|
|
105
105
|
})]
|
|
106
106
|
});
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
107
|
+
}, (prevProps, nextProps) => {
|
|
108
|
+
// Custom comparison for better performance
|
|
109
|
+
const prev = prevProps.asteroid;
|
|
110
|
+
const next = nextProps.asteroid;
|
|
111
|
+
return prev.id === next.id && prev.x === next.x && prev.y === next.y && prev.width === next.width && prev.height === next.height;
|
|
112
|
+
});
|
|
111
113
|
//# sourceMappingURL=AsteroidComponent.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["React","View","jsx","_jsx","jsxs","_jsxs","AsteroidComponent","memo","asteroid","style","position","left","x","top","y","width","height","backgroundColor","borderRadius","shadowColor","shadowOffset","shadowOpacity","shadowRadius","borderWidth","borderColor","children","Math","max","prevProps","nextProps","prev","next","id"],"sourceRoot":"../../../../../src","sources":["games/space-fighter/components/AsteroidComponent.tsx"],"mappings":";;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,IAAI,QAAQ,cAAc;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAOpC,OAAO,MAAMC,iBAAmD,gBAAGN,KAAK,CAACO,IAAI,CAAC,CAAC;EAAEC;AAAS,CAAC,KAAK;EAC9F;EACA,oBACEH,KAAA,CAACJ,IAAI;IACHQ,KAAK,EAAE;MACLC,QAAQ,EAAE,UAAU;MACpBC,IAAI,EAAEH,QAAQ,CAACI,CAAC;MAChBC,GAAG,EAAEL,QAAQ,CAACM,CAAC;MACfC,KAAK,EAAEP,QAAQ,CAACO,KAAK;MACrBC,MAAM,EAAER,QAAQ,CAACQ,MAAM;MACvBC,eAAe,EAAE,SAAS;MAAE;MAC5BC,YAAY,EAAE,EAAE;MAAE;MAClBC,WAAW,EAAE,SAAS;MACtBC,YAAY,EAAE;QAAEL,KAAK,EAAE,CAAC;QAAEC,MAAM,EAAE;MAAE,CAAC;MACrCK,aAAa,EAAE,GAAG;MAClBC,YAAY,EAAE,EAAE;MAChB;MACAC,WAAW,EAAE,CAAC;MACdC,WAAW,EAAE;IACf,CAAE;IAAAC,QAAA,gBAGFtB,IAAA,CAACF,IAAI;MACHQ,KAAK,EAAE;QACLC,QAAQ,EAAE,UAAU;QACpBC,IAAI,EAAE,CAAC;QACPE,GAAG,EAAE,CAAC;QACNE,KAAK,EAAEP,QAAQ,CAACO,KAA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