react-native-games 1.1.0 → 1.3.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 +101 -30
- package/lib/module/games/balloon-blaster/BalloonBlaster.js +1 -167
- package/lib/module/games/balloon-blaster/BalloonBlaster.js.map +1 -1
- package/lib/module/games/balloon-blaster/BalloonBlasterConstants.js +1 -182
- package/lib/module/games/balloon-blaster/BalloonBlasterConstants.js.map +1 -1
- package/lib/module/games/balloon-blaster/BalloonBlasterService.js +1 -318
- package/lib/module/games/balloon-blaster/BalloonBlasterStore.js +1 -183
- package/lib/module/games/balloon-blaster/components/BalloonComponent.js +1 -237
- package/lib/module/games/balloon-blaster/components/GameArea.js +1 -156
- package/lib/module/games/balloon-blaster/components/GameBackground.js +1 -476
- package/lib/module/games/balloon-blaster/components/ScoreBoard.js +1 -112
- package/lib/module/games/balloon-blaster/components/ScoreBoard.js.map +1 -1
- package/lib/module/games/balloon-blaster/components/index.js +1 -7
- package/lib/module/games/bike-racing/BikeRacing.js +1 -0
- package/lib/module/games/bike-racing/BikeRacing.js.map +1 -0
- package/lib/module/games/bike-racing/BikeRacingConstants.js +1 -0
- package/lib/module/games/bike-racing/BikeRacingConstants.js.map +1 -0
- package/lib/module/games/bike-racing/BikeRacingService.js +1 -0
- package/lib/module/games/bike-racing/BikeRacingService.js.map +1 -0
- package/lib/module/games/bike-racing/BikeRacingStore.js +1 -0
- package/lib/module/games/bike-racing/BikeRacingStore.js.map +1 -0
- package/lib/module/games/bike-racing/components/BikeComponent.js +1 -0
- package/lib/module/games/bike-racing/components/BikeComponent.js.map +1 -0
- package/lib/module/games/bike-racing/components/GameBackground.js +1 -0
- package/lib/module/games/bike-racing/components/GameBackground.js.map +1 -0
- package/lib/module/games/bike-racing/components/ScoreBoard.js +1 -0
- package/lib/module/games/bike-racing/components/ScoreBoard.js.map +1 -0
- package/lib/module/games/bike-racing/components/index.js +1 -0
- package/lib/module/games/bike-racing/components/index.js.map +1 -0
- package/lib/module/games/bike-racing/index.js +1 -0
- package/lib/module/games/bike-racing/index.js.map +1 -0
- package/lib/module/games/block-blast/BlockBlast.js +1 -0
- package/lib/module/games/block-blast/BlockBlast.js.map +1 -0
- package/lib/module/games/block-blast/BlockBlastConstants.js +1 -0
- package/lib/module/games/block-blast/BlockBlastConstants.js.map +1 -0
- package/lib/module/games/block-blast/BlockBlastService.js +1 -0
- package/lib/module/games/block-blast/BlockBlastService.js.map +1 -0
- package/lib/module/games/block-blast/BlockBlastStore.js +1 -0
- package/lib/module/games/block-blast/BlockBlastStore.js.map +1 -0
- package/lib/module/games/block-blast/components/BlockPieceComponent.js +1 -0
- package/lib/module/games/block-blast/components/BlockPieceComponent.js.map +1 -0
- package/lib/module/games/block-blast/components/GameArea.js +1 -0
- package/lib/module/games/block-blast/components/GameArea.js.map +1 -0
- package/lib/module/games/block-blast/components/GameBackground.js +1 -0
- package/lib/module/games/block-blast/components/GameBackground.js.map +1 -0
- package/lib/module/games/block-blast/components/GridComponent.js +1 -0
- package/lib/module/games/block-blast/components/GridComponent.js.map +1 -0
- package/lib/module/games/block-blast/components/ScoreBoard.js +1 -0
- package/lib/module/games/block-blast/components/ScoreBoard.js.map +1 -0
- package/lib/module/games/block-blast/components/index.js +1 -0
- package/lib/module/games/block-blast/components/index.js.map +1 -0
- package/lib/module/games/block-blast/index.js +1 -0
- package/lib/module/games/block-blast/index.js.map +1 -0
- package/lib/module/games/bubble-shooter/BubbleShooter.js +1 -0
- package/lib/module/games/bubble-shooter/BubbleShooter.js.map +1 -0
- package/lib/module/games/bubble-shooter/BubbleShooterConstants.js +1 -0
- package/lib/module/games/bubble-shooter/BubbleShooterConstants.js.map +1 -0
- package/lib/module/games/bubble-shooter/BubbleShooterService.js +1 -0
- package/lib/module/games/bubble-shooter/BubbleShooterService.js.map +1 -0
- package/lib/module/games/bubble-shooter/BubbleShooterStore.js +1 -0
- package/lib/module/games/bubble-shooter/BubbleShooterStore.js.map +1 -0
- package/lib/module/games/bubble-shooter/components/GameArea.js +1 -0
- package/lib/module/games/bubble-shooter/components/GameArea.js.map +1 -0
- package/lib/module/games/bubble-shooter/components/GameBackground.js +1 -0
- package/lib/module/games/bubble-shooter/components/GameBackground.js.map +1 -0
- package/lib/module/games/bubble-shooter/components/ScoreBoard.js +1 -0
- package/lib/module/games/bubble-shooter/components/ScoreBoard.js.map +1 -0
- package/lib/module/games/bubble-shooter/components/index.js +1 -0
- package/lib/module/games/bubble-shooter/components/index.js.map +1 -0
- package/lib/module/games/bubble-shooter/index.js +1 -0
- package/lib/module/games/bubble-shooter/index.js.map +1 -0
- package/lib/module/games/candy-crush/CandyCrush.js +1 -131
- package/lib/module/games/candy-crush/CandyCrush.js.map +1 -1
- package/lib/module/games/candy-crush/CandyCrushConstants.js +1 -125
- package/lib/module/games/candy-crush/CandyCrushConstants.js.map +1 -1
- package/lib/module/games/candy-crush/CandyCrushService.js +1 -370
- package/lib/module/games/candy-crush/CandyCrushStore.js +1 -303
- package/lib/module/games/candy-crush/components/CandyItem.js +1 -191
- package/lib/module/games/candy-crush/components/GameBackground.js +1 -85
- package/lib/module/games/candy-crush/components/GameGrid.js +1 -314
- package/lib/module/games/candy-crush/components/ScoreBoard.js +1 -79
- package/lib/module/games/candy-crush/components/index.js +1 -7
- package/lib/module/games/candy-crush/index.js +1 -6
- package/lib/module/games/car-racing/CarRacing.js +1 -0
- package/lib/module/games/car-racing/CarRacing.js.map +1 -0
- package/lib/module/games/car-racing/CarRacingConstants.js +1 -0
- package/lib/module/games/car-racing/CarRacingConstants.js.map +1 -0
- package/lib/module/games/car-racing/CarRacingService.js +1 -0
- package/lib/module/games/car-racing/CarRacingService.js.map +1 -0
- package/lib/module/games/car-racing/CarRacingStore.js +1 -0
- package/lib/module/games/car-racing/CarRacingStore.js.map +1 -0
- package/lib/module/games/car-racing/components/CarComponent.js +1 -0
- package/lib/module/games/car-racing/components/CarComponent.js.map +1 -0
- package/lib/module/games/car-racing/components/GameBackground.js +1 -0
- package/lib/module/games/car-racing/components/GameBackground.js.map +1 -0
- package/lib/module/games/car-racing/components/ScoreBoard.js +1 -0
- package/lib/module/games/car-racing/components/ScoreBoard.js.map +1 -0
- package/lib/module/games/car-racing/components/index.js +1 -0
- package/lib/module/games/car-racing/components/index.js.map +1 -0
- package/lib/module/games/colors-sort/ColorsSort.js +1 -143
- package/lib/module/games/colors-sort/ColorsSort.js.map +1 -1
- package/lib/module/games/colors-sort/ColorsSortConstants.js +1 -72
- package/lib/module/games/colors-sort/ColorsSortConstants.js.map +1 -1
- package/lib/module/games/colors-sort/ColorsSortService.js +1 -255
- package/lib/module/games/colors-sort/ColorsSortStore.js +1 -257
- package/lib/module/games/colors-sort/ColorsSortStore.js.map +1 -1
- package/lib/module/games/colors-sort/components/ColorContainer.js +1 -140
- package/lib/module/games/colors-sort/components/GameBackground.js +1 -135
- package/lib/module/games/colors-sort/components/ScoreBoard.js +1 -70
- package/lib/module/games/colors-sort/components/index.js +1 -6
- package/lib/module/games/dino-jump/DinoJump.js +1 -209
- package/lib/module/games/dino-jump/DinoJump.js.map +1 -1
- package/lib/module/games/dino-jump/DinoJumpConstants.js +1 -189
- package/lib/module/games/dino-jump/DinoJumpConstants.js.map +1 -1
- package/lib/module/games/dino-jump/DinoJumpService.js +1 -270
- package/lib/module/games/dino-jump/DinoJumpStore.js +1 -381
- package/lib/module/games/dino-jump/components/DinoSprite.js +1 -418
- package/lib/module/games/dino-jump/components/DinoSprite.js.map +1 -1
- package/lib/module/games/dino-jump/components/GameArea.js +1 -68
- package/lib/module/games/dino-jump/components/GameBackground.js +1 -444
- package/lib/module/games/dino-jump/components/ObstacleSprite.js +1 -306
- package/lib/module/games/dino-jump/components/ScoreBoard.js +1 -105
- package/lib/module/games/dino-jump/components/ScoreBoard.js.map +1 -1
- package/lib/module/games/dino-jump/components/StarSprite.js +1 -45
- package/lib/module/games/dino-jump/components/index.js +1 -9
- package/lib/module/games/flappy-bird/FlappyBird.js +1 -126
- package/lib/module/games/flappy-bird/FlappyBird.js.map +1 -1
- package/lib/module/games/flappy-bird/FlappyBirdConstants.js +1 -90
- package/lib/module/games/flappy-bird/FlappyBirdConstants.js.map +1 -1
- package/lib/module/games/flappy-bird/FlappyBirdStore.js +1 -300
- package/lib/module/games/flappy-bird/components/Bird.js +1 -87
- package/lib/module/games/flappy-bird/components/GameArea.js +1 -87
- package/lib/module/games/flappy-bird/components/GameBackground.js +1 -79
- package/lib/module/games/flappy-bird/components/Pipes.js +1 -172
- package/lib/module/games/flappy-bird/components/ScoreBoard.js +1 -73
- package/lib/module/games/flappy-bird/components/index.js +1 -8
- package/lib/module/games/fruit-merger/FruitMerger.js +1 -120
- package/lib/module/games/fruit-merger/FruitMerger.js.map +1 -1
- package/lib/module/games/fruit-merger/FruitMergerConstants.js +1 -119
- package/lib/module/games/fruit-merger/FruitMergerConstants.js.map +1 -1
- package/lib/module/games/fruit-merger/FruitMergerService.js +1 -13
- package/lib/module/games/fruit-merger/FruitMergerStore.js +1 -315
- package/lib/module/games/fruit-merger/components/FruitItem.js +1 -102
- package/lib/module/games/fruit-merger/components/GameArea.js +1 -103
- package/lib/module/games/fruit-merger/components/GameBackground.js +1 -498
- package/lib/module/games/fruit-merger/components/ScoreBoard.js +1 -58
- package/lib/module/games/fruit-merger/components/index.js +1 -7
- package/lib/module/games/fruit-ninja/FruitNinja.js +1 -134
- package/lib/module/games/fruit-ninja/FruitNinja.js.map +1 -1
- package/lib/module/games/fruit-ninja/FruitNinjaConstants.js +1 -148
- package/lib/module/games/fruit-ninja/FruitNinjaConstants.js.map +1 -1
- package/lib/module/games/fruit-ninja/FruitNinjaService.js +1 -311
- package/lib/module/games/fruit-ninja/FruitNinjaStore.js +1 -191
- package/lib/module/games/fruit-ninja/FruitNinjaStore.js.map +1 -1
- package/lib/module/games/fruit-ninja/components/FruitComponent.js +1 -99
- package/lib/module/games/fruit-ninja/components/GameArea.js +1 -215
- package/lib/module/games/fruit-ninja/components/GameBackground.js +1 -1267
- package/lib/module/games/fruit-ninja/components/ScoreBoard.js +1 -92
- package/lib/module/games/fruit-ninja/components/ScoreBoard.js.map +1 -1
- package/lib/module/games/fruit-ninja/components/index.js +1 -7
- package/lib/module/games/game-2048/Game2048.js +1 -149
- package/lib/module/games/game-2048/Game2048.js.map +1 -1
- package/lib/module/games/game-2048/Game2048Constants.js +1 -263
- package/lib/module/games/game-2048/Game2048Constants.js.map +1 -1
- package/lib/module/games/game-2048/Game2048Service.js +1 -457
- package/lib/module/games/game-2048/Game2048Store.js +1 -236
- package/lib/module/games/game-2048/components/GameBackground.js +1 -247
- package/lib/module/games/game-2048/components/GameGrid.js +1 -139
- package/lib/module/games/game-2048/components/GameTile.js +1 -72
- package/lib/module/games/game-2048/components/ScoreBoard.js +1 -52
- package/lib/module/games/game-2048/components/index.js +1 -7
- package/lib/module/games/maze-runner/MazeRunner.js +1 -267
- package/lib/module/games/maze-runner/MazeRunner.js.map +1 -1
- package/lib/module/games/maze-runner/MazeRunnerConstants.js +1 -100
- package/lib/module/games/maze-runner/MazeRunnerConstants.js.map +1 -1
- package/lib/module/games/maze-runner/MazeRunnerService.js +1 -586
- package/lib/module/games/maze-runner/components/EnhancedBallComponent.js +1 -150
- package/lib/module/games/maze-runner/components/EnhancedGameArea.js +1 -370
- package/lib/module/games/maze-runner/components/GameBackground.js +1 -175
- package/lib/module/games/maze-runner/components/ScoreBoard.js +1 -61
- package/lib/module/games/maze-runner/components/SkiaPipeComponent.js +1 -209
- package/lib/module/games/maze-runner/components/StaticGameBackground.js +1 -169
- package/lib/module/games/maze-runner/components/WallComponent.js +1 -91
- package/lib/module/games/maze-runner/components/index.js +1 -8
- package/lib/module/games/perfect-circle/PerfectCircle.js +1 -0
- package/lib/module/games/perfect-circle/PerfectCircle.js.map +1 -0
- package/lib/module/games/perfect-circle/PerfectCircleConstants.js +1 -0
- package/lib/module/games/perfect-circle/PerfectCircleConstants.js.map +1 -0
- package/lib/module/games/perfect-circle/PerfectCircleService.js +1 -0
- package/lib/module/games/perfect-circle/PerfectCircleService.js.map +1 -0
- package/lib/module/games/perfect-circle/PerfectCircleStore.js +1 -0
- package/lib/module/games/perfect-circle/PerfectCircleStore.js.map +1 -0
- package/lib/module/games/perfect-circle/components/DrawingCanvas.js +1 -0
- package/lib/module/games/perfect-circle/components/DrawingCanvas.js.map +1 -0
- package/lib/module/games/perfect-circle/components/GameBackground.js +1 -0
- package/lib/module/games/perfect-circle/components/GameBackground.js.map +1 -0
- package/lib/module/games/perfect-circle/components/ScoreBoard.js +1 -0
- package/lib/module/games/perfect-circle/components/ScoreBoard.js.map +1 -0
- package/lib/module/games/perfect-circle/index.js +1 -0
- package/lib/module/games/perfect-circle/index.js.map +1 -0
- package/lib/module/games/popit-fidget/PopitFidget.js +1 -285
- package/lib/module/games/popit-fidget/PopitFidget.js.map +1 -1
- package/lib/module/games/popit-fidget/PopitFidgetConstants.js +1 -113
- package/lib/module/games/popit-fidget/PopitFidgetConstants.js.map +1 -1
- package/lib/module/games/popit-fidget/PopitFidgetService.js +1 -132
- package/lib/module/games/popit-fidget/PopitFidgetStore.js +1 -125
- package/lib/module/games/popit-fidget/components/BubbleComponent.js +1 -198
- package/lib/module/games/popit-fidget/components/FidgetGrid.js +1 -165
- package/lib/module/games/popit-fidget/components/GameBackground.js +1 -177
- package/lib/module/games/popit-fidget/components/ScoreBoard.js +1 -61
- package/lib/module/games/popit-fidget/components/index.js +1 -7
- package/lib/module/games/sliding-numbers/SlidingNumbers.js +1 -159
- package/lib/module/games/sliding-numbers/SlidingNumbers.js.map +1 -1
- package/lib/module/games/sliding-numbers/SlidingNumbersConstants.js +1 -207
- package/lib/module/games/sliding-numbers/SlidingNumbersConstants.js.map +1 -1
- package/lib/module/games/sliding-numbers/SlidingNumbersService.js +1 -248
- package/lib/module/games/sliding-numbers/SlidingNumbersStore.js +1 -274
- package/lib/module/games/sliding-numbers/components/GameBackground.js +1 -259
- package/lib/module/games/sliding-numbers/components/NumbersGrid.js +1 -174
- package/lib/module/games/sliding-numbers/components/NumbersTile.js +1 -116
- package/lib/module/games/sliding-numbers/components/ScoreBoard.js +1 -64
- package/lib/module/games/sliding-numbers/components/index.js +1 -7
- package/lib/module/games/snake/Snake.js +1 -189
- package/lib/module/games/snake/Snake.js.map +1 -1
- package/lib/module/games/snake/SnakeConstants.js +1 -138
- package/lib/module/games/snake/SnakeConstants.js.map +1 -1
- package/lib/module/games/snake/SnakeService.js +1 -148
- package/lib/module/games/snake/SnakeStore.js +1 -182
- package/lib/module/games/snake/SnakeStore.js.map +1 -1
- package/lib/module/games/snake/components/GameBackground.js +1 -221
- package/lib/module/games/snake/components/GameGrid.js +1 -153
- package/lib/module/games/snake/components/ScoreBoard.js +1 -51
- package/lib/module/games/snake/components/ScoreBoard.js.map +1 -1
- package/lib/module/games/snake/components/index.js +1 -6
- package/lib/module/games/snake/index.js +1 -6
- package/lib/module/games/space-fighter/SpaceFighter.js +1 -165
- package/lib/module/games/space-fighter/SpaceFighter.js.map +1 -1
- package/lib/module/games/space-fighter/SpaceFighterConstants.js +1 -108
- package/lib/module/games/space-fighter/SpaceFighterConstants.js.map +1 -1
- package/lib/module/games/space-fighter/SpaceFighterService.js +1 -326
- package/lib/module/games/space-fighter/SpaceFighterStore.js +1 -209
- package/lib/module/games/space-fighter/components/AsteroidComponent.js +1 -113
- package/lib/module/games/space-fighter/components/GameArea.js +1 -289
- package/lib/module/games/space-fighter/components/GameBackground.js +1 -239
- package/lib/module/games/space-fighter/components/ScoreBoard.js +1 -136
- package/lib/module/games/space-fighter/components/Spacecraft3D.js +1 -202
- package/lib/module/games/space-fighter/components/SpacecraftPath.js +1 -52
- package/lib/module/games/space-fighter/components/index.js +1 -9
- package/lib/module/games/whack-a-mole/WhackAMole.js +1 -270
- package/lib/module/games/whack-a-mole/WhackAMole.js.map +1 -1
- package/lib/module/games/whack-a-mole/WhackAMoleConstants.js +1 -115
- package/lib/module/games/whack-a-mole/WhackAMoleConstants.js.map +1 -1
- package/lib/module/games/whack-a-mole/WhackAMoleService.js +1 -120
- package/lib/module/games/whack-a-mole/WhackAMoleStore.js +1 -172
- package/lib/module/games/whack-a-mole/components/GameBackground.js +1 -477
- package/lib/module/games/whack-a-mole/components/GameGrid.js +1 -97
- package/lib/module/games/whack-a-mole/components/GameHole.js +1 -196
- package/lib/module/games/whack-a-mole/components/MoleCharacter.js +1 -241
- package/lib/module/games/whack-a-mole/components/ScoreBoard.js +1 -67
- package/lib/module/games/whack-a-mole/components/ScoreBoard.js.map +1 -1
- package/lib/module/games/whack-a-mole/components/index.js +1 -8
- package/lib/module/helpers/AnimationFrame.js +1 -120
- package/lib/module/helpers/AnimationTracker.js +1 -89
- package/lib/module/helpers/ErrorHandler.js +1 -269
- package/lib/module/helpers/GameControlButton.js +1 -219
- package/lib/module/helpers/GameOverModal.js +1 -144
- package/lib/module/helpers/GameOverModal.js.map +1 -1
- package/lib/module/helpers/GameSettingsModal.js +1 -287
- package/lib/module/helpers/GameSettingsModal.js.map +1 -1
- package/lib/module/helpers/ParticleBlast.js +1 -134
- package/lib/module/helpers/ScoreBoardContainer.js +1 -34
- package/lib/module/helpers/ScoreBoardContainer.js.map +1 -1
- package/lib/module/helpers/index.js +1 -12
- package/lib/module/index.js +1 -22
- package/lib/module/index.js.map +1 -1
- package/lib/module/services/GamesConstants.js +1 -178
- package/lib/module/services/GamesConstants.js.map +1 -1
- package/lib/module/services/GamesService.js +1 -112
- package/lib/module/services/GamesService.js.map +1 -1
- package/lib/module/services/HapticsService.js +1 -77
- package/lib/module/services/ScoringService.js +1 -0
- package/lib/module/services/ScoringService.js.map +1 -0
- package/lib/module/services/SoundsService.js +1 -302
- package/lib/module/services/SoundsService.js.map +1 -1
- package/lib/module/services/UtilsService.js +1 -32
- package/lib/module/services/UtilsService.js.map +1 -1
- package/lib/typescript/src/games/balloon-blaster/BalloonBlaster.d.ts.map +1 -1
- package/lib/typescript/src/games/balloon-blaster/BalloonBlasterConstants.d.ts +1 -1
- package/lib/typescript/src/games/balloon-blaster/components/ScoreBoard.d.ts.map +1 -1
- package/lib/typescript/src/games/bike-racing/BikeRacing.d.ts +4 -0
- package/lib/typescript/src/games/bike-racing/BikeRacing.d.ts.map +1 -0
- package/lib/typescript/src/games/bike-racing/BikeRacingConstants.d.ts +76 -0
- package/lib/typescript/src/games/bike-racing/BikeRacingConstants.d.ts.map +1 -0
- package/lib/typescript/src/games/bike-racing/BikeRacingService.d.ts +22 -0
- package/lib/typescript/src/games/bike-racing/BikeRacingService.d.ts.map +1 -0
- package/lib/typescript/src/games/bike-racing/BikeRacingStore.d.ts +72 -0
- package/lib/typescript/src/games/bike-racing/BikeRacingStore.d.ts.map +1 -0
- package/lib/typescript/src/games/bike-racing/components/BikeComponent.d.ts +12 -0
- package/lib/typescript/src/games/bike-racing/components/BikeComponent.d.ts.map +1 -0
- package/lib/typescript/src/games/bike-racing/components/GameBackground.d.ts +9 -0
- package/lib/typescript/src/games/bike-racing/components/GameBackground.d.ts.map +1 -0
- package/lib/typescript/src/games/bike-racing/components/ScoreBoard.d.ts +7 -0
- package/lib/typescript/src/games/bike-racing/components/ScoreBoard.d.ts.map +1 -0
- package/lib/typescript/src/games/bike-racing/components/index.d.ts +4 -0
- package/lib/typescript/src/games/bike-racing/components/index.d.ts.map +1 -0
- package/lib/typescript/src/games/bike-racing/index.d.ts +5 -0
- package/lib/typescript/src/games/bike-racing/index.d.ts.map +1 -0
- package/lib/typescript/src/games/block-blast/BlockBlast.d.ts +4 -0
- package/lib/typescript/src/games/block-blast/BlockBlast.d.ts.map +1 -0
- package/lib/typescript/src/games/block-blast/BlockBlastConstants.d.ts +82 -0
- package/lib/typescript/src/games/block-blast/BlockBlastConstants.d.ts.map +1 -0
- package/lib/typescript/src/games/block-blast/BlockBlastService.d.ts +17 -0
- package/lib/typescript/src/games/block-blast/BlockBlastService.d.ts.map +1 -0
- package/lib/typescript/src/games/block-blast/BlockBlastStore.d.ts +62 -0
- package/lib/typescript/src/games/block-blast/BlockBlastStore.d.ts.map +1 -0
- package/lib/typescript/src/games/block-blast/components/BlockPieceComponent.d.ts +14 -0
- package/lib/typescript/src/games/block-blast/components/BlockPieceComponent.d.ts.map +1 -0
- package/lib/typescript/src/games/block-blast/components/GameArea.d.ts +12 -0
- package/lib/typescript/src/games/block-blast/components/GameArea.d.ts.map +1 -0
- package/lib/typescript/src/games/block-blast/components/GameBackground.d.ts +7 -0
- package/lib/typescript/src/games/block-blast/components/GameBackground.d.ts.map +1 -0
- package/lib/typescript/src/games/block-blast/components/GridComponent.d.ts +17 -0
- package/lib/typescript/src/games/block-blast/components/GridComponent.d.ts.map +1 -0
- package/lib/typescript/src/games/block-blast/components/ScoreBoard.d.ts +7 -0
- package/lib/typescript/src/games/block-blast/components/ScoreBoard.d.ts.map +1 -0
- package/lib/typescript/src/games/block-blast/components/index.d.ts +6 -0
- package/lib/typescript/src/games/block-blast/components/index.d.ts.map +1 -0
- package/lib/typescript/src/games/block-blast/index.d.ts +5 -0
- package/lib/typescript/src/games/block-blast/index.d.ts.map +1 -0
- package/lib/typescript/src/games/bubble-shooter/BubbleShooter.d.ts +4 -0
- package/lib/typescript/src/games/bubble-shooter/BubbleShooter.d.ts.map +1 -0
- package/lib/typescript/src/games/bubble-shooter/BubbleShooterConstants.d.ts +61 -0
- package/lib/typescript/src/games/bubble-shooter/BubbleShooterConstants.d.ts.map +1 -0
- package/lib/typescript/src/games/bubble-shooter/BubbleShooterService.d.ts +26 -0
- package/lib/typescript/src/games/bubble-shooter/BubbleShooterService.d.ts.map +1 -0
- package/lib/typescript/src/games/bubble-shooter/BubbleShooterStore.d.ts +62 -0
- package/lib/typescript/src/games/bubble-shooter/BubbleShooterStore.d.ts.map +1 -0
- package/lib/typescript/src/games/bubble-shooter/components/GameArea.d.ts +9 -0
- package/lib/typescript/src/games/bubble-shooter/components/GameArea.d.ts.map +1 -0
- package/lib/typescript/src/games/bubble-shooter/components/GameBackground.d.ts +8 -0
- package/lib/typescript/src/games/bubble-shooter/components/GameBackground.d.ts.map +1 -0
- package/lib/typescript/src/games/bubble-shooter/components/ScoreBoard.d.ts +7 -0
- package/lib/typescript/src/games/bubble-shooter/components/ScoreBoard.d.ts.map +1 -0
- package/lib/typescript/src/games/bubble-shooter/components/index.d.ts +4 -0
- package/lib/typescript/src/games/bubble-shooter/components/index.d.ts.map +1 -0
- package/lib/typescript/src/games/bubble-shooter/index.d.ts +3 -0
- package/lib/typescript/src/games/bubble-shooter/index.d.ts.map +1 -0
- package/lib/typescript/src/games/candy-crush/CandyCrush.d.ts.map +1 -1
- package/lib/typescript/src/games/candy-crush/CandyCrushConstants.d.ts +7 -7
- package/lib/typescript/src/games/car-racing/CarRacing.d.ts +4 -0
- package/lib/typescript/src/games/car-racing/CarRacing.d.ts.map +1 -0
- package/lib/typescript/src/games/car-racing/CarRacingConstants.d.ts +76 -0
- package/lib/typescript/src/games/car-racing/CarRacingConstants.d.ts.map +1 -0
- package/lib/typescript/src/games/car-racing/CarRacingService.d.ts +22 -0
- package/lib/typescript/src/games/car-racing/CarRacingService.d.ts.map +1 -0
- package/lib/typescript/src/games/car-racing/CarRacingStore.d.ts +72 -0
- package/lib/typescript/src/games/car-racing/CarRacingStore.d.ts.map +1 -0
- package/lib/typescript/src/games/car-racing/components/CarComponent.d.ts +13 -0
- package/lib/typescript/src/games/car-racing/components/CarComponent.d.ts.map +1 -0
- package/lib/typescript/src/games/car-racing/components/GameBackground.d.ts +9 -0
- package/lib/typescript/src/games/car-racing/components/GameBackground.d.ts.map +1 -0
- package/lib/typescript/src/games/car-racing/components/ScoreBoard.d.ts +7 -0
- package/lib/typescript/src/games/car-racing/components/ScoreBoard.d.ts.map +1 -0
- package/lib/typescript/src/games/car-racing/components/index.d.ts +4 -0
- package/lib/typescript/src/games/car-racing/components/index.d.ts.map +1 -0
- package/lib/typescript/src/games/colors-sort/ColorsSort.d.ts.map +1 -1
- package/lib/typescript/src/games/colors-sort/ColorsSortStore.d.ts.map +1 -1
- package/lib/typescript/src/games/dino-jump/DinoJump.d.ts.map +1 -1
- package/lib/typescript/src/games/dino-jump/components/DinoSprite.d.ts.map +1 -1
- package/lib/typescript/src/games/flappy-bird/FlappyBird.d.ts.map +1 -1
- package/lib/typescript/src/games/flappy-bird/FlappyBirdConstants.d.ts.map +1 -1
- package/lib/typescript/src/games/fruit-merger/FruitMerger.d.ts.map +1 -1
- package/lib/typescript/src/games/fruit-merger/FruitMergerConstants.d.ts.map +1 -1
- package/lib/typescript/src/games/fruit-ninja/FruitNinja.d.ts.map +1 -1
- package/lib/typescript/src/games/fruit-ninja/components/ScoreBoard.d.ts.map +1 -1
- package/lib/typescript/src/games/game-2048/Game2048.d.ts.map +1 -1
- package/lib/typescript/src/games/maze-runner/MazeRunner.d.ts.map +1 -1
- package/lib/typescript/src/games/perfect-circle/PerfectCircle.d.ts +4 -0
- package/lib/typescript/src/games/perfect-circle/PerfectCircle.d.ts.map +1 -0
- package/lib/typescript/src/games/perfect-circle/PerfectCircleConstants.d.ts +81 -0
- package/lib/typescript/src/games/perfect-circle/PerfectCircleConstants.d.ts.map +1 -0
- package/lib/typescript/src/games/perfect-circle/PerfectCircleService.d.ts +14 -0
- package/lib/typescript/src/games/perfect-circle/PerfectCircleService.d.ts.map +1 -0
- package/lib/typescript/src/games/perfect-circle/PerfectCircleStore.d.ts +40 -0
- package/lib/typescript/src/games/perfect-circle/PerfectCircleStore.d.ts.map +1 -0
- package/lib/typescript/src/games/perfect-circle/components/DrawingCanvas.d.ts +9 -0
- package/lib/typescript/src/games/perfect-circle/components/DrawingCanvas.d.ts.map +1 -0
- package/lib/typescript/src/games/perfect-circle/components/GameBackground.d.ts +8 -0
- package/lib/typescript/src/games/perfect-circle/components/GameBackground.d.ts.map +1 -0
- package/lib/typescript/src/games/perfect-circle/components/ScoreBoard.d.ts +7 -0
- package/lib/typescript/src/games/perfect-circle/components/ScoreBoard.d.ts.map +1 -0
- package/lib/typescript/src/games/perfect-circle/index.d.ts +3 -0
- package/lib/typescript/src/games/perfect-circle/index.d.ts.map +1 -0
- package/lib/typescript/src/games/popit-fidget/PopitFidget.d.ts.map +1 -1
- package/lib/typescript/src/games/sliding-numbers/SlidingNumbers.d.ts.map +1 -1
- package/lib/typescript/src/games/snake/Snake.d.ts.map +1 -1
- package/lib/typescript/src/games/snake/SnakeStore.d.ts +4 -0
- package/lib/typescript/src/games/snake/SnakeStore.d.ts.map +1 -1
- package/lib/typescript/src/games/snake/components/ScoreBoard.d.ts.map +1 -1
- package/lib/typescript/src/games/space-fighter/SpaceFighter.d.ts.map +1 -1
- package/lib/typescript/src/games/whack-a-mole/WhackAMole.d.ts.map +1 -1
- package/lib/typescript/src/games/whack-a-mole/WhackAMoleConstants.d.ts +1 -1
- package/lib/typescript/src/games/whack-a-mole/components/ScoreBoard.d.ts.map +1 -1
- package/lib/typescript/src/helpers/GameOverModal.d.ts +3 -0
- package/lib/typescript/src/helpers/GameOverModal.d.ts.map +1 -1
- package/lib/typescript/src/helpers/ScoreBoardContainer.d.ts.map +1 -1
- package/lib/typescript/src/index.d.ts +6 -1
- package/lib/typescript/src/index.d.ts.map +1 -1
- package/lib/typescript/src/services/GamesConstants.d.ts +57 -7
- package/lib/typescript/src/services/GamesConstants.d.ts.map +1 -1
- package/lib/typescript/src/services/GamesService.d.ts +2 -1
- package/lib/typescript/src/services/GamesService.d.ts.map +1 -1
- package/lib/typescript/src/services/ScoringService.d.ts +2 -0
- package/lib/typescript/src/services/ScoringService.d.ts.map +1 -0
- package/lib/typescript/src/services/SoundsService.d.ts +88 -0
- package/lib/typescript/src/services/SoundsService.d.ts.map +1 -1
- package/lib/typescript/src/services/UtilsService.d.ts +12 -1
- package/lib/typescript/src/services/UtilsService.d.ts.map +1 -1
- package/package.json +2 -2
|
@@ -1,174 +1 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
import React, { useMemo } from 'react';
|
|
4
|
-
import { View, StyleSheet, Dimensions } from 'react-native';
|
|
5
|
-
import Animated, { useAnimatedStyle, withSpring, useSharedValue, withSequence } from 'react-native-reanimated';
|
|
6
|
-
import { NumbersTile } from "./NumbersTile.js";
|
|
7
|
-
import { useTiles, useGridSize, useEmptyPosition, useSlidingNumbersStore } from "../SlidingNumbersStore.js";
|
|
8
|
-
import { SLIDING_NUMBERS_GAME_CONFIG, SLIDING_NUMBERS_ANIMATION_CONFIG } from "../SlidingNumbersConstants.js";
|
|
9
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
10
|
-
export const NumbersGrid = /*#__PURE__*/React.memo(({
|
|
11
|
-
difficulty
|
|
12
|
-
}) => {
|
|
13
|
-
const tiles = useTiles();
|
|
14
|
-
const gridSize = useGridSize();
|
|
15
|
-
const emptyPosition = useEmptyPosition();
|
|
16
|
-
const isPlaying = useSlidingNumbersStore(state => state.isPlaying);
|
|
17
|
-
const isCompleted = useSlidingNumbersStore(state => state.isCompleted);
|
|
18
|
-
const moveTile = useSlidingNumbersStore(state => state.moveTile);
|
|
19
|
-
const checkCompletion = useSlidingNumbersStore(state => state.checkCompletion);
|
|
20
|
-
const completionScale = useSharedValue(1);
|
|
21
|
-
|
|
22
|
-
// Calculate grid dimensions
|
|
23
|
-
const gridDimensions = useMemo(() => {
|
|
24
|
-
const gap = SLIDING_NUMBERS_GAME_CONFIG.TILE_GAP;
|
|
25
|
-
const padding = (gap + 8) * 2; // padding from grid container
|
|
26
|
-
|
|
27
|
-
// Calculate available space for the grid content
|
|
28
|
-
const {
|
|
29
|
-
width: screenWidth
|
|
30
|
-
} = Dimensions.get('window');
|
|
31
|
-
const maxAvailableWidth = screenWidth - padding - 40; // Leave margin for screen edges
|
|
32
|
-
|
|
33
|
-
// Calculate optimal tile size based on grid size
|
|
34
|
-
const availableForTiles = maxAvailableWidth - gap * (gridSize - 1);
|
|
35
|
-
const optimalTileSize = Math.floor(availableForTiles / gridSize);
|
|
36
|
-
|
|
37
|
-
// Ensure minimum tile size for usability
|
|
38
|
-
const minTileSize = 45;
|
|
39
|
-
const maxTileSize = 80;
|
|
40
|
-
const tileSize = Math.max(minTileSize, Math.min(maxTileSize, optimalTileSize));
|
|
41
|
-
|
|
42
|
-
// Calculate actual content size: tiles + gaps between them
|
|
43
|
-
const tilesWidth = tileSize * gridSize;
|
|
44
|
-
const gapsWidth = gap * (gridSize - 1);
|
|
45
|
-
const contentSize = tilesWidth + gapsWidth;
|
|
46
|
-
const totalSize = contentSize + padding;
|
|
47
|
-
return {
|
|
48
|
-
width: totalSize,
|
|
49
|
-
height: totalSize,
|
|
50
|
-
contentWidth: contentSize,
|
|
51
|
-
contentHeight: contentSize,
|
|
52
|
-
tileSize,
|
|
53
|
-
gap
|
|
54
|
-
};
|
|
55
|
-
}, [gridSize]);
|
|
56
|
-
|
|
57
|
-
// Create grid layout
|
|
58
|
-
const gridLayout = useMemo(() => {
|
|
59
|
-
const layout = [];
|
|
60
|
-
|
|
61
|
-
// Initialize empty grid
|
|
62
|
-
for (let row = 0; row < gridSize; row++) {
|
|
63
|
-
layout[row] = [];
|
|
64
|
-
for (let col = 0; col < gridSize; col++) {
|
|
65
|
-
const rowArray = layout[row];
|
|
66
|
-
if (rowArray) {
|
|
67
|
-
rowArray[col] = null;
|
|
68
|
-
}
|
|
69
|
-
}
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
// Place tiles in their current positions
|
|
73
|
-
tiles.forEach(tile => {
|
|
74
|
-
const {
|
|
75
|
-
row,
|
|
76
|
-
col
|
|
77
|
-
} = tile.position;
|
|
78
|
-
if (row >= 0 && row < gridSize && col >= 0 && col < gridSize && layout[row]) {
|
|
79
|
-
layout[row][col] = tile;
|
|
80
|
-
}
|
|
81
|
-
});
|
|
82
|
-
return layout;
|
|
83
|
-
}, [tiles, gridSize]);
|
|
84
|
-
|
|
85
|
-
// Memoized tile press handler with useCallback
|
|
86
|
-
const handleTilePress = React.useCallback(tileId => {
|
|
87
|
-
if (!isPlaying || isCompleted) return;
|
|
88
|
-
const success = moveTile(tileId);
|
|
89
|
-
if (success) {
|
|
90
|
-
// Check completion after successful move
|
|
91
|
-
checkCompletion(difficulty);
|
|
92
|
-
}
|
|
93
|
-
}, [isPlaying, isCompleted, moveTile, checkCompletion, difficulty]);
|
|
94
|
-
|
|
95
|
-
// Memoized tile movability checker with useCallback
|
|
96
|
-
const isTileMovable = React.useCallback(tile => {
|
|
97
|
-
if (!tile || tile.value === 0 || !isPlaying || isCompleted) return false;
|
|
98
|
-
const emptyPos = emptyPosition;
|
|
99
|
-
const rowDiff = Math.abs(tile.position.row - emptyPos.row);
|
|
100
|
-
const colDiff = Math.abs(tile.position.col - emptyPos.col);
|
|
101
|
-
return rowDiff === 1 && colDiff === 0 || rowDiff === 0 && colDiff === 1;
|
|
102
|
-
}, [emptyPosition, isPlaying, isCompleted]);
|
|
103
|
-
|
|
104
|
-
// Animated style for completion celebration
|
|
105
|
-
const animatedGridStyle = useAnimatedStyle(() => ({
|
|
106
|
-
transform: [{
|
|
107
|
-
scale: completionScale.value
|
|
108
|
-
}]
|
|
109
|
-
}));
|
|
110
|
-
|
|
111
|
-
// Trigger completion animation
|
|
112
|
-
React.useEffect(() => {
|
|
113
|
-
if (isCompleted) {
|
|
114
|
-
completionScale.value = withSequence(withSpring(1.1, SLIDING_NUMBERS_ANIMATION_CONFIG.COMPLETION_CELEBRATION), withSpring(1, SLIDING_NUMBERS_ANIMATION_CONFIG.COMPLETION_CELEBRATION));
|
|
115
|
-
}
|
|
116
|
-
}, [isCompleted]);
|
|
117
|
-
|
|
118
|
-
// Memoize grid container style
|
|
119
|
-
const gridContainerStyle = useMemo(() => [styles.gridContainer, {
|
|
120
|
-
width: gridDimensions.width,
|
|
121
|
-
height: gridDimensions.height
|
|
122
|
-
}, animatedGridStyle], [gridDimensions.width, gridDimensions.height, animatedGridStyle]);
|
|
123
|
-
|
|
124
|
-
// Memoize tile slot style factory
|
|
125
|
-
const getTileSlotStyle = React.useCallback(tileSize => [styles.tileSlot, {
|
|
126
|
-
width: tileSize,
|
|
127
|
-
height: tileSize
|
|
128
|
-
}], []);
|
|
129
|
-
return /*#__PURE__*/_jsx(Animated.View, {
|
|
130
|
-
style: gridContainerStyle,
|
|
131
|
-
children: gridLayout.map((row, rowIndex) => /*#__PURE__*/_jsx(View, {
|
|
132
|
-
style: styles.row,
|
|
133
|
-
children: row.map((tile, colIndex) => /*#__PURE__*/_jsx(View, {
|
|
134
|
-
style: getTileSlotStyle(gridDimensions.tileSize),
|
|
135
|
-
children: tile && tile.value !== 0 && /*#__PURE__*/_jsx(NumbersTile, {
|
|
136
|
-
tile: tile,
|
|
137
|
-
onPress: handleTilePress,
|
|
138
|
-
isMovable: isTileMovable(tile),
|
|
139
|
-
tileSize: gridDimensions.tileSize
|
|
140
|
-
})
|
|
141
|
-
}, `${rowIndex}-${colIndex}`))
|
|
142
|
-
}, rowIndex))
|
|
143
|
-
});
|
|
144
|
-
});
|
|
145
|
-
const styles = StyleSheet.create({
|
|
146
|
-
gridContainer: {
|
|
147
|
-
backgroundColor: '#FFFFFF',
|
|
148
|
-
borderRadius: 20,
|
|
149
|
-
padding: SLIDING_NUMBERS_GAME_CONFIG.TILE_GAP + 8,
|
|
150
|
-
// Clean shadow like the physical puzzle frame
|
|
151
|
-
shadowColor: '#000',
|
|
152
|
-
shadowOffset: {
|
|
153
|
-
width: 0,
|
|
154
|
-
height: 4
|
|
155
|
-
},
|
|
156
|
-
shadowOpacity: 0.1,
|
|
157
|
-
shadowRadius: 8,
|
|
158
|
-
elevation: 8,
|
|
159
|
-
// Ensure the container fits its content properly
|
|
160
|
-
alignSelf: 'center'
|
|
161
|
-
},
|
|
162
|
-
row: {
|
|
163
|
-
flexDirection: 'row',
|
|
164
|
-
justifyContent: 'center',
|
|
165
|
-
alignItems: 'center'
|
|
166
|
-
},
|
|
167
|
-
tileSlot: {
|
|
168
|
-
justifyContent: 'center',
|
|
169
|
-
alignItems: 'center',
|
|
170
|
-
margin: SLIDING_NUMBERS_GAME_CONFIG.TILE_GAP / 2
|
|
171
|
-
}
|
|
172
|
-
});
|
|
173
|
-
NumbersGrid.displayName = 'NumbersGrid';
|
|
174
|
-
//# sourceMappingURL=NumbersGrid.js.map
|
|
1
|
+
"use strict";import React,{useMemo}from 'react';import{View,StyleSheet,Dimensions}from 'react-native';import Animated,{useAnimatedStyle,withSpring,useSharedValue,withSequence}from 'react-native-reanimated';import{NumbersTile}from "./NumbersTile.js";import{useTiles,useGridSize,useEmptyPosition,useSlidingNumbersStore}from "../SlidingNumbersStore.js";import{SLIDING_NUMBERS_GAME_CONFIG,SLIDING_NUMBERS_ANIMATION_CONFIG}from "../SlidingNumbersConstants.js";import{jsx as _jsx}from "react/jsx-runtime";export const NumbersGrid = React.memo(({difficulty})=>{const tiles = useTiles();const gridSize = useGridSize();const emptyPosition = useEmptyPosition();const isPlaying = useSlidingNumbersStore(state => state.isPlaying);const isCompleted = useSlidingNumbersStore(state => state.isCompleted);const moveTile = useSlidingNumbersStore(state => state.moveTile);const checkCompletion = useSlidingNumbersStore(state => state.checkCompletion);const completionScale = useSharedValue(1);const gridDimensions = useMemo(()=>{const gap = SLIDING_NUMBERS_GAME_CONFIG.TILE_GAP;const padding =(gap + 8)* 2;const{width:screenWidth}= Dimensions.get('window');const maxAvailableWidth = screenWidth - padding - 40;const availableForTiles = maxAvailableWidth - gap *(gridSize - 1);const optimalTileSize = Math.floor(availableForTiles / gridSize);const minTileSize = 45;const maxTileSize = 80;const tileSize = Math.max(minTileSize,Math.min(maxTileSize,optimalTileSize));const tilesWidth = tileSize * gridSize;const gapsWidth = gap *(gridSize - 1);const contentSize = tilesWidth + gapsWidth;const totalSize = contentSize + padding;return{width:totalSize,height:totalSize,contentWidth:contentSize,contentHeight:contentSize,tileSize,gap};},[gridSize]);const gridLayout = useMemo(()=>{const layout = [];for(let row = 0;row < gridSize;row++){layout[row] = [];for(let col = 0;col < gridSize;col++){const rowArray = layout[row];if(rowArray){rowArray[col] = null;}}}tiles.forEach(tile =>{const{row,col}= tile.position;if(row >= 0 && row < gridSize && col >= 0 && col < gridSize && layout[row]){layout[row][col] = tile;}});return layout;},[tiles,gridSize]);const handleTilePress = React.useCallback(tileId =>{if(!isPlaying || isCompleted)return;const success = moveTile(tileId);if(success){checkCompletion(difficulty);}},[isPlaying,isCompleted,moveTile,checkCompletion,difficulty]);const isTileMovable = React.useCallback(tile =>{if(!tile || tile.value === 0 || !isPlaying || isCompleted)return false;const emptyPos = emptyPosition;const rowDiff = Math.abs(tile.position.row - emptyPos.row);const colDiff = Math.abs(tile.position.col - emptyPos.col);return rowDiff === 1 && colDiff === 0 || rowDiff === 0 && colDiff === 1;},[emptyPosition,isPlaying,isCompleted]);const animatedGridStyle = useAnimatedStyle(()=>({transform:[{scale:completionScale.value}]}));React.useEffect(()=>{if(isCompleted){completionScale.value = withSequence(withSpring(1.1,SLIDING_NUMBERS_ANIMATION_CONFIG.COMPLETION_CELEBRATION),withSpring(1,SLIDING_NUMBERS_ANIMATION_CONFIG.COMPLETION_CELEBRATION));}},[isCompleted]);const gridContainerStyle = useMemo(()=> [styles.gridContainer,{width:gridDimensions.width,height:gridDimensions.height},animatedGridStyle],[gridDimensions.width,gridDimensions.height,animatedGridStyle]);const getTileSlotStyle = React.useCallback(tileSize => [styles.tileSlot,{width:tileSize,height:tileSize}],[]);return _jsx(Animated.View,{style:gridContainerStyle,children:gridLayout.map((row,rowIndex)=> _jsx(View,{style:styles.row,children:row.map((tile,colIndex)=> _jsx(View,{style:getTileSlotStyle(gridDimensions.tileSize),children:tile && tile.value !== 0 && _jsx(NumbersTile,{tile:tile,onPress:handleTilePress,isMovable:isTileMovable(tile),tileSize:gridDimensions.tileSize})},`${rowIndex}-${colIndex}`))},rowIndex))});});const styles = StyleSheet.create({gridContainer:{backgroundColor:'#FFFFFF',borderRadius:20,padding:SLIDING_NUMBERS_GAME_CONFIG.TILE_GAP + 8,shadowColor:'#000',shadowOffset:{width:0,height:4},shadowOpacity:0.1,shadowRadius:8,elevation:8,alignSelf:'center'},row:{flexDirection:'row',justifyContent:'center',alignItems:'center'},tileSlot:{justifyContent:'center',alignItems:'center',margin:SLIDING_NUMBERS_GAME_CONFIG.TILE_GAP / 2}});NumbersGrid.displayName = 'NumbersGrid';
|
|
@@ -1,116 +1 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
import React from 'react';
|
|
4
|
-
import { StyleSheet, TouchableOpacity, Text } from 'react-native';
|
|
5
|
-
import Animated, { useSharedValue, useAnimatedStyle, withSpring, runOnJS } from 'react-native-reanimated';
|
|
6
|
-
import { SLIDING_NUMBERS_COLORS, SLIDING_NUMBERS_GAME_CONFIG, SLIDING_NUMBERS_ANIMATION_CONFIG, NUMBER_WORDS } from "../SlidingNumbersConstants.js";
|
|
7
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
8
|
-
const AnimatedTouchableOpacity = Animated.createAnimatedComponent(TouchableOpacity);
|
|
9
|
-
export const NumbersTile = /*#__PURE__*/React.memo(({
|
|
10
|
-
tile,
|
|
11
|
-
onPress,
|
|
12
|
-
isMovable,
|
|
13
|
-
tileSize
|
|
14
|
-
}) => {
|
|
15
|
-
const scale = useSharedValue(1);
|
|
16
|
-
const opacity = useSharedValue(tile.value === 0 ? 0 : 1);
|
|
17
|
-
const handlePress = React.useCallback(() => {
|
|
18
|
-
if (tile.value !== 0 && isMovable) {
|
|
19
|
-
// Animate press feedback
|
|
20
|
-
scale.value = withSpring(0.95, SLIDING_NUMBERS_ANIMATION_CONFIG.TILE_PRESS, () => {
|
|
21
|
-
scale.value = withSpring(1, SLIDING_NUMBERS_ANIMATION_CONFIG.TILE_PRESS);
|
|
22
|
-
});
|
|
23
|
-
runOnJS(onPress)(tile.id);
|
|
24
|
-
}
|
|
25
|
-
}, [tile.value, tile.id, isMovable, onPress, scale]);
|
|
26
|
-
const animatedStyle = useAnimatedStyle(() => ({
|
|
27
|
-
transform: [{
|
|
28
|
-
scale: scale.value
|
|
29
|
-
}],
|
|
30
|
-
opacity: opacity.value
|
|
31
|
-
}));
|
|
32
|
-
|
|
33
|
-
// Don't render empty tile
|
|
34
|
-
if (tile.value === 0) {
|
|
35
|
-
return null;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
// Memoized tile color and word
|
|
39
|
-
const {
|
|
40
|
-
tileColor,
|
|
41
|
-
numberWord
|
|
42
|
-
} = React.useMemo(() => {
|
|
43
|
-
const colorIndex = (tile.value - 1) % SLIDING_NUMBERS_COLORS.TILE_COLORS.length;
|
|
44
|
-
const color = SLIDING_NUMBERS_COLORS.TILE_COLORS[colorIndex] || SLIDING_NUMBERS_COLORS.TILE_COLORS[0];
|
|
45
|
-
const word = NUMBER_WORDS[tile.value] || '';
|
|
46
|
-
return {
|
|
47
|
-
tileColor: color,
|
|
48
|
-
numberWord: word
|
|
49
|
-
};
|
|
50
|
-
}, [tile.value]);
|
|
51
|
-
|
|
52
|
-
// Memoized font sizes
|
|
53
|
-
const {
|
|
54
|
-
numberFontSize,
|
|
55
|
-
wordFontSize
|
|
56
|
-
} = React.useMemo(() => ({
|
|
57
|
-
numberFontSize: Math.max(16, tileSize * 0.4),
|
|
58
|
-
wordFontSize: Math.max(8, tileSize * 0.15)
|
|
59
|
-
}), [tileSize]);
|
|
60
|
-
return /*#__PURE__*/_jsxs(AnimatedTouchableOpacity, {
|
|
61
|
-
style: [styles.tile, {
|
|
62
|
-
width: tileSize,
|
|
63
|
-
height: tileSize,
|
|
64
|
-
backgroundColor: tileColor,
|
|
65
|
-
borderColor: tile.isCorrect ? 'transparent' : '#FF4444',
|
|
66
|
-
borderWidth: tile.isCorrect ? 0 : 2
|
|
67
|
-
}, animatedStyle],
|
|
68
|
-
onPress: handlePress,
|
|
69
|
-
activeOpacity: 0.8,
|
|
70
|
-
disabled: !isMovable || tile.value === 0,
|
|
71
|
-
children: [/*#__PURE__*/_jsx(Text, {
|
|
72
|
-
style: [styles.number, {
|
|
73
|
-
fontSize: numberFontSize
|
|
74
|
-
}],
|
|
75
|
-
children: tile.value
|
|
76
|
-
}), /*#__PURE__*/_jsx(Text, {
|
|
77
|
-
style: [styles.word, {
|
|
78
|
-
fontSize: wordFontSize
|
|
79
|
-
}],
|
|
80
|
-
children: numberWord
|
|
81
|
-
})]
|
|
82
|
-
});
|
|
83
|
-
}, (prevProps, nextProps) => {
|
|
84
|
-
// Custom comparison for better memoization
|
|
85
|
-
return prevProps.tile.id === nextProps.tile.id && prevProps.tile.value === nextProps.tile.value && prevProps.tile.isCorrect === nextProps.tile.isCorrect && prevProps.tile.position.row === nextProps.tile.position.row && prevProps.tile.position.col === nextProps.tile.position.col && prevProps.isMovable === nextProps.isMovable && prevProps.tileSize === nextProps.tileSize;
|
|
86
|
-
});
|
|
87
|
-
const styles = StyleSheet.create({
|
|
88
|
-
tile: {
|
|
89
|
-
margin: SLIDING_NUMBERS_GAME_CONFIG.TILE_GAP / 2,
|
|
90
|
-
justifyContent: 'center',
|
|
91
|
-
alignItems: 'center',
|
|
92
|
-
borderRadius: 16,
|
|
93
|
-
// Soft shadow like in the image
|
|
94
|
-
shadowColor: '#000',
|
|
95
|
-
shadowOffset: {
|
|
96
|
-
width: 0,
|
|
97
|
-
height: 3
|
|
98
|
-
},
|
|
99
|
-
shadowOpacity: 0.15,
|
|
100
|
-
shadowRadius: 6,
|
|
101
|
-
elevation: 6
|
|
102
|
-
},
|
|
103
|
-
number: {
|
|
104
|
-
fontWeight: 'bold',
|
|
105
|
-
color: '#000000',
|
|
106
|
-
textAlign: 'center',
|
|
107
|
-
marginBottom: 2
|
|
108
|
-
},
|
|
109
|
-
word: {
|
|
110
|
-
fontWeight: 'normal',
|
|
111
|
-
color: '#000000',
|
|
112
|
-
textAlign: 'center'
|
|
113
|
-
}
|
|
114
|
-
});
|
|
115
|
-
NumbersTile.displayName = 'NumbersTile';
|
|
116
|
-
//# sourceMappingURL=NumbersTile.js.map
|
|
1
|
+
"use strict";import React from 'react';import{StyleSheet,TouchableOpacity,Text}from 'react-native';import Animated,{useSharedValue,useAnimatedStyle,withSpring,runOnJS}from 'react-native-reanimated';import{SLIDING_NUMBERS_COLORS,SLIDING_NUMBERS_GAME_CONFIG,SLIDING_NUMBERS_ANIMATION_CONFIG,NUMBER_WORDS}from "../SlidingNumbersConstants.js";import{jsx as _jsx,jsxs as _jsxs}from "react/jsx-runtime";const AnimatedTouchableOpacity = Animated.createAnimatedComponent(TouchableOpacity);export const NumbersTile = React.memo(({tile,onPress,isMovable,tileSize})=>{const scale = useSharedValue(1);const opacity = useSharedValue(tile.value === 0 ? 0:1);const handlePress = React.useCallback(()=>{if(tile.value !== 0 && isMovable){scale.value = withSpring(0.95,SLIDING_NUMBERS_ANIMATION_CONFIG.TILE_PRESS,()=>{scale.value = withSpring(1,SLIDING_NUMBERS_ANIMATION_CONFIG.TILE_PRESS);});runOnJS(onPress)(tile.id);}},[tile.value,tile.id,isMovable,onPress,scale]);const animatedStyle = useAnimatedStyle(()=>({transform:[{scale:scale.value}],opacity:opacity.value}));if(tile.value === 0){return null;}const{tileColor,numberWord}= React.useMemo(()=>{const colorIndex =(tile.value - 1)% SLIDING_NUMBERS_COLORS.TILE_COLORS.length;const color = SLIDING_NUMBERS_COLORS.TILE_COLORS[colorIndex] || SLIDING_NUMBERS_COLORS.TILE_COLORS[0];const word = NUMBER_WORDS[tile.value] || '';return{tileColor:color,numberWord:word};},[tile.value]);const{numberFontSize,wordFontSize}= React.useMemo(()=>({numberFontSize:Math.max(16,tileSize * 0.4),wordFontSize:Math.max(8,tileSize * 0.15)}),[tileSize]);return _jsxs(AnimatedTouchableOpacity,{style:[styles.tile,{width:tileSize,height:tileSize,backgroundColor:tileColor,borderColor:tile.isCorrect ? 'transparent':'#FF4444',borderWidth:tile.isCorrect ? 0:2},animatedStyle],onPress:handlePress,activeOpacity:0.8,disabled:!isMovable || tile.value === 0,children:[_jsx(Text,{style:[styles.number,{fontSize:numberFontSize}],children:tile.value}),_jsx(Text,{style:[styles.word,{fontSize:wordFontSize}],children:numberWord})]});},(prevProps,nextProps)=>{return prevProps.tile.id === nextProps.tile.id && prevProps.tile.value === nextProps.tile.value && prevProps.tile.isCorrect === nextProps.tile.isCorrect && prevProps.tile.position.row === nextProps.tile.position.row && prevProps.tile.position.col === nextProps.tile.position.col && prevProps.isMovable === nextProps.isMovable && prevProps.tileSize === nextProps.tileSize;});const styles = StyleSheet.create({tile:{margin:SLIDING_NUMBERS_GAME_CONFIG.TILE_GAP / 2,justifyContent:'center',alignItems:'center',borderRadius:16,shadowColor:'#000',shadowOffset:{width:0,height:3},shadowOpacity:0.15,shadowRadius:6,elevation:6},number:{fontWeight:'bold',color:'#000000',textAlign:'center',marginBottom:2},word:{fontWeight:'normal',color:'#000000',textAlign:'center'}});NumbersTile.displayName = 'NumbersTile';
|
|
@@ -1,64 +1 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
import React, { useMemo } from 'react';
|
|
4
|
-
import { View, Text, StyleSheet } from 'react-native';
|
|
5
|
-
import { useTimeElapsed } from "../SlidingNumbersStore.js";
|
|
6
|
-
import { SlidingNumbersService } from "../SlidingNumbersService.js";
|
|
7
|
-
import { ScoreBoardContainer } from "../../../helpers/index.js";
|
|
8
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
9
|
-
export const ScoreBoard = /*#__PURE__*/React.memo(({
|
|
10
|
-
offset = 0
|
|
11
|
-
}) => {
|
|
12
|
-
const gameService = useMemo(() => new SlidingNumbersService(), []);
|
|
13
|
-
const timeElapsed = useTimeElapsed();
|
|
14
|
-
const formattedTime = useMemo(() => gameService.formatTime(timeElapsed), [gameService, timeElapsed]);
|
|
15
|
-
return /*#__PURE__*/_jsx(ScoreBoardContainer, {
|
|
16
|
-
offset: offset,
|
|
17
|
-
backgroundColor: "rgba(245, 245, 220, 0.6)",
|
|
18
|
-
borderColor: "rgba(255, 255, 255, 0.3)",
|
|
19
|
-
children: /*#__PURE__*/_jsx(View, {
|
|
20
|
-
style: styles.scoreBoard,
|
|
21
|
-
children: /*#__PURE__*/_jsxs(View, {
|
|
22
|
-
style: styles.scoreSection,
|
|
23
|
-
children: [/*#__PURE__*/_jsx(Text, {
|
|
24
|
-
style: styles.scoreLabel,
|
|
25
|
-
children: "Time Elapsed"
|
|
26
|
-
}), /*#__PURE__*/_jsx(Text, {
|
|
27
|
-
style: [styles.timeValue, {
|
|
28
|
-
color: '#3b82f6'
|
|
29
|
-
}],
|
|
30
|
-
children: formattedTime
|
|
31
|
-
})]
|
|
32
|
-
})
|
|
33
|
-
})
|
|
34
|
-
});
|
|
35
|
-
});
|
|
36
|
-
const styles = StyleSheet.create({
|
|
37
|
-
scoreBoard: {
|
|
38
|
-
flexDirection: 'row',
|
|
39
|
-
justifyContent: 'space-between',
|
|
40
|
-
alignItems: 'center'
|
|
41
|
-
},
|
|
42
|
-
scoreSection: {
|
|
43
|
-
alignItems: 'center',
|
|
44
|
-
flex: 1
|
|
45
|
-
},
|
|
46
|
-
scoreLabel: {
|
|
47
|
-
fontSize: 18,
|
|
48
|
-
fontWeight: 'bold',
|
|
49
|
-
color: '#4a5568',
|
|
50
|
-
// Dark gray for better contrast
|
|
51
|
-
marginBottom: 4
|
|
52
|
-
},
|
|
53
|
-
timeValue: {
|
|
54
|
-
fontSize: 30,
|
|
55
|
-
fontWeight: 'bold'
|
|
56
|
-
},
|
|
57
|
-
hintText: {
|
|
58
|
-
fontSize: 18,
|
|
59
|
-
fontWeight: '600',
|
|
60
|
-
color: '#10b981' // Green color for motivation
|
|
61
|
-
}
|
|
62
|
-
});
|
|
63
|
-
ScoreBoard.displayName = 'ScoreBoard';
|
|
64
|
-
//# sourceMappingURL=ScoreBoard.js.map
|
|
1
|
+
"use strict";import React,{useMemo}from 'react';import{View,Text,StyleSheet}from 'react-native';import{useTimeElapsed}from "../SlidingNumbersStore.js";import{SlidingNumbersService}from "../SlidingNumbersService.js";import{ScoreBoardContainer}from "../../../helpers/index.js";import{jsx as _jsx,jsxs as _jsxs}from "react/jsx-runtime";export const ScoreBoard = React.memo(({offset = 0})=>{const gameService = useMemo(()=> new SlidingNumbersService(),[]);const timeElapsed = useTimeElapsed();const formattedTime = useMemo(()=> gameService.formatTime(timeElapsed),[gameService,timeElapsed]);return _jsx(ScoreBoardContainer,{offset:offset,backgroundColor:"rgba(245,245,220,0.6)",borderColor:"rgba(255,255,255,0.3)",children:_jsx(View,{style:styles.scoreBoard,children:_jsxs(View,{style:styles.scoreSection,children:[_jsx(Text,{style:styles.scoreLabel,children:"Time Elapsed"}),_jsx(Text,{style:[styles.timeValue,{color:'#3b82f6'}],children:formattedTime})]})})});});const styles = StyleSheet.create({scoreBoard:{flexDirection:'row',justifyContent:'space-between',alignItems:'center'},scoreSection:{alignItems:'center',flex:1},scoreLabel:{fontSize:16,fontWeight:'bold',color:'#4a5568',marginBottom:4},timeValue:{fontSize:25,fontWeight:'bold'},hintText:{fontSize:18,fontWeight:'600',color:'#10b981'}});ScoreBoard.displayName = 'ScoreBoard';
|
|
@@ -1,7 +1 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
export { NumbersTile } from "./NumbersTile.js";
|
|
4
|
-
export { NumbersGrid } from "./NumbersGrid.js";
|
|
5
|
-
export { ScoreBoard } from "./ScoreBoard.js";
|
|
6
|
-
export { GameBackground } from "./GameBackground.js";
|
|
7
|
-
//# sourceMappingURL=index.js.map
|
|
1
|
+
"use strict";export{NumbersTile}from "./NumbersTile.js";export{NumbersGrid}from "./NumbersGrid.js";export{ScoreBoard}from "./ScoreBoard.js";export{GameBackground}from "./GameBackground.js";
|
|
@@ -1,189 +1 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
import React from 'react';
|
|
4
|
-
import { View, StyleSheet } from 'react-native';
|
|
5
|
-
import { GestureHandlerRootView, Gesture, GestureDetector } from 'react-native-gesture-handler';
|
|
6
|
-
import { runOnJS } from 'react-native-reanimated';
|
|
7
|
-
import { GameControlButton, GameOverModal, GameSettingsModal } from "../../helpers/index.js";
|
|
8
|
-
import { DEFAULT_GAME_SETTINGS, GAME_IDS } from "../../services/UtilsService.js";
|
|
9
|
-
import { GameBackground, GameGrid, ScoreBoard } from "./components/index.js";
|
|
10
|
-
import { useSnakeStore, useScore, useIsPlaying, useIsGameOver } from "./SnakeStore.js";
|
|
11
|
-
import { SNAKE_COLORS } from "./SnakeConstants.js";
|
|
12
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
13
|
-
export const Snake = /*#__PURE__*/React.memo(({
|
|
14
|
-
settings,
|
|
15
|
-
onSettingsChange
|
|
16
|
-
}) => {
|
|
17
|
-
// Zustand store selectors for optimal re-renders
|
|
18
|
-
const score = useScore();
|
|
19
|
-
const isPlaying = useIsPlaying();
|
|
20
|
-
const isGameOver = useIsGameOver();
|
|
21
|
-
|
|
22
|
-
// Store actions - use stable references to prevent re-renders
|
|
23
|
-
const startGame = useSnakeStore(state => state.startGame);
|
|
24
|
-
const stopGame = useSnakeStore(state => state.stopGame);
|
|
25
|
-
const resetGame = useSnakeStore(state => state.resetGame);
|
|
26
|
-
const initializeGame = useSnakeStore(state => state.initializeGame);
|
|
27
|
-
const updateSettings = useSnakeStore(state => state.updateSettings);
|
|
28
|
-
const changeDirection = useSnakeStore(state => state.changeDirection);
|
|
29
|
-
|
|
30
|
-
// Track previous values to prevent unnecessary updates
|
|
31
|
-
const prevSettingsRef = React.useRef({
|
|
32
|
-
enableSounds: true,
|
|
33
|
-
enableHaptics: true
|
|
34
|
-
});
|
|
35
|
-
const prevDifficultyRef = React.useRef('easy');
|
|
36
|
-
|
|
37
|
-
// Update settings when they change
|
|
38
|
-
React.useEffect(() => {
|
|
39
|
-
const enableSounds = settings?.enableSounds ?? true;
|
|
40
|
-
const enableHaptics = settings?.enableHaptics ?? true;
|
|
41
|
-
|
|
42
|
-
// Only update if values actually changed
|
|
43
|
-
if (prevSettingsRef.current.enableSounds !== enableSounds || prevSettingsRef.current.enableHaptics !== enableHaptics) {
|
|
44
|
-
prevSettingsRef.current = {
|
|
45
|
-
enableSounds,
|
|
46
|
-
enableHaptics
|
|
47
|
-
};
|
|
48
|
-
updateSettings(enableSounds, enableHaptics);
|
|
49
|
-
}
|
|
50
|
-
}, [updateSettings, settings?.enableSounds, settings?.enableHaptics]);
|
|
51
|
-
|
|
52
|
-
// Initialize on mount and when difficulty changes
|
|
53
|
-
React.useEffect(() => {
|
|
54
|
-
const difficulty = settings?.difficulty || 'easy';
|
|
55
|
-
|
|
56
|
-
// Only initialize if difficulty actually changed
|
|
57
|
-
if (prevDifficultyRef.current !== difficulty) {
|
|
58
|
-
prevDifficultyRef.current = difficulty;
|
|
59
|
-
initializeGame(difficulty);
|
|
60
|
-
}
|
|
61
|
-
}, [initializeGame, settings?.difficulty]);
|
|
62
|
-
|
|
63
|
-
// Game control handlers
|
|
64
|
-
const handleStartGame = React.useCallback(() => {
|
|
65
|
-
startGame();
|
|
66
|
-
}, [startGame]);
|
|
67
|
-
const handleResetGame = React.useCallback(() => {
|
|
68
|
-
resetGame();
|
|
69
|
-
}, [resetGame]);
|
|
70
|
-
const handleStopGame = React.useCallback(() => {
|
|
71
|
-
stopGame();
|
|
72
|
-
}, [stopGame]);
|
|
73
|
-
|
|
74
|
-
// Gesture handler for swipe controls with safe state updates
|
|
75
|
-
const handleSwipe = React.useCallback(direction => {
|
|
76
|
-
try {
|
|
77
|
-
if (!isPlaying) return;
|
|
78
|
-
|
|
79
|
-
// Use requestAnimationFrame for safer state updates
|
|
80
|
-
requestAnimationFrame(() => {
|
|
81
|
-
try {
|
|
82
|
-
changeDirection(direction);
|
|
83
|
-
} catch (error) {
|
|
84
|
-
console.error('Direction change error:', error);
|
|
85
|
-
}
|
|
86
|
-
});
|
|
87
|
-
} catch (error) {
|
|
88
|
-
console.error('Swipe handler error:', error);
|
|
89
|
-
}
|
|
90
|
-
}, [isPlaying, changeDirection]);
|
|
91
|
-
|
|
92
|
-
// Pan gesture for swipe detection
|
|
93
|
-
const panGesture = React.useMemo(() => Gesture.Pan().onEnd(event => {
|
|
94
|
-
const threshold = 30; // Minimum swipe distance
|
|
95
|
-
const absX = Math.abs(event.translationX);
|
|
96
|
-
const absY = Math.abs(event.translationY);
|
|
97
|
-
if (absX > threshold || absY > threshold) {
|
|
98
|
-
if (absX > absY) {
|
|
99
|
-
// Horizontal swipe
|
|
100
|
-
if (event.translationX > 0) {
|
|
101
|
-
runOnJS(handleSwipe)('RIGHT');
|
|
102
|
-
} else {
|
|
103
|
-
runOnJS(handleSwipe)('LEFT');
|
|
104
|
-
}
|
|
105
|
-
} else {
|
|
106
|
-
// Vertical swipe
|
|
107
|
-
if (event.translationY > 0) {
|
|
108
|
-
runOnJS(handleSwipe)('DOWN');
|
|
109
|
-
} else {
|
|
110
|
-
runOnJS(handleSwipe)('UP');
|
|
111
|
-
}
|
|
112
|
-
}
|
|
113
|
-
}
|
|
114
|
-
}), [handleSwipe]);
|
|
115
|
-
|
|
116
|
-
// Memoized GameControlButton props
|
|
117
|
-
const gameControlButtonProps = React.useMemo(() => ({
|
|
118
|
-
isPlaying,
|
|
119
|
-
gameOver: isGameOver,
|
|
120
|
-
onStartGame: handleStartGame,
|
|
121
|
-
onStopGame: handleStopGame,
|
|
122
|
-
onResetGame: handleResetGame,
|
|
123
|
-
startButtonText: 'Start Slithering!',
|
|
124
|
-
startButtonSubtext: 'Swipe to move or turn.',
|
|
125
|
-
startButtonColor: SNAKE_COLORS.BUTTON_PRIMARY,
|
|
126
|
-
startButtonBorderColor: SNAKE_COLORS.BUTTON_SECONDARY
|
|
127
|
-
}), [isPlaying, isGameOver, handleStartGame, handleStopGame, handleResetGame]);
|
|
128
|
-
|
|
129
|
-
// Memoized GameOverModal props
|
|
130
|
-
const gameOverModalProps = React.useMemo(() => ({
|
|
131
|
-
isVisible: isGameOver,
|
|
132
|
-
score,
|
|
133
|
-
onPlayAgain: handleResetGame,
|
|
134
|
-
buttonText: 'Play Again!',
|
|
135
|
-
primaryColor: SNAKE_COLORS.MODAL_PRIMARY,
|
|
136
|
-
borderColor: SNAKE_COLORS.MODAL_BORDER,
|
|
137
|
-
buttonColor: SNAKE_COLORS.MODAL_BUTTON,
|
|
138
|
-
buttonBorderColor: SNAKE_COLORS.MODAL_BUTTON_BORDER,
|
|
139
|
-
scoreFormatter: s => `${s}`,
|
|
140
|
-
additionalInfo: 'Great slithering!'
|
|
141
|
-
}), [isGameOver, score, handleResetGame]);
|
|
142
|
-
|
|
143
|
-
// Memoized GameSettingsModal props
|
|
144
|
-
const gameSettingsModalProps = React.useMemo(() => ({
|
|
145
|
-
gameId: GAME_IDS.SNAKE,
|
|
146
|
-
settings: settings || DEFAULT_GAME_SETTINGS,
|
|
147
|
-
onSettingsChange
|
|
148
|
-
}), [settings, onSettingsChange]);
|
|
149
|
-
|
|
150
|
-
// Get offset from settings
|
|
151
|
-
const offset = settings?.offset ?? 0;
|
|
152
|
-
return /*#__PURE__*/_jsx(GameBackground, {
|
|
153
|
-
children: /*#__PURE__*/_jsxs(GestureHandlerRootView, {
|
|
154
|
-
style: styles.container,
|
|
155
|
-
children: [/*#__PURE__*/_jsx(GestureDetector, {
|
|
156
|
-
gesture: panGesture,
|
|
157
|
-
children: /*#__PURE__*/_jsx(View, {
|
|
158
|
-
style: styles.container,
|
|
159
|
-
children: /*#__PURE__*/_jsx(View, {
|
|
160
|
-
style: [styles.gridContainer, {
|
|
161
|
-
paddingTop: offset
|
|
162
|
-
}],
|
|
163
|
-
children: /*#__PURE__*/_jsx(GameGrid, {})
|
|
164
|
-
})
|
|
165
|
-
})
|
|
166
|
-
}), /*#__PURE__*/_jsx(ScoreBoard, {
|
|
167
|
-
offset: offset
|
|
168
|
-
}), /*#__PURE__*/_jsx(GameControlButton, {
|
|
169
|
-
...gameControlButtonProps
|
|
170
|
-
}), /*#__PURE__*/_jsx(GameOverModal, {
|
|
171
|
-
...gameOverModalProps
|
|
172
|
-
}), /*#__PURE__*/_jsx(GameSettingsModal, {
|
|
173
|
-
...gameSettingsModalProps
|
|
174
|
-
})]
|
|
175
|
-
})
|
|
176
|
-
});
|
|
177
|
-
});
|
|
178
|
-
Snake.displayName = 'Snake';
|
|
179
|
-
const styles = StyleSheet.create({
|
|
180
|
-
container: {
|
|
181
|
-
flex: 1
|
|
182
|
-
},
|
|
183
|
-
gridContainer: {
|
|
184
|
-
flex: 1,
|
|
185
|
-
justifyContent: 'center',
|
|
186
|
-
alignItems: 'center'
|
|
187
|
-
}
|
|
188
|
-
});
|
|
189
|
-
//# sourceMappingURL=Snake.js.map
|
|
1
|
+
"use strict";import React from 'react';import{View,StyleSheet}from 'react-native';import{GestureHandlerRootView,Gesture,GestureDetector}from 'react-native-gesture-handler';import{runOnJS}from 'react-native-reanimated';import{GameControlButton,GameOverModal,GameSettingsModal}from "../../helpers/index.js";import{DEFAULT_GAME_SETTINGS,GAME_IDS}from "../../services/UtilsService.js";import{GameBackground,GameGrid,ScoreBoard}from "./components/index.js";import{useSnakeStore,useScore,useIsPlaying,useIsGameOver}from "./SnakeStore.js";import{SNAKE_COLORS}from "./SnakeConstants.js";import{jsx as _jsx,jsxs as _jsxs}from "react/jsx-runtime";export const Snake = React.memo(({settings,onSettingsChange,onEndGame})=>{const score = useScore();const isPlaying = useIsPlaying();const isGameOver = useIsGameOver();const gameReportedRef = React.useRef(false);const reportGameEnd = React.useCallback(status =>{if(onEndGame && !gameReportedRef.current){onEndGame({status,score:score.toString()});gameReportedRef.current = true;}},[onEndGame,score]);const startGame = useSnakeStore(state => state.startGame);const stopGame = useSnakeStore(state => state.stopGame);const resetGame = useSnakeStore(state => state.resetGame);const initializeGame = useSnakeStore(state => state.initializeGame);const updateSettings = useSnakeStore(state => state.updateSettings);const changeDirection = useSnakeStore(state => state.changeDirection);const prevSettingsRef = React.useRef({enableSounds:true,enableHaptics:true});const prevDifficultyRef = React.useRef('easy');React.useEffect(()=>{const enableSounds = settings?.enableSounds ?? true;const enableHaptics = settings?.enableHaptics ?? true;if(prevSettingsRef.current.enableSounds !== enableSounds || prevSettingsRef.current.enableHaptics !== enableHaptics){prevSettingsRef.current ={enableSounds,enableHaptics};updateSettings(enableSounds,enableHaptics);}},[updateSettings,settings?.enableSounds,settings?.enableHaptics]);React.useEffect(()=>{const difficulty = settings?.difficulty || 'easy';if(prevDifficultyRef.current !== difficulty){prevDifficultyRef.current = difficulty;initializeGame(difficulty);}},[initializeGame,settings?.difficulty]);React.useEffect(()=>{if(isGameOver && !gameReportedRef.current){reportGameEnd('lose');}if(!isGameOver){gameReportedRef.current = false;}},[isGameOver,reportGameEnd]);const handleStartGame = React.useCallback(()=>{gameReportedRef.current = false;startGame();},[startGame]);const handleResetGame = React.useCallback(()=>{resetGame();},[resetGame]);const handleStopGame = React.useCallback(()=>{reportGameEnd('cancel');stopGame();},[stopGame,reportGameEnd]);const handleSwipe = React.useCallback(direction =>{try{if(!isPlaying)return;requestAnimationFrame(()=>{try{changeDirection(direction);}catch(error){console.error('Direction change error:',error);}});}catch(error){console.error('Swipe handler error:',error);}},[isPlaying,changeDirection]);const panGesture = React.useMemo(()=> Gesture.Pan().onEnd(event =>{const threshold = 30;const absX = Math.abs(event.translationX);const absY = Math.abs(event.translationY);if(absX > threshold || absY > threshold){if(absX > absY){if(event.translationX > 0){runOnJS(handleSwipe)('RIGHT');}else{runOnJS(handleSwipe)('LEFT');}}else{if(event.translationY > 0){runOnJS(handleSwipe)('DOWN');}else{runOnJS(handleSwipe)('UP');}}}}),[handleSwipe]);const gameControlButtonProps = React.useMemo(()=>({isPlaying,gameOver:isGameOver,onStartGame:handleStartGame,onStopGame:handleStopGame,onResetGame:handleResetGame,startButtonText:'Start Slithering!',startButtonSubtext:'Swipe to move or turn.',startButtonColor:SNAKE_COLORS.BUTTON_PRIMARY,startButtonBorderColor:SNAKE_COLORS.BUTTON_SECONDARY}),[isPlaying,isGameOver,handleStartGame,handleStopGame,handleResetGame]);const gameOverModalProps = React.useMemo(()=>({isVisible:isGameOver,score,onPlayAgain:handleResetGame,buttonText:'Play Again!',primaryColor:"rgba(0,204,106,0.5)",borderColor:"rgba(0,204,106,0.5)",buttonColor:"#ffffff",buttonBorderColor:"#ffffff",buttonTextColor:"#00cc6a",scoreFormatter:s => `${s}`}),[isGameOver,score,handleResetGame]);const gameSettingsModalProps = React.useMemo(()=>({gameId:GAME_IDS.SNAKE,settings:settings || DEFAULT_GAME_SETTINGS,onSettingsChange}),[settings,onSettingsChange]);const offset = settings?.offset ?? 0;return _jsx(GameBackground,{children:_jsxs(GestureHandlerRootView,{style:styles.container,children:[_jsx(GestureDetector,{gesture:panGesture,children:_jsx(View,{style:styles.container,children:_jsx(View,{style:[styles.gridContainer,{paddingTop:offset}],children:_jsx(GameGrid,{})})})}),_jsx(ScoreBoard,{offset:offset}),_jsx(GameControlButton,{...gameControlButtonProps}),_jsx(GameOverModal,{...gameOverModalProps}),_jsx(GameSettingsModal,{...gameSettingsModalProps})]})});});Snake.displayName = 'Snake';const styles = StyleSheet.create({container:{flex:1},gridContainer:{flex:1,justifyContent:'center',alignItems:'center'}});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","View","StyleSheet","GestureHandlerRootView","Gesture","GestureDetector","runOnJS","GameControlButton","GameOverModal","GameSettingsModal","DEFAULT_GAME_SETTINGS","GAME_IDS","GameBackground","GameGrid","ScoreBoard","useSnakeStore","useScore","useIsPlaying","useIsGameOver","SNAKE_COLORS","jsx","_jsx","jsxs","_jsxs","Snake","memo","settings","onSettingsChange","score","isPlaying","isGameOver","startGame","state","stopGame","resetGame","initializeGame","updateSettings","changeDirection","prevSettingsRef","
|
|
1
|
+
{"version":3,"names":["React","View","StyleSheet","GestureHandlerRootView","Gesture","GestureDetector","runOnJS","GameControlButton","GameOverModal","GameSettingsModal","DEFAULT_GAME_SETTINGS","GAME_IDS","GameBackground","GameGrid","ScoreBoard","useSnakeStore","useScore","useIsPlaying","useIsGameOver","SNAKE_COLORS","jsx","_jsx","jsxs","_jsxs","Snake","memo","settings","onSettingsChange","onEndGame","score","isPlaying","isGameOver","gameReportedRef","useRef","reportGameEnd","useCallback","status","current","toString","startGame","state","stopGame","resetGame","initializeGame","updateSettings","changeDirection","prevSettingsRef","enableSounds","enableHaptics","prevDifficultyRef","useEffect","difficulty","handleStartGame","handleResetGame","handleStopGame","handleSwipe","direction","requestAnimationFrame","error","console","panGesture","useMemo","Pan","onEnd","event","threshold","absX","Math","abs","translationX","absY","translationY","gameControlButtonProps","gameOver","onStartGame","onStopGame","onResetGame","startButtonText","startButtonSubtext","startButtonColor","BUTTON_PRIMARY","startButtonBorderColor","BUTTON_SECONDARY","gameOverModalProps","isVisible","onPlayAgain","buttonText","primaryColor","borderColor","buttonColor","buttonBorderColor","buttonTextColor","scoreFormatter","s","gameSettingsModalProps","gameId","SNAKE","offset","children","style","styles","container","gesture","gridContainer","paddingTop","displayName","create","flex","justifyContent","alignItems"],"sourceRoot":"../../../../src","sources":["games/snake/Snake.tsx"],"mappings":";;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,IAAI,EAAEC,UAAU,QAAQ,cAAc;AAC/C,SAASC,sBAAsB,EAAEC,OAAO,EAAEC,eAAe,QAAQ,8BAA8B;AAC/F,SAASC,OAAO,QAAQ,yBAAyB;AACjD,SAASC,iBAAiB,EAAEC,aAAa,EAAEC,iBAAiB,QAAQ,wBAAe;AACnF,SAAyBC,qBAAqB,EAAEC,QAAQ,QAAQ,gCAA6B;AAC7F,SAASC,cAAc,EAAEC,QAAQ,EAAEC,UAAU,QAAQ,uBAAc;AACnE,SACEC,aAAa,EACbC,QAAQ,EACRC,YAAY,EACZC,aAAa,QACR,iBAAc;AACrB,SAASC,YAAY,QAAwB,qBAAkB;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAGhE,OAAO,MAAMC,KAA0B,gBAAGxB,KAAK,CAACyB,IAAI,CAAC,CAAC;EAAEC,QAAQ;EAAEC,gBAAgB;EAAEC;AAAU,CAAC,KAAK;EAClG;EACA,MAAMC,KAAK,GAAGb,QAAQ,CAAC,CAAC;EACxB,MAAMc,SAAS,GAAGb,YAAY,CAAC,CAAC;EAChC,MAAMc,UAAU,GAAGb,aAAa,CAAC,CAAC;;EAElC;EAC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