react-native-games 0.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.
Files changed (269) hide show
  1. package/LICENSE +66 -0
  2. package/README.md +269 -0
  3. package/lib/module/games/balloon-blaster/BalloonBlaster.js +391 -0
  4. package/lib/module/games/balloon-blaster/BalloonBlaster.js.map +1 -0
  5. package/lib/module/games/balloon-blaster/BalloonBlasterService.js +293 -0
  6. package/lib/module/games/balloon-blaster/BalloonBlasterService.js.map +1 -0
  7. package/lib/module/games/balloon-blaster/BalloonBlasterStore.js +156 -0
  8. package/lib/module/games/balloon-blaster/BalloonBlasterStore.js.map +1 -0
  9. package/lib/module/games/balloon-blaster/components/BalloonComponent.js +227 -0
  10. package/lib/module/games/balloon-blaster/components/BalloonComponent.js.map +1 -0
  11. package/lib/module/games/balloon-blaster/components/GameArea.js +42 -0
  12. package/lib/module/games/balloon-blaster/components/GameArea.js.map +1 -0
  13. package/lib/module/games/balloon-blaster/components/GameBackground.js +544 -0
  14. package/lib/module/games/balloon-blaster/components/GameBackground.js.map +1 -0
  15. package/lib/module/games/balloon-blaster/components/GameControls.js +229 -0
  16. package/lib/module/games/balloon-blaster/components/GameControls.js.map +1 -0
  17. package/lib/module/games/balloon-blaster/components/GameOverModal.js +133 -0
  18. package/lib/module/games/balloon-blaster/components/GameOverModal.js.map +1 -0
  19. package/lib/module/games/balloon-blaster/components/ParticleSystem.js +52 -0
  20. package/lib/module/games/balloon-blaster/components/ParticleSystem.js.map +1 -0
  21. package/lib/module/games/balloon-blaster/components/ScoreBoard.js +119 -0
  22. package/lib/module/games/balloon-blaster/components/ScoreBoard.js.map +1 -0
  23. package/lib/module/games/balloon-blaster/components/SliceTrail.js +58 -0
  24. package/lib/module/games/balloon-blaster/components/SliceTrail.js.map +1 -0
  25. package/lib/module/games/balloon-blaster/components/index.js +11 -0
  26. package/lib/module/games/balloon-blaster/components/index.js.map +1 -0
  27. package/lib/module/games/cat-popper/CatPopper.js +230 -0
  28. package/lib/module/games/cat-popper/CatPopper.js.map +1 -0
  29. package/lib/module/games/cat-popper/CatPopperService.js +100 -0
  30. package/lib/module/games/cat-popper/CatPopperService.js.map +1 -0
  31. package/lib/module/games/cat-popper/CatPopperStore.js +113 -0
  32. package/lib/module/games/cat-popper/CatPopperStore.js.map +1 -0
  33. package/lib/module/games/cat-popper/components/CatCharacter.js +281 -0
  34. package/lib/module/games/cat-popper/components/CatCharacter.js.map +1 -0
  35. package/lib/module/games/cat-popper/components/GameBackground.js +531 -0
  36. package/lib/module/games/cat-popper/components/GameBackground.js.map +1 -0
  37. package/lib/module/games/cat-popper/components/GameControls.js +230 -0
  38. package/lib/module/games/cat-popper/components/GameControls.js.map +1 -0
  39. package/lib/module/games/cat-popper/components/GameGrid.js +66 -0
  40. package/lib/module/games/cat-popper/components/GameGrid.js.map +1 -0
  41. package/lib/module/games/cat-popper/components/GameHole.js +183 -0
  42. package/lib/module/games/cat-popper/components/GameHole.js.map +1 -0
  43. package/lib/module/games/cat-popper/components/GameOverModal.js +131 -0
  44. package/lib/module/games/cat-popper/components/GameOverModal.js.map +1 -0
  45. package/lib/module/games/cat-popper/components/ScoreBoard.js +77 -0
  46. package/lib/module/games/cat-popper/components/ScoreBoard.js.map +1 -0
  47. package/lib/module/games/cat-popper/components/index.js +10 -0
  48. package/lib/module/games/cat-popper/components/index.js.map +1 -0
  49. package/lib/module/games/fruit-slicer/FruitSlicer.js +411 -0
  50. package/lib/module/games/fruit-slicer/FruitSlicer.js.map +1 -0
  51. package/lib/module/games/fruit-slicer/FruitSlicerService.js +293 -0
  52. package/lib/module/games/fruit-slicer/FruitSlicerService.js.map +1 -0
  53. package/lib/module/games/fruit-slicer/FruitSlicerStore.js +156 -0
  54. package/lib/module/games/fruit-slicer/FruitSlicerStore.js.map +1 -0
  55. package/lib/module/games/fruit-slicer/components/FruitComponent.js +99 -0
  56. package/lib/module/games/fruit-slicer/components/FruitComponent.js.map +1 -0
  57. package/lib/module/games/fruit-slicer/components/GameArea.js +50 -0
  58. package/lib/module/games/fruit-slicer/components/GameArea.js.map +1 -0
  59. package/lib/module/games/fruit-slicer/components/GameBackground.js +1296 -0
  60. package/lib/module/games/fruit-slicer/components/GameBackground.js.map +1 -0
  61. package/lib/module/games/fruit-slicer/components/GameControls.js +230 -0
  62. package/lib/module/games/fruit-slicer/components/GameControls.js.map +1 -0
  63. package/lib/module/games/fruit-slicer/components/GameOverModal.js +189 -0
  64. package/lib/module/games/fruit-slicer/components/GameOverModal.js.map +1 -0
  65. package/lib/module/games/fruit-slicer/components/ParticleSystem.js +52 -0
  66. package/lib/module/games/fruit-slicer/components/ParticleSystem.js.map +1 -0
  67. package/lib/module/games/fruit-slicer/components/ScoreBoard.js +121 -0
  68. package/lib/module/games/fruit-slicer/components/ScoreBoard.js.map +1 -0
  69. package/lib/module/games/fruit-slicer/components/SliceTrail.js +58 -0
  70. package/lib/module/games/fruit-slicer/components/SliceTrail.js.map +1 -0
  71. package/lib/module/games/fruit-slicer/components/index.js +11 -0
  72. package/lib/module/games/fruit-slicer/components/index.js.map +1 -0
  73. package/lib/module/games/maze-runner/MazeRunner.js +242 -0
  74. package/lib/module/games/maze-runner/MazeRunner.js.map +1 -0
  75. package/lib/module/games/maze-runner/MazeRunnerService.js +560 -0
  76. package/lib/module/games/maze-runner/MazeRunnerService.js.map +1 -0
  77. package/lib/module/games/maze-runner/components/EnhancedBallComponent.js +149 -0
  78. package/lib/module/games/maze-runner/components/EnhancedBallComponent.js.map +1 -0
  79. package/lib/module/games/maze-runner/components/EnhancedGameArea.js +357 -0
  80. package/lib/module/games/maze-runner/components/EnhancedGameArea.js.map +1 -0
  81. package/lib/module/games/maze-runner/components/GameBackground.js +216 -0
  82. package/lib/module/games/maze-runner/components/GameBackground.js.map +1 -0
  83. package/lib/module/games/maze-runner/components/GameControls.js +129 -0
  84. package/lib/module/games/maze-runner/components/GameControls.js.map +1 -0
  85. package/lib/module/games/maze-runner/components/GameOverModal.js +134 -0
  86. package/lib/module/games/maze-runner/components/GameOverModal.js.map +1 -0
  87. package/lib/module/games/maze-runner/components/ScoreBoard.js +81 -0
  88. package/lib/module/games/maze-runner/components/ScoreBoard.js.map +1 -0
  89. package/lib/module/games/maze-runner/components/SkiaPipeComponent.js +209 -0
  90. package/lib/module/games/maze-runner/components/SkiaPipeComponent.js.map +1 -0
  91. package/lib/module/games/maze-runner/components/StaticGameBackground.js +169 -0
  92. package/lib/module/games/maze-runner/components/StaticGameBackground.js.map +1 -0
  93. package/lib/module/games/maze-runner/components/WallComponent.js +90 -0
  94. package/lib/module/games/maze-runner/components/WallComponent.js.map +1 -0
  95. package/lib/module/games/maze-runner/components/index.js +10 -0
  96. package/lib/module/games/maze-runner/components/index.js.map +1 -0
  97. package/lib/module/games/space-traveller/SpaceTraveller.js +393 -0
  98. package/lib/module/games/space-traveller/SpaceTraveller.js.map +1 -0
  99. package/lib/module/games/space-traveller/SpaceTravellerService.js +298 -0
  100. package/lib/module/games/space-traveller/SpaceTravellerService.js.map +1 -0
  101. package/lib/module/games/space-traveller/SpaceTravellerStore.js +139 -0
  102. package/lib/module/games/space-traveller/SpaceTravellerStore.js.map +1 -0
  103. package/lib/module/games/space-traveller/components/AsteroidComponent.js +111 -0
  104. package/lib/module/games/space-traveller/components/AsteroidComponent.js.map +1 -0
  105. package/lib/module/games/space-traveller/components/GameArea.js +75 -0
  106. package/lib/module/games/space-traveller/components/GameArea.js.map +1 -0
  107. package/lib/module/games/space-traveller/components/GameBackground.js +294 -0
  108. package/lib/module/games/space-traveller/components/GameBackground.js.map +1 -0
  109. package/lib/module/games/space-traveller/components/GameControls.js +177 -0
  110. package/lib/module/games/space-traveller/components/GameControls.js.map +1 -0
  111. package/lib/module/games/space-traveller/components/GameOverModal.js +182 -0
  112. package/lib/module/games/space-traveller/components/GameOverModal.js.map +1 -0
  113. package/lib/module/games/space-traveller/components/ParticleComponent.js +34 -0
  114. package/lib/module/games/space-traveller/components/ParticleComponent.js.map +1 -0
  115. package/lib/module/games/space-traveller/components/ScoreBoard.js +143 -0
  116. package/lib/module/games/space-traveller/components/ScoreBoard.js.map +1 -0
  117. package/lib/module/games/space-traveller/components/SettingsModal.js +222 -0
  118. package/lib/module/games/space-traveller/components/SettingsModal.js.map +1 -0
  119. package/lib/module/games/space-traveller/components/Spacecraft3D.js +362 -0
  120. package/lib/module/games/space-traveller/components/Spacecraft3D.js.map +1 -0
  121. package/lib/module/games/space-traveller/components/SpacecraftPath.js +37 -0
  122. package/lib/module/games/space-traveller/components/SpacecraftPath.js.map +1 -0
  123. package/lib/module/games/space-traveller/components/index.js +13 -0
  124. package/lib/module/games/space-traveller/components/index.js.map +1 -0
  125. package/lib/module/index.js +12 -0
  126. package/lib/module/index.js.map +1 -0
  127. package/lib/module/package.json +1 -0
  128. package/lib/module/services/GamesConstants.js +561 -0
  129. package/lib/module/services/GamesConstants.js.map +1 -0
  130. package/lib/module/services/GamesService.js +34 -0
  131. package/lib/module/services/GamesService.js.map +1 -0
  132. package/lib/module/shared/settings/GameSettings.js +295 -0
  133. package/lib/module/shared/settings/GameSettings.js.map +1 -0
  134. package/lib/module/shared/settings/SettingsService.js +119 -0
  135. package/lib/module/shared/settings/SettingsService.js.map +1 -0
  136. package/lib/typescript/package.json +1 -0
  137. package/lib/typescript/src/games/balloon-blaster/BalloonBlaster.d.ts +16 -0
  138. package/lib/typescript/src/games/balloon-blaster/BalloonBlaster.d.ts.map +1 -0
  139. package/lib/typescript/src/games/balloon-blaster/BalloonBlasterService.d.ts +66 -0
  140. package/lib/typescript/src/games/balloon-blaster/BalloonBlasterService.d.ts.map +1 -0
  141. package/lib/typescript/src/games/balloon-blaster/BalloonBlasterStore.d.ts +37 -0
  142. package/lib/typescript/src/games/balloon-blaster/BalloonBlasterStore.d.ts.map +1 -0
  143. package/lib/typescript/src/games/balloon-blaster/components/BalloonComponent.d.ts +10 -0
  144. package/lib/typescript/src/games/balloon-blaster/components/BalloonComponent.d.ts.map +1 -0
  145. package/lib/typescript/src/games/balloon-blaster/components/GameArea.d.ts +17 -0
  146. package/lib/typescript/src/games/balloon-blaster/components/GameArea.d.ts.map +1 -0
  147. package/lib/typescript/src/games/balloon-blaster/components/GameBackground.d.ts +7 -0
  148. package/lib/typescript/src/games/balloon-blaster/components/GameBackground.d.ts.map +1 -0
  149. package/lib/typescript/src/games/balloon-blaster/components/GameControls.d.ts +10 -0
  150. package/lib/typescript/src/games/balloon-blaster/components/GameControls.d.ts.map +1 -0
  151. package/lib/typescript/src/games/balloon-blaster/components/GameOverModal.d.ts +9 -0
  152. package/lib/typescript/src/games/balloon-blaster/components/GameOverModal.d.ts.map +1 -0
  153. package/lib/typescript/src/games/balloon-blaster/components/ParticleSystem.d.ts +8 -0
  154. package/lib/typescript/src/games/balloon-blaster/components/ParticleSystem.d.ts.map +1 -0
  155. package/lib/typescript/src/games/balloon-blaster/components/ScoreBoard.d.ts +9 -0
  156. package/lib/typescript/src/games/balloon-blaster/components/ScoreBoard.d.ts.map +1 -0
  157. package/lib/typescript/src/games/balloon-blaster/components/SliceTrail.d.ts +11 -0
  158. package/lib/typescript/src/games/balloon-blaster/components/SliceTrail.d.ts.map +1 -0
  159. package/lib/typescript/src/games/balloon-blaster/components/index.d.ts +9 -0
  160. package/lib/typescript/src/games/balloon-blaster/components/index.d.ts.map +1 -0
  161. package/lib/typescript/src/games/cat-popper/CatPopper.d.ts +13 -0
  162. package/lib/typescript/src/games/cat-popper/CatPopper.d.ts.map +1 -0
  163. package/lib/typescript/src/games/cat-popper/CatPopperService.d.ts +32 -0
  164. package/lib/typescript/src/games/cat-popper/CatPopperService.d.ts.map +1 -0
  165. package/lib/typescript/src/games/cat-popper/CatPopperStore.d.ts +21 -0
  166. package/lib/typescript/src/games/cat-popper/CatPopperStore.d.ts.map +1 -0
  167. package/lib/typescript/src/games/cat-popper/components/CatCharacter.d.ts +7 -0
  168. package/lib/typescript/src/games/cat-popper/components/CatCharacter.d.ts.map +1 -0
  169. package/lib/typescript/src/games/cat-popper/components/GameBackground.d.ts +7 -0
  170. package/lib/typescript/src/games/cat-popper/components/GameBackground.d.ts.map +1 -0
  171. package/lib/typescript/src/games/cat-popper/components/GameControls.d.ts +10 -0
  172. package/lib/typescript/src/games/cat-popper/components/GameControls.d.ts.map +1 -0
  173. package/lib/typescript/src/games/cat-popper/components/GameGrid.d.ts +13 -0
  174. package/lib/typescript/src/games/cat-popper/components/GameGrid.d.ts.map +1 -0
  175. package/lib/typescript/src/games/cat-popper/components/GameHole.d.ts +12 -0
  176. package/lib/typescript/src/games/cat-popper/components/GameHole.d.ts.map +1 -0
  177. package/lib/typescript/src/games/cat-popper/components/GameOverModal.d.ts +9 -0
  178. package/lib/typescript/src/games/cat-popper/components/GameOverModal.d.ts.map +1 -0
  179. package/lib/typescript/src/games/cat-popper/components/ScoreBoard.d.ts +8 -0
  180. package/lib/typescript/src/games/cat-popper/components/ScoreBoard.d.ts.map +1 -0
  181. package/lib/typescript/src/games/cat-popper/components/index.d.ts +8 -0
  182. package/lib/typescript/src/games/cat-popper/components/index.d.ts.map +1 -0
  183. package/lib/typescript/src/games/fruit-slicer/FruitSlicer.d.ts +16 -0
  184. package/lib/typescript/src/games/fruit-slicer/FruitSlicer.d.ts.map +1 -0
  185. package/lib/typescript/src/games/fruit-slicer/FruitSlicerService.d.ts +67 -0
  186. package/lib/typescript/src/games/fruit-slicer/FruitSlicerService.d.ts.map +1 -0
  187. package/lib/typescript/src/games/fruit-slicer/FruitSlicerStore.d.ts +37 -0
  188. package/lib/typescript/src/games/fruit-slicer/FruitSlicerStore.d.ts.map +1 -0
  189. package/lib/typescript/src/games/fruit-slicer/components/FruitComponent.d.ts +10 -0
  190. package/lib/typescript/src/games/fruit-slicer/components/FruitComponent.d.ts.map +1 -0
  191. package/lib/typescript/src/games/fruit-slicer/components/GameArea.d.ts +17 -0
  192. package/lib/typescript/src/games/fruit-slicer/components/GameArea.d.ts.map +1 -0
  193. package/lib/typescript/src/games/fruit-slicer/components/GameBackground.d.ts +7 -0
  194. package/lib/typescript/src/games/fruit-slicer/components/GameBackground.d.ts.map +1 -0
  195. package/lib/typescript/src/games/fruit-slicer/components/GameControls.d.ts +10 -0
  196. package/lib/typescript/src/games/fruit-slicer/components/GameControls.d.ts.map +1 -0
  197. package/lib/typescript/src/games/fruit-slicer/components/GameOverModal.d.ts +9 -0
  198. package/lib/typescript/src/games/fruit-slicer/components/GameOverModal.d.ts.map +1 -0
  199. package/lib/typescript/src/games/fruit-slicer/components/ParticleSystem.d.ts +8 -0
  200. package/lib/typescript/src/games/fruit-slicer/components/ParticleSystem.d.ts.map +1 -0
  201. package/lib/typescript/src/games/fruit-slicer/components/ScoreBoard.d.ts +9 -0
  202. package/lib/typescript/src/games/fruit-slicer/components/ScoreBoard.d.ts.map +1 -0
  203. package/lib/typescript/src/games/fruit-slicer/components/SliceTrail.d.ts +11 -0
  204. package/lib/typescript/src/games/fruit-slicer/components/SliceTrail.d.ts.map +1 -0
  205. package/lib/typescript/src/games/fruit-slicer/components/index.d.ts +9 -0
  206. package/lib/typescript/src/games/fruit-slicer/components/index.d.ts.map +1 -0
  207. package/lib/typescript/src/games/maze-runner/MazeRunner.d.ts +18 -0
  208. package/lib/typescript/src/games/maze-runner/MazeRunner.d.ts.map +1 -0
  209. package/lib/typescript/src/games/maze-runner/MazeRunnerService.d.ts +82 -0
  210. package/lib/typescript/src/games/maze-runner/MazeRunnerService.d.ts.map +1 -0
  211. package/lib/typescript/src/games/maze-runner/components/EnhancedBallComponent.d.ts +11 -0
  212. package/lib/typescript/src/games/maze-runner/components/EnhancedBallComponent.d.ts.map +1 -0
  213. package/lib/typescript/src/games/maze-runner/components/EnhancedGameArea.d.ts +12 -0
  214. package/lib/typescript/src/games/maze-runner/components/EnhancedGameArea.d.ts.map +1 -0
  215. package/lib/typescript/src/games/maze-runner/components/GameBackground.d.ts +7 -0
  216. package/lib/typescript/src/games/maze-runner/components/GameBackground.d.ts.map +1 -0
  217. package/lib/typescript/src/games/maze-runner/components/GameControls.d.ts +10 -0
  218. package/lib/typescript/src/games/maze-runner/components/GameControls.d.ts.map +1 -0
  219. package/lib/typescript/src/games/maze-runner/components/GameOverModal.d.ts +11 -0
  220. package/lib/typescript/src/games/maze-runner/components/GameOverModal.d.ts.map +1 -0
  221. package/lib/typescript/src/games/maze-runner/components/ScoreBoard.d.ts +8 -0
  222. package/lib/typescript/src/games/maze-runner/components/ScoreBoard.d.ts.map +1 -0
  223. package/lib/typescript/src/games/maze-runner/components/SkiaPipeComponent.d.ts +25 -0
  224. package/lib/typescript/src/games/maze-runner/components/SkiaPipeComponent.d.ts.map +1 -0
  225. package/lib/typescript/src/games/maze-runner/components/StaticGameBackground.d.ts +7 -0
  226. package/lib/typescript/src/games/maze-runner/components/StaticGameBackground.d.ts.map +1 -0
  227. package/lib/typescript/src/games/maze-runner/components/WallComponent.d.ts +10 -0
  228. package/lib/typescript/src/games/maze-runner/components/WallComponent.d.ts.map +1 -0
  229. package/lib/typescript/src/games/maze-runner/components/index.d.ts +8 -0
  230. package/lib/typescript/src/games/maze-runner/components/index.d.ts.map +1 -0
  231. package/lib/typescript/src/games/space-traveller/SpaceTraveller.d.ts +17 -0
  232. package/lib/typescript/src/games/space-traveller/SpaceTraveller.d.ts.map +1 -0
  233. package/lib/typescript/src/games/space-traveller/SpaceTravellerService.d.ts +65 -0
  234. package/lib/typescript/src/games/space-traveller/SpaceTravellerService.d.ts.map +1 -0
  235. package/lib/typescript/src/games/space-traveller/SpaceTravellerStore.d.ts +35 -0
  236. package/lib/typescript/src/games/space-traveller/SpaceTravellerStore.d.ts.map +1 -0
  237. package/lib/typescript/src/games/space-traveller/components/AsteroidComponent.d.ts +9 -0
  238. package/lib/typescript/src/games/space-traveller/components/AsteroidComponent.d.ts.map +1 -0
  239. package/lib/typescript/src/games/space-traveller/components/GameArea.d.ts +17 -0
  240. package/lib/typescript/src/games/space-traveller/components/GameArea.d.ts.map +1 -0
  241. package/lib/typescript/src/games/space-traveller/components/GameBackground.d.ts +7 -0
  242. package/lib/typescript/src/games/space-traveller/components/GameBackground.d.ts.map +1 -0
  243. package/lib/typescript/src/games/space-traveller/components/GameControls.d.ts +10 -0
  244. package/lib/typescript/src/games/space-traveller/components/GameControls.d.ts.map +1 -0
  245. package/lib/typescript/src/games/space-traveller/components/GameOverModal.d.ts +9 -0
  246. package/lib/typescript/src/games/space-traveller/components/GameOverModal.d.ts.map +1 -0
  247. package/lib/typescript/src/games/space-traveller/components/ParticleComponent.d.ts +8 -0
  248. package/lib/typescript/src/games/space-traveller/components/ParticleComponent.d.ts.map +1 -0
  249. package/lib/typescript/src/games/space-traveller/components/ScoreBoard.d.ts +8 -0
  250. package/lib/typescript/src/games/space-traveller/components/ScoreBoard.d.ts.map +1 -0
  251. package/lib/typescript/src/games/space-traveller/components/SettingsModal.d.ts +9 -0
  252. package/lib/typescript/src/games/space-traveller/components/SettingsModal.d.ts.map +1 -0
  253. package/lib/typescript/src/games/space-traveller/components/Spacecraft3D.d.ts +9 -0
  254. package/lib/typescript/src/games/space-traveller/components/Spacecraft3D.d.ts.map +1 -0
  255. package/lib/typescript/src/games/space-traveller/components/SpacecraftPath.d.ts +10 -0
  256. package/lib/typescript/src/games/space-traveller/components/SpacecraftPath.d.ts.map +1 -0
  257. package/lib/typescript/src/games/space-traveller/components/index.d.ts +11 -0
  258. package/lib/typescript/src/games/space-traveller/components/index.d.ts.map +1 -0
  259. package/lib/typescript/src/index.d.ts +7 -0
  260. package/lib/typescript/src/index.d.ts.map +1 -0
  261. package/lib/typescript/src/services/GamesConstants.d.ts +372 -0
  262. package/lib/typescript/src/services/GamesConstants.d.ts.map +1 -0
  263. package/lib/typescript/src/services/GamesService.d.ts +8 -0
  264. package/lib/typescript/src/services/GamesService.d.ts.map +1 -0
  265. package/lib/typescript/src/shared/settings/GameSettings.d.ts +36 -0
  266. package/lib/typescript/src/shared/settings/GameSettings.d.ts.map +1 -0
  267. package/lib/typescript/src/shared/settings/SettingsService.d.ts +32 -0
  268. package/lib/typescript/src/shared/settings/SettingsService.d.ts.map +1 -0
  269. package/package.json +125 -0
