Richard Davey
7aa46657c2
Tidying up jsdocs and changing float to number
2018-06-26 23:19:14 +01:00
Richard Davey
f1190529d2
ScenePlugin.start
and ScenePlugin.restart
will now always queue the op with the Scene Manager, regardless of the state of the Scene, in order to avoid issues where plugins carry on running for a frame before closing down. Fix #3776
2018-06-26 16:35:45 +01:00
Richard Davey
b95f980023
Added in data object passing to all relevant methods #3748
2018-06-26 16:08:14 +01:00
Richard Davey
1d4a15f297
Merge pull request #3748 from rook2pawn/wake-resume-data-from-run
...
[feat] scene.run can now pass data to .wake and .resume if it needs
2018-06-26 15:28:50 +01:00
rook2pawn
b040146b4a
simplified logic on queueOp starting an unready scene
2018-06-22 03:55:21 -07:00
rook2pawn
dd53268a23
removed superfluous queue stop
2018-06-22 03:37:14 -07:00
rook2pawn
c09b4baf16
[fix] sceneManager run will queueOp if scene not ready
...
fixed linting
2018-06-22 03:37:14 -07:00
rook2pawn
44a0813591
[feat] scene.run can now pass data to .wake and .resume if it needs to invoke those methods
...
update javadoc for scene and scene systems
2018-06-22 03:32:17 -07:00
Richard Davey
19eb363a84
Only set Scene status to running if still in creating
2018-06-13 17:27:30 +01:00
Richard Davey
579f5bf4a1
Added the new sceneUpdate reference property.
2018-06-12 16:21:37 +01:00
Richard Davey
eb8d3ccdf1
No longer injects update
into a Scene, and now calls step
from init onwards.
2018-06-12 16:21:17 +01:00
Richard Davey
bf46135d84
Allow for Scene level input settings
2018-06-08 15:16:09 +01:00
Richard Davey
43fd10bbc1
ScenePlugin.run
is a new method that will run the given Scene and not change the state of the current Scene at all. If the scene is asleep, it will be woken. If it's paused, it will be resumed. If not running at all, it will be started.
2018-06-08 15:07:00 +01:00
Richard Davey
6906e6bd15
Hundreds more jsdocs completed.
2018-06-04 15:19:25 +01:00
Richard Davey
0b1d32b571
New registerFileType argument, new Global Plugin mapping and createEntry method
...
* PluginManager.registerFileType has a new property `addToScene` which allows you to inject the new file type into the LoaderPlugin of the given Scene. You could use this to add the file type into the Scene in which it was loaded.
* PluginManager.install has a new property `mapping`. This allows you to give a Global Plugin a property key, so that it is automatically injected into any Scenes as a Scene level instance. This allows you to have a single global plugin running in the PluginManager, that is injected into every Scene automatically.
* PluginManager.createEntry is a new private method to create a plugin entry and return it. This avoids code duplication in several other methods, which now use this instead.
2018-05-18 18:43:27 +01:00
Michael B
e322ed7916
jsdoc fixes
2018-05-18 02:56:32 +02:00
Richard Davey
350cb037b7
All systems now register themselves with the new PluginCache
2018-05-15 12:51:50 +01:00
Richard Davey
4959ed70ef
Now gets the list from the PluginManager
2018-05-11 16:00:46 +01:00
Richard Davey
e431cc33f9
Moved plugins file to DefaultPlugins and changed the namespace
2018-05-11 14:06:13 +01:00
Richard Davey
f6d8606daa
Fixed type
2018-05-10 22:01:40 +01:00
Richard Davey
be330e609e
Moved PluginManager to new location
2018-05-10 17:14:33 +01:00
Richard Davey
b1d41e506f
Typo fix
2018-05-09 12:11:29 +01:00
Richard Davey
0415dfbb7e
lint fixes
2018-05-04 15:16:20 +01:00
Richard Davey
ebf77e2bbc
The Scene Settings payload property has changed from files
to pack
and now follows the Pack File format.
2018-05-04 14:33:28 +01:00
Richard Davey
a14ce15685
Fixed setActive and setVisible
2018-05-01 12:35:56 +01:00
Richard Davey
e1532b3154
The Scene Systems will emit a ready
event when it has fully finished starting up and all plugins are available. Fix #3636
2018-05-01 12:22:18 +01:00
Richard Davey
425acd3f63
Fixed moveAbove and moveBelow
2018-05-01 01:23:34 +01:00
Richard Davey
5d3c06d8b7
ScenePlugin.getIndex will return the index of the given Scene in the Scene List.
2018-05-01 01:23:19 +01:00
Richard Davey
a07cc81806
Fixed passing of data for freshly added Scenes
2018-04-25 17:14:10 +01:00
Daniel
2c584d3d0e
Fill all description tags in GetPhysicsPlugins.js
2018-04-22 16:50:09 +10:00
Richard Davey
b0544c73b8
jsdoc fixes
2018-04-18 13:29:22 +01:00
Richard Davey
55965c748f
jsdoc fixes
2018-04-18 12:13:49 +01:00
Richard Davey
529cdedc70
Re-enabled getScene. #3579
2018-04-17 15:07:54 +01:00
Richard Davey
1be486fab4
destroy
only called once, no matter how many times the Scene restarts. Fix #3581
2018-04-17 12:25:45 +01:00
Richard Davey
1507dcf448
eslint fix
2018-04-16 17:16:07 +01:00
Richard Davey
b28a7276f4
Fixed Game.destroy
2018-04-16 17:02:32 +01:00
Richard Davey
b392dee5a9
More jsdoc fixes
2018-04-16 15:11:51 +01:00
Richard Davey
bd023c20df
Clear listeners on shutdown, tighten up the flow and allow you to remove a scene after transition
2018-04-15 23:14:56 +01:00
Richard Davey
ce7d67297f
Moving from 3.4.1 to 3.5.0 so we can release new camera fx and scene transitions
2018-04-15 12:44:47 +01:00
Pavle Goloskokovic
d87daba379
Merge remote-tracking branch 'origin/master'
2018-04-14 18:56:45 +02:00
Pavle Goloskokovic
433247f515
Unlocking sound manager after preloading any scene when using HTML5 audio
2018-04-14 17:47:29 +02:00
Richard Davey
a56465fdad
jsdoc tweak
2018-04-14 12:35:28 +01:00
Richard Davey
2b4e5ecd23
Is scene is asleep, wake it rather than start it
2018-04-14 04:28:39 +01:00
Richard Davey
b519e24279
lint fix
2018-04-14 04:27:39 +01:00
Richard Davey
352ec91bb5
New methods to determine if a Scene is transitioning
2018-04-14 04:24:21 +01:00
Richard Davey
2a73964399
Added new transition properties
2018-04-14 04:24:05 +01:00
Richard Davey
370fbdd5f2
Added transition progress, sleep support and better checking
2018-04-14 04:23:57 +01:00
Richard Davey
2698fe1b58
Clear out the transition events
2018-04-14 04:23:24 +01:00
Richard Davey
616d17fa83
Sorted out the scene event order, targets and callbacks
2018-04-13 20:12:29 +01:00
Richard Davey
cfb1826da9
Added new test feature
2018-04-13 18:59:00 +01:00
Richard Davey
18a6cf8ad1
eslint fixes
2018-04-13 18:09:16 +01:00
Richard Davey
6b2307594a
Scene plugin flow overhaul
...
Every Plugin has been updated to correctly follow the same flow through the Scene lifecycle. Instead of listening for the Scene 'boot' event, which is only dispatched once (when the Scene is first created), they will now listen for the Scene 'start' event, which occurs every time the Scene is started. All plugins now consistently follow the same Shutdown and Destroy patterns too, meaning they tidy-up after themselves on a shutdown, not just a destroy. Overall, this change means that there should be less issues when returning to previously closed Scenes, as the plugins will restart themselves properly.
2018-04-13 17:12:17 +01:00
Richard Davey
623df29522
The Scene Manager would never reach an isBooted
state if you didn't add any Scenes into the Game Config. Fix #3553
2018-04-13 12:24:02 +01:00
Sebastian Warmbrunn
968c0a3aec
Add typedef for new scene config option mapAdd
...
Also add a description for mapAdd and map config options.
2018-04-09 21:32:19 +02:00
Sebastian Warmbrunn
593245742e
Add a config to merge keys into scene InjectionMap
...
This way the defaults of the scene injection map are kept and the user
is able to merge with those defaults.
2018-04-09 21:16:45 +02:00
Richard Davey
ca2097f4e2
Recoded how the boot data and processing works to allow for more flexibility when setting-up scenes. Updates #3470
2018-04-09 12:57:47 +01:00
Richard Davey
66a9bec9bb
Only set data if it's not undefined.
2018-04-09 12:57:03 +01:00
Richard Davey
bf368ab70b
ScenePlugin.restart allows you to restart the current Scene. It's the same result as calling ScenePlugin.start
without any arguments, but is more clear.
2018-04-09 12:56:28 +01:00
Richard Davey
a0dcfdd3fc
Merge pull request #3470 from pixelhijack/fix-issue-3363
...
[ISSUE #3363 ] Phaser Scene - passing data to scene init & create methods
2018-04-09 10:20:57 +01:00
Eirik S Korsnes
798356cb64
jsdoc: fix correct type reference on Scene#load
2018-04-04 20:19:21 +02:00
Richard Davey
c1e5aa72ef
Added jsdocs for TS defs export
2018-04-03 15:08:48 +01:00
Chris Andrew
f3675b6085
Added a missing full stop. 🚀
2018-04-02 18:43:41 +01:00
Chris Andrew
e047977f52
Documented the ScenePlugin class.
2018-04-02 18:29:23 +01:00
Chris Andrew
7eb0342663
Documented the SceneManager.
2018-04-02 18:01:17 +01:00
Richard Davey
d8e378b052
Updated comments
2018-03-30 17:01:29 +01:00
Richard Davey
89c963c19c
Ignore consts
2018-03-30 14:38:58 +01:00
pixelhijack
e728f3a1b9
[ISSUE #3363 ] Phaser Scene - passing data to scene init & create methods
2018-03-29 21:40:32 +02:00
Richard Davey
91008232ad
jsdoc fixes
2018-03-29 13:12:07 +01:00
Richard Davey
f1e646c9ee
jsdoc fixes
2018-03-28 15:39:57 +01:00
orblazer
ed1f2a7011
Fix wrong types
2018-03-22 13:51:30 +01:00
orblazer
dcd80375c0
Fix "object" types on Renderer and Scene
2018-03-21 14:41:17 +01:00
orblazer
7fba122321
Fix "any" types
2018-03-20 17:15:49 +01:00
orblazer
44103dc475
Fix remaining multiple types
2018-03-20 16:12:42 +01:00
orblazer
4cff464555
Fix nullable types
2018-03-20 15:36:03 +01:00
Richard Davey
4fe6a25117
Added jsdoc data types
2018-03-19 11:25:46 +00:00
orblazer
6a4dd8db8f
Update JSDoc on Renderer and Scene
2018-03-19 01:59:59 +01:00
Arkadiusz Buras
e981932db1
Remove scene key in SceneManager
2018-03-17 13:42:42 +01:00
Richard Davey
a524dc44b0
Expose constants. Fix #3387
2018-03-16 13:29:30 +00:00
Richard Davey
a6d742227c
Merge pull request #3394 from stuff/patch-2
...
pass data to the manager queue when starting a scene
2018-03-16 13:00:25 +00:00
Nicolas Challeil
53de26e572
pass data to the manager queue
2018-03-14 23:52:00 +01:00
samme
55ccf7f026
Remove unused callbacks in createSceneFromObject
...
Phaser never calls 'shutdown' or 'destroy' methods.
2018-03-14 13:28:04 -07:00
Richard Davey
7adcb66267
Merge branch 'master' of https://github.com/photonstorm/phaser
2018-03-09 15:42:27 +00:00
Richard Davey
db3112de31
The SceneManager.render will now render a Scene as long as it's in a LOADING state or higher. Before it would only render RUNNING scenes, but this precluded those that were loading assets.
2018-03-09 15:33:07 +00:00
migiyubi
decbe18705
Make scene restartable
2018-03-08 20:27:22 +09:00
Richard Davey
1e6bfe660f
Removed accidental overwrite of the object key #3185
2018-03-05 16:58:59 +00:00
Richard Davey
5168300463
The SceneManager now employs a new queue for all pending Scenes, creating them and booting them in strict sequence. This should prevent errors where Scenes were unable to reference other Scenes further down the boot list in their create functions. Fix #3314
2018-03-05 14:48:30 +00:00
Richard Davey
7c16368d3e
SceneManager uses new internal boot queue.
2018-03-05 14:11:42 +00:00
Richard Davey
ae1c91cf6a
eslint fixes
2018-03-05 01:40:11 +00:00
Richard Davey
95d85576c9
SceneManager.moveAbove and moveBelow added.
...
SceneManager.moveAbove will move a Scene to be directly above another Scene in the Scenes list. This is also exposed in the ScenePlugin.
SceneManager.moveBelow will move a Scene to be directly below another Scene in the Scenes list. This is also exposed in the ScenePlugin.
2018-03-02 18:25:44 +00:00
Richard Davey
9a6e6265e8
The SceneManager no longer renders a Scene unless it is visible AND either running or paused. This now skips Scenes that are in an init
state.
2018-03-02 17:48:45 +00:00
Richard Davey
a993251dea
ScenePlugin.swapPosition now allows you to use it to swap the positions of any two Scenes. Before the change it only allowed you to swap the position of the calling Scene and another one, but a new optional keyB
argument opens this up.
2018-03-02 17:47:01 +00:00
Richard Davey
98930de3a8
The SceneManager has a new method: remove
which allows you to remove and destroy a Scene, freeing up the Scene key for use by future scenes and potentially clearing the Scene from active memory for gc.
2018-03-02 03:50:55 +00:00
Richard Davey
63e5681073
Merge pull request #3287 from gaudeon/master
...
BugFix for ScenePlugin.launch, data now passed to queued scenes
2018-02-28 20:47:51 +00:00
srobertson421
66e881c7eb
swapped queue loop to use _queue prop rather than queueLength var
2018-02-28 12:25:43 -08:00
Richard Davey
e6059f65cd
SceneManager invokes resize method on all Systems.
2018-02-28 17:18:55 +00:00
Richard Davey
e44ce76214
Scene.Systems resize handler added.
2018-02-28 17:18:40 +00:00
Travis Chase
ca0366bfc8
launching a scene that is not running will now pass data through when start op is called for this scene in the scene process queue
2018-02-26 22:04:58 -07:00
AleBles
697d096221
Added data to ScenePlugin, fixes #3180
2018-02-22 12:34:19 +01:00
Rafael Barbosa Lopes
7d64c12e66
Removed unused queue property in ScenePlugin
.
2018-02-19 10:00:52 -03:00
Richard Davey
d23688c3e4
Added eslint fixes and overrides
2018-02-16 18:44:07 +00:00