Commit graph

940 commits

Author SHA1 Message Date
Richard Davey
8e1809688c The WebGLRenderer will now validate that the mipmapFilter property in the Game Config is a valid mipmap before assigning it. 2023-08-01 13:44:58 +01:00
Richard Davey
bba300b866 Update Config.js 2023-07-21 16:18:15 +01:00
William Pederzoli
f89ea401d5 add proper key value to scale width and height 2023-05-11 20:36:27 +02:00
Richard Davey
43a20e571e Added glowFXQuality and glowFXDistance config options 2023-02-27 13:48:31 +00:00
Richard Davey
86d557b84b Game.isPaused is a new boolean that tracks if the Game loop is paused, or not (and can also be toggled directly). Fix #6373 2023-01-29 22:05:06 +00:00
Richard Davey
5619f4ddde Update PhysicsConfig.js 2023-01-27 17:46:22 +00:00
Richard Davey
49efda3d9b Default mipmapFilter is now an empty string. 2023-01-23 20:58:43 +00:00
Richard Davey
51d10677b1 The Game.registry, which is a DataManager instance that can be used as a global store of game wide data will now use its own Event Emitter, instead of the Game's Event Emitter. This means it's perfectly safe for you to now use the Registry to emit and listen for your own custom events without conflicting with events the Phaser Game instance emits. 2023-01-06 17:19:45 +00:00
Richard Davey
468bf7821d Updated copyright year 2023-01-02 17:36:27 +00:00
Richard Davey
4346113fee
Merge pull request #6238 from ubershmekel/master
Introduce `SceneType` for ease and correctness
2022-11-29 14:33:39 +00:00
Richard Davey
fa6963319a The Game.headlessStep method will now reset SceneManager.isProcessing before PRE_RENDER. This fixes issues in HEADLESS mode where the Scene Manager wouldn't process additionally added Scenes created after the Game had started. Fix #5872 #5974 2022-11-23 16:14:15 +00:00
Richard Davey
e608c2caf1 The CONTEXT_RESTORED Game Event has been removed and the WebGL Renderer no longer listens for the contextrestored DOM event, or has a contextRestoredHandler method. This never actually worked properly, in any version of Phaser 3 - although the WebGLRenderer would be restored, none of the shaders, pipelines or textures were correctly re-created. If a context is now lost, Phaser will display an error in the console and all rendering will halt. It will no longer try to re-create the context, leading to masses of WebGL errors in the console. Instead, it will die gracefully and require a page reload. 2022-11-17 18:04:51 +00:00
Richard Davey
1657f9e843 If in debug mode, add to window 2022-10-28 17:53:41 +01:00
Richard Davey
5dd3a40342 Fixed data types 2022-10-09 18:11:00 +01:00
Yuval Greenfield
7a4dd97793 Fix the typescript types in the js
This generates the desired phaser.d.ts
2022-10-04 10:48:21 -07:00
Richard Davey
fea000cf94 Added defaultPipeline and autoMobilePipeline configs 2022-10-04 18:04:01 +01:00
Richard Davey
083100163b Updates stableSort and added autoMobilePipeline 2022-10-04 17:08:34 +01:00
Richard Davey
023343c789 All events have a type of string. Fix #6136 2022-09-21 22:01:03 +01:00
Richard Davey
71703ff19c GameConfig.stableSort is a new optional property that will control if the internal depth sorting routine uses our own StableSort function, or the built-in browser Array.sort one. Only modern browsers have a _stable_ Array.sort implementation, which Phaser requires. Older ones need to use our function instead. Set to 1 to use the legacy version, 0 to use the ES2019 version or -1 to have Phaser try and detect which is best for the browser
Ref #6217
2022-09-21 17:52:57 +01:00
Richard Davey
7c9d6a180b Testing native stable sort 2022-09-21 16:34:08 +01:00
Richard Davey
783254f47a
Merge pull request #6213 from vzhou842/delta-smoothing-max-fix
Fix delta history array length
2022-09-07 18:26:20 +01:00
Richard Davey
2482eab664 Added Game.pause and Game.resume methods 2022-09-07 16:11:13 +01:00
Victor Zhou
213dc394bc Fix delta history array length 2022-09-06 14:36:04 -07:00
Richard Davey
42b1afb784 Fixed fps rate limit 2022-08-29 16:58:54 +01:00
Richard Davey
9017d29d52 Update FPSConfig.js 2022-08-29 16:31:58 +01:00
Richard Davey
f776037f8e Lots of jsdoc updates. Fixed time reset. Split limit fps up. 2022-08-29 16:29:37 +01:00
Richard Davey
7fdaa08343 Testing new fps limit system 2022-08-26 18:54:55 +01:00
Richard Davey
593aaced12 The TimeStep no longer calculates or passes the interpolation value to Game.step as it was removed several versions ago, so is redundant. 2022-08-26 17:56:54 +01:00
Richard Davey
b1f03649bb LoaderPlugin.localSchemes is a new array of scheme strings that the Loader considers as being local files. This is populated by the new Phaser.Core.Config#loaderLocalScheme game / scene config property. It defaults to [ 'file://', 'capacitor://' ] but additional schemes can be defined or pushed onto this array. Based on #6010 2022-05-09 18:34:56 +01:00
Richard Davey
21bdac8a29
Merge pull request #6010 from Azim-Palmer/bugfix/cordova-webaudio-fix
Fix WebAudio for Crodova based apps
2022-05-09 16:56:37 +01:00
Richard Davey
201bfabf00 Setting scale.mode in the Game Config would be ignored. It now accepts either this, or scaleMode directly. Fix #5970 2022-05-06 18:21:28 +01:00
Krzysztof Głogocki
726c874c10 Merge remote-tracking branch 'origin/master' into bugfix/cordova-webaudio-fix 2022-04-07 14:08:05 +02:00
Richard Davey
59fbcc5ca3 Updated copyright year 2022-02-28 14:29:51 +00:00
Krzysztof Głogocki
897d2444f5 Fixing WebAudio for Cordova by introducing localScheme configuration 2022-02-15 12:07:48 +01:00
Richard Davey
063e8c78ef Including a render object within the Game Config will no longer erase any top-level config render settings. The render object will now take priority over the game config, but both will be used. Close #5935 2021-12-21 17:16:22 +00:00
Andy Mikulski
607bbe4ccd
TimeStep: Continue to use setTimeout after waking 2021-12-19 11:11:48 -07:00
Richard Davey
461e1ff4d0 Update PipelineConfig.js 2021-10-21 18:38:05 +01:00
Richard Davey
c8aeb4724a Added scale configs to game config #5840 2021-09-22 12:12:35 +01:00
Richard Davey
1e5542df92
Merge pull request #5740 from hanzooo/loader-type
feat: Add support for load image by HTMLImageElement
2021-09-21 11:52:28 +01:00
samme
ec8a629d1c Fix WEBGL-only selection and throw for unknown renderer type
Fixes #5583
2021-07-30 11:41:28 -07:00
Jm
28f58f4e5e
Merge branch 'photonstorm:master' into loader-type 2021-06-23 13:09:15 +08:00
Richard Davey
7d70bfbd57 Removed Config.domBehindCanvas property as it's never used internally. Fix #5749 2021-06-18 18:03:07 +01:00
Jm
c1e73c3c2f feat: add image load type 2021-06-10 13:24:29 +00:00
Richard Davey
72959cf953 Core.Config.domPointerEvents is a new config property set via dom: { pointerEvents } within the Game Config that allows you to set the pointerEvents css attribute on the DOM Element container. 2021-03-30 10:23:45 +01:00
Richard Davey
b7e678cf6c Update GameConfig.js 2021-03-24 16:30:33 +00:00
Richard Davey
20831604c7 Fixed missing backgroundColor property in GameConfig. 2021-03-24 15:42:55 +00:00
Richard Davey
8171c70bf5 Removed duplicate property 2021-03-08 15:06:05 +00:00
Richard Davey
c5cbb413d2 You can now set the boolean preserveDrawingBuffer in the Game Config (either directly, or in the Render Config). This is passed to the WebGL context during creation and controls if the buffers are automatically cleared each frame or not. The default is to clear them. Set to true to retain them. 2021-02-04 15:58:41 +00:00
Richard Davey
d1a08da63d Update RenderConfig.js 2021-02-04 15:28:35 +00:00
Richard Davey
a10919391a type fix 2021-02-01 15:17:59 +00:00