@vpmedia/phaser 1.102.0 → 1.104.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +38 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +21129 -0
- package/dist/index.js.map +1 -0
- package/{types → dist}/phaser/core/animation.d.ts +80 -76
- package/dist/phaser/core/animation.d.ts.map +1 -0
- package/{types → dist}/phaser/core/animation_manager.d.ts +46 -55
- package/dist/phaser/core/animation_manager.d.ts.map +1 -0
- package/dist/phaser/core/animation_parser.d.ts +21 -0
- package/dist/phaser/core/animation_parser.d.ts.map +1 -0
- package/{types → dist}/phaser/core/array_set.d.ts +13 -13
- package/dist/phaser/core/array_set.d.ts.map +1 -0
- package/{types → dist}/phaser/core/cache.d.ts +86 -91
- package/dist/phaser/core/cache.d.ts.map +1 -0
- package/dist/phaser/core/const.d.ts +262 -0
- package/dist/phaser/core/const.d.ts.map +1 -0
- package/dist/phaser/core/device.d.ts +31 -0
- package/dist/phaser/core/device.d.ts.map +1 -0
- package/dist/phaser/core/device_util.d.ts +65 -0
- package/dist/phaser/core/device_util.d.ts.map +1 -0
- package/dist/phaser/core/dom.d.ts +75 -0
- package/dist/phaser/core/dom.d.ts.map +1 -0
- package/dist/phaser/core/error_code.d.ts +9 -0
- package/dist/phaser/core/error_code.d.ts.map +1 -0
- package/{types → dist}/phaser/core/event_manager.d.ts +33 -35
- package/dist/phaser/core/event_manager.d.ts.map +1 -0
- package/{types → dist}/phaser/core/factory.d.ts +10 -15
- package/dist/phaser/core/factory.d.ts.map +1 -0
- package/{types → dist}/phaser/core/frame.d.ts +7 -28
- package/dist/phaser/core/frame.d.ts.map +1 -0
- package/{types → dist}/phaser/core/frame_data.d.ts +14 -15
- package/dist/phaser/core/frame_data.d.ts.map +1 -0
- package/dist/phaser/core/frame_util.d.ts +15 -0
- package/dist/phaser/core/frame_util.d.ts.map +1 -0
- package/{types → dist}/phaser/core/game.d.ts +63 -74
- package/dist/phaser/core/game.d.ts.map +1 -0
- package/{types → dist}/phaser/core/input.d.ts +68 -76
- package/dist/phaser/core/input.d.ts.map +1 -0
- package/{types → dist}/phaser/core/input_handler.d.ts +73 -93
- package/dist/phaser/core/input_handler.d.ts.map +1 -0
- package/dist/phaser/core/input_mouse.d.ts +61 -0
- package/dist/phaser/core/input_mouse.d.ts.map +1 -0
- package/dist/phaser/core/input_mspointer.d.ts +67 -0
- package/dist/phaser/core/input_mspointer.d.ts.map +1 -0
- package/dist/phaser/core/input_pointer.d.ts +150 -0
- package/dist/phaser/core/input_pointer.d.ts.map +1 -0
- package/{types → dist}/phaser/core/input_touch.d.ts +24 -25
- package/dist/phaser/core/input_touch.d.ts.map +1 -0
- package/{types → dist}/phaser/core/loader.d.ts +67 -78
- package/dist/phaser/core/loader.d.ts.map +1 -0
- package/dist/phaser/core/loader_parser.d.ts +35 -0
- package/dist/phaser/core/loader_parser.d.ts.map +1 -0
- package/{types → dist}/phaser/core/raf.d.ts +5 -5
- package/dist/phaser/core/raf.d.ts.map +1 -0
- package/{types → dist}/phaser/core/scale_manager.d.ts +96 -124
- package/dist/phaser/core/scale_manager.d.ts.map +1 -0
- package/{types → dist}/phaser/core/scene.d.ts +7 -3
- package/dist/phaser/core/scene.d.ts.map +1 -0
- package/{types → dist}/phaser/core/scene_manager.d.ts +25 -27
- package/dist/phaser/core/scene_manager.d.ts.map +1 -0
- package/{types → dist}/phaser/core/signal.d.ts +21 -17
- package/dist/phaser/core/signal.d.ts.map +1 -0
- package/{types → dist}/phaser/core/signal_binding.d.ts +15 -15
- package/dist/phaser/core/signal_binding.d.ts.map +1 -0
- package/{types → dist}/phaser/core/sound.d.ts +115 -75
- package/dist/phaser/core/sound.d.ts.map +1 -0
- package/{types → dist}/phaser/core/sound_manager.d.ts +37 -43
- package/dist/phaser/core/sound_manager.d.ts.map +1 -0
- package/dist/phaser/core/sound_sprite.d.ts +33 -0
- package/dist/phaser/core/sound_sprite.d.ts.map +1 -0
- package/{types → dist}/phaser/core/stage.d.ts +33 -17
- package/dist/phaser/core/stage.d.ts.map +1 -0
- package/{types → dist}/phaser/core/time.d.ts +39 -64
- package/dist/phaser/core/time.d.ts.map +1 -0
- package/{types → dist}/phaser/core/timer.d.ts +34 -54
- package/dist/phaser/core/timer.d.ts.map +1 -0
- package/{types → dist}/phaser/core/timer_event.d.ts +11 -11
- package/dist/phaser/core/timer_event.d.ts.map +1 -0
- package/{types → dist}/phaser/core/tween.d.ts +54 -49
- package/dist/phaser/core/tween.d.ts.map +1 -0
- package/{types → dist}/phaser/core/tween_data.d.ts +33 -35
- package/dist/phaser/core/tween_data.d.ts.map +1 -0
- package/dist/phaser/core/tween_easing.d.ts +187 -0
- package/dist/phaser/core/tween_easing.d.ts.map +1 -0
- package/{types → dist}/phaser/core/tween_manager.d.ts +13 -18
- package/dist/phaser/core/tween_manager.d.ts.map +1 -0
- package/{types → dist}/phaser/core/world.d.ts +3 -3
- package/dist/phaser/core/world.d.ts.map +1 -0
- package/{types → dist}/phaser/display/bitmap_text.d.ts +65 -71
- package/dist/phaser/display/bitmap_text.d.ts.map +1 -0
- package/{types → dist}/phaser/display/button.d.ts +53 -37
- package/dist/phaser/display/button.d.ts.map +1 -0
- package/{types → dist}/phaser/display/canvas/buffer.d.ts +7 -7
- package/dist/phaser/display/canvas/buffer.d.ts.map +1 -0
- package/dist/phaser/display/canvas/graphics.d.ts +18 -0
- package/dist/phaser/display/canvas/graphics.d.ts.map +1 -0
- package/dist/phaser/display/canvas/masker.d.ts +12 -0
- package/dist/phaser/display/canvas/masker.d.ts.map +1 -0
- package/dist/phaser/display/canvas/pool.d.ts +40 -0
- package/dist/phaser/display/canvas/pool.d.ts.map +1 -0
- package/{types → dist}/phaser/display/canvas/renderer.d.ts +19 -28
- package/dist/phaser/display/canvas/renderer.d.ts.map +1 -0
- package/dist/phaser/display/canvas/tinter.d.ts +41 -0
- package/dist/phaser/display/canvas/tinter.d.ts.map +1 -0
- package/dist/phaser/display/canvas/util.d.ts +70 -0
- package/dist/phaser/display/canvas/util.d.ts.map +1 -0
- package/{types → dist}/phaser/display/display_object.d.ts +90 -95
- package/dist/phaser/display/display_object.d.ts.map +1 -0
- package/{types → dist}/phaser/display/graphics.d.ts +77 -65
- package/dist/phaser/display/graphics.d.ts.map +1 -0
- package/{types → dist}/phaser/display/graphics_data.d.ts +12 -12
- package/dist/phaser/display/graphics_data.d.ts.map +1 -0
- package/dist/phaser/display/graphics_data_util.d.ts +8 -0
- package/dist/phaser/display/graphics_data_util.d.ts.map +1 -0
- package/{types → dist}/phaser/display/group.d.ts +50 -40
- package/dist/phaser/display/group.d.ts.map +1 -0
- package/{types → dist}/phaser/display/image.d.ts +89 -50
- package/dist/phaser/display/image.d.ts.map +1 -0
- package/dist/phaser/display/sprite_batch.d.ts +9 -0
- package/dist/phaser/display/sprite_batch.d.ts.map +1 -0
- package/dist/phaser/display/sprite_util.d.ts +35 -0
- package/dist/phaser/display/sprite_util.d.ts.map +1 -0
- package/{types → dist}/phaser/display/text.d.ts +176 -181
- package/dist/phaser/display/text.d.ts.map +1 -0
- package/{types → dist}/phaser/display/webgl/abstract_filter.d.ts +8 -8
- package/dist/phaser/display/webgl/abstract_filter.d.ts.map +1 -0
- package/{types → dist}/phaser/display/webgl/base_texture.d.ts +15 -15
- package/dist/phaser/display/webgl/base_texture.d.ts.map +1 -0
- package/{types → dist}/phaser/display/webgl/blend_manager.d.ts +9 -5
- package/dist/phaser/display/webgl/blend_manager.d.ts.map +1 -0
- package/{types → dist}/phaser/display/webgl/earcut.d.ts +28 -27
- package/dist/phaser/display/webgl/earcut.d.ts.map +1 -0
- package/{types → dist}/phaser/display/webgl/earcut_node.d.ts +11 -11
- package/dist/phaser/display/webgl/earcut_node.d.ts.map +1 -0
- package/{types → dist}/phaser/display/webgl/fast_sprite_batch.d.ts +21 -28
- package/dist/phaser/display/webgl/fast_sprite_batch.d.ts.map +1 -0
- package/{types → dist}/phaser/display/webgl/filter_manager.d.ts +9 -7
- package/dist/phaser/display/webgl/filter_manager.d.ts.map +1 -0
- package/{types → dist}/phaser/display/webgl/filter_texture.d.ts +7 -9
- package/dist/phaser/display/webgl/filter_texture.d.ts.map +1 -0
- package/dist/phaser/display/webgl/graphics.d.ts +78 -0
- package/dist/phaser/display/webgl/graphics.d.ts.map +1 -0
- package/dist/phaser/display/webgl/graphics_data.d.ts +25 -0
- package/dist/phaser/display/webgl/graphics_data.d.ts.map +1 -0
- package/dist/phaser/display/webgl/mask_manager.d.ts +13 -0
- package/dist/phaser/display/webgl/mask_manager.d.ts.map +1 -0
- package/{types → dist}/phaser/display/webgl/render_texture.d.ts +15 -13
- package/dist/phaser/display/webgl/render_texture.d.ts.map +1 -0
- package/dist/phaser/display/webgl/renderer.d.ts +68 -0
- package/dist/phaser/display/webgl/renderer.d.ts.map +1 -0
- package/dist/phaser/display/webgl/shader/complex.d.ts +21 -0
- package/dist/phaser/display/webgl/shader/complex.d.ts.map +1 -0
- package/dist/phaser/display/webgl/shader/fast.d.ts +22 -0
- package/dist/phaser/display/webgl/shader/fast.d.ts.map +1 -0
- package/dist/phaser/display/webgl/shader/normal.d.ts +39 -0
- package/dist/phaser/display/webgl/shader/normal.d.ts.map +1 -0
- package/dist/phaser/display/webgl/shader/primitive.d.ts +21 -0
- package/dist/phaser/display/webgl/shader/primitive.d.ts.map +1 -0
- package/dist/phaser/display/webgl/shader/strip.d.ts +21 -0
- package/dist/phaser/display/webgl/shader/strip.d.ts.map +1 -0
- package/dist/phaser/display/webgl/shader_manager.d.ts +37 -0
- package/dist/phaser/display/webgl/shader_manager.d.ts.map +1 -0
- package/{types → dist}/phaser/display/webgl/sprite_batch.d.ts +24 -31
- package/dist/phaser/display/webgl/sprite_batch.d.ts.map +1 -0
- package/{types → dist}/phaser/display/webgl/stencil_manager.d.ts +12 -9
- package/dist/phaser/display/webgl/stencil_manager.d.ts.map +1 -0
- package/dist/phaser/display/webgl/texture.d.ts +56 -0
- package/dist/phaser/display/webgl/texture.d.ts.map +1 -0
- package/dist/phaser/display/webgl/texture_util.d.ts +17 -0
- package/dist/phaser/display/webgl/texture_util.d.ts.map +1 -0
- package/dist/phaser/display/webgl/util.d.ts +54 -0
- package/dist/phaser/display/webgl/util.d.ts.map +1 -0
- package/{types → dist}/phaser/geom/circle.d.ts +35 -41
- package/dist/phaser/geom/circle.d.ts.map +1 -0
- package/{types → dist}/phaser/geom/ellipse.d.ts +12 -18
- package/dist/phaser/geom/ellipse.d.ts.map +1 -0
- package/{types → dist}/phaser/geom/line.d.ts +20 -23
- package/dist/phaser/geom/line.d.ts.map +1 -0
- package/{types → dist}/phaser/geom/matrix.d.ts +21 -29
- package/dist/phaser/geom/matrix.d.ts.map +1 -0
- package/{types → dist}/phaser/geom/point.d.ts +30 -33
- package/dist/phaser/geom/point.d.ts.map +1 -0
- package/{types → dist}/phaser/geom/polygon.d.ts +18 -24
- package/dist/phaser/geom/polygon.d.ts.map +1 -0
- package/{types → dist}/phaser/geom/rectangle.d.ts +74 -79
- package/dist/phaser/geom/rectangle.d.ts.map +1 -0
- package/{types → dist}/phaser/geom/rounded_rectangle.d.ts +9 -9
- package/dist/phaser/geom/rounded_rectangle.d.ts.map +1 -0
- package/dist/phaser/geom/util/circle.d.ts +55 -0
- package/dist/phaser/geom/util/circle.d.ts.map +1 -0
- package/dist/phaser/geom/util/ellipse.d.ts +9 -0
- package/dist/phaser/geom/util/ellipse.d.ts.map +1 -0
- package/dist/phaser/geom/util/line.d.ts +42 -0
- package/dist/phaser/geom/util/line.d.ts.map +1 -0
- package/dist/phaser/geom/util/matrix.d.ts +18 -0
- package/dist/phaser/geom/util/matrix.d.ts.map +1 -0
- package/dist/phaser/geom/util/point.d.ts +159 -0
- package/dist/phaser/geom/util/point.d.ts.map +1 -0
- package/dist/phaser/geom/util/polygon.d.ts +8 -0
- package/dist/phaser/geom/util/polygon.d.ts.map +1 -0
- package/dist/phaser/geom/util/rectangle.d.ts +123 -0
- package/dist/phaser/geom/util/rectangle.d.ts.map +1 -0
- package/dist/phaser/geom/util/rounded_rectangle.d.ts +8 -0
- package/dist/phaser/geom/util/rounded_rectangle.d.ts.map +1 -0
- package/dist/phaser/util/math.d.ts +154 -0
- package/dist/phaser/util/math.d.ts.map +1 -0
- package/package.json +26 -12
- package/src/phaser/core/{animation.js → animation.ts} +50 -3
- package/src/phaser/core/{animation_manager.js → animation_manager.ts} +11 -1
- package/src/phaser/core/{array_set.js → array_set.ts} +4 -1
- package/src/phaser/core/{cache.js → cache.ts} +10 -1
- package/src/phaser/core/{device.js → device.ts} +25 -1
- package/src/phaser/core/{dom.js → dom.ts} +7 -0
- package/src/phaser/core/{event_manager.js → event_manager.ts} +18 -1
- package/src/phaser/core/{factory.js → factory.ts} +2 -0
- package/src/phaser/core/{frame.js → frame.ts} +2 -1
- package/src/phaser/core/{frame_data.js → frame_data.ts} +4 -1
- package/src/phaser/core/{frame_util.js → frame_util.ts} +2 -1
- package/src/phaser/core/{game.js → game.ts} +61 -4
- package/src/phaser/core/{input.js → input.ts} +52 -0
- package/src/phaser/core/{input_handler.js → input_handler.ts} +42 -0
- package/src/phaser/core/{input_mouse.js → input_mouse.ts} +24 -0
- package/src/phaser/core/{input_mspointer.js → input_mspointer.ts} +17 -0
- package/src/phaser/core/{input_pointer.js → input_pointer.ts} +45 -0
- package/src/phaser/core/{input_touch.js → input_touch.ts} +18 -0
- package/src/phaser/core/{loader.js → loader.ts} +30 -1
- package/src/phaser/core/{loader_parser.js → loader_parser.ts} +2 -1
- package/src/phaser/core/{raf.js → raf.ts} +3 -0
- package/src/phaser/core/{scale_manager.js → scale_manager.ts} +56 -0
- package/src/phaser/core/{scene.js → scene.ts} +3 -0
- package/src/phaser/core/{scene_manager.js → scene_manager.ts} +16 -0
- package/src/phaser/core/{signal.js → signal.ts} +7 -0
- package/src/phaser/core/{signal_binding.js → signal_binding.ts} +10 -0
- package/src/phaser/core/{sound.js → sound.ts} +100 -6
- package/src/phaser/core/{sound_manager.js → sound_manager.ts} +19 -1
- package/src/phaser/core/{sound_sprite.js → sound_sprite.ts} +8 -1
- package/src/phaser/core/{stage.js → stage.ts} +5 -0
- package/src/phaser/core/{time.js → time.ts} +29 -1
- package/src/phaser/core/{timer.js → timer.ts} +22 -1
- package/src/phaser/core/{timer_event.js → timer_event.ts} +11 -1
- package/src/phaser/core/{tween.js → tween.ts} +49 -2
- package/src/phaser/core/{tween_data.js → tween_data.ts} +26 -1
- package/src/phaser/core/{tween_manager.js → tween_manager.ts} +6 -1
- package/src/phaser/core/{world.js → world.ts} +1 -0
- package/src/phaser/display/{bitmap_text.js → bitmap_text.ts} +14 -0
- package/src/phaser/display/{button.js → button.ts} +29 -0
- package/src/phaser/display/canvas/{buffer.js → buffer.ts} +5 -0
- package/src/phaser/display/canvas/{graphics.js → graphics.ts} +1 -0
- package/src/phaser/display/canvas/{masker.js → masker.ts} +1 -0
- package/src/phaser/display/canvas/{pool.js → pool.ts} +1 -0
- package/src/phaser/display/canvas/{renderer.js → renderer.ts} +14 -0
- package/src/phaser/display/canvas/{tinter.js → tinter.ts} +1 -0
- package/src/phaser/display/{display_object.js → display_object.ts} +92 -31
- package/src/phaser/display/{graphics.js → graphics.ts} +19 -0
- package/src/phaser/display/{graphics_data.js → graphics_data.ts} +11 -0
- package/src/phaser/display/{graphics_data_util.js → graphics_data_util.ts} +1 -0
- package/src/phaser/display/{group.js → group.ts} +29 -0
- package/src/phaser/display/{image.js → image.ts} +45 -6
- package/src/phaser/display/{sprite_batch.js → sprite_batch.ts} +1 -0
- package/src/phaser/display/{sprite_util.js → sprite_util.ts} +1 -0
- package/src/phaser/display/{text.js → text.ts} +1 -0
- package/src/phaser/display/webgl/{abstract_filter.js → abstract_filter.ts} +7 -0
- package/src/phaser/display/webgl/{base_texture.js → base_texture.ts} +13 -0
- package/src/phaser/display/webgl/{blend_manager.js → blend_manager.ts} +3 -0
- package/src/phaser/display/webgl/{earcut.js → earcut.ts} +2 -2
- package/src/phaser/display/webgl/{earcut_node.js → earcut_node.ts} +10 -0
- package/src/phaser/display/webgl/{fast_sprite_batch.js → fast_sprite_batch.ts} +16 -0
- package/src/phaser/display/webgl/{filter_manager.js → filter_manager.ts} +4 -0
- package/src/phaser/display/webgl/{filter_texture.js → filter_texture.ts} +5 -0
- package/src/phaser/display/webgl/{graphics.js → graphics.ts} +1 -0
- package/src/phaser/display/webgl/{graphics_data.js → graphics_data.ts} +10 -0
- package/src/phaser/display/webgl/{mask_manager.js → mask_manager.ts} +1 -0
- package/src/phaser/display/webgl/{render_texture.js → render_texture.ts} +11 -0
- package/src/phaser/display/webgl/{renderer.js → renderer.ts} +18 -0
- package/src/phaser/display/webgl/shader/{complex.js → complex.ts} +6 -0
- package/src/phaser/display/webgl/shader/{fast.js → fast.ts} +7 -0
- package/src/phaser/display/webgl/shader/{normal.js → normal.ts} +11 -0
- package/src/phaser/display/webgl/shader/{primitive.js → primitive.ts} +6 -0
- package/src/phaser/display/webgl/shader/{strip.js → strip.ts} +6 -0
- package/src/phaser/display/webgl/{shader_manager.js → shader_manager.ts} +11 -0
- package/src/phaser/display/webgl/{sprite_batch.js → sprite_batch.ts} +17 -0
- package/src/phaser/display/webgl/{stencil_manager.js → stencil_manager.ts} +4 -0
- package/src/phaser/display/webgl/{texture.js → texture.ts} +21 -0
- package/src/phaser/display/webgl/{texture_util.js → texture_util.ts} +1 -0
- package/src/phaser/geom/{circle.js → circle.ts} +7 -1
- package/src/phaser/geom/{ellipse.js → ellipse.ts} +6 -0
- package/src/phaser/geom/{line.js → line.ts} +4 -0
- package/src/phaser/geom/{matrix.js → matrix.ts} +8 -0
- package/src/phaser/geom/{point.js → point.ts} +5 -1
- package/src/phaser/geom/{polygon.js → polygon.ts} +6 -0
- package/src/phaser/geom/{rectangle.js → rectangle.ts} +10 -4
- package/src/phaser/geom/{rounded_rectangle.js → rounded_rectangle.ts} +7 -0
- package/.vscode/extensions.json +0 -6
- package/.vscode/settings.json +0 -27
- package/AGENTS.md +0 -1
- package/CHANGELOG.md +0 -336
- package/CLAUDE.md +0 -1
- package/SECURITY.md +0 -5
- package/typedefs/global.d.ts +0 -7
- package/types/index.d.ts +0 -38
- package/types/index.d.ts.map +0 -1
- package/types/phaser/core/animation.d.ts.map +0 -1
- package/types/phaser/core/animation_manager.d.ts.map +0 -1
- package/types/phaser/core/animation_parser.d.ts +0 -4
- package/types/phaser/core/animation_parser.d.ts.map +0 -1
- package/types/phaser/core/array_set.d.ts.map +0 -1
- package/types/phaser/core/cache.d.ts.map +0 -1
- package/types/phaser/core/const.d.ts +0 -262
- package/types/phaser/core/const.d.ts.map +0 -1
- package/types/phaser/core/device.d.ts +0 -96
- package/types/phaser/core/device.d.ts.map +0 -1
- package/types/phaser/core/device_util.d.ts +0 -13
- package/types/phaser/core/device_util.d.ts.map +0 -1
- package/types/phaser/core/dom.d.ts +0 -180
- package/types/phaser/core/dom.d.ts.map +0 -1
- package/types/phaser/core/error_code.d.ts +0 -9
- package/types/phaser/core/error_code.d.ts.map +0 -1
- package/types/phaser/core/event_manager.d.ts.map +0 -1
- package/types/phaser/core/factory.d.ts.map +0 -1
- package/types/phaser/core/frame.d.ts.map +0 -1
- package/types/phaser/core/frame_data.d.ts.map +0 -1
- package/types/phaser/core/frame_util.d.ts +0 -5
- package/types/phaser/core/frame_util.d.ts.map +0 -1
- package/types/phaser/core/game.d.ts.map +0 -1
- package/types/phaser/core/input.d.ts.map +0 -1
- package/types/phaser/core/input_handler.d.ts.map +0 -1
- package/types/phaser/core/input_mouse.d.ts +0 -86
- package/types/phaser/core/input_mouse.d.ts.map +0 -1
- package/types/phaser/core/input_mspointer.d.ts +0 -67
- package/types/phaser/core/input_mspointer.d.ts.map +0 -1
- package/types/phaser/core/input_pointer.d.ts +0 -170
- package/types/phaser/core/input_pointer.d.ts.map +0 -1
- package/types/phaser/core/input_touch.d.ts.map +0 -1
- package/types/phaser/core/loader.d.ts.map +0 -1
- package/types/phaser/core/loader_parser.d.ts +0 -5
- package/types/phaser/core/loader_parser.d.ts.map +0 -1
- package/types/phaser/core/raf.d.ts.map +0 -1
- package/types/phaser/core/scale_manager.d.ts.map +0 -1
- package/types/phaser/core/scene.d.ts.map +0 -1
- package/types/phaser/core/scene_manager.d.ts.map +0 -1
- package/types/phaser/core/signal.d.ts.map +0 -1
- package/types/phaser/core/signal_binding.d.ts.map +0 -1
- package/types/phaser/core/sound.d.ts.map +0 -1
- package/types/phaser/core/sound_manager.d.ts.map +0 -1
- package/types/phaser/core/sound_sprite.d.ts +0 -36
- package/types/phaser/core/sound_sprite.d.ts.map +0 -1
- package/types/phaser/core/stage.d.ts.map +0 -1
- package/types/phaser/core/time.d.ts.map +0 -1
- package/types/phaser/core/timer.d.ts.map +0 -1
- package/types/phaser/core/timer_event.d.ts.map +0 -1
- package/types/phaser/core/tween.d.ts.map +0 -1
- package/types/phaser/core/tween_data.d.ts.map +0 -1
- package/types/phaser/core/tween_easing.d.ts +0 -32
- package/types/phaser/core/tween_easing.d.ts.map +0 -1
- package/types/phaser/core/tween_manager.d.ts.map +0 -1
- package/types/phaser/core/world.d.ts.map +0 -1
- package/types/phaser/display/bitmap_text.d.ts.map +0 -1
- package/types/phaser/display/button.d.ts.map +0 -1
- package/types/phaser/display/canvas/buffer.d.ts.map +0 -1
- package/types/phaser/display/canvas/graphics.d.ts +0 -4
- package/types/phaser/display/canvas/graphics.d.ts.map +0 -1
- package/types/phaser/display/canvas/masker.d.ts +0 -3
- package/types/phaser/display/canvas/masker.d.ts.map +0 -1
- package/types/phaser/display/canvas/pool.d.ts +0 -11
- package/types/phaser/display/canvas/pool.d.ts.map +0 -1
- package/types/phaser/display/canvas/renderer.d.ts.map +0 -1
- package/types/phaser/display/canvas/tinter.d.ts +0 -7
- package/types/phaser/display/canvas/tinter.d.ts.map +0 -1
- package/types/phaser/display/canvas/util.d.ts +0 -10
- package/types/phaser/display/canvas/util.d.ts.map +0 -1
- package/types/phaser/display/display_object.d.ts.map +0 -1
- package/types/phaser/display/graphics.d.ts.map +0 -1
- package/types/phaser/display/graphics_data.d.ts.map +0 -1
- package/types/phaser/display/graphics_data_util.d.ts +0 -3
- package/types/phaser/display/graphics_data_util.d.ts.map +0 -1
- package/types/phaser/display/group.d.ts.map +0 -1
- package/types/phaser/display/image.d.ts.map +0 -1
- package/types/phaser/display/sprite_batch.d.ts +0 -4
- package/types/phaser/display/sprite_batch.d.ts.map +0 -1
- package/types/phaser/display/sprite_util.d.ts +0 -6
- package/types/phaser/display/sprite_util.d.ts.map +0 -1
- package/types/phaser/display/text.d.ts.map +0 -1
- package/types/phaser/display/webgl/abstract_filter.d.ts.map +0 -1
- package/types/phaser/display/webgl/base_texture.d.ts.map +0 -1
- package/types/phaser/display/webgl/blend_manager.d.ts.map +0 -1
- package/types/phaser/display/webgl/earcut.d.ts.map +0 -1
- package/types/phaser/display/webgl/earcut_node.d.ts.map +0 -1
- package/types/phaser/display/webgl/fast_sprite_batch.d.ts.map +0 -1
- package/types/phaser/display/webgl/filter_manager.d.ts.map +0 -1
- package/types/phaser/display/webgl/filter_texture.d.ts.map +0 -1
- package/types/phaser/display/webgl/graphics.d.ts +0 -16
- package/types/phaser/display/webgl/graphics.d.ts.map +0 -1
- package/types/phaser/display/webgl/graphics_data.d.ts +0 -27
- package/types/phaser/display/webgl/graphics_data.d.ts.map +0 -1
- package/types/phaser/display/webgl/mask_manager.d.ts +0 -3
- package/types/phaser/display/webgl/mask_manager.d.ts.map +0 -1
- package/types/phaser/display/webgl/render_texture.d.ts.map +0 -1
- package/types/phaser/display/webgl/renderer.d.ts +0 -87
- package/types/phaser/display/webgl/renderer.d.ts.map +0 -1
- package/types/phaser/display/webgl/shader/complex.d.ts +0 -33
- package/types/phaser/display/webgl/shader/complex.d.ts.map +0 -1
- package/types/phaser/display/webgl/shader/fast.d.ts +0 -36
- package/types/phaser/display/webgl/shader/fast.d.ts.map +0 -1
- package/types/phaser/display/webgl/shader/normal.d.ts +0 -52
- package/types/phaser/display/webgl/shader/normal.d.ts.map +0 -1
- package/types/phaser/display/webgl/shader/primitive.d.ts +0 -32
- package/types/phaser/display/webgl/shader/primitive.d.ts.map +0 -1
- package/types/phaser/display/webgl/shader/strip.d.ts +0 -33
- package/types/phaser/display/webgl/shader/strip.d.ts.map +0 -1
- package/types/phaser/display/webgl/shader_manager.d.ts +0 -44
- package/types/phaser/display/webgl/shader_manager.d.ts.map +0 -1
- package/types/phaser/display/webgl/sprite_batch.d.ts.map +0 -1
- package/types/phaser/display/webgl/stencil_manager.d.ts.map +0 -1
- package/types/phaser/display/webgl/texture.d.ts +0 -63
- package/types/phaser/display/webgl/texture.d.ts.map +0 -1
- package/types/phaser/display/webgl/texture_util.d.ts +0 -5
- package/types/phaser/display/webgl/texture_util.d.ts.map +0 -1
- package/types/phaser/display/webgl/util.d.ts +0 -15
- package/types/phaser/display/webgl/util.d.ts.map +0 -1
- package/types/phaser/geom/circle.d.ts.map +0 -1
- package/types/phaser/geom/ellipse.d.ts.map +0 -1
- package/types/phaser/geom/line.d.ts.map +0 -1
- package/types/phaser/geom/matrix.d.ts.map +0 -1
- package/types/phaser/geom/point.d.ts.map +0 -1
- package/types/phaser/geom/polygon.d.ts.map +0 -1
- package/types/phaser/geom/rectangle.d.ts.map +0 -1
- package/types/phaser/geom/rounded_rectangle.d.ts.map +0 -1
- package/types/phaser/geom/util/circle.d.ts +0 -10
- package/types/phaser/geom/util/circle.d.ts.map +0 -1
- package/types/phaser/geom/util/ellipse.d.ts +0 -2
- package/types/phaser/geom/util/ellipse.d.ts.map +0 -1
- package/types/phaser/geom/util/line.d.ts +0 -8
- package/types/phaser/geom/util/line.d.ts.map +0 -1
- package/types/phaser/geom/util/matrix.d.ts +0 -5
- package/types/phaser/geom/util/matrix.d.ts.map +0 -1
- package/types/phaser/geom/util/point.d.ts +0 -22
- package/types/phaser/geom/util/point.d.ts.map +0 -1
- package/types/phaser/geom/util/polygon.d.ts +0 -3
- package/types/phaser/geom/util/polygon.d.ts.map +0 -1
- package/types/phaser/geom/util/rectangle.d.ts +0 -19
- package/types/phaser/geom/util/rectangle.d.ts.map +0 -1
- package/types/phaser/geom/util/rounded_rectangle.d.ts +0 -3
- package/types/phaser/geom/util/rounded_rectangle.d.ts.map +0 -1
- package/types/phaser/util/math.d.ts +0 -58
- package/types/phaser/util/math.d.ts.map +0 -1
- /package/src/{index.js → index.ts} +0 -0
- /package/src/phaser/core/{animation_parser.js → animation_parser.ts} +0 -0
- /package/src/phaser/core/{const.js → const.ts} +0 -0
- /package/src/phaser/core/{device_util.js → device_util.ts} +0 -0
- /package/src/phaser/core/{error_code.js → error_code.ts} +0 -0
- /package/src/phaser/core/{signal.test.js → signal.test.ts} +0 -0
- /package/src/phaser/core/{tween_easing.js → tween_easing.ts} +0 -0
- /package/src/phaser/display/canvas/{util.js → util.ts} +0 -0
- /package/src/phaser/display/webgl/{util.js → util.ts} +0 -0
- /package/src/phaser/geom/{circle.test.js → circle.test.ts} +0 -0
- /package/src/phaser/geom/{ellipse.test.js → ellipse.test.ts} +0 -0
- /package/src/phaser/geom/{line.test.js → line.test.ts} +0 -0
- /package/src/phaser/geom/{matrix.test.js → matrix.test.ts} +0 -0
- /package/src/phaser/geom/{point.test.js → point.test.ts} +0 -0
- /package/src/phaser/geom/{rectangle.test.js → rectangle.test.ts} +0 -0
- /package/src/phaser/geom/{rounded_rectangle.test.js → rounded_rectangle.test.ts} +0 -0
- /package/src/phaser/geom/util/{circle.test.js → circle.test.ts} +0 -0
- /package/src/phaser/geom/util/{circle.js → circle.ts} +0 -0
- /package/src/phaser/geom/util/{ellipse.test.js → ellipse.test.ts} +0 -0
- /package/src/phaser/geom/util/{ellipse.js → ellipse.ts} +0 -0
- /package/src/phaser/geom/util/{line.test.js → line.test.ts} +0 -0
- /package/src/phaser/geom/util/{line.js → line.ts} +0 -0
- /package/src/phaser/geom/util/{matrix.test.js → matrix.test.ts} +0 -0
- /package/src/phaser/geom/util/{matrix.js → matrix.ts} +0 -0
- /package/src/phaser/geom/util/{point.test.js → point.test.ts} +0 -0
- /package/src/phaser/geom/util/{point.js → point.ts} +0 -0
- /package/src/phaser/geom/util/{polygon.test.js → polygon.test.ts} +0 -0
- /package/src/phaser/geom/util/{polygon.js → polygon.ts} +0 -0
- /package/src/phaser/geom/util/{rectangle.test.js → rectangle.test.ts} +0 -0
- /package/src/phaser/geom/util/{rectangle.js → rectangle.ts} +0 -0
- /package/src/phaser/geom/util/{rounded_rectangle.test.js → rounded_rectangle.test.ts} +0 -0
- /package/src/phaser/geom/util/{rounded_rectangle.js → rounded_rectangle.ts} +0 -0
- /package/src/phaser/util/{math.test.js → math.test.ts} +0 -0
- /package/src/phaser/util/{math.js → math.ts} +0 -0
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
1
2
|
import { Rectangle } from '../geom/rectangle.js';
|
|
2
3
|
import { canPlayAudio } from './device_util.js';
|
|
3
4
|
import { ENGINE_ERROR_INVALID_BITMAP_FONT_ATLAS } from './error_code.js';
|
|
@@ -6,6 +7,34 @@ import { Signal } from './signal.js';
|
|
|
6
7
|
const TEXTURE_ATLAS_JSON_HASH = 1;
|
|
7
8
|
|
|
8
9
|
export class Loader {
|
|
10
|
+
game;
|
|
11
|
+
cache;
|
|
12
|
+
isLoading;
|
|
13
|
+
isUseLog;
|
|
14
|
+
isUseRetry;
|
|
15
|
+
maxRetry;
|
|
16
|
+
hasLoaded;
|
|
17
|
+
preloadSprite;
|
|
18
|
+
crossOrigin;
|
|
19
|
+
baseURL;
|
|
20
|
+
path;
|
|
21
|
+
headers;
|
|
22
|
+
onLoadStart;
|
|
23
|
+
onLoadComplete;
|
|
24
|
+
onPackComplete;
|
|
25
|
+
onFileStart;
|
|
26
|
+
onFileComplete;
|
|
27
|
+
onFileError;
|
|
28
|
+
maxParallelDownloads;
|
|
29
|
+
_withSyncPointDepth;
|
|
30
|
+
_fileList;
|
|
31
|
+
_flightQueue;
|
|
32
|
+
_processingHead;
|
|
33
|
+
_fileLoadStarted;
|
|
34
|
+
_totalPackCount;
|
|
35
|
+
_totalFileCount;
|
|
36
|
+
_loadedPackCount;
|
|
37
|
+
_loadedFileCount;
|
|
9
38
|
/**
|
|
10
39
|
* Creates a new Loader instance.
|
|
11
40
|
* @param {import('./game.js').Game} game - Reference to the Phaser Game instance.
|
|
@@ -1196,4 +1225,4 @@ export class Loader {
|
|
|
1196
1225
|
get progress() {
|
|
1197
1226
|
return Math.round(this.progressFloat);
|
|
1198
1227
|
}
|
|
1199
|
-
}
|
|
1228
|
+
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
1
2
|
import { Texture } from '../display/webgl/texture.js';
|
|
2
3
|
import { Rectangle } from '../geom/rectangle.js';
|
|
3
4
|
|
|
@@ -101,4 +102,4 @@ export const jsonBitmapFont = (json, baseTexture, xSpacing, ySpacing) => {
|
|
|
101
102
|
});
|
|
102
103
|
}
|
|
103
104
|
return finalizeBitmapFont(baseTexture, data);
|
|
104
|
-
};
|
|
105
|
+
};
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
1
2
|
import { Point } from '../geom/point.js';
|
|
2
3
|
import { Rectangle } from '../geom/rectangle.js';
|
|
3
4
|
import { RENDER_CANVAS, SCALE_EXACT_FIT, SCALE_OFF, SCALE_RESIZE, SCALE_SHOW_ALL, SCALE_USER } from './const.js';
|
|
@@ -5,6 +6,61 @@ import { DOM } from './dom.js';
|
|
|
5
6
|
import { Signal } from './signal.js';
|
|
6
7
|
|
|
7
8
|
export class ScaleManager {
|
|
9
|
+
game;
|
|
10
|
+
dom;
|
|
11
|
+
width;
|
|
12
|
+
height;
|
|
13
|
+
minWidth;
|
|
14
|
+
maxWidth;
|
|
15
|
+
minHeight;
|
|
16
|
+
maxHeight;
|
|
17
|
+
offset;
|
|
18
|
+
forceLandscape;
|
|
19
|
+
forcePortrait;
|
|
20
|
+
incorrectOrientation;
|
|
21
|
+
_pageAlignHorizontally;
|
|
22
|
+
_pageAlignVertically;
|
|
23
|
+
onOrientationChange;
|
|
24
|
+
enterIncorrectOrientation;
|
|
25
|
+
leaveIncorrectOrientation;
|
|
26
|
+
hasPhaserSetFullScreen;
|
|
27
|
+
fullScreenTarget;
|
|
28
|
+
_createdFullScreenTarget;
|
|
29
|
+
onFullScreenInit;
|
|
30
|
+
onFullScreenChange;
|
|
31
|
+
onFullScreenError;
|
|
32
|
+
screenOrientation;
|
|
33
|
+
scaleFactor;
|
|
34
|
+
scaleFactorInversed;
|
|
35
|
+
margin;
|
|
36
|
+
bounds;
|
|
37
|
+
aspectRatio;
|
|
38
|
+
sourceAspectRatio;
|
|
39
|
+
event;
|
|
40
|
+
windowConstraints;
|
|
41
|
+
compatibility;
|
|
42
|
+
_scaleMode;
|
|
43
|
+
_fullScreenScaleMode;
|
|
44
|
+
parentIsWindow;
|
|
45
|
+
parentNode;
|
|
46
|
+
parentScaleFactor;
|
|
47
|
+
trackParentInterval;
|
|
48
|
+
onSizeChange;
|
|
49
|
+
onResize;
|
|
50
|
+
onResizeContext;
|
|
51
|
+
_pendingScaleMode;
|
|
52
|
+
_fullScreenRestore;
|
|
53
|
+
_gameSize;
|
|
54
|
+
_userScaleFactor;
|
|
55
|
+
_userScaleTrim;
|
|
56
|
+
_lastUpdate;
|
|
57
|
+
_updateThrottle;
|
|
58
|
+
_updateThrottleReset;
|
|
59
|
+
_parentBounds;
|
|
60
|
+
_tempBounds;
|
|
61
|
+
_lastReportedCanvasSize;
|
|
62
|
+
_lastReportedGameSize;
|
|
63
|
+
_booted;
|
|
8
64
|
/**
|
|
9
65
|
* TBD.
|
|
10
66
|
* @param {import('./game.js').Game} game - TBD.
|
|
@@ -1,6 +1,22 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
1
2
|
import { Scene } from './scene.js';
|
|
2
3
|
|
|
3
4
|
export class SceneManager {
|
|
5
|
+
game;
|
|
6
|
+
states;
|
|
7
|
+
_pendingState;
|
|
8
|
+
_clearWorld;
|
|
9
|
+
_clearCache;
|
|
10
|
+
_created;
|
|
11
|
+
_args;
|
|
12
|
+
current;
|
|
13
|
+
onInitCallback;
|
|
14
|
+
onPreloadCallback;
|
|
15
|
+
onCreateCallback;
|
|
16
|
+
onUpdateCallback;
|
|
17
|
+
onResizeCallback;
|
|
18
|
+
onPauseUpdateCallback;
|
|
19
|
+
onShutDownCallback;
|
|
4
20
|
/**
|
|
5
21
|
* Creates a new SceneManager instance.
|
|
6
22
|
* @param {import('./game.js').Game} game - The game instance this manager belongs to.
|
|
@@ -1,6 +1,13 @@
|
|
|
1
1
|
import { SignalBinding } from './signal_binding.js';
|
|
2
2
|
|
|
3
3
|
export class Signal {
|
|
4
|
+
_bindings: any;
|
|
5
|
+
_prevParams: any;
|
|
6
|
+
memorize: boolean;
|
|
7
|
+
_shouldPropagate: boolean;
|
|
8
|
+
active: boolean;
|
|
9
|
+
_boundDispatch: any;
|
|
10
|
+
|
|
4
11
|
/**
|
|
5
12
|
* Creates a new Signal instance.
|
|
6
13
|
* A Signal is a simple event system that allows you to dispatch events and listen for them.
|
|
@@ -1,4 +1,14 @@
|
|
|
1
1
|
export class SignalBinding {
|
|
2
|
+
_signal: any;
|
|
3
|
+
_listener: any;
|
|
4
|
+
_args: any;
|
|
5
|
+
_priority: number;
|
|
6
|
+
_isOnce: boolean;
|
|
7
|
+
context: any;
|
|
8
|
+
callCount: number;
|
|
9
|
+
active: boolean;
|
|
10
|
+
params: any;
|
|
11
|
+
|
|
2
12
|
/**
|
|
3
13
|
* TBD.
|
|
4
14
|
* @param {import('./signal.js').Signal} signal - TBD.
|
|
@@ -1,6 +1,100 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
1
2
|
import { Signal } from './signal.js';
|
|
2
3
|
|
|
3
4
|
export class Sound {
|
|
5
|
+
_paused;
|
|
6
|
+
/** @type {import('./game.js').Game} */
|
|
7
|
+
game;
|
|
8
|
+
/** @type {string} */
|
|
9
|
+
name;
|
|
10
|
+
/** @type {string} */
|
|
11
|
+
key;
|
|
12
|
+
/** @type {boolean} */
|
|
13
|
+
loop;
|
|
14
|
+
/** @type {object} */
|
|
15
|
+
markers;
|
|
16
|
+
/** @type {AudioContext} */
|
|
17
|
+
context;
|
|
18
|
+
/** @type {boolean} */
|
|
19
|
+
autoplay;
|
|
20
|
+
/** @type {number} */
|
|
21
|
+
totalDuration;
|
|
22
|
+
/** @type {number} */
|
|
23
|
+
startTime;
|
|
24
|
+
/** @type {number} */
|
|
25
|
+
currentTime;
|
|
26
|
+
/** @type {number} */
|
|
27
|
+
duration;
|
|
28
|
+
/** @type {number} */
|
|
29
|
+
durationMS;
|
|
30
|
+
/** @type {number} */
|
|
31
|
+
position;
|
|
32
|
+
/** @type {number} */
|
|
33
|
+
stopTime;
|
|
34
|
+
/** @type {boolean} */
|
|
35
|
+
paused;
|
|
36
|
+
/** @type {number} */
|
|
37
|
+
pausedPosition;
|
|
38
|
+
/** @type {number} */
|
|
39
|
+
pausedTime;
|
|
40
|
+
/** @type {boolean} */
|
|
41
|
+
isPlaying;
|
|
42
|
+
/** @type {string} */
|
|
43
|
+
currentMarker;
|
|
44
|
+
/** @type {import('./tween.js').Tween | null} */
|
|
45
|
+
fadeTween;
|
|
46
|
+
/** @type {boolean} */
|
|
47
|
+
pendingPlayback;
|
|
48
|
+
/** @type {boolean} */
|
|
49
|
+
override;
|
|
50
|
+
/** @type {boolean} */
|
|
51
|
+
allowMultiple;
|
|
52
|
+
/** @type {AudioNode | null} */
|
|
53
|
+
externalNode;
|
|
54
|
+
/** @type {GainNode | null} */
|
|
55
|
+
masterGainNode;
|
|
56
|
+
/** @type {GainNode | null} */
|
|
57
|
+
gainNode;
|
|
58
|
+
/** @type {AudioBufferSourceNode | null} */
|
|
59
|
+
_sound;
|
|
60
|
+
/** @type {boolean} */
|
|
61
|
+
_markedToDelete;
|
|
62
|
+
/** @type {boolean} */
|
|
63
|
+
_removeFromSoundManager;
|
|
64
|
+
/** @type {Signal} */
|
|
65
|
+
onPlay;
|
|
66
|
+
/** @type {Signal} */
|
|
67
|
+
onPause;
|
|
68
|
+
/** @type {Signal} */
|
|
69
|
+
onResume;
|
|
70
|
+
/** @type {Signal} */
|
|
71
|
+
onLoop;
|
|
72
|
+
/** @type {Signal} */
|
|
73
|
+
onStop;
|
|
74
|
+
/** @type {Signal} */
|
|
75
|
+
onMute;
|
|
76
|
+
/** @type {Signal} */
|
|
77
|
+
onMarkerComplete;
|
|
78
|
+
/** @type {Signal} */
|
|
79
|
+
onFadeComplete;
|
|
80
|
+
/** @type {number} */
|
|
81
|
+
_volume;
|
|
82
|
+
/** @type {AudioBuffer | null} */
|
|
83
|
+
_buffer;
|
|
84
|
+
/** @type {boolean} */
|
|
85
|
+
_muted;
|
|
86
|
+
/** @type {string} */
|
|
87
|
+
_tempMarker;
|
|
88
|
+
/** @type {number} */
|
|
89
|
+
_tempPosition;
|
|
90
|
+
/** @type {number} */
|
|
91
|
+
_tempVolume;
|
|
92
|
+
/** @type {number} */
|
|
93
|
+
_tempPause;
|
|
94
|
+
/** @type {number} */
|
|
95
|
+
_muteVolume;
|
|
96
|
+
/** @type {boolean} */
|
|
97
|
+
_tempLoop;
|
|
4
98
|
/**
|
|
5
99
|
* Creates a new Sound instance.
|
|
6
100
|
* @param {import('./game.js').Game} game - Reference to the Phaser Game instance.
|
|
@@ -171,14 +265,14 @@ export class Sound {
|
|
|
171
265
|
this.currentTime = this.game.time.time - this.startTime;
|
|
172
266
|
if (this.currentTime >= this.durationMS) {
|
|
173
267
|
if (this.loop) {
|
|
174
|
-
//
|
|
268
|
+
// Won't work with markers, needs to reset the position
|
|
175
269
|
this.onLoop.dispatch(this);
|
|
176
270
|
// Gets reset by the play function
|
|
177
271
|
this.isPlaying = false;
|
|
178
272
|
if (this.currentMarker === '') {
|
|
179
273
|
this.currentTime = 0;
|
|
180
274
|
this.startTime = this.game.time.time;
|
|
181
|
-
this.isPlaying = true; //
|
|
275
|
+
this.isPlaying = true; // Play not called again in this case
|
|
182
276
|
} else {
|
|
183
277
|
this.onMarkerComplete.dispatch(this.currentMarker, this);
|
|
184
278
|
this.play(this.currentMarker, 0, this.volume, true, true);
|
|
@@ -235,7 +329,7 @@ export class Sound {
|
|
|
235
329
|
}
|
|
236
330
|
if (marker === '' && Object.keys(this.markers).length > 0) {
|
|
237
331
|
// If they didn't specify a marker but this is an audio sprite,
|
|
238
|
-
//
|
|
332
|
+
// We should never play the entire thing
|
|
239
333
|
return this;
|
|
240
334
|
}
|
|
241
335
|
if (marker !== '') {
|
|
@@ -247,10 +341,10 @@ export class Sound {
|
|
|
247
341
|
this.loop = this.markers[marker].loop;
|
|
248
342
|
this.duration = this.markers[marker].duration;
|
|
249
343
|
this.durationMS = this.markers[marker].durationMS;
|
|
250
|
-
if (
|
|
344
|
+
if (volume !== undefined) {
|
|
251
345
|
this.volume = volume;
|
|
252
346
|
}
|
|
253
|
-
if (
|
|
347
|
+
if (loop !== undefined) {
|
|
254
348
|
this.loop = loop;
|
|
255
349
|
}
|
|
256
350
|
this._tempMarker = marker;
|
|
@@ -267,7 +361,7 @@ export class Sound {
|
|
|
267
361
|
volume = this._volume;
|
|
268
362
|
}
|
|
269
363
|
if (loop === undefined) {
|
|
270
|
-
loop = this
|
|
364
|
+
({ loop } = this);
|
|
271
365
|
}
|
|
272
366
|
this.position = Math.max(0, position);
|
|
273
367
|
this.volume = volume;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
1
2
|
import {
|
|
2
3
|
addPageLifecycleCallback,
|
|
3
4
|
getPageLifecycleEventEmitter,
|
|
@@ -12,6 +13,23 @@ import { Sound } from './sound.js';
|
|
|
12
13
|
import { SoundSprite } from './sound_sprite.js';
|
|
13
14
|
|
|
14
15
|
export class SoundManager {
|
|
16
|
+
game;
|
|
17
|
+
onChange;
|
|
18
|
+
context;
|
|
19
|
+
baseLatency;
|
|
20
|
+
noAudio;
|
|
21
|
+
type;
|
|
22
|
+
connectToMaster;
|
|
23
|
+
isLocked;
|
|
24
|
+
_codeMuted;
|
|
25
|
+
_muted;
|
|
26
|
+
_unlockSource;
|
|
27
|
+
_volume;
|
|
28
|
+
_sounds;
|
|
29
|
+
_watchList;
|
|
30
|
+
_watching;
|
|
31
|
+
_watchCallback;
|
|
32
|
+
_watchContext;
|
|
15
33
|
/**
|
|
16
34
|
* Creates a new SoundManager instance.
|
|
17
35
|
* @param {import('./game.js').Game} game - Reference to the Phaser Game instance.
|
|
@@ -507,4 +525,4 @@ export class SoundManager {
|
|
|
507
525
|
}
|
|
508
526
|
}
|
|
509
527
|
}
|
|
510
|
-
}
|
|
528
|
+
}
|
|
@@ -1,4 +1,11 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
1
2
|
export class SoundSprite {
|
|
3
|
+
game;
|
|
4
|
+
key;
|
|
5
|
+
config;
|
|
6
|
+
autoplayKey;
|
|
7
|
+
autoplay;
|
|
8
|
+
sounds;
|
|
2
9
|
/**
|
|
3
10
|
* TBD.
|
|
4
11
|
* @param {import('./game.js').Game} game - TBD.
|
|
@@ -57,4 +64,4 @@ export class SoundSprite {
|
|
|
57
64
|
get(marker) {
|
|
58
65
|
return this.sounds[marker];
|
|
59
66
|
}
|
|
60
|
-
}
|
|
67
|
+
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
1
2
|
import { setTouchAction, setUserSelect } from '../display/canvas/util.js';
|
|
2
3
|
import { DisplayObject } from '../display/display_object.js';
|
|
3
4
|
import { Matrix } from '../geom/matrix.js';
|
|
@@ -5,6 +6,10 @@ import { valueToColor } from '../util/math.js';
|
|
|
5
6
|
import { SCALE_LINEAR, SCALE_NEAREST } from './const.js';
|
|
6
7
|
|
|
7
8
|
export class Stage extends DisplayObject {
|
|
9
|
+
name;
|
|
10
|
+
worldTransform;
|
|
11
|
+
currentRenderOrderID;
|
|
12
|
+
_bgColor;
|
|
8
13
|
/**
|
|
9
14
|
* Creates a new Stage instance.
|
|
10
15
|
* @param {import('./game.js').Game} game - The game instance.
|
|
@@ -1,6 +1,34 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
1
2
|
import { Timer } from './timer.js';
|
|
2
3
|
|
|
3
4
|
export class Time {
|
|
5
|
+
game;
|
|
6
|
+
time;
|
|
7
|
+
prevTime;
|
|
8
|
+
now;
|
|
9
|
+
elapsed;
|
|
10
|
+
elapsedMS;
|
|
11
|
+
desiredFpsMult;
|
|
12
|
+
_desiredFps;
|
|
13
|
+
suggestedFps;
|
|
14
|
+
advancedTiming;
|
|
15
|
+
frames;
|
|
16
|
+
fps;
|
|
17
|
+
fpsMin;
|
|
18
|
+
fpsMax;
|
|
19
|
+
msMin;
|
|
20
|
+
msMax;
|
|
21
|
+
pauseDuration;
|
|
22
|
+
timeToCall;
|
|
23
|
+
timeExpected;
|
|
24
|
+
events;
|
|
25
|
+
_frameCount;
|
|
26
|
+
_elapsedAccumulator;
|
|
27
|
+
_started;
|
|
28
|
+
_timeLastSecond;
|
|
29
|
+
_pauseStarted;
|
|
30
|
+
_justResumed;
|
|
31
|
+
_timers;
|
|
4
32
|
/**
|
|
5
33
|
* Creates a new Time instance.
|
|
6
34
|
* @param {import('./game.js').Game} game - Reference to the Phaser Game instance.
|
|
@@ -269,4 +297,4 @@ export class Time {
|
|
|
269
297
|
this._desiredFps = value;
|
|
270
298
|
this.desiredFpsMult = 1 / value;
|
|
271
299
|
}
|
|
272
|
-
}
|
|
300
|
+
}
|
|
@@ -1,7 +1,28 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
1
2
|
import { Signal } from './signal.js';
|
|
2
3
|
import { TimerEvent } from './timer_event.js';
|
|
3
4
|
|
|
4
5
|
export class Timer {
|
|
6
|
+
game;
|
|
7
|
+
running;
|
|
8
|
+
autoDestroy;
|
|
9
|
+
expired;
|
|
10
|
+
elapsed;
|
|
11
|
+
events;
|
|
12
|
+
onComplete;
|
|
13
|
+
nextTick;
|
|
14
|
+
timeCap;
|
|
15
|
+
paused;
|
|
16
|
+
_codePaused;
|
|
17
|
+
_started;
|
|
18
|
+
_pauseStarted;
|
|
19
|
+
_pauseTotal;
|
|
20
|
+
_now;
|
|
21
|
+
_len;
|
|
22
|
+
_marked;
|
|
23
|
+
_i;
|
|
24
|
+
_diff;
|
|
25
|
+
_newTick;
|
|
5
26
|
/**
|
|
6
27
|
* Creates a new Timer instance.
|
|
7
28
|
* @param {import('./game.js').Game} game - The game instance.
|
|
@@ -412,4 +433,4 @@ export class Timer {
|
|
|
412
433
|
}
|
|
413
434
|
return 0;
|
|
414
435
|
}
|
|
415
|
-
}
|
|
436
|
+
}
|
|
@@ -1,4 +1,14 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
1
2
|
export class TimerEvent {
|
|
3
|
+
timer;
|
|
4
|
+
delay;
|
|
5
|
+
tick;
|
|
6
|
+
repeatCount;
|
|
7
|
+
loop;
|
|
8
|
+
callback;
|
|
9
|
+
callbackContext;
|
|
10
|
+
args;
|
|
11
|
+
pendingDelete;
|
|
2
12
|
/**
|
|
3
13
|
* Creates a new TimerEvent instance.
|
|
4
14
|
* @param {import('./timer.js').Timer} timer - Reference to the parent Timer.
|
|
@@ -21,4 +31,4 @@ export class TimerEvent {
|
|
|
21
31
|
this.args = args;
|
|
22
32
|
this.pendingDelete = false;
|
|
23
33
|
}
|
|
24
|
-
}
|
|
34
|
+
}
|
|
@@ -1,9 +1,56 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
1
2
|
import * as MathUtils from '../util/math.js';
|
|
2
3
|
import { TWEEN_COMPLETE, TWEEN_LOOPED, TWEEN_PENDING, TWEEN_RUNNING } from './const.js';
|
|
3
4
|
import { Signal } from './signal.js';
|
|
4
5
|
import { TweenData } from './tween_data.js';
|
|
5
6
|
|
|
6
7
|
export class Tween {
|
|
8
|
+
/** @type {import('./game.js').Game} */
|
|
9
|
+
game;
|
|
10
|
+
/** @type {import('../display/display_object.js').DisplayObject} */
|
|
11
|
+
target;
|
|
12
|
+
/** @type {import('./tween_manager.js').TweenManager} */
|
|
13
|
+
manager;
|
|
14
|
+
/** @type {TweenData[]} */
|
|
15
|
+
timeline;
|
|
16
|
+
/** @type {boolean} */
|
|
17
|
+
reverse;
|
|
18
|
+
/** @type {number} */
|
|
19
|
+
timeScale;
|
|
20
|
+
/** @type {number} */
|
|
21
|
+
repeatCounter;
|
|
22
|
+
/** @type {boolean} */
|
|
23
|
+
pendingDelete;
|
|
24
|
+
/** @type {Signal} */
|
|
25
|
+
onStart;
|
|
26
|
+
/** @type {Signal} */
|
|
27
|
+
onLoop;
|
|
28
|
+
/** @type {Signal} */
|
|
29
|
+
onRepeat;
|
|
30
|
+
/** @type {Signal} */
|
|
31
|
+
onChildComplete;
|
|
32
|
+
/** @type {Signal} */
|
|
33
|
+
onComplete;
|
|
34
|
+
/** @type {boolean} */
|
|
35
|
+
isRunning;
|
|
36
|
+
/** @type {number} */
|
|
37
|
+
current;
|
|
38
|
+
/** @type {object} */
|
|
39
|
+
properties;
|
|
40
|
+
/** @type {Tween | null} */
|
|
41
|
+
chainedTween;
|
|
42
|
+
/** @type {boolean} */
|
|
43
|
+
isPaused;
|
|
44
|
+
/** @type {Function | null} */
|
|
45
|
+
_onUpdateCallback;
|
|
46
|
+
/** @type {object | null} */
|
|
47
|
+
_onUpdateCallbackContext;
|
|
48
|
+
/** @type {number} */
|
|
49
|
+
_pausedTime;
|
|
50
|
+
/** @type {boolean} */
|
|
51
|
+
_codePaused;
|
|
52
|
+
/** @type {boolean} */
|
|
53
|
+
_hasStarted;
|
|
7
54
|
/**
|
|
8
55
|
* Creates a new Tween instance.
|
|
9
56
|
* @param {import('../display/display_object.js').DisplayObject} target - The object to tween.
|
|
@@ -71,7 +118,7 @@ export class Tween {
|
|
|
71
118
|
if (this.isRunning) {
|
|
72
119
|
return this;
|
|
73
120
|
}
|
|
74
|
-
// @ts-
|
|
121
|
+
// @ts-expect-error
|
|
75
122
|
this.timeline.push(new TweenData(this).to(properties, duration, ease, delay, repeat, yoyo));
|
|
76
123
|
if (autoStart) {
|
|
77
124
|
this.start();
|
|
@@ -98,7 +145,7 @@ export class Tween {
|
|
|
98
145
|
this.game.logger.warn('Tween.from cannot be called after Tween.start');
|
|
99
146
|
return this;
|
|
100
147
|
}
|
|
101
|
-
// @ts-
|
|
148
|
+
// @ts-expect-error
|
|
102
149
|
this.timeline.push(new TweenData(this).from(properties, duration, ease, delay, repeat, yoyo));
|
|
103
150
|
if (autoStart) {
|
|
104
151
|
this.start();
|
|
@@ -1,7 +1,32 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
1
2
|
import * as MathUtils from '../util/math.js';
|
|
2
3
|
import { TWEEN_COMPLETE, TWEEN_LOOPED, TWEEN_PENDING, TWEEN_RUNNING } from './const.js';
|
|
3
4
|
|
|
4
5
|
export class TweenData {
|
|
6
|
+
parent;
|
|
7
|
+
game;
|
|
8
|
+
vStart;
|
|
9
|
+
vStartCache;
|
|
10
|
+
vEnd;
|
|
11
|
+
vEndCache;
|
|
12
|
+
duration;
|
|
13
|
+
percent;
|
|
14
|
+
value;
|
|
15
|
+
repeatCounter;
|
|
16
|
+
repeatDelay;
|
|
17
|
+
repeatTotal;
|
|
18
|
+
interpolate;
|
|
19
|
+
yoyo;
|
|
20
|
+
yoyoDelay;
|
|
21
|
+
inReverse;
|
|
22
|
+
delay;
|
|
23
|
+
dt;
|
|
24
|
+
startTime;
|
|
25
|
+
easingFunction;
|
|
26
|
+
interpolationFunction;
|
|
27
|
+
interpolationContext;
|
|
28
|
+
isRunning;
|
|
29
|
+
isFrom;
|
|
5
30
|
/**
|
|
6
31
|
* Creates a new TweenData instance.
|
|
7
32
|
* @param {import('./tween.js').Tween} parent - The parent Tween instance.
|
|
@@ -294,4 +319,4 @@ export class TweenData {
|
|
|
294
319
|
}
|
|
295
320
|
return TWEEN_LOOPED;
|
|
296
321
|
}
|
|
297
|
-
}
|
|
322
|
+
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
1
2
|
import { GROUP } from './const.js';
|
|
2
3
|
import { Tween } from './tween.js';
|
|
3
4
|
import {
|
|
@@ -35,6 +36,10 @@ import {
|
|
|
35
36
|
} from './tween_easing.js';
|
|
36
37
|
|
|
37
38
|
export class TweenManager {
|
|
39
|
+
game;
|
|
40
|
+
_tweens;
|
|
41
|
+
_add;
|
|
42
|
+
easeMap;
|
|
38
43
|
/**
|
|
39
44
|
* Creates a new TweenManager instance.
|
|
40
45
|
* @param {import('./game.js').Game} game - The game instance this manager belongs to.
|
|
@@ -252,4 +257,4 @@ export class TweenManager {
|
|
|
252
257
|
this._tweens[i].resume(true);
|
|
253
258
|
}
|
|
254
259
|
}
|
|
255
|
-
}
|
|
260
|
+
}
|
|
@@ -1,9 +1,23 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
1
2
|
import { BITMAP_TEXT, SCALE_LINEAR, SCALE_NEAREST } from '../core/const.js';
|
|
2
3
|
import { Point } from '../geom/point.js';
|
|
3
4
|
import { DisplayObject } from './display_object.js';
|
|
4
5
|
import { Image } from './image.js';
|
|
5
6
|
|
|
6
7
|
export class BitmapText extends DisplayObject {
|
|
8
|
+
type;
|
|
9
|
+
textWidth;
|
|
10
|
+
textHeight;
|
|
11
|
+
_prevAnchor;
|
|
12
|
+
_glyphs;
|
|
13
|
+
_maxWidth;
|
|
14
|
+
_text;
|
|
15
|
+
_data;
|
|
16
|
+
_font;
|
|
17
|
+
_fontSize;
|
|
18
|
+
_align;
|
|
19
|
+
_tint;
|
|
20
|
+
dirty;
|
|
7
21
|
/**
|
|
8
22
|
* Creates a new BitmapText instance.
|
|
9
23
|
* @param {import('../core/game.js').Game} game - The game instance this bitmap text belongs to.
|