File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -31,6 +31,11 @@ if (typeof EXPERIMENTAL)
3131 var ScaleManager = require ( './ScaleManager' ) ;
3232}
3333
34+ if ( typeof PLUGIN_FBINSTANT )
35+ {
36+ var FacebookInstantGamesPlugin = require ( '../../plugins/fbinstant/src/FacebookInstantGamesPlugin' ) ;
37+ }
38+
3439/**
3540 * @classdesc
3641 * The Phaser.Game instance is the main controller for the entire Phaser game. It is responsible
@@ -270,6 +275,21 @@ var Game = new Class({
270275 */
271276 this . plugins = new PluginManager ( this , this . config ) ;
272277
278+ if ( typeof PLUGIN_FBINSTANT )
279+ {
280+ /**
281+ * An instance of the Facebook Instant Games Plugin.
282+ *
283+ * This will only be available if the plugin has been built into Phaser,
284+ * or you're using the special Facebook Instant Games custom build.
285+ *
286+ * @name Phaser.Game#facebook
287+ * @type {Phaser.FacebookInstantGamesPlugin }
288+ * @since 3.13.0
289+ */
290+ this . facebook = new FacebookInstantGamesPlugin ( this ) ;
291+ }
292+
273293 /**
274294 * Is this Game pending destruction at the start of the next frame?
275295 *
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -57,6 +57,11 @@ if (typeof PLUGIN_CAMERA3D)
5757 Phaser . GameObjects . Creators . Sprite3D = require ( '../plugins/camera3d/src/sprite3d/Sprite3DCreator' ) ;
5858}
5959
60+ if ( typeof PLUGIN_FBINSTANT )
61+ {
62+ Phaser . FacebookInstantGamesPlugin = require ( '../plugins/fbinstant/src/FacebookInstantGamesPlugin' ) ;
63+ }
64+
6065// Merge in the consts
6166
6267Phaser = Extend ( false , Phaser , CONST ) ;
Original file line number Diff line number Diff line change @@ -55,7 +55,7 @@ var Systems = new Class({
5555 if ( typeof PLUGIN_FBINSTANT )
5656 {
5757 /**
58- * The FaceBook Instant Games Plugin.
58+ * The Facebook Instant Games Plugin.
5959 *
6060 * @name Phaser.Scenes.Systems#facebook
6161 * @type {any }
You can’t perform that action at this time.
0 commit comments