@p100-web/core 100.0.61

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 (349) hide show
  1. package/dist/index.d.ts +136 -0
  2. package/dist/index.d.ts.map +1 -0
  3. package/dist/index.js +101 -0
  4. package/dist/index.js.map +1 -0
  5. package/dist/src/AdaptivePerformance.d.ts +20 -0
  6. package/dist/src/AdaptivePerformance.d.ts.map +1 -0
  7. package/dist/src/AdaptivePerformance.js +110 -0
  8. package/dist/src/AdaptivePerformance.js.map +1 -0
  9. package/dist/src/DBEvent.d.ts +22 -0
  10. package/dist/src/DBEvent.d.ts.map +1 -0
  11. package/dist/src/DBEvent.js +19 -0
  12. package/dist/src/DBEvent.js.map +1 -0
  13. package/dist/src/DBNode.d.ts +33 -0
  14. package/dist/src/DBNode.d.ts.map +1 -0
  15. package/dist/src/DBNode.js +31 -0
  16. package/dist/src/DBNode.js.map +1 -0
  17. package/dist/src/DBScene.d.ts +11 -0
  18. package/dist/src/DBScene.d.ts.map +1 -0
  19. package/dist/src/DBScene.js +9 -0
  20. package/dist/src/DBScene.js.map +1 -0
  21. package/dist/src/DBVariable.d.ts +22 -0
  22. package/dist/src/DBVariable.d.ts.map +1 -0
  23. package/dist/src/DBVariable.js +19 -0
  24. package/dist/src/DBVariable.js.map +1 -0
  25. package/dist/src/DevTools.d.ts +4 -0
  26. package/dist/src/DevTools.d.ts.map +1 -0
  27. package/dist/src/DevTools.js +10 -0
  28. package/dist/src/DevTools.js.map +1 -0
  29. package/dist/src/GameContext.d.ts +179 -0
  30. package/dist/src/GameContext.d.ts.map +1 -0
  31. package/dist/src/GameContext.js +594 -0
  32. package/dist/src/GameContext.js.map +1 -0
  33. package/dist/src/IAudioListener.d.ts +4 -0
  34. package/dist/src/IAudioListener.d.ts.map +1 -0
  35. package/dist/src/IAudioListener.js +2 -0
  36. package/dist/src/IAudioListener.js.map +1 -0
  37. package/dist/src/ICameraControls.d.ts +14 -0
  38. package/dist/src/ICameraControls.d.ts.map +1 -0
  39. package/dist/src/ICameraControls.js +2 -0
  40. package/dist/src/ICameraControls.js.map +1 -0
  41. package/dist/src/ICameraNode.d.ts +6 -0
  42. package/dist/src/ICameraNode.d.ts.map +1 -0
  43. package/dist/src/ICameraNode.js +2 -0
  44. package/dist/src/ICameraNode.js.map +1 -0
  45. package/dist/src/IComponentFactory.d.ts +8 -0
  46. package/dist/src/IComponentFactory.d.ts.map +1 -0
  47. package/dist/src/IComponentFactory.js +2 -0
  48. package/dist/src/IComponentFactory.js.map +1 -0
  49. package/dist/src/IEngine.d.ts +26 -0
  50. package/dist/src/IEngine.d.ts.map +1 -0
  51. package/dist/src/IEngine.js +2 -0
  52. package/dist/src/IEngine.js.map +1 -0
  53. package/dist/src/IMaterial.d.ts +5 -0
  54. package/dist/src/IMaterial.d.ts.map +1 -0
  55. package/dist/src/IMaterial.js +2 -0
  56. package/dist/src/IMaterial.js.map +1 -0
  57. package/dist/src/IPCanvas.d.ts +45 -0
  58. package/dist/src/IPCanvas.d.ts.map +1 -0
  59. package/dist/src/IPCanvas.js +2 -0
  60. package/dist/src/IPCanvas.js.map +1 -0
  61. package/dist/src/IPNodeRenderer.d.ts +23 -0
  62. package/dist/src/IPNodeRenderer.d.ts.map +1 -0
  63. package/dist/src/IPNodeRenderer.js +2 -0
  64. package/dist/src/IPNodeRenderer.js.map +1 -0
  65. package/dist/src/IStats.d.ts +9 -0
  66. package/dist/src/IStats.d.ts.map +1 -0
  67. package/dist/src/IStats.js +3 -0
  68. package/dist/src/IStats.js.map +1 -0
  69. package/dist/src/MathTools.d.ts +4 -0
  70. package/dist/src/MathTools.d.ts.map +1 -0
  71. package/dist/src/MathTools.js +7 -0
  72. package/dist/src/MathTools.js.map +1 -0
  73. package/dist/src/PAction.d.ts +64 -0
  74. package/dist/src/PAction.d.ts.map +1 -0
  75. package/dist/src/PAction.js +209 -0
  76. package/dist/src/PAction.js.map +1 -0
  77. package/dist/src/PComponent.d.ts +60 -0
  78. package/dist/src/PComponent.d.ts.map +1 -0
  79. package/dist/src/PComponent.js +44 -0
  80. package/dist/src/PComponent.js.map +1 -0
  81. package/dist/src/PEnums.d.ts +98 -0
  82. package/dist/src/PEnums.d.ts.map +1 -0
  83. package/dist/src/PEnums.js +110 -0
  84. package/dist/src/PEnums.js.map +1 -0
  85. package/dist/src/PEvent.d.ts +27 -0
  86. package/dist/src/PEvent.d.ts.map +1 -0
  87. package/dist/src/PEvent.js +40 -0
  88. package/dist/src/PEvent.js.map +1 -0
  89. package/dist/src/PNode.d.ts +111 -0
  90. package/dist/src/PNode.d.ts.map +1 -0
  91. package/dist/src/PNode.js +488 -0
  92. package/dist/src/PNode.js.map +1 -0
  93. package/dist/src/PPayload.d.ts +7 -0
  94. package/dist/src/PPayload.d.ts.map +1 -0
  95. package/dist/src/PPayload.js +19 -0
  96. package/dist/src/PPayload.js.map +1 -0
  97. package/dist/src/PTypes.d.ts +140 -0
  98. package/dist/src/PTypes.d.ts.map +1 -0
  99. package/dist/src/PTypes.js +2 -0
  100. package/dist/src/PTypes.js.map +1 -0
  101. package/dist/src/PVariable.d.ts +29 -0
  102. package/dist/src/PVariable.d.ts.map +1 -0
  103. package/dist/src/PVariable.js +51 -0
  104. package/dist/src/PVariable.js.map +1 -0
  105. package/dist/src/PVector2.d.ts +14 -0
  106. package/dist/src/PVector2.d.ts.map +1 -0
  107. package/dist/src/PVector2.js +25 -0
  108. package/dist/src/PVector2.js.map +1 -0
  109. package/dist/src/PVector3.d.ts +17 -0
  110. package/dist/src/PVector3.d.ts.map +1 -0
  111. package/dist/src/PVector3.js +36 -0
  112. package/dist/src/PVector3.js.map +1 -0
  113. package/dist/src/animations/IAnimationAction.d.ts +9 -0
  114. package/dist/src/animations/IAnimationAction.d.ts.map +1 -0
  115. package/dist/src/animations/IAnimationAction.js +2 -0
  116. package/dist/src/animations/IAnimationAction.js.map +1 -0
  117. package/dist/src/animations/IAnimationClip.d.ts +5 -0
  118. package/dist/src/animations/IAnimationClip.d.ts.map +1 -0
  119. package/dist/src/animations/IAnimationClip.js +2 -0
  120. package/dist/src/animations/IAnimationClip.js.map +1 -0
  121. package/dist/src/animations/IAnimationMixer.d.ts +7 -0
  122. package/dist/src/animations/IAnimationMixer.d.ts.map +1 -0
  123. package/dist/src/animations/IAnimationMixer.js +2 -0
  124. package/dist/src/animations/IAnimationMixer.js.map +1 -0
  125. package/dist/src/media/IMediaLoader.d.ts +31 -0
  126. package/dist/src/media/IMediaLoader.d.ts.map +1 -0
  127. package/dist/src/media/IMediaLoader.js +2 -0
  128. package/dist/src/media/IMediaLoader.js.map +1 -0
  129. package/dist/src/media/MediaManager.d.ts +17 -0
  130. package/dist/src/media/MediaManager.d.ts.map +1 -0
  131. package/dist/src/media/MediaManager.js +19 -0
  132. package/dist/src/media/MediaManager.js.map +1 -0
  133. package/dist/src/media/PFile.d.ts +13 -0
  134. package/dist/src/media/PFile.d.ts.map +1 -0
  135. package/dist/src/media/PFile.js +28 -0
  136. package/dist/src/media/PFile.js.map +1 -0
  137. package/dist/src/pcomponents/BaseBackground.d.ts +27 -0
  138. package/dist/src/pcomponents/BaseBackground.d.ts.map +1 -0
  139. package/dist/src/pcomponents/BaseBackground.js +21 -0
  140. package/dist/src/pcomponents/BaseBackground.js.map +1 -0
  141. package/dist/src/pcomponents/BaseMaterial.d.ts +45 -0
  142. package/dist/src/pcomponents/BaseMaterial.d.ts.map +1 -0
  143. package/dist/src/pcomponents/BaseMaterial.js +47 -0
  144. package/dist/src/pcomponents/BaseMaterial.js.map +1 -0
  145. package/dist/src/pcomponents/PAnimator.d.ts +37 -0
  146. package/dist/src/pcomponents/PAnimator.d.ts.map +1 -0
  147. package/dist/src/pcomponents/PAnimator.js +43 -0
  148. package/dist/src/pcomponents/PAnimator.js.map +1 -0
  149. package/dist/src/pcomponents/PBasicMaterial.d.ts +23 -0
  150. package/dist/src/pcomponents/PBasicMaterial.d.ts.map +1 -0
  151. package/dist/src/pcomponents/PBasicMaterial.js +38 -0
  152. package/dist/src/pcomponents/PBasicMaterial.js.map +1 -0
  153. package/dist/src/pcomponents/PCallAction.d.ts +19 -0
  154. package/dist/src/pcomponents/PCallAction.d.ts.map +1 -0
  155. package/dist/src/pcomponents/PCallAction.js +25 -0
  156. package/dist/src/pcomponents/PCallAction.js.map +1 -0
  157. package/dist/src/pcomponents/PCallActions.d.ts +24 -0
  158. package/dist/src/pcomponents/PCallActions.d.ts.map +1 -0
  159. package/dist/src/pcomponents/PCallActions.js +38 -0
  160. package/dist/src/pcomponents/PCallActions.js.map +1 -0
  161. package/dist/src/pcomponents/PCameraPosition.d.ts +29 -0
  162. package/dist/src/pcomponents/PCameraPosition.d.ts.map +1 -0
  163. package/dist/src/pcomponents/PCameraPosition.js +76 -0
  164. package/dist/src/pcomponents/PCameraPosition.js.map +1 -0
  165. package/dist/src/pcomponents/PCameraTarget.d.ts +29 -0
  166. package/dist/src/pcomponents/PCameraTarget.d.ts.map +1 -0
  167. package/dist/src/pcomponents/PCameraTarget.js +77 -0
  168. package/dist/src/pcomponents/PCameraTarget.js.map +1 -0
  169. package/dist/src/pcomponents/PCollider.d.ts +39 -0
  170. package/dist/src/pcomponents/PCollider.d.ts.map +1 -0
  171. package/dist/src/pcomponents/PCollider.js +56 -0
  172. package/dist/src/pcomponents/PCollider.js.map +1 -0
  173. package/dist/src/pcomponents/PCompareBoolean.d.ts +23 -0
  174. package/dist/src/pcomponents/PCompareBoolean.d.ts.map +1 -0
  175. package/dist/src/pcomponents/PCompareBoolean.js +39 -0
  176. package/dist/src/pcomponents/PCompareBoolean.js.map +1 -0
  177. package/dist/src/pcomponents/PCompareNumber.d.ts +25 -0
  178. package/dist/src/pcomponents/PCompareNumber.d.ts.map +1 -0
  179. package/dist/src/pcomponents/PCompareNumber.js +45 -0
  180. package/dist/src/pcomponents/PCompareNumber.js.map +1 -0
  181. package/dist/src/pcomponents/PCompareString.d.ts +25 -0
  182. package/dist/src/pcomponents/PCompareString.d.ts.map +1 -0
  183. package/dist/src/pcomponents/PCompareString.js +43 -0
  184. package/dist/src/pcomponents/PCompareString.js.map +1 -0
  185. package/dist/src/pcomponents/PCompareVariable.d.ts +28 -0
  186. package/dist/src/pcomponents/PCompareVariable.d.ts.map +1 -0
  187. package/dist/src/pcomponents/PCompareVariable.js +51 -0
  188. package/dist/src/pcomponents/PCompareVariable.js.map +1 -0
  189. package/dist/src/pcomponents/PControllerInput.d.ts +30 -0
  190. package/dist/src/pcomponents/PControllerInput.d.ts.map +1 -0
  191. package/dist/src/pcomponents/PControllerInput.js +42 -0
  192. package/dist/src/pcomponents/PControllerInput.js.map +1 -0
  193. package/dist/src/pcomponents/PCubeGeometry.d.ts +18 -0
  194. package/dist/src/pcomponents/PCubeGeometry.d.ts.map +1 -0
  195. package/dist/src/pcomponents/PCubeGeometry.js +22 -0
  196. package/dist/src/pcomponents/PCubeGeometry.js.map +1 -0
  197. package/dist/src/pcomponents/PDebug.d.ts +21 -0
  198. package/dist/src/pcomponents/PDebug.d.ts.map +1 -0
  199. package/dist/src/pcomponents/PDebug.js +31 -0
  200. package/dist/src/pcomponents/PDebug.js.map +1 -0
  201. package/dist/src/pcomponents/PEnvironment.d.ts +28 -0
  202. package/dist/src/pcomponents/PEnvironment.d.ts.map +1 -0
  203. package/dist/src/pcomponents/PEnvironment.js +44 -0
  204. package/dist/src/pcomponents/PEnvironment.js.map +1 -0
  205. package/dist/src/pcomponents/PFadeAnimation.d.ts +30 -0
  206. package/dist/src/pcomponents/PFadeAnimation.d.ts.map +1 -0
  207. package/dist/src/pcomponents/PFadeAnimation.js +94 -0
  208. package/dist/src/pcomponents/PFadeAnimation.js.map +1 -0
  209. package/dist/src/pcomponents/PHud.d.ts +12 -0
  210. package/dist/src/pcomponents/PHud.d.ts.map +1 -0
  211. package/dist/src/pcomponents/PHud.js +12 -0
  212. package/dist/src/pcomponents/PHud.js.map +1 -0
  213. package/dist/src/pcomponents/PImageBackground.d.ts +13 -0
  214. package/dist/src/pcomponents/PImageBackground.d.ts.map +1 -0
  215. package/dist/src/pcomponents/PImageBackground.js +18 -0
  216. package/dist/src/pcomponents/PImageBackground.js.map +1 -0
  217. package/dist/src/pcomponents/PImageCache.d.ts +22 -0
  218. package/dist/src/pcomponents/PImageCache.d.ts.map +1 -0
  219. package/dist/src/pcomponents/PImageCache.js +69 -0
  220. package/dist/src/pcomponents/PImageCache.js.map +1 -0
  221. package/dist/src/pcomponents/PImageDetector.d.ts +28 -0
  222. package/dist/src/pcomponents/PImageDetector.d.ts.map +1 -0
  223. package/dist/src/pcomponents/PImageDetector.js +38 -0
  224. package/dist/src/pcomponents/PImageDetector.js.map +1 -0
  225. package/dist/src/pcomponents/PLight.d.ts +15 -0
  226. package/dist/src/pcomponents/PLight.d.ts.map +1 -0
  227. package/dist/src/pcomponents/PLight.js +18 -0
  228. package/dist/src/pcomponents/PLight.js.map +1 -0
  229. package/dist/src/pcomponents/PLightDirectional.d.ts +19 -0
  230. package/dist/src/pcomponents/PLightDirectional.d.ts.map +1 -0
  231. package/dist/src/pcomponents/PLightDirectional.js +24 -0
  232. package/dist/src/pcomponents/PLightDirectional.js.map +1 -0
  233. package/dist/src/pcomponents/PMaskedMaterial.d.ts +20 -0
  234. package/dist/src/pcomponents/PMaskedMaterial.d.ts.map +1 -0
  235. package/dist/src/pcomponents/PMaskedMaterial.js +35 -0
  236. package/dist/src/pcomponents/PMaskedMaterial.js.map +1 -0
  237. package/dist/src/pcomponents/PModelGLTF.d.ts +33 -0
  238. package/dist/src/pcomponents/PModelGLTF.d.ts.map +1 -0
  239. package/dist/src/pcomponents/PModelGLTF.js +53 -0
  240. package/dist/src/pcomponents/PModelGLTF.js.map +1 -0
  241. package/dist/src/pcomponents/PMoveAnimation.d.ts +22 -0
  242. package/dist/src/pcomponents/PMoveAnimation.d.ts.map +1 -0
  243. package/dist/src/pcomponents/PMoveAnimation.js +44 -0
  244. package/dist/src/pcomponents/PMoveAnimation.js.map +1 -0
  245. package/dist/src/pcomponents/PMoveToAnimation.d.ts +26 -0
  246. package/dist/src/pcomponents/PMoveToAnimation.d.ts.map +1 -0
  247. package/dist/src/pcomponents/PMoveToAnimation.js +79 -0
  248. package/dist/src/pcomponents/PMoveToAnimation.js.map +1 -0
  249. package/dist/src/pcomponents/PPhysicalMaterial.d.ts +27 -0
  250. package/dist/src/pcomponents/PPhysicalMaterial.d.ts.map +1 -0
  251. package/dist/src/pcomponents/PPhysicalMaterial.js +41 -0
  252. package/dist/src/pcomponents/PPhysicalMaterial.js.map +1 -0
  253. package/dist/src/pcomponents/PPlaneDetector.d.ts +20 -0
  254. package/dist/src/pcomponents/PPlaneDetector.d.ts.map +1 -0
  255. package/dist/src/pcomponents/PPlaneDetector.js +26 -0
  256. package/dist/src/pcomponents/PPlaneDetector.js.map +1 -0
  257. package/dist/src/pcomponents/PPlaneGeometry.d.ts +20 -0
  258. package/dist/src/pcomponents/PPlaneGeometry.d.ts.map +1 -0
  259. package/dist/src/pcomponents/PPlaneGeometry.js +25 -0
  260. package/dist/src/pcomponents/PPlaneGeometry.js.map +1 -0
  261. package/dist/src/pcomponents/PProjectRoot.d.ts +38 -0
  262. package/dist/src/pcomponents/PProjectRoot.d.ts.map +1 -0
  263. package/dist/src/pcomponents/PProjectRoot.js +82 -0
  264. package/dist/src/pcomponents/PProjectRoot.js.map +1 -0
  265. package/dist/src/pcomponents/PRotateAnimation.d.ts +30 -0
  266. package/dist/src/pcomponents/PRotateAnimation.d.ts.map +1 -0
  267. package/dist/src/pcomponents/PRotateAnimation.js +72 -0
  268. package/dist/src/pcomponents/PRotateAnimation.js.map +1 -0
  269. package/dist/src/pcomponents/PScaleAnimation.d.ts +28 -0
  270. package/dist/src/pcomponents/PScaleAnimation.d.ts.map +1 -0
  271. package/dist/src/pcomponents/PScaleAnimation.js +75 -0
  272. package/dist/src/pcomponents/PScaleAnimation.js.map +1 -0
  273. package/dist/src/pcomponents/PSceneContainer.d.ts +22 -0
  274. package/dist/src/pcomponents/PSceneContainer.d.ts.map +1 -0
  275. package/dist/src/pcomponents/PSceneContainer.js +50 -0
  276. package/dist/src/pcomponents/PSceneContainer.js.map +1 -0
  277. package/dist/src/pcomponents/PSceneRoot.d.ts +16 -0
  278. package/dist/src/pcomponents/PSceneRoot.d.ts.map +1 -0
  279. package/dist/src/pcomponents/PSceneRoot.js +22 -0
  280. package/dist/src/pcomponents/PSceneRoot.js.map +1 -0
  281. package/dist/src/pcomponents/PSlider.d.ts +28 -0
  282. package/dist/src/pcomponents/PSlider.d.ts.map +1 -0
  283. package/dist/src/pcomponents/PSlider.js +37 -0
  284. package/dist/src/pcomponents/PSlider.js.map +1 -0
  285. package/dist/src/pcomponents/PSound.d.ts +34 -0
  286. package/dist/src/pcomponents/PSound.d.ts.map +1 -0
  287. package/dist/src/pcomponents/PSound.js +44 -0
  288. package/dist/src/pcomponents/PSound.js.map +1 -0
  289. package/dist/src/pcomponents/PSphereGeometry.d.ts +19 -0
  290. package/dist/src/pcomponents/PSphereGeometry.d.ts.map +1 -0
  291. package/dist/src/pcomponents/PSphereGeometry.js +24 -0
  292. package/dist/src/pcomponents/PSphereGeometry.js.map +1 -0
  293. package/dist/src/pcomponents/PSprite.d.ts +19 -0
  294. package/dist/src/pcomponents/PSprite.d.ts.map +1 -0
  295. package/dist/src/pcomponents/PSprite.js +26 -0
  296. package/dist/src/pcomponents/PSprite.js.map +1 -0
  297. package/dist/src/pcomponents/PSpriteAnimation.d.ts +25 -0
  298. package/dist/src/pcomponents/PSpriteAnimation.d.ts.map +1 -0
  299. package/dist/src/pcomponents/PSpriteAnimation.js +29 -0
  300. package/dist/src/pcomponents/PSpriteAnimation.js.map +1 -0
  301. package/dist/src/pcomponents/PText.d.ts +35 -0
  302. package/dist/src/pcomponents/PText.d.ts.map +1 -0
  303. package/dist/src/pcomponents/PText.js +48 -0
  304. package/dist/src/pcomponents/PText.js.map +1 -0
  305. package/dist/src/pcomponents/PTransform.d.ts +22 -0
  306. package/dist/src/pcomponents/PTransform.d.ts.map +1 -0
  307. package/dist/src/pcomponents/PTransform.js +37 -0
  308. package/dist/src/pcomponents/PTransform.js.map +1 -0
  309. package/dist/src/pcomponents/PVarList.d.ts +26 -0
  310. package/dist/src/pcomponents/PVarList.d.ts.map +1 -0
  311. package/dist/src/pcomponents/PVarList.js +52 -0
  312. package/dist/src/pcomponents/PVarList.js.map +1 -0
  313. package/dist/src/pcomponents/PVarReader.d.ts +19 -0
  314. package/dist/src/pcomponents/PVarReader.d.ts.map +1 -0
  315. package/dist/src/pcomponents/PVarReader.js +26 -0
  316. package/dist/src/pcomponents/PVarReader.js.map +1 -0
  317. package/dist/src/pcomponents/PVarWriter.d.ts +25 -0
  318. package/dist/src/pcomponents/PVarWriter.d.ts.map +1 -0
  319. package/dist/src/pcomponents/PVarWriter.js +46 -0
  320. package/dist/src/pcomponents/PVarWriter.js.map +1 -0
  321. package/dist/src/pcomponents/PVideoBackground.d.ts +36 -0
  322. package/dist/src/pcomponents/PVideoBackground.d.ts.map +1 -0
  323. package/dist/src/pcomponents/PVideoBackground.js +89 -0
  324. package/dist/src/pcomponents/PVideoBackground.js.map +1 -0
  325. package/dist/src/pcomponents/PVideoMaterial.d.ts +26 -0
  326. package/dist/src/pcomponents/PVideoMaterial.d.ts.map +1 -0
  327. package/dist/src/pcomponents/PVideoMaterial.js +40 -0
  328. package/dist/src/pcomponents/PVideoMaterial.js.map +1 -0
  329. package/dist/src/pcomponents/PVideoPlayer.d.ts +31 -0
  330. package/dist/src/pcomponents/PVideoPlayer.d.ts.map +1 -0
  331. package/dist/src/pcomponents/PVideoPlayer.js +70 -0
  332. package/dist/src/pcomponents/PVideoPlayer.js.map +1 -0
  333. package/dist/src/pcomponents/PVisibility.d.ts +33 -0
  334. package/dist/src/pcomponents/PVisibility.d.ts.map +1 -0
  335. package/dist/src/pcomponents/PVisibility.js +62 -0
  336. package/dist/src/pcomponents/PVisibility.js.map +1 -0
  337. package/dist/src/pcomponents/PXRTools.d.ts +32 -0
  338. package/dist/src/pcomponents/PXRTools.d.ts.map +1 -0
  339. package/dist/src/pcomponents/PXRTools.js +45 -0
  340. package/dist/src/pcomponents/PXRTools.js.map +1 -0
  341. package/dist/src/settings/Settings_Base.d.ts +7 -0
  342. package/dist/src/settings/Settings_Base.d.ts.map +1 -0
  343. package/dist/src/settings/Settings_Base.js +18 -0
  344. package/dist/src/settings/Settings_Base.js.map +1 -0
  345. package/dist/src/settings/Settings_Threejs.d.ts +9 -0
  346. package/dist/src/settings/Settings_Threejs.d.ts.map +1 -0
  347. package/dist/src/settings/Settings_Threejs.js +172 -0
  348. package/dist/src/settings/Settings_Threejs.js.map +1 -0
  349. package/package.json +23 -0