@@ -0,0 +1,216 @@
1
+ "use strict";
2
+
3
+ import React from 'react';
4
+ import { Canvas, LinearGradient, vec, Circle, Path, Shadow } from '@shopify/react-native-skia';
5
+ import { useSharedValue, useAnimatedStyle, withRepeat, withTiming, withSequence } from 'react-native-reanimated';
6
+ import Animated from 'react-native-reanimated';
7
+ import { Dimensions } from 'react-native';
8
+ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
9
+ const {
10
+ width: screenWidth,
11
+ height: screenHeight
12
+ } = Dimensions.get('window');
13
+ export const GameBackground = ({
14
+ children
15
+ }) => {
16
+ // Animation values
17
+ const mazeFloat = useSharedValue(0);
18
+ const particleFloat = useSharedValue(0);
19
+ const glowPulse = useSharedValue(0);
20
+ React.useEffect(() => {
21
+ // Maze pattern floating animation
22
+ mazeFloat.value = withRepeat(withSequence(withTiming(1, {
23
+ duration: 4000
24
+ }), withTiming(0, {
25
+ duration: 4000
26
+ })), -1, true);
27
+
28
+ // Particle floating animation
29
+ particleFloat.value = withRepeat(withTiming(1, {
30
+ duration: 6000
31
+ }), -1, true);
32
+
33
+ // Glow pulse animation
34
+ glowPulse.value = withRepeat(withSequence(withTiming(1, {
35
+ duration: 2000
36
+ }), withTiming(0.3, {
37
+ duration: 2000
38
+ })), -1, true);
39
+ }, []);
40
+ const animatedStyle = useAnimatedStyle(() => {
41
+ return {
42
+ position: 'absolute',
43
+ top: 0,
44
+ left: 0,
45
+ right: 0,
46
+ bottom: 0,
47
+ zIndex: -1
48
+ };
49
+ });
50
+ const renderMazePattern = React.useMemo(() => {
51
+ const gridSize = 20;
52
+ const cellSize = screenWidth / gridSize;
53
+ const elements = [];
54
+
55
+ // Create maze-like grid pattern with deterministic values
56
+ for (let i = 0; i < gridSize; i++) {
57
+ for (let j = 0; j < gridSize; j++) {
58
+ const x = i * cellSize;
59
+ const y = j * cellSize;
60
+ // Use deterministic values based on position instead of Math.random()
61
+ const seed = (i * 31 + j * 17) % 100;
62
+ const opacity = seed > 70 ? 0.1 : 0.05;
63
+
64
+ // Vertical lines - deterministic based on position
65
+ if ((i + j * 2) % 5 > 2) {
66
+ elements.push(/*#__PURE__*/_jsx(Path, {
67
+ path: `M ${x} ${y} L ${x} ${y + cellSize}`,
68
+ style: "stroke",
69
+ strokeWidth: 1,
70
+ color: `rgba(139, 69, 19, ${opacity})`
71
+ }, `v-${i}-${j}`));
72
+ }
73
+
74
+ // Horizontal lines - deterministic based on position
75
+ if ((i * 2 + j) % 5 > 2) {
76
+ elements.push(/*#__PURE__*/_jsx(Path, {
77
+ path: `M ${x} ${y} L ${x + cellSize} ${y}`,
78
+ style: "stroke",
79
+ strokeWidth: 1,
80
+ color: `rgba(139, 69, 19, ${opacity})`
81
+ }, `h-${i}-${j}`));
82
+ }
83
+ }
84
+ }
85
+ return elements;
86
+ }, []);
87
+ const renderFloatingElements = React.useMemo(() => {
88
+ const elements = [];
89
+
90
+ // Floating maze pieces with deterministic positioning
91
+ for (let i = 0; i < 8; i++) {
92
+ const seed = i * 37; // Use index-based seed for consistent positioning
93
+ const x = screenWidth / 8 * i + seed % 50;
94
+ const y = screenHeight / 4 * (i % 4) + seed * 2 % 100;
95
+ const size = 15 + seed * 3 % 10;
96
+ elements.push(/*#__PURE__*/_jsx(Circle, {
97
+ cx: x,
98
+ cy: y,
99
+ r: size,
100
+ opacity: 0.15,
101
+ color: "rgba(139, 69, 19, 0.3)",
102
+ children: /*#__PURE__*/_jsx(Shadow, {
103
+ dx: 1,
104
+ dy: 1,
105
+ blur: 3,
106
+ color: "rgba(0,0,0,0.2)"
107
+ })
108
+ }, `maze-piece-${i}`));
109
+ }
110
+
111
+ // Corner accent pieces
112
+ const cornerSize = 40;
113
+ elements.push(
114
+ /*#__PURE__*/
115
+ // Top-left corner
116
+ _jsx(Path, {
117
+ path: `M 20 20 L ${cornerSize + 20} 20 L ${cornerSize + 20} 40 L 40 40 L 40 ${cornerSize + 20} L 20 ${cornerSize + 20} Z`,
118
+ color: "rgba(139, 69, 19, 0.2)",
119
+ opacity: 0.6,
120
+ children: /*#__PURE__*/_jsx(Shadow, {
121
+ dx: 2,
122
+ dy: 2,
123
+ blur: 4,
124
+ color: "rgba(0,0,0,0.1)"
125
+ })
126
+ }, "corner-tl"),
127
+ /*#__PURE__*/
128
+ // Top-right corner
129
+ _jsx(Path, {
130
+ path: `M ${screenWidth - cornerSize - 20} 20 L ${screenWidth - 20} 20 L ${screenWidth - 20} ${cornerSize + 20} L ${screenWidth - 40} ${cornerSize + 20} L ${screenWidth - 40} 40 L ${screenWidth - cornerSize - 20} 40 Z`,
131
+ color: "rgba(139, 69, 19, 0.2)",
132
+ opacity: 0.6,
133
+ children: /*#__PURE__*/_jsx(Shadow, {
134
+ dx: -2,
135
+ dy: 2,
136
+ blur: 4,
137
+ color: "rgba(0,0,0,0.1)"
138
+ })
139
+ }, "corner-tr"),
140
+ /*#__PURE__*/
141
+ // Bottom-left corner
142
+ _jsx(Path, {
143
+ path: `M 20 ${screenHeight - cornerSize - 20} L 40 ${screenHeight - cornerSize - 20} L 40 ${screenHeight - 40} L ${cornerSize + 20} ${screenHeight - 40} L ${cornerSize + 20} ${screenHeight - 20} L 20 ${screenHeight - 20} Z`,
144
+ color: "rgba(139, 69, 19, 0.2)",
145
+ opacity: 0.6,
146
+ children: /*#__PURE__*/_jsx(Shadow, {
147
+ dx: 2,
148
+ dy: -2,
149
+ blur: 4,
150
+ color: "rgba(0,0,0,0.1)"
151
+ })
152
+ }, "corner-bl"),
153
+ /*#__PURE__*/
154
+ // Bottom-right corner
155
+ _jsx(Path, {
156
+ path: `M ${screenWidth - 40} ${screenHeight - cornerSize - 20} L ${screenWidth - 20} ${screenHeight - cornerSize - 20} L ${screenWidth - 20} ${screenHeight - 20} L ${screenWidth - cornerSize - 20} ${screenHeight - 20} L ${screenWidth - cornerSize - 20} ${screenHeight - 40} L ${screenWidth - 40} ${screenHeight - 40} Z`,
157
+ color: "rgba(139, 69, 19, 0.2)",
158
+ opacity: 0.6,
159
+ children: /*#__PURE__*/_jsx(Shadow, {
160
+ dx: -2,
161
+ dy: -2,
162
+ blur: 4,
163
+ color: "rgba(0,0,0,0.1)"
164
+ })
165
+ }, "corner-br"));
166
+ return elements;
167
+ }, []);
168
+ const renderParticles = React.useMemo(() => {
169
+ const particles = [];
170
+ for (let i = 0; i < 20; i++) {
171
+ // Use deterministic values based on index
172
+ const seed = i * 43;
173
+ const x = seed % screenWidth;
174
+ const y = seed * 7 % screenHeight;
175
+ const size = 2 + seed * 3 % 3;
176
+ const opacity = 0.1 + seed * 5 % 20 / 100;
177
+ particles.push(/*#__PURE__*/_jsx(Circle, {
178
+ cx: x,
179
+ cy: y,
180
+ r: size,
181
+ color: `rgba(160, 82, 45, ${opacity})`
182
+ }, `particle-${i}`));
183
+ }
184
+ return particles;
185
+ }, []);
186
+ return /*#__PURE__*/_jsxs(_Fragment, {
187
+ children: [/*#__PURE__*/_jsx(Animated.View, {
188
+ style: animatedStyle,
189
+ children: /*#__PURE__*/_jsxs(Canvas, {
190
+ style: {
191
+ width: screenWidth,
192
+ height: screenHeight
193
+ },
194
+ children: [/*#__PURE__*/_jsx(Path, {
195
+ path: `M 0 0 L ${screenWidth} 0 L ${screenWidth} ${screenHeight} L 0 ${screenHeight} Z`,
196
+ children: /*#__PURE__*/_jsx(LinearGradient, {
197
+ start: vec(0, 0),
198
+ end: vec(0, screenHeight),
199
+ colors: ['#f8f4e6',
200
+ // Light cream
201
+ '#f0e6d2',
202
+ // Warm beige
203
+ '#e8d5b7',
204
+ // Light brown
205
+ '#d4c4a8' // Medium beige
206
+ ]
207
+ })
208
+ }), renderMazePattern, renderFloatingElements, renderParticles, /*#__PURE__*/_jsx(Path, {
209
+ path: `M 0 0 L ${screenWidth} 0 L ${screenWidth} ${screenHeight} L 0 ${screenHeight} Z`,
210
+ color: "rgba(139, 69, 19, 0.03)"
211
+ })]
212
+ })
213
+ }), children]
214
+ });
215
+ };
216
+ //# sourceMappingURL=GameBackground.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["React","Canvas","LinearGradient","vec","Circle","Path","Shadow","useSharedValue","useAnimatedStyle","withRepeat","withTiming","withSequence","Animated","Dimensions","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","width","screenWidth","height","screenHeight","get","GameBackground","children","mazeFloat","particleFloat","glowPulse","useEffect","value","duration","animatedStyle","position","top","left","right","bottom","zIndex","renderMazePattern","useMemo","gridSize","cellSize","elements","i","j","x","y","seed","opacity","push","path","style","strokeWidth","color","renderFloatingElements","size","cx","cy","r","dx","dy","blur","cornerSize","renderParticles","particles","View","start","end","colors"],"sourceRoot":"../../../../../src","sources":["games/maze-runner/components/GameBackground.tsx"],"mappings":";;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,MAAM,EAAEC,cAAc,EAAEC,GAAG,EAAEC,MAAM,EAAEC,IAAI,EAAEC,MAAM,QAAQ,4BAA4B;AAC9F,SACEC,cAAc,EACdC,gBAAgB,EAChBC,UAAU,EACVC,UAAU,EACVC,YAAY,QACP,yBAAyB;AAChC,OAAOC,QAAQ,MAAM,yBAAyB;AAC9C,SAASC,UAAU,QAAQ,cAAc;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA,EAAAC,QAAA,IAAAC,SAAA;AAE1C,MAAM;EAAEC,KAAK,EAAEC,WAAW;EAAEC,MAAM,EAAEC;AAAa,CAAC,GAAGV,UAAU,CAACW,GAAG,CAAC,QAAQ,CAAC;AAM7E,OAAO,MAAMC,cAA6C,GAAGA,CAAC;EAAEC;AAAS,CAAC,KAAK;EAC7E;EACA,MAAMC,SAAS,GAAGpB,cAAc,CAAC,CAAC,CAAC;EACnC,MAAMqB,aAAa,GAAGrB,cAAc,CAAC,CAAC,CAAC;EACvC,MAAMsB,SAAS,GAAGtB,cAAc,CAAC,CAAC,CAAC;EAEnCP,KAAK,CAAC8B,SAAS,CAAC,MAAM;IACpB;IACAH,SAAS,CAAC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OqB,SAAS;EAClB,CAAC,EAAE,EAAE,CAAC;EAEN,oBACEjD,KAAA,CAAAE,SAAA;IAAAO,QAAA,gBACEX,IAAA,CAACH,QAAQ,CAACuD,IAAI;MAACd,KAAK,EAAEpB,aAAc;MAAAP,QAAA,eAClCT,KAAA,CAAChB,MAAM;QAACoD,KAAK,EAAE;UAAEjC,KAAK,EAAEC,WAAW;UAAEC,MAAM,EAAEC;QAAa,CAAE;QAAAG,QAAA,gBAE1DX,IAAA,CAACV,IAAI;UACH+C,IAAI,EAAE,WAAW/B,WAAW,QAAQA,WAAW,IAAIE,YAAY,QAAQA,YAAY,IAAK;UAAAG,QAAA,eAExFX,IAAA,CAACb,cAAc;YACbkE,KAAK,EAAEjE,GAAG,CAAC,CAAC,EAAE,CAAC,CAAE;YACjBkE,GAAG,EAAElE,GAAG,CAAC,CAAC,EAAEoB,YAAY,CAAE;YAC1B+C,MAAM,EAAE,CACN,SAAS;YAAE;YACX,SAAS;YAAE;YACX,SAAS;YAAE;YACX,SAAS,CAAE;YAAA;UACX,CACH;QAAC,CACE,CAAC,EAGN9B,iBAAiB,EAGjBgB,sBAAsB,EAGtBS,eAAe,eAGhBlD,IAAA,CAACV,IAAI;UACH+C,IAAI,EAAE,WAAW/B,WAAW,QAAQA,WAAW,IAAIE,YAAY,QAAQA,YAAY,IAAK;UACxFgC,KAAK,EAAC;QAAyB,CAChC,CAAC;MAAA,CACI;IAAC,CACI,CAAC,EACf7B,QAAQ;EAAA,CACT,CAAC;AAEP,CAAC","ignoreList":[]}
@@ -0,0 +1,129 @@
1
+ "use strict";
2
+
3
+ import React from 'react';
4
+ import { View, Text, TouchableOpacity, StyleSheet } from 'react-native';
5
+ import Animated, { useSharedValue, useAnimatedStyle, withSpring, withRepeat, withSequence, withTiming } from 'react-native-reanimated';
6
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
7
+ export const GameControls = ({
8
+ gameState,
9
+ onStartGame,
10
+ onStopGame
11
+ }) => {
12
+ const buttonScale = useSharedValue(1);
13
+ const pulseAnimation = useSharedValue(1);
14
+ React.useEffect(() => {
15
+ if (!gameState.isPlaying) {
16
+ // Pulse animation for start button when not playing
17
+ pulseAnimation.value = withRepeat(withSequence(withTiming(1.05, {
18
+ duration: 1000
19
+ }), withTiming(1, {
20
+ duration: 1000
21
+ })), -1, true);
22
+ } else {
23
+ pulseAnimation.value = withTiming(1, {
24
+ duration: 300
25
+ });
26
+ }
27
+ }, [gameState.isPlaying]);
28
+ const handleButtonPress = action => {
29
+ buttonScale.value = withSequence(withSpring(0.95, {
30
+ duration: 100
31
+ }), withSpring(1, {
32
+ duration: 100
33
+ }));
34
+ action();
35
+ };
36
+ const animatedButtonStyle = useAnimatedStyle(() => ({
37
+ transform: [{
38
+ scale: buttonScale.value * (!gameState.isPlaying ? pulseAnimation.value : 1)
39
+ }]
40
+ }));
41
+ return /*#__PURE__*/_jsx(View, {
42
+ style: styles.container,
43
+ children: /*#__PURE__*/_jsx(Animated.View, {
44
+ style: animatedButtonStyle,
45
+ children: !gameState.isPlaying ? /*#__PURE__*/_jsxs(TouchableOpacity, {
46
+ style: [styles.button, styles.startButton],
47
+ onPress: () => handleButtonPress(onStartGame),
48
+ activeOpacity: 0.8,
49
+ children: [/*#__PURE__*/_jsx(Text, {
50
+ style: styles.buttonText,
51
+ children: "\uD83C\uDFC1 START MAZE"
52
+ }), /*#__PURE__*/_jsx(Text, {
53
+ style: styles.buttonSubtext,
54
+ children: "Navigate through the maze!"
55
+ })]
56
+ }) : /*#__PURE__*/_jsxs(TouchableOpacity, {
57
+ style: [styles.button, styles.stopButton],
58
+ onPress: () => handleButtonPress(onStopGame),
59
+ activeOpacity: 0.8,
60
+ children: [/*#__PURE__*/_jsx(Text, {
61
+ style: styles.buttonText,
62
+ children: "\uD83D\uDED1 STOP MAZE"
63
+ }), /*#__PURE__*/_jsx(Text, {
64
+ style: styles.buttonSubtext,
65
+ children: "End current maze game"
66
+ })]
67
+ })
68
+ })
69
+ });
70
+ };
71
+ const styles = StyleSheet.create({
72
+ container: {
73
+ paddingHorizontal: 20,
74
+ paddingVertical: 15,
75
+ alignItems: 'center'
76
+ },
77
+ button: {
78
+ minHeight: 70,
79
+ minWidth: 200,
80
+ borderRadius: 30,
81
+ justifyContent: 'center',
82
+ alignItems: 'center',
83
+ paddingHorizontal: 32,
84
+ paddingVertical: 20,
85
+ marginVertical: 8,
86
+ shadowColor: '#000',
87
+ shadowOffset: {
88
+ width: 0,
89
+ height: 8
90
+ },
91
+ shadowOpacity: 0.4,
92
+ shadowRadius: 12,
93
+ elevation: 8,
94
+ overflow: 'hidden',
95
+ position: 'relative'
96
+ },
97
+ startButton: {
98
+ backgroundColor: '#10b981',
99
+ borderWidth: 3,
100
+ borderColor: '#34d399'
101
+ },
102
+ stopButton: {
103
+ backgroundColor: '#dc2626',
104
+ borderWidth: 3,
105
+ borderColor: '#f87171'
106
+ },
107
+ buttonText: {
108
+ fontSize: 20,
109
+ fontWeight: '800',
110
+ color: '#ffffff',
111
+ textAlign: 'center',
112
+ letterSpacing: 1,
113
+ textShadowColor: 'rgba(0, 0, 0, 0.3)',
114
+ textShadowOffset: {
115
+ width: 1,
116
+ height: 1
117
+ },
118
+ textShadowRadius: 2
119
+ },
120
+ buttonSubtext: {
121
+ fontSize: 14,
122
+ fontWeight: '600',
123
+ color: 'rgba(255, 255, 255, 0.8)',
124
+ textAlign: 'center',
125
+ marginTop: 4,
126
+ letterSpacing: 0.5
127
+ }
128
+ });
129
+ //# sourceMappingURL=GameControls.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["React","View","Text","TouchableOpacity","StyleSheet","Animated","useSharedValue","useAnimatedStyle","withSpring","withRepeat","withSequence","withTiming","jsx","_jsx","jsxs","_jsxs","GameControls","gameState","onStartGame","onStopGame","buttonScale","pulseAnimation","useEffect","isPlaying","value","duration","handleButtonPress","action","animatedButtonStyle","transform","scale","style","styles","container","children","button","startButton","onPress","activeOpacity","buttonText","buttonSubtext","stopButton","create","paddingHorizontal","paddingVertical","alignItems","minHeight","minWidth","borderRadius","justifyContent","marginVertical","shadowColor","shadowOffset","width","height","shadowOpacity","shadowRadius","elevation","overflow","position","backgroundColor","borderWidth","borderColor","fontSize","fontWeight","color","textAlign","letterSpacing","textShadowColor","textShadowOffset","textShadowRadius","marginTop"],"sourceRoot":"../../../../../src","sources":["games/maze-runner/components/GameControls.tsx"],"mappings":";;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,IAAI,EAAEC,IAAI,EAAEC,gBAAgB,EAAEC,UAAU,QAAQ,cAAc;AACvE,OAAOC,QAAQ,IACbC,cAAc,EACdC,gBAAgB,EAChBC,UAAU,EACVC,UAAU,EACVC,YAAY,EACZC,UAAU,QACL,yBAAyB;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AASjC,OAAO,MAAMC,YAAyC,GAAGA,CAAC;EACxDC,SAAS;EACTC,WAAW;EACXC;AACF,CAAC,KAAK;EACJ,MAAMC,WAAW,GAAGd,cAAc,CAAC,CAAC,CAAC;EACrC,MAAMe,cAAc,GAAGf,cAAc,CAAC,CAAC,CAAC;EAExCN,KAAK,CAACsB,SAAS,CAAC,MAAM;IACpB,IAAI,CAACL,SAAS,CAACM,SAAS,EAAE;MACxB;MACAF,cAAc,CAACG,KAAK,GAAGf,UAAU,CAC/BC,YAAY,CACVC,UAAU,CAAC,IAAI,EAAE;QAAEc,QAAQ,EAAE;MAAK,CAAC,CAAC,EACpCd,UAAU,CAAC,CAAC,EAAE;QAAEc,QAAQ,EAAE;MAAK,CAAC,CAClC,CAAC,EACD,CAAC,CAAC,EACF,IACF,CAAC;IACH,CAAC,MAAM;MACLJ,cAAc,CAACG,KAAK,GAAGb,UAAU,CAAC,CAAC,EAAE;QAAEc,QAAQ,EAAE;MAAI,CAAC,CAAC;IACzD;EACF,CAAC,EAAE,CAACR,SAAS,CAACM,SAAS,CAAC,CAAC;EAEzB,MAAMG,iBAAiB,GAAIC,MAAk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EAAE,SAAS;IAChBC,SAAS,EAAE,QAAQ;IACnBC,aAAa,EAAE,CAAC;IAChBC,eAAe,EAAE,oBAAoB;IACrCC,gBAAgB,EAAE;MAAEhB,KAAK,EAAE,CAAC;MAAEC,MAAM,EAAE;IAAE,CAAC;IACzCgB,gBAAgB,EAAE;EACpB,CAAC;EACD9B,aAAa,EAAE;IACbuB,QAAQ,EAAE,EAAE;IACZC,UAAU,EAAE,KAAK;IACjBC,KAAK,EAAE,0BAA0B;IACjCC,SAAS,EAAE,QAAQ;IACnBK,SAAS,EAAE,CAAC;IACZJ,aAAa,EAAE;EACjB;AACF,CAAC,CAAC","ignoreList":[]}
@@ -0,0 +1,134 @@
1
+ "use strict";
2
+
3
+ import React from 'react';
4
+ import { View, Text, TouchableOpacity, StyleSheet, Modal } from 'react-native';
5
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
6
+ export const GameOverModal = ({
7
+ visible,
8
+ gameState,
9
+ onPlayAgain,
10
+ onClose
11
+ }) => {
12
+ return /*#__PURE__*/_jsx(Modal, {
13
+ visible: visible,
14
+ transparent: true,
15
+ animationType: "fade",
16
+ onRequestClose: onClose,
17
+ children: /*#__PURE__*/_jsx(View, {
18
+ style: styles.gameOverOverlay,
19
+ children: /*#__PURE__*/_jsx(View, {
20
+ style: styles.gameOverModal,
21
+ children: /*#__PURE__*/_jsxs(View, {
22
+ style: styles.modalContent,
23
+ children: [/*#__PURE__*/_jsx(Text, {
24
+ style: styles.gameOverTitle,
25
+ children: gameState.isCompleted ? 'Maze Completed!' : 'Game Over!'
26
+ }), /*#__PURE__*/_jsxs(View, {
27
+ style: styles.finalScoreContainer,
28
+ children: [/*#__PURE__*/_jsx(Text, {
29
+ style: styles.finalScoreLabel,
30
+ children: "Final Score"
31
+ }), /*#__PURE__*/_jsx(Text, {
32
+ style: styles.finalScoreValue,
33
+ children: gameState.score
34
+ })]
35
+ }), /*#__PURE__*/_jsx(View, {
36
+ style: styles.playAgainContainer,
37
+ children: /*#__PURE__*/_jsx(TouchableOpacity, {
38
+ style: styles.playAgainButton,
39
+ onPress: onPlayAgain,
40
+ children: /*#__PURE__*/_jsx(Text, {
41
+ style: styles.buttonText,
42
+ children: "Play Again"
43
+ })
44
+ })
45
+ })]
46
+ })
47
+ })
48
+ })
49
+ });
50
+ };
51
+ const styles = StyleSheet.create({
52
+ gameOverOverlay: {
53
+ flex: 1,
54
+ justifyContent: 'center',
55
+ alignItems: 'center',
56
+ backgroundColor: 'rgba(0, 0, 0, 0.3)' // 0.3 transparent background as requested
57
+ },
58
+ gameOverModal: {
59
+ backgroundColor: 'rgba(139, 69, 19, 0.8)',
60
+ // Sky blue background like WhackIt
61
+ borderRadius: 24,
62
+ minWidth: '80%',
63
+ shadowColor: '#000',
64
+ shadowOffset: {
65
+ width: 0,
66
+ height: 8
67
+ },
68
+ shadowOpacity: 0.4,
69
+ shadowRadius: 12,
70
+ elevation: 12,
71
+ borderWidth: 3,
72
+ borderColor: 'rgba(139, 69, 19, 0.8)' // Brown border for maze theme
73
+ },
74
+ modalContent: {
75
+ padding: 40,
76
+ alignItems: 'center'
77
+ },
78
+ gameOverTitle: {
79
+ fontSize: 30,
80
+ fontWeight: 'bold',
81
+ color: '#ffffff',
82
+ marginBottom: 32,
83
+ textAlign: 'center'
84
+ },
85
+ finalScoreContainer: {
86
+ alignItems: 'center',
87
+ marginBottom: 32,
88
+ backgroundColor: '#8B4513',
89
+ // Brown background for maze theme
90
+ borderRadius: 16,
91
+ padding: 20,
92
+ minWidth: 150
93
+ },
94
+ finalScoreLabel: {
95
+ fontSize: 18,
96
+ color: '#ffffff',
97
+ fontWeight: 'bold',
98
+ marginBottom: 8
99
+ },
100
+ finalScoreValue: {
101
+ fontSize: 48,
102
+ color: '#facc15',
103
+ // Gold color for score
104
+ fontWeight: 'bold',
105
+ textAlign: 'center'
106
+ },
107
+ playAgainContainer: {
108
+ alignItems: 'center'
109
+ },
110
+ playAgainButton: {
111
+ backgroundColor: '#22c55e',
112
+ paddingHorizontal: 40,
113
+ paddingVertical: 20,
114
+ borderRadius: 24,
115
+ shadowColor: '#000',
116
+ shadowOffset: {
117
+ width: 0,
118
+ height: 2
119
+ },
120
+ shadowOpacity: 0.25,
121
+ shadowRadius: 3.84,
122
+ elevation: 5,
123
+ borderWidth: 2,
124
+ borderColor: '#4ade80'
125
+ },
126
+ buttonText: {
127
+ fontSize: 18,
128
+ fontWeight: 'bold',
129
+ color: '#ffffff',
130
+ textAlign: 'center',
131
+ lineHeight: 24
132
+ }
133
+ });
134
+ //# sourceMappingURL=GameOverModal.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["React","View","Text","TouchableOpacity","StyleSheet","Modal","jsx","_jsx","jsxs","_jsxs","GameOverModal","visible","gameState","onPlayAgain","onClose","transparent","animationType","onRequestClose","children","style","styles","gameOverOverlay","gameOverModal","modalContent","gameOverTitle","isCompleted","finalScoreContainer","finalScoreLabel","finalScoreValue","score","playAgainContainer","playAgainButton","onPress","buttonText","create","flex","justifyContent","alignItems","backgroundColor","borderRadius","minWidth","shadowColor","shadowOffset","width","height","shadowOpacity","shadowRadius","elevation","borderWidth","borderColor","padding","fontSize","fontWeight","color","marginBottom","textAlign","paddingHorizontal","paddingVertical","lineHeight"],"sourceRoot":"../../../../../src","sources":["games/maze-runner/components/GameOverModal.tsx"],"mappings":";;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,IAAI,EAAEC,IAAI,EAAEC,gBAAgB,EAAEC,UAAU,EAAEC,KAAK,QAAQ,cAAc;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAU/E,OAAO,MAAMC,aAA2C,GAAGA,CAAC;EAC1DC,OAAO;EACPC,SAAS;EACTC,WAAW;EACXC;AACF,CAAC,KAAK;EACJ,oBACEP,IAAA,CAACF,KAAK;IACJM,OAAO,EAAEA,OAAQ;IACjBI,WAAW;IACXC,aAAa,EAAC,MAAM;IACpBC,cAAc,EAAEH,OAAQ;I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,EAAE,EAAE;IAChBE,WAAW,EAAE,MAAM;IACnBC,YAAY,EAAE;MAAEC,KAAK,EAAE,CAAC;MAAEC,MAAM,EAAE;IAAE,CAAC;IACrCC,aAAa,EAAE,IAAI;IACnBC,YAAY,EAAE,IAAI;IAClBC,SAAS,EAAE,CAAC;IACZC,WAAW,EAAE,CAAC;IACdC,WAAW,EAAE;EACf,CAAC;EACDhB,UAAU,EAAE;IACVkB,QAAQ,EAAE,EAAE;IACZC,UAAU,EAAE,MAAM;IAClBC,KAAK,EAAE,SAAS;IAChBE,SAAS,EAAE,QAAQ;IACnBG,UAAU,EAAE;EACd;AACF,CAAC,CAAC","ignoreList":[]}
@@ -0,0 +1,81 @@
1
+ "use strict";
2
+
3
+ import React from 'react';
4
+ import { View, Text, StyleSheet } from 'react-native';
5
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
6
+ export const ScoreBoard = ({
7
+ gameState
8
+ }) => {
9
+ const formatTime = seconds => {
10
+ const mins = Math.floor(seconds / 60);
11
+ const secs = seconds % 60;
12
+ return `${mins}:${secs.toString().padStart(2, '0')}`;
13
+ };
14
+ return /*#__PURE__*/_jsxs(View, {
15
+ style: styles.scoreBoard,
16
+ children: [/*#__PURE__*/_jsxs(View, {
17
+ style: styles.scoreSection,
18
+ children: [/*#__PURE__*/_jsx(Text, {
19
+ style: styles.scoreLabel,
20
+ children: "Score"
21
+ }), /*#__PURE__*/_jsx(Text, {
22
+ style: styles.scoreValue,
23
+ children: gameState.score
24
+ })]
25
+ }), /*#__PURE__*/_jsxs(View, {
26
+ style: styles.scoreSection,
27
+ children: [/*#__PURE__*/_jsx(Text, {
28
+ style: styles.scoreLabel,
29
+ children: "Time"
30
+ }), /*#__PURE__*/_jsx(Text, {
31
+ style: styles.timeValue,
32
+ children: formatTime(gameState.timeElapsed)
33
+ })]
34
+ })]
35
+ });
36
+ };
37
+ const styles = StyleSheet.create({
38
+ scoreBoard: {
39
+ flexDirection: 'row',
40
+ justifyContent: 'space-between',
41
+ alignItems: 'center',
42
+ backgroundColor: 'rgba(139, 69, 19, 0.4)',
43
+ // Semi-transparent brown for maze theme
44
+ borderRadius: 16,
45
+ padding: 20,
46
+ margin: 20,
47
+ borderWidth: 1,
48
+ borderColor: 'rgba(255, 255, 255, 0.3)',
49
+ // Subtle white border
50
+ shadowColor: '#000',
51
+ shadowOffset: {
52
+ width: 0,
53
+ height: 2
54
+ },
55
+ shadowOpacity: 0.15,
56
+ // Reduced shadow opacity
57
+ shadowRadius: 3.84,
58
+ elevation: 3 // Reduced elevation
59
+ },
60
+ scoreSection: {
61
+ alignItems: 'center',
62
+ flex: 1
63
+ },
64
+ scoreLabel: {
65
+ fontSize: 18,
66
+ fontWeight: 'bold',
67
+ color: '#ffffff',
68
+ marginBottom: 4
69
+ },
70
+ scoreValue: {
71
+ fontSize: 30,
72
+ fontWeight: 'bold',
73
+ color: '#92400e' // Brown color for score value
74
+ },
75
+ timeValue: {
76
+ fontSize: 30,
77
+ fontWeight: 'bold',
78
+ color: '#92400e' // Brown color for time value
79
+ }
80
+ });
81
+ //# sourceMappingURL=ScoreBoard.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["React","View","Text","StyleSheet","jsx","_jsx","jsxs","_jsxs","ScoreBoard","gameState","formatTime","seconds","mins","Math","floor","secs","toString","padStart","style","styles","scoreBoard","children","scoreSection","scoreLabel","scoreValue","score","timeValue","timeElapsed","create","flexDirection","justifyContent","alignItems","backgroundColor","borderRadius","padding","margin","borderWidth","borderColor","shadowColor","shadowOffset","width","height","shadowOpacity","shadowRadius","elevation","flex","fontSize","fontWeight","color","marginBottom"],"sourceRoot":"../../../../../src","sources":["games/maze-runner/components/ScoreBoard.tsx"],"mappings":";;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,IAAI,EAAEC,IAAI,EAAEC,UAAU,QAAQ,cAAc;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAOtD,OAAO,MAAM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