|
@@ -14,6 +14,11 @@ module BABYLON {
|
|
get: function (this:Scene) {
|
|
get: function (this:Scene) {
|
|
if (!this._gamepadManager) {
|
|
if (!this._gamepadManager) {
|
|
this._gamepadManager = new GamepadManager(this);
|
|
this._gamepadManager = new GamepadManager(this);
|
|
|
|
+ let component = this._getComponent(SceneComponentConstants.NAME_GAMEPAD) as GamepadSystemSceneComponent;
|
|
|
|
+ if (!component) {
|
|
|
|
+ component = new GamepadSystemSceneComponent(this);
|
|
|
|
+ this._addComponent(component);
|
|
|
|
+ }
|
|
}
|
|
}
|
|
|
|
|
|
return this._gamepadManager;
|
|
return this._gamepadManager;
|