mirror of
https://github.com/photonstorm/phaser
synced 2024-12-23 11:33:28 +00:00
d804e056ed
This is one monster update.
19 lines
548 B
JavaScript
19 lines
548 B
JavaScript
var Quad = require('./Quad');
|
|
var GetAdvancedValue = require('../../utils/object/GetAdvancedValue');
|
|
var BuildGameObject = require('../BuildGameObject');
|
|
|
|
var QuadCreator = function (scene, config)
|
|
{
|
|
var x = GetAdvancedValue(config, 'x', 0);
|
|
var y = GetAdvancedValue(config, 'y', 0);
|
|
var key = GetAdvancedValue(config, 'key', null);
|
|
var frame = GetAdvancedValue(config, 'frame', null);
|
|
|
|
var quad = new Quad(scene, x, y, key, frame);
|
|
|
|
BuildGameObject(scene, quad, config);
|
|
|
|
return quad;
|
|
};
|
|
|
|
module.exports = QuadCreator;
|