-
Notifications
You must be signed in to change notification settings - Fork 38
/
phaser-custom-sprite.js
44 lines (33 loc) · 1 KB
/
phaser-custom-sprite.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
require('polyfills');
var CONST = require('const');
var Extend = require('utils/object/Extend');
var Phaser = {
Cameras: {
Scene2D: require('cameras/2d')
},
Events: require('events/index'),
Game: require('core/Game'),
GameObjects: {
DisplayList: require('gameobjects/DisplayList'),
UpdateList: require('gameobjects/UpdateList'),
Image: require('gameobjects/image/Image'),
Sprite: require('gameobjects/sprite/Sprite'),
Factories: {
Image: require('gameobjects/image/ImageFactory'),
Sprite: require('gameobjects/sprite/SpriteFactory')
},
Creators: {
Image: require('gameobjects/image/ImageCreator'),
Sprite: require('gameobjects/sprite/SpriteCreator')
}
},
Loader: require('loader'),
Math: {
Between: require('math/Between')
}
};
// Merge in the consts
Phaser = Extend(false, Phaser, CONST);
// Export it
module.exports = Phaser;
global.Phaser = Phaser;