@@ -0,0 +1,28 @@
1
+ import GameContext from "../GameContext";
2
+ import PNode from "../PNode";
3
+ import { IInAction, PInAction } from "../PAction";
4
+ import PComponent, { DBComponent } from "../PComponent";
5
+ import { Tween } from "@tweenjs/tween.js";
6
+ interface DBScaleAnimation extends DBComponent {
7
+ inevent_scaleInOn: IInAction | null;
8
+ inevent_scaleOutOn: IInAction | null;
9
+ from: number;
10
+ to: number;
11
+ duration: number;
12
+ }
13
+ export type { DBScaleAnimation };
14
+ export default class PScaleAnimation extends PComponent {
15
+ inevent_scaleInOn: PInAction | null;
16
+ inevent_scaleOutOn: PInAction | null;
17
+ from: number;
18
+ to: number;
19
+ duration: number;
20
+ protected _tween: Tween<any> | null;
21
+ constructor(dbComponent: DBScaleAnimation, node: PNode, context: GameContext);
22
+ toDB(): DBScaleAnimation;
23
+ render(): void;
24
+ unrender(): void;
25
+ callback_scaleInOn: () => void;
26
+ callback_scaleOutOn: () => void;
27
+ }
28
+ //# sourceMappingURL=PScaleAnimation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PScaleAnimation.d.ts","sourceRoot":"","sources":["../../../src/pcomponents/PScaleAnimation.ts"],"names":[],"mappings":"AAAA,OAAO,WAAW,MAAM,gBAAgB,CAAC;AACzC,OAAO,KAAK,MAAM,UAAU,CAAC;AAC7B,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAClD,OAAO,UAAU,EAAE,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACxD,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAE1C,UAAU,gBAAiB,SAAQ,WAAW;IAC5C,iBAAiB,EAAE,SAAS,GAAG,IAAI,CAAC;IACpC,kBAAkB,EAAE,SAAS,GAAG,IAAI,CAAC;IACrC,IAAI,EAAE,MAAM,CAAC;IACb,EAAE,EAAE,MAAM,CAAC;IACX,QAAQ,EAAE,MAAM,CAAC;CAClB;AACD,YAAY,EAAE,gBAAgB,EAAE,CAAC;AAEjC,MAAM,CAAC,OAAO,OAAO,eAAgB,SAAQ,UAAU;IACrD,iBAAiB,EAAE,SAAS,GAAG,IAAI,CAAC;IACpC,kBAAkB,EAAE,SAAS,GAAG,IAAI,CAAC;IACrC,IAAI,EAAE,MAAM,CAAC;IACb,EAAE,EAAE,MAAM,CAAC;IACX,QAAQ,EAAE,MAAM,CAAC;IAEjB,SAAS,CAAC,MAAM,EAAE,KAAK,CAAC,GAAG,CAAC,GAAG,IAAI,CAAQ;gBAGzC,WAAW,EAAE,gBAAgB,EAC7B,IAAI,EAAE,KAAK,EACX,OAAO,EAAE,WAAW;IAoBtB,IAAI,IAAI,gBAAgB;IAWxB,MAAM,IAAI,IAAI;IAEd,QAAQ;IAOR,kBAAkB,aAqBhB;IAEF,mBAAmB,aAsBjB;CACH"}
@@ -0,0 +1,75 @@
1
+ import { PInAction } from "../PAction";
2
+ import PComponent from "../PComponent";
3
+ import { Tween } from "@tweenjs/tween.js";
4
+ export default class PScaleAnimation extends PComponent {
5
+ inevent_scaleInOn;
6
+ inevent_scaleOutOn;
7
+ from;
8
+ to;
9
+ duration;
10
+ _tween = null;
11
+ constructor(dbComponent, node, context) {
12
+ super("PScaleAnimation", "Scale Animation", node, context);
13
+ this.inevent_scaleInOn = node.registerInAction("Scale In", dbComponent.inevent_scaleInOn, this.callback_scaleInOn);
14
+ this.inevent_scaleOutOn = node.registerInAction("Scale Out", dbComponent.inevent_scaleOutOn, this.callback_scaleOutOn);
15
+ this.from = dbComponent.from || 1.0;
16
+ this.to = dbComponent.to || 1.25;
17
+ this.duration = dbComponent.duration || 500;
18
+ }
19
+ toDB() {
20
+ return {
21
+ ...super.toDB(),
22
+ inevent_scaleInOn: PInAction.toDB(this.inevent_scaleInOn),
23
+ inevent_scaleOutOn: PInAction.toDB(this.inevent_scaleOutOn),
24
+ from: this.from,
25
+ to: this.to,
26
+ duration: this.duration,
27
+ };
28
+ }
29
+ render() { }
30
+ unrender() {
31
+ if (this._tween !== null) {
32
+ this._tween.stop();
33
+ this._tween = null;
34
+ }
35
+ }
36
+ callback_scaleInOn = () => {
37
+ if (!this.node.isRunning() || !this.node.hasEl()) {
38
+ return;
39
+ }
40
+ if (this._tween !== null) {
41
+ this._tween.stop();
42
+ this._tween = null;
43
+ }
44
+ const target = {
45
+ x: this.to,
46
+ y: this.to,
47
+ z: this.to,
48
+ };
49
+ const nodeScale = this.context
50
+ .getNodeRenderer()
51
+ .getScaleVector(this.node);
52
+ this._tween = new Tween(nodeScale).to(target, this.duration).start();
53
+ this.context.addTween(this._tween);
54
+ };
55
+ callback_scaleOutOn = () => {
56
+ if (!this.node.isRunning() || !this.node.hasEl()) {
57
+ return;
58
+ }
59
+ if (this._tween !== null) {
60
+ this._tween.stop();
61
+ this._tween = null;
62
+ }
63
+ const target = {
64
+ x: this.from,
65
+ y: this.from,
66
+ z: this.from,
67
+ };
68
+ const nodeScale = this.context
69
+ .getNodeRenderer()
70
+ .getScaleVector(this.node);
71
+ this._tween = new Tween(nodeScale).to(target, this.duration).start();
72
+ this.context.addTween(this._tween);
73
+ };
74
+ }
75
+ //# sourceMappingURL=PScaleAnimation.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PScaleAnimation.js","sourceRoot":"","sources":["../../../src/pcomponents/PScaleAnimation.ts"],"names":[],"mappings":"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"}
@@ -0,0 +1,22 @@
1
+ import PComponent, { DBComponent } from "../PComponent";
2
+ import { IInAction, IOutAction, PInAction, POutAction } from "../PAction";
3
+ import GameContext from "../GameContext";
4
+ import PNode from "../PNode";
5
+ interface DBSceneContainer extends DBComponent {
6
+ inevent_loadScene: IInAction | null;
7
+ inevent_unloadScene: IInAction | null;
8
+ outevent_onSceneLoaded: IOutAction | null;
9
+ }
10
+ export type { DBSceneContainer };
11
+ export default class PSceneContainer extends PComponent {
12
+ inevent_loadScene: PInAction | null;
13
+ inevent_unloadScene: PInAction | null;
14
+ outevent_onSceneLoaded: POutAction | null;
15
+ constructor(dbComponent: DBSceneContainer, node: PNode, context: GameContext);
16
+ toDB(): DBSceneContainer;
17
+ render(): void;
18
+ unrender(): void;
19
+ callback_loadScene: (payloadValue: string | null) => void;
20
+ callback_unloadScene: (_payloadValue: string | null) => void;
21
+ }
22
+ //# sourceMappingURL=PSceneContainer.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PSceneContainer.d.ts","sourceRoot":"","sources":["../../../src/pcomponents/PSceneContainer.ts"],"names":[],"mappings":"AAAA,OAAO,UAAU,EAAE,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACxD,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAE1E,OAAO,WAAW,MAAM,gBAAgB,CAAC;AACzC,OAAO,KAAK,MAAM,UAAU,CAAC;AAE7B,UAAU,gBAAiB,SAAQ,WAAW;IAC5C,iBAAiB,EAAE,SAAS,GAAG,IAAI,CAAC;IACpC,mBAAmB,EAAE,SAAS,GAAG,IAAI,CAAC;IACtC,sBAAsB,EAAE,UAAU,GAAG,IAAI,CAAC;CAC3C;AAED,YAAY,EAAE,gBAAgB,EAAE,CAAC;AAEjC,MAAM,CAAC,OAAO,OAAO,eAAgB,SAAQ,UAAU;IACrD,iBAAiB,EAAE,SAAS,GAAG,IAAI,CAAC;IACpC,mBAAmB,EAAE,SAAS,GAAG,IAAI,CAAC;IACtC,sBAAsB,EAAE,UAAU,GAAG,IAAI,CAAC;gBAGxC,WAAW,EAAE,gBAAgB,EAC7B,IAAI,EAAE,KAAK,EACX,OAAO,EAAE,WAAW;IA0BtB,IAAI,IAAI,gBAAgB;IASxB,MAAM,IAAI,IAAI;IAEd,QAAQ,IAAI,IAAI;IAEhB,kBAAkB,GAAI,cAAc,MAAM,GAAG,IAAI,UAoB/C;IAEF,oBAAoB,GAAI,eAAe,MAAM,GAAG,IAAI,UAQlD;CACH"}
@@ -0,0 +1,50 @@
1
+ import PComponent from "../PComponent";
2
+ import { PInAction, POutAction } from "../PAction";
3
+ import { DataType, PProperties } from "../PEnums";
4
+ export default class PSceneContainer extends PComponent {
5
+ inevent_loadScene;
6
+ inevent_unloadScene;
7
+ outevent_onSceneLoaded;
8
+ constructor(dbComponent, node, context) {
9
+ super("PSceneContainer", "Scene Container", node, context);
10
+ this.properties = PProperties.SceneContainer;
11
+ this.inevent_loadScene = node.registerInAction("Load Scene", dbComponent.inevent_loadScene, this.callback_loadScene, DataType.Scene);
12
+ this.inevent_unloadScene = node.registerInAction("Unload Scene", dbComponent.inevent_unloadScene, this.callback_unloadScene, DataType.None);
13
+ this.outevent_onSceneLoaded = node.registerOutAction(dbComponent.outevent_onSceneLoaded, DataType.Scene);
14
+ }
15
+ toDB() {
16
+ return {
17
+ ...super.toDB(),
18
+ inevent_loadScene: PInAction.toDB(this.inevent_loadScene),
19
+ inevent_unloadScene: PInAction.toDB(this.inevent_unloadScene),
20
+ outevent_onSceneLoaded: POutAction.toDB(this.outevent_onSceneLoaded),
21
+ };
22
+ }
23
+ render() { }
24
+ unrender() { }
25
+ callback_loadScene = (payloadValue) => {
26
+ if (!payloadValue || payloadValue === "") {
27
+ this.context.error("Scene has not been set");
28
+ return;
29
+ }
30
+ // Unload scenes
31
+ const scenes = this.node.children.filter((n) => n.hasProperty(PProperties.SceneRoot));
32
+ for (const scene of scenes) {
33
+ this.context.unloadScene(scene);
34
+ }
35
+ const pscene = this.context.getScene(payloadValue);
36
+ if (!pscene) {
37
+ this.context.error("Could not find scene: " + payloadValue);
38
+ return;
39
+ }
40
+ this.context.loadScene(pscene, this.node, this.outevent_onSceneLoaded);
41
+ };
42
+ callback_unloadScene = (_payloadValue) => {
43
+ // Unload scenes
44
+ const scenes = this.node.children.filter((n) => n.hasProperty(PProperties.SceneRoot));
45
+ for (const scene of scenes) {
46
+ this.context.unloadScene(scene);
47
+ }
48
+ };
49
+ }
50
+ //# sourceMappingURL=PSceneContainer.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PSceneContainer.js","sourceRoot":"","sources":["../../../src/pcomponents/PSceneContainer.ts"],"names":[],"mappings":"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"}
@@ -0,0 +1,16 @@
1
+ import { IOutAction, POutAction } from "../PAction";
2
+ import GameContext from "../GameContext";
3
+ import PComponent, { DBComponent } from "../PComponent";
4
+ import PNode from "../PNode";
5
+ interface DBSceneRoot extends DBComponent {
6
+ outevent_onSceneLoaded: IOutAction | null;
7
+ }
8
+ export { type DBSceneRoot };
9
+ export default abstract class PSceneRoot extends PComponent {
10
+ outevent_onSceneLoaded: POutAction | null;
11
+ constructor(dbComponent: DBSceneRoot, node: PNode, context: GameContext);
12
+ toDB(): DBSceneRoot;
13
+ render(): void;
14
+ unrender(): void;
15
+ }
16
+ //# sourceMappingURL=PSceneRoot.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PSceneRoot.d.ts","sourceRoot":"","sources":["../../../src/pcomponents/PSceneRoot.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AACpD,OAAO,WAAW,MAAM,gBAAgB,CAAC;AACzC,OAAO,UAAU,EAAE,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACxD,OAAO,KAAK,MAAM,UAAU,CAAC;AAE7B,UAAU,WAAY,SAAQ,WAAW;IACvC,sBAAsB,EAAE,UAAU,GAAG,IAAI,CAAC;CAC3C;AACD,OAAO,EAAE,KAAK,WAAW,EAAE,CAAC;AAE5B,MAAM,CAAC,OAAO,CAAC,QAAQ,OAAO,UAAW,SAAQ,UAAU;IACzD,sBAAsB,EAAE,UAAU,GAAG,IAAI,CAAC;gBAE9B,WAAW,EAAE,WAAW,EAAE,IAAI,EAAE,KAAK,EAAE,OAAO,EAAE,WAAW;IAWvE,IAAI,IAAI,WAAW;IAOnB,MAAM,IAAI,IAAI;IAId,QAAQ,IAAI,IAAI;CAGjB"}
@@ -0,0 +1,22 @@
1
+ import { DataType, PProperties } from "../PEnums";
2
+ import { POutAction } from "../PAction";
3
+ import PComponent from "../PComponent";
4
+ export default class PSceneRoot extends PComponent {
5
+ outevent_onSceneLoaded;
6
+ constructor(dbComponent, node, context) {
7
+ super("PSceneRoot", "Scene", node, context);
8
+ this.properties = PProperties.RootNode | PProperties.SceneRoot;
9
+ this.outevent_onSceneLoaded = node.registerOutAction(dbComponent.outevent_onSceneLoaded, DataType.Scene);
10
+ }
11
+ toDB() {
12
+ return {
13
+ ...super.toDB(),
14
+ outevent_onSceneLoaded: POutAction.toDB(this.outevent_onSceneLoaded),
15
+ };
16
+ }
17
+ render() {
18
+ }
19
+ unrender() {
20
+ }
21
+ }
22
+ //# sourceMappingURL=PSceneRoot.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PSceneRoot.js","sourceRoot":"","sources":["../../../src/pcomponents/PSceneRoot.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AAClD,OAAO,EAAc,UAAU,EAAE,MAAM,YAAY,CAAC;AAEpD,OAAO,UAA2B,MAAM,eAAe,CAAC;AAQxD,MAAM,CAAC,OAAO,OAAgB,UAAW,SAAQ,UAAU;IACzD,sBAAsB,CAAoB;IAE1C,YAAY,WAAwB,EAAE,IAAW,EAAE,OAAoB;QACrE,KAAK,CAAC,YAAY,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;QAE5C,IAAI,CAAC,UAAU,GAAG,WAAW,CAAC,QAAQ,GAAG,WAAW,CAAC,SAAS,CAAC;QAE/D,IAAI,CAAC,sBAAsB,GAAG,IAAI,CAAC,iBAAiB,CAClD,WAAW,CAAC,sBAAsB,EAClC,QAAQ,CAAC,KAAK,CACf,CAAC;IACJ,CAAC;IAED,IAAI;QACF,OAAO;YACL,GAAG,KAAK,CAAC,IAAI,EAAE;YACf,sBAAsB,EAAE,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,sBAAsB,CAAC;SACrE,CAAC;IACJ,CAAC;IAED,MAAM;IAEN,CAAC;IAED,QAAQ;IAER,CAAC;CACF"}
@@ -0,0 +1,28 @@
1
+ import PComponent, { DBComponent } from "../PComponent";
2
+ import { IOutAction, POutAction } from "../PAction";
3
+ import GameContext from "../GameContext";
4
+ import PNode from "../PNode";
5
+ import { IVector3 } from "../PVector3";
6
+ interface DBSlider extends DBComponent {
7
+ editor_showColliders: boolean;
8
+ outevent_onHoverEnter: IOutAction | null;
9
+ outevent_onHoverExit: IOutAction | null;
10
+ outevent_onClick: IOutAction | null;
11
+ outevent_onChange: IOutAction | null;
12
+ }
13
+ export type { DBSlider };
14
+ export default abstract class PSlider extends PComponent {
15
+ outevent_onHoverEnter: POutAction | null;
16
+ outevent_onHoverExit: POutAction | null;
17
+ outevent_onClick: POutAction | null;
18
+ outevent_onChange: POutAction | null;
19
+ editor_showColliders: boolean;
20
+ hidden: boolean;
21
+ _width: number;
22
+ constructor(dbComponent: DBSlider, node: PNode, context: GameContext);
23
+ toDB(): DBSlider;
24
+ abstract native_onHoverEnter(point: IVector3): void;
25
+ native_onHoverExit: () => void;
26
+ native_onClick: () => void;
27
+ }
28
+ //# sourceMappingURL=PSlider.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PSlider.d.ts","sourceRoot":"","sources":["../../../src/pcomponents/PSlider.ts"],"names":[],"mappings":"AAAA,OAAO,UAAU,EAAE,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACxD,OAAO,EAAE,UAAU,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAEpD,OAAO,WAAW,MAAM,gBAAgB,CAAC;AACzC,OAAO,KAAK,MAAM,UAAU,CAAC;AAC7B,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAEvC,UAAU,QAAS,SAAQ,WAAW;IACpC,oBAAoB,EAAE,OAAO,CAAC;IAC9B,qBAAqB,EAAE,UAAU,GAAG,IAAI,CAAC;IACzC,oBAAoB,EAAE,UAAU,GAAG,IAAI,CAAC;IACxC,gBAAgB,EAAE,UAAU,GAAG,IAAI,CAAC;IACpC,iBAAiB,EAAE,UAAU,GAAG,IAAI,CAAC;CACtC;AAED,YAAY,EAAE,QAAQ,EAAE,CAAC;AAEzB,MAAM,CAAC,OAAO,CAAC,QAAQ,OAAO,OAAQ,SAAQ,UAAU;IACtD,qBAAqB,EAAE,UAAU,GAAG,IAAI,CAAC;IACzC,oBAAoB,EAAE,UAAU,GAAG,IAAI,CAAC;IACxC,gBAAgB,EAAE,UAAU,GAAG,IAAI,CAAC;IAEpC,iBAAiB,EAAE,UAAU,GAAG,IAAI,CAAC;IACrC,oBAAoB,UAAS;IAE7B,MAAM,UAAS;IAEf,MAAM,SAAO;gBAED,WAAW,EAAE,QAAQ,EAAE,IAAI,EAAE,KAAK,EAAE,OAAO,EAAE,WAAW;IA0BpE,IAAI,IAAI,QAAQ;IAehB,QAAQ,CAAC,mBAAmB,CAAC,KAAK,EAAE,QAAQ,GAAG,IAAI;IAEnD,kBAAkB,aAEhB;IAEF,cAAc,aAEZ;CACH"}
@@ -0,0 +1,37 @@
1
+ import PComponent from "../PComponent";
2
+ import { POutAction } from "../PAction";
3
+ import { DataType } from "../PEnums";
4
+ export default class PSlider extends PComponent {
5
+ outevent_onHoverEnter;
6
+ outevent_onHoverExit;
7
+ outevent_onClick;
8
+ outevent_onChange;
9
+ editor_showColliders = false;
10
+ hidden = false;
11
+ _width = 0.0;
12
+ constructor(dbComponent, node, context) {
13
+ super("PSlider", "Slider", node, context);
14
+ this.editor_showColliders = dbComponent.editor_showColliders;
15
+ this.outevent_onHoverEnter = node.registerOutAction(dbComponent.outevent_onHoverEnter, DataType.Node);
16
+ this.outevent_onHoverExit = node.registerOutAction(dbComponent.outevent_onHoverExit, DataType.Node);
17
+ this.outevent_onClick = node.registerOutAction(dbComponent.outevent_onClick, DataType.Node);
18
+ this.outevent_onChange = node.registerOutAction(dbComponent.outevent_onChange, DataType.Percent);
19
+ }
20
+ toDB() {
21
+ return {
22
+ ...super.toDB(),
23
+ editor_showColliders: this.editor_showColliders,
24
+ outevent_onHoverEnter: POutAction.toDB(this.outevent_onHoverEnter),
25
+ outevent_onHoverExit: POutAction.toDB(this.outevent_onHoverExit),
26
+ outevent_onClick: POutAction.toDB(this.outevent_onClick),
27
+ outevent_onChange: POutAction.toDB(this.outevent_onChange),
28
+ };
29
+ }
30
+ native_onHoverExit = () => {
31
+ this.outevent_onHoverExit?.emit(this.node.id, this);
32
+ };
33
+ native_onClick = () => {
34
+ this.outevent_onClick?.emit(this.node.id, this);
35
+ };
36
+ }
37
+ //# sourceMappingURL=PSlider.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PSlider.js","sourceRoot":"","sources":["../../../src/pcomponents/PSlider.ts"],"names":[],"mappings":"AAAA,OAAO,UAA2B,MAAM,eAAe,CAAC;AACxD,OAAO,EAAc,UAAU,EAAE,MAAM,YAAY,CAAC;AACpD,OAAO,EAAE,QAAQ,EAAE,MAAM,WAAW,CAAC;AAerC,MAAM,CAAC,OAAO,OAAgB,OAAQ,SAAQ,UAAU;IACtD,qBAAqB,CAAoB;IACzC,oBAAoB,CAAoB;IACxC,gBAAgB,CAAoB;IAEpC,iBAAiB,CAAoB;IACrC,oBAAoB,GAAG,KAAK,CAAC;IAE7B,MAAM,GAAG,KAAK,CAAC;IAEf,MAAM,GAAG,GAAG,CAAC;IAEb,YAAY,WAAqB,EAAE,IAAW,EAAE,OAAoB;QAClE,KAAK,CAAC,SAAS,EAAE,QAAQ,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;QAE1C,IAAI,CAAC,oBAAoB,GAAG,WAAW,CAAC,oBAAoB,CAAC;QAE7D,IAAI,CAAC,qBAAqB,GAAG,IAAI,CAAC,iBAAiB,CACjD,WAAW,CAAC,qBAAqB,EACjC,QAAQ,CAAC,IAAI,CACd,CAAC;QAEF,IAAI,CAAC,oBAAoB,GAAG,IAAI,CAAC,iBAAiB,CAChD,WAAW,CAAC,oBAAoB,EAChC,QAAQ,CAAC,IAAI,CACd,CAAC;QAEF,IAAI,CAAC,gBAAgB,GAAG,IAAI,CAAC,iBAAiB,CAC5C,WAAW,CAAC,gBAAgB,EAC5B,QAAQ,CAAC,IAAI,CACd,CAAC;QAEF,IAAI,CAAC,iBAAiB,GAAG,IAAI,CAAC,iBAAiB,CAC7C,WAAW,CAAC,iBAAiB,EAC7B,QAAQ,CAAC,OAAO,CACjB,CAAC;IACJ,CAAC;IAED,IAAI;QACF,OAAO;YACL,GAAG,KAAK,CAAC,IAAI,EAAE;YACf,oBAAoB,EAAE,IAAI,CAAC,oBAAoB;YAC/C,qBAAqB,EAAE,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,qBAAqB,CAAC;YAClE,oBAAoB,EAAE,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,oBAAoB,CAAC;YAChE,gBAAgB,EAAE,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,gBAAgB,CAAC;YACxD,iBAAiB,EAAE,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,iBAAiB,CAAC;SAC3D,CAAC;IACJ,CAAC;IAQD,kBAAkB,GAAG,GAAG,EAAE;QACxB,IAAI,CAAC,oBAAoB,EAAE,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,EAAE,IAAI,CAAC,CAAC;IACtD,CAAC,CAAC;IAEF,cAAc,GAAG,GAAG,EAAE;QACpB,IAAI,CAAC,gBAAgB,EAAE,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,EAAE,IAAI,CAAC,CAAC;IAClD,CAAC,CAAC;CACH"}
@@ -0,0 +1,34 @@
1
+ import PComponent, { DBComponent } from "../PComponent";
2
+ import PFile from "../media/PFile";
3
+ import { IInAction, IOutAction, PInAction, POutAction } from "../PAction";
4
+ import GameContext from "../GameContext";
5
+ import PNode from "../PNode";
6
+ interface DBSound extends DBComponent {
7
+ file_sound: string | null;
8
+ inevent_playOn: IInAction | null;
9
+ inevent_stopOn: IInAction | null;
10
+ outevent_onEnd: IOutAction | null;
11
+ outevent_onStart: IOutAction | null;
12
+ positional: boolean;
13
+ loop: boolean;
14
+ volume: number;
15
+ distance: number;
16
+ }
17
+ export type { DBSound };
18
+ export default abstract class PSound extends PComponent {
19
+ file_sound: PFile | null;
20
+ inevent_playOn: PInAction | null;
21
+ inevent_stopOn: PInAction | null;
22
+ outevent_onEnd: POutAction | null;
23
+ outevent_onStart: POutAction | null;
24
+ positional: boolean;
25
+ loop: boolean;
26
+ volume: number;
27
+ distance: number;
28
+ constructor(dbComponent: DBSound, node: PNode, context: GameContext);
29
+ toDB(): DBSound;
30
+ dispose(): void;
31
+ abstract callback_onPlay(): void;
32
+ abstract callback_onStop(): void;
33
+ }
34
+ //# sourceMappingURL=PSound.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PSound.d.ts","sourceRoot":"","sources":["../../../src/pcomponents/PSound.ts"],"names":[],"mappings":"AAAA,OAAO,UAAU,EAAE,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACxD,OAAO,KAAK,MAAM,gBAAgB,CAAC;AACnC,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAC1E,OAAO,WAAW,MAAM,gBAAgB,CAAC;AACzC,OAAO,KAAK,MAAM,UAAU,CAAC;AAE7B,UAAU,OAAQ,SAAQ,WAAW;IACnC,UAAU,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,cAAc,EAAE,SAAS,GAAG,IAAI,CAAC;IACjC,cAAc,EAAE,SAAS,GAAG,IAAI,CAAC;IACjC,cAAc,EAAE,UAAU,GAAG,IAAI,CAAC;IAClC,gBAAgB,EAAE,UAAU,GAAG,IAAI,CAAC;IACpC,UAAU,EAAE,OAAO,CAAC;IACpB,IAAI,EAAE,OAAO,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,YAAY,EAAE,OAAO,EAAE,CAAC;AAExB,MAAM,CAAC,OAAO,CAAC,QAAQ,OAAO,MAAO,SAAQ,UAAU;IACrD,UAAU,EAAE,KAAK,GAAG,IAAI,CAAC;IAEzB,cAAc,EAAE,SAAS,GAAG,IAAI,CAAC;IACjC,cAAc,EAAE,SAAS,GAAG,IAAI,CAAC;IACjC,cAAc,EAAE,UAAU,GAAG,IAAI,CAAC;IAClC,gBAAgB,EAAE,UAAU,GAAG,IAAI,CAAC;IAEpC,UAAU,EAAE,OAAO,CAAC;IACpB,IAAI,EAAE,OAAO,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;gBAEL,WAAW,EAAE,OAAO,EAAE,IAAI,EAAE,KAAK,EAAE,OAAO,EAAE,WAAW;IA0BnE,IAAI,IAAI,OAAO;IAef,OAAO;IAQP,QAAQ,CAAC,eAAe,IAAI,IAAI;IAChC,QAAQ,CAAC,eAAe,IAAI,IAAI;CACjC"}
@@ -0,0 +1,44 @@
1
+ import PComponent from "../PComponent";
2
+ import { PInAction, POutAction } from "../PAction";
3
+ export default class PSound extends PComponent {
4
+ file_sound;
5
+ inevent_playOn;
6
+ inevent_stopOn;
7
+ outevent_onEnd;
8
+ outevent_onStart;
9
+ positional;
10
+ loop;
11
+ volume;
12
+ distance;
13
+ constructor(dbComponent, node, context) {
14
+ super("PSound", "Sound", node, context);
15
+ this.file_sound = this.context.requestFile(dbComponent.file_sound, node);
16
+ this.inevent_playOn = node.registerInAction("Play", dbComponent.inevent_playOn, () => this.callback_onPlay());
17
+ this.inevent_stopOn = node.registerInAction("Stop", dbComponent.inevent_stopOn, () => this.callback_onStop());
18
+ this.outevent_onEnd = node.registerOutAction(dbComponent.outevent_onEnd);
19
+ this.outevent_onStart = node.registerOutAction(dbComponent.outevent_onStart);
20
+ this.volume = dbComponent.volume || 1;
21
+ this.distance = dbComponent.distance || 10;
22
+ this.positional = dbComponent.positional || false;
23
+ this.loop = dbComponent.loop === true || false;
24
+ }
25
+ toDB() {
26
+ return {
27
+ ...super.toDB(),
28
+ inevent_playOn: PInAction.toDB(this.inevent_playOn),
29
+ inevent_stopOn: PInAction.toDB(this.inevent_stopOn),
30
+ outevent_onEnd: POutAction.toDB(this.outevent_onEnd),
31
+ outevent_onStart: POutAction.toDB(this.outevent_onStart),
32
+ positional: this.positional,
33
+ file_sound: this.file_sound?._id || null,
34
+ volume: this.volume,
35
+ loop: this.loop,
36
+ distance: this.distance,
37
+ };
38
+ }
39
+ dispose() {
40
+ if (this.file_sound)
41
+ this.context.releaseFile(this.file_sound);
42
+ }
43
+ }
44
+ //# sourceMappingURL=PSound.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PSound.js","sourceRoot":"","sources":["../../../src/pcomponents/PSound.ts"],"names":[],"mappings":"AAAA,OAAO,UAA2B,MAAM,eAAe,CAAC;AAExD,OAAO,EAAyB,SAAS,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAkB1E,MAAM,CAAC,OAAO,OAAgB,MAAO,SAAQ,UAAU;IACrD,UAAU,CAAe;IAEzB,cAAc,CAAmB;IACjC,cAAc,CAAmB;IACjC,cAAc,CAAoB;IAClC,gBAAgB,CAAoB;IAEpC,UAAU,CAAU;IACpB,IAAI,CAAU;IACd,MAAM,CAAS;IACf,QAAQ,CAAS;IAEjB,YAAY,WAAoB,EAAE,IAAW,EAAE,OAAoB;QACjE,KAAK,CAAC,QAAQ,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;QAExC,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,WAAW,CAAC,UAAU,EAAE,IAAI,CAAC,CAAC;QAEzE,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,gBAAgB,CACzC,MAAM,EACN,WAAW,CAAC,cAAc,EAC1B,GAAG,EAAE,CAAC,IAAI,CAAC,eAAe,EAAE,CAC7B,CAAC;QACF,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,gBAAgB,CACzC,MAAM,EACN,WAAW,CAAC,cAAc,EAC1B,GAAG,EAAE,CAAC,IAAI,CAAC,eAAe,EAAE,CAC7B,CAAC;QACF,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,iBAAiB,CAAC,WAAW,CAAC,cAAc,CAAC,CAAC;QACzE,IAAI,CAAC,gBAAgB,GAAG,IAAI,CAAC,iBAAiB,CAC5C,WAAW,CAAC,gBAAgB,CAC7B,CAAC;QAEF,IAAI,CAAC,MAAM,GAAG,WAAW,CAAC,MAAM,IAAI,CAAC,CAAC;QACtC,IAAI,CAAC,QAAQ,GAAG,WAAW,CAAC,QAAQ,IAAI,EAAE,CAAC;QAC3C,IAAI,CAAC,UAAU,GAAG,WAAW,CAAC,UAAU,IAAI,KAAK,CAAC;QAClD,IAAI,CAAC,IAAI,GAAG,WAAW,CAAC,IAAI,KAAK,IAAI,IAAI,KAAK,CAAC;IACjD,CAAC;IAED,IAAI;QACF,OAAO;YACL,GAAG,KAAK,CAAC,IAAI,EAAE;YACf,cAAc,EAAE,SAAS,CAAC,IAAI,CAAC,IAAI,CAAC,cAAc,CAAC;YACnD,cAAc,EAAE,SAAS,CAAC,IAAI,CAAC,IAAI,CAAC,cAAc,CAAC;YACnD,cAAc,EAAE,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,cAAc,CAAC;YACpD,gBAAgB,EAAE,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,gBAAgB,CAAC;YACxD,UAAU,EAAE,IAAI,CAAC,UAAU;YAC3B,UAAU,EAAE,IAAI,CAAC,UAAU,EAAE,GAAG,IAAI,IAAI;YACxC,MAAM,EAAE,IAAI,CAAC,MAAM;YACnB,IAAI,EAAE,IAAI,CAAC,IAAI;YACf,QAAQ,EAAE,IAAI,CAAC,QAAQ;SACxB,CAAC;IACJ,CAAC;IAED,OAAO;QACL,IAAI,IAAI,CAAC,UAAU;YAAE,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;IACjE,CAAC;CAQF"}
@@ -0,0 +1,19 @@
1
+ import GameContext from "../GameContext";
2
+ import PComponent, { DBComponent } from "../PComponent";
3
+ import PNode from "../PNode";
4
+ interface DBSphereGeometry extends DBComponent {
5
+ radius: number;
6
+ segments: number;
7
+ castShadow: boolean;
8
+ receiveShadow: boolean;
9
+ }
10
+ export type { DBSphereGeometry };
11
+ export default abstract class PSphereGeometry extends PComponent {
12
+ radius: number;
13
+ segments: number;
14
+ castShadow: boolean;
15
+ receiveShadow: boolean;
16
+ constructor(dbComponent: DBSphereGeometry, node: PNode, context: GameContext);
17
+ toDB(): DBSphereGeometry;
18
+ }
19
+ //# sourceMappingURL=PSphereGeometry.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PSphereGeometry.d.ts","sourceRoot":"","sources":["../../../src/pcomponents/PSphereGeometry.ts"],"names":[],"mappings":"AAAA,OAAO,WAAW,MAAM,gBAAgB,CAAC;AACzC,OAAO,UAAU,EAAE,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAExD,OAAO,KAAK,MAAM,UAAU,CAAC;AAE7B,UAAU,gBAAiB,SAAQ,WAAW;IAC5C,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,EAAE,OAAO,CAAC;IACpB,aAAa,EAAE,OAAO,CAAC;CACxB;AAED,YAAY,EAAE,gBAAgB,EAAE,CAAC;AAEjC,MAAM,CAAC,OAAO,CAAC,QAAQ,OAAO,eAAgB,SAAQ,UAAU;IAE9D,MAAM,EAAE,MAAM,CAAK;IACnB,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,EAAE,OAAO,CAAC;IACpB,aAAa,EAAE,OAAO,CAAC;gBAGrB,WAAW,EAAE,gBAAgB,EAC7B,IAAI,EAAE,KAAK,EACX,OAAO,EAAE,WAAW;IAUtB,IAAI,IAAI,gBAAgB;CAUzB"}
@@ -0,0 +1,24 @@
1
+ import PComponent from "../PComponent";
2
+ export default class PSphereGeometry extends PComponent {
3
+ radius = 1;
4
+ segments;
5
+ castShadow;
6
+ receiveShadow;
7
+ constructor(dbComponent, node, context) {
8
+ super("PSphereGeometry", "Sphere Geometry", node, context);
9
+ this.radius = dbComponent.radius;
10
+ this.segments = (dbComponent.segments || 0);
11
+ this.castShadow = dbComponent.castShadow;
12
+ this.receiveShadow = dbComponent.receiveShadow || false;
13
+ }
14
+ toDB() {
15
+ return {
16
+ ...super.toDB(),
17
+ radius: this.radius,
18
+ segments: this.segments,
19
+ castShadow: this.castShadow,
20
+ receiveShadow: this.receiveShadow,
21
+ };
22
+ }
23
+ }
24
+ //# sourceMappingURL=PSphereGeometry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PSphereGeometry.js","sourceRoot":"","sources":["../../../src/pcomponents/PSphereGeometry.ts"],"names":[],"mappings":"AACA,OAAO,UAA2B,MAAM,eAAe,CAAC;AAaxD,MAAM,CAAC,OAAO,OAAgB,eAAgB,SAAQ,UAAU;IAE9D,MAAM,GAAW,CAAC,CAAC;IACnB,QAAQ,CAAS;IACjB,UAAU,CAAU;IACpB,aAAa,CAAU;IAEvB,YACE,WAA6B,EAC7B,IAAW,EACX,OAAoB;QAEpB,KAAK,CAAC,iBAAiB,EAAE,iBAAiB,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;QAE3D,IAAI,CAAC,MAAM,GAAG,WAAW,CAAC,MAAM,CAAC;QACjC,IAAI,CAAC,QAAQ,GAAG,CAAC,WAAW,CAAC,QAAQ,IAAI,CAAC,CAAY,CAAC;QACvD,IAAI,CAAC,UAAU,GAAG,WAAW,CAAC,UAAU,CAAC;QACzC,IAAI,CAAC,aAAa,GAAG,WAAW,CAAC,aAAa,IAAI,KAAK,CAAC;IAC1D,CAAC;IAED,IAAI;QACF,OAAO;YACL,GAAG,KAAK,CAAC,IAAI,EAAE;YACf,MAAM,EAAE,IAAI,CAAC,MAAM;YACnB,QAAQ,EAAE,IAAI,CAAC,QAAQ;YACvB,UAAU,EAAE,IAAI,CAAC,UAAU;YAC3B,aAAa,EAAE,IAAI,CAAC,aAAa;SAClC,CAAC;IACJ,CAAC;CAEF"}
@@ -0,0 +1,19 @@
1
+ import GameContext from "../GameContext";
2
+ import PNode from "../PNode";
3
+ import PComponent, { DBComponent } from "../PComponent";
4
+ import PFile from "../media/PFile";
5
+ interface DBSprite extends DBComponent {
6
+ file_image: string | null;
7
+ opacity: number;
8
+ color: string;
9
+ }
10
+ export type { DBSprite };
11
+ export default abstract class PSprite extends PComponent {
12
+ file_image: PFile | null;
13
+ opacity: number;
14
+ color: string;
15
+ constructor(dbComponent: DBSprite, node: PNode, context: GameContext);
16
+ toDB(): DBSprite;
17
+ dispose(): void;
18
+ }
19
+ //# sourceMappingURL=PSprite.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PSprite.d.ts","sourceRoot":"","sources":["../../../src/pcomponents/PSprite.ts"],"names":[],"mappings":"AAAA,OAAO,WAAW,MAAM,gBAAgB,CAAC;AACzC,OAAO,KAAK,MAAM,UAAU,CAAC;AAC7B,OAAO,UAAU,EAAE,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACxD,OAAO,KAAK,MAAM,gBAAgB,CAAC;AAEnC,UAAU,QAAS,SAAQ,WAAW;IACpC,UAAU,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;CACf;AAED,YAAY,EAAE,QAAQ,EAAE,CAAC;AAEzB,MAAM,CAAC,OAAO,CAAC,QAAQ,OAAO,OAAQ,SAAQ,UAAU;IACtD,UAAU,EAAE,KAAK,GAAG,IAAI,CAAC;IACzB,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;gBAEF,WAAW,EAAE,QAAQ,EAAE,IAAI,EAAE,KAAK,EAAE,OAAO,EAAE,WAAW;IAOpE,IAAI,IAAI,QAAQ;IAShB,OAAO;CAIR"}
@@ -0,0 +1,26 @@
1
+ import PComponent from "../PComponent";
2
+ export default class PSprite extends PComponent {
3
+ file_image;
4
+ opacity;
5
+ color;
6
+ constructor(dbComponent, node, context) {
7
+ super("PSprite", "Sprite", node, context);
8
+ this.file_image = this.context.requestFile(dbComponent.file_image);
9
+ this.opacity = dbComponent.opacity;
10
+ this.color = dbComponent.color;
11
+ }
12
+ toDB() {
13
+ return {
14
+ ...super.toDB(),
15
+ file_image: this.file_image?._id || null,
16
+ opacity: this.opacity,
17
+ color: this.color,
18
+ };
19
+ }
20
+ dispose() {
21
+ // Release files
22
+ if (this.file_image)
23
+ this.context.releaseFile(this.file_image);
24
+ }
25
+ }
26
+ //# sourceMappingURL=PSprite.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PSprite.js","sourceRoot":"","sources":["../../../src/pcomponents/PSprite.ts"],"names":[],"mappings":"AAEA,OAAO,UAA2B,MAAM,eAAe,CAAC;AAWxD,MAAM,CAAC,OAAO,OAAgB,OAAQ,SAAQ,UAAU;IACtD,UAAU,CAAe;IACzB,OAAO,CAAS;IAChB,KAAK,CAAS;IAEd,YAAY,WAAqB,EAAE,IAAW,EAAE,OAAoB;QAClE,KAAK,CAAC,SAAS,EAAE,QAAQ,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;QAC1C,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,WAAW,CAAC,UAAU,CAAC,CAAC;QACnE,IAAI,CAAC,OAAO,GAAG,WAAW,CAAC,OAAO,CAAC;QACnC,IAAI,CAAC,KAAK,GAAG,WAAW,CAAC,KAAK,CAAC;IACjC,CAAC;IAED,IAAI;QACF,OAAO;YACL,GAAG,KAAK,CAAC,IAAI,EAAE;YACf,UAAU,EAAE,IAAI,CAAC,UAAU,EAAE,GAAG,IAAI,IAAI;YACxC,OAAO,EAAE,IAAI,CAAC,OAAO;YACrB,KAAK,EAAE,IAAI,CAAC,KAAK;SAClB,CAAC;IACJ,CAAC;IAED,OAAO;QACL,gBAAgB;QAChB,IAAI,IAAI,CAAC,UAAU;YAAE,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;IACjE,CAAC;CACF"}
@@ -0,0 +1,25 @@
1
+ import PVector2, { IVector2 } from "../PVector2";
2
+ import { IInAction, PInAction } from "../PAction";
3
+ import PComponent, { DBComponent } from "../PComponent";
4
+ import GameContext from "../GameContext";
5
+ import PNode from "../PNode";
6
+ interface DBSpriteAnimation extends DBComponent {
7
+ inevent_start: IInAction | null;
8
+ inevent_stop: IInAction | null;
9
+ loop: boolean;
10
+ size: IVector2;
11
+ duration: number;
12
+ }
13
+ export type { DBSpriteAnimation };
14
+ export default abstract class PSpriteAnimation extends PComponent {
15
+ inevent_start: PInAction | null;
16
+ inevent_stop: PInAction | null;
17
+ loop: boolean;
18
+ size: PVector2;
19
+ duration: number;
20
+ constructor(dbComponent: DBSpriteAnimation, node: PNode, context: GameContext);
21
+ toDB(): DBSpriteAnimation;
22
+ protected abstract callback_startAnimation(): void;
23
+ protected abstract callback_stopAnimation(): void;
24
+ }
25
+ //# sourceMappingURL=PSpriteAnimation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PSpriteAnimation.d.ts","sourceRoot":"","sources":["../../../src/pcomponents/PSpriteAnimation.ts"],"names":[],"mappings":"AAAA,OAAO,QAAQ,EAAE,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACjD,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAClD,OAAO,UAAU,EAAE,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACxD,OAAO,WAAW,MAAM,gBAAgB,CAAC;AACzC,OAAO,KAAK,MAAM,UAAU,CAAC;AAE7B,UAAU,iBAAkB,SAAQ,WAAW;IAC7C,aAAa,EAAE,SAAS,GAAG,IAAI,CAAC;IAChC,YAAY,EAAE,SAAS,GAAG,IAAI,CAAC;IAC/B,IAAI,EAAE,OAAO,CAAC;IACd,IAAI,EAAE,QAAQ,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;CAClB;AACD,YAAY,EAAE,iBAAiB,EAAE,CAAC;AAElC,MAAM,CAAC,OAAO,CAAC,QAAQ,OAAO,gBAAiB,SAAQ,UAAU;IAC/D,aAAa,EAAE,SAAS,GAAG,IAAI,CAAQ;IACvC,YAAY,EAAE,SAAS,GAAG,IAAI,CAAQ;IAEtC,IAAI,EAAE,OAAO,CAAC;IACd,IAAI,EAAE,QAAQ,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;gBAGf,WAAW,EAAE,iBAAiB,EAC9B,IAAI,EAAE,KAAK,EACX,OAAO,EAAE,WAAW;IAoBtB,IAAI,IAAI,iBAAiB;IAWzB,SAAS,CAAC,QAAQ,CAAC,uBAAuB,IAAI,IAAI;IAClD,SAAS,CAAC,QAAQ,CAAC,sBAAsB,IAAI,IAAI;CAClD"}
@@ -0,0 +1,29 @@
1
+ import PVector2 from "../PVector2";
2
+ import { PInAction } from "../PAction";
3
+ import PComponent from "../PComponent";
4
+ export default class PSpriteAnimation extends PComponent {
5
+ inevent_start = null;
6
+ inevent_stop = null;
7
+ loop;
8
+ size;
9
+ duration;
10
+ constructor(dbComponent, node, context) {
11
+ super("PSpriteAnimation", "Sprite Animation", node, context);
12
+ this.inevent_start = node.registerInAction("Play", dbComponent.inevent_start, () => this.callback_startAnimation());
13
+ this.inevent_stop = node.registerInAction("Stop", dbComponent.inevent_stop, () => this.callback_stopAnimation());
14
+ this.size = new PVector2(dbComponent.size);
15
+ this.loop = dbComponent.loop || false;
16
+ this.duration = dbComponent.duration || 1000;
17
+ }
18
+ toDB() {
19
+ return {
20
+ ...super.toDB(),
21
+ inevent_start: PInAction.toDB(this.inevent_start),
22
+ inevent_stop: PInAction.toDB(this.inevent_stop),
23
+ loop: this.loop,
24
+ size: this.size,
25
+ duration: this.duration,
26
+ };
27
+ }
28
+ }
29
+ //# sourceMappingURL=PSpriteAnimation.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PSpriteAnimation.js","sourceRoot":"","sources":["../../../src/pcomponents/PSpriteAnimation.ts"],"names":[],"mappings":"AAAA,OAAO,QAAsB,MAAM,aAAa,CAAC;AACjD,OAAO,EAAa,SAAS,EAAE,MAAM,YAAY,CAAC;AAClD,OAAO,UAA2B,MAAM,eAAe,CAAC;AAaxD,MAAM,CAAC,OAAO,OAAgB,gBAAiB,SAAQ,UAAU;IAC/D,aAAa,GAAqB,IAAI,CAAC;IACvC,YAAY,GAAqB,IAAI,CAAC;IAEtC,IAAI,CAAU;IACd,IAAI,CAAW;IACf,QAAQ,CAAS;IAEjB,YACE,WAA8B,EAC9B,IAAW,EACX,OAAoB;QAEpB,KAAK,CAAC,kBAAkB,EAAE,kBAAkB,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;QAE7D,IAAI,CAAC,aAAa,GAAG,IAAI,CAAC,gBAAgB,CACxC,MAAM,EACN,WAAW,CAAC,aAAa,EACzB,GAAG,EAAE,CAAC,IAAI,CAAC,uBAAuB,EAAE,CACrC,CAAC;QACF,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC,gBAAgB,CACvC,MAAM,EACN,WAAW,CAAC,YAAY,EACxB,GAAG,EAAE,CAAC,IAAI,CAAC,sBAAsB,EAAE,CACpC,CAAC;QAEF,IAAI,CAAC,IAAI,GAAG,IAAI,QAAQ,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;QAC3C,IAAI,CAAC,IAAI,GAAG,WAAW,CAAC,IAAI,IAAI,KAAK,CAAC;QACtC,IAAI,CAAC,QAAQ,GAAG,WAAW,CAAC,QAAQ,IAAI,IAAI,CAAC;IAC/C,CAAC;IAED,IAAI;QACF,OAAO;YACL,GAAG,KAAK,CAAC,IAAI,EAAE;YACf,aAAa,EAAE,SAAS,CAAC,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC;YACjD,YAAY,EAAE,SAAS,CAAC,IAAI,CAAC,IAAI,CAAC,YAAY,CAAC;YAC/C,IAAI,EAAE,IAAI,CAAC,IAAI;YACf,IAAI,EAAE,IAAI,CAAC,IAAI;YACf,QAAQ,EAAE,IAAI,CAAC,QAAQ;SACxB,CAAC;IACJ,CAAC;CAIF"}
@@ -0,0 +1,35 @@
1
+ import PComponent, { DBComponent } from "../PComponent";
2
+ import { IInAction, IOutAction, PInAction, POutAction } from "../PAction";
3
+ import PFile from "../media/PFile";
4
+ import GameContext from "../GameContext";
5
+ import PNode from "../PNode";
6
+ interface DBText extends DBComponent {
7
+ file_font: string | null;
8
+ text: string;
9
+ color: string;
10
+ outlineColor: string;
11
+ outlineWidth: number;
12
+ fontSize: number;
13
+ textAlign: string;
14
+ verticalAlign: string;
15
+ inevent_setText: IInAction | null;
16
+ outevent_onSetText: IOutAction | null;
17
+ }
18
+ export type { DBText };
19
+ export default abstract class PText extends PComponent {
20
+ text: string;
21
+ color: string;
22
+ outlineColor: string;
23
+ outlineWidth: number;
24
+ fontSize: number;
25
+ textAlign: string;
26
+ verticalAlign: string;
27
+ file_font: PFile | null;
28
+ inevent_setText: PInAction | null;
29
+ outevent_onSetText: POutAction | null;
30
+ constructor(dbComponent: DBText, node: PNode, context: GameContext);
31
+ toDB(): DBText;
32
+ dispose(): void;
33
+ abstract callback_setText(payloadValue: string | null): void;
34
+ }
35
+ //# sourceMappingURL=PText.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PText.d.ts","sourceRoot":"","sources":["../../../src/pcomponents/PText.ts"],"names":[],"mappings":"AACA,OAAO,UAAU,EAAE,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACxD,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAC1E,OAAO,KAAK,MAAM,gBAAgB,CAAC;AACnC,OAAO,WAAW,MAAM,gBAAgB,CAAC;AACzC,OAAO,KAAK,MAAM,UAAU,CAAC;AAE7B,UAAU,MAAO,SAAQ,WAAW;IAClC,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IAEzB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,YAAY,EAAE,MAAM,CAAC;IACrB,YAAY,EAAE,MAAM,CAAC;IACrB,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,MAAM,CAAC;IAClB,aAAa,EAAE,MAAM,CAAC;IACtB,eAAe,EAAE,SAAS,GAAG,IAAI,CAAC;IAClC,kBAAkB,EAAE,UAAU,GAAG,IAAI,CAAC;CACvC;AACD,YAAY,EAAE,MAAM,EAAE,CAAC;AAEvB,MAAM,CAAC,OAAO,CAAC,QAAQ,OAAO,KAAM,SAAQ,UAAU;IACpD,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,YAAY,EAAE,MAAM,CAAC;IACrB,YAAY,EAAE,MAAM,CAAC;IACrB,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,MAAM,CAAC;IAClB,aAAa,EAAE,MAAM,CAAC;IAEtB,SAAS,EAAE,KAAK,GAAG,IAAI,CAAC;IAExB,eAAe,EAAE,SAAS,GAAG,IAAI,CAAC;IAClC,kBAAkB,EAAE,UAAU,GAAG,IAAI,CAAC;gBAE1B,WAAW,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,OAAO,EAAE,WAAW;IA2BlE,IAAI,IAAI,MAAM;IAgBd,OAAO;IAIP,QAAQ,CAAC,gBAAgB,CAAC,YAAY,EAAE,MAAM,GAAG,IAAI,GAAG,IAAI;CAC7D"}