diff --git a/.gitignore b/.gitignore index 3afe179fc..c4d6855e1 100644 --- a/.gitignore +++ b/.gitignore @@ -14,7 +14,7 @@ node_modules/ /npm-debug.log build/ out/ -scripts/tsgen/test/bin/ -scripts/tsgen/test/output.txt +#scripts/tsgen/test/bin/ +#scripts/tsgen/test/output.txt plugins/spine/spine-runtimes/ \ No newline at end of file diff --git a/scripts/tsgen/test/bin/game.js b/scripts/tsgen/test/bin/game.js new file mode 100644 index 000000000..d390af097 --- /dev/null +++ b/scripts/tsgen/test/bin/game.js @@ -0,0 +1,39 @@ +var __extends = (this && this.__extends) || (function () { + var extendStatics = function (d, b) { + extendStatics = Object.setPrototypeOf || + ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || + function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + return extendStatics(d, b); + }; + return function (d, b) { + extendStatics(d, b); + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); + }; +})(); +var MyScene = /** @class */ (function (_super) { + __extends(MyScene, _super); + function MyScene() { + return _super !== null && _super.apply(this, arguments) || this; + } + MyScene.prototype.preload = function () { + this.load.atlas('cards', 'assets/atlas/cards.png', 'assets/atlas/cards.json'); + }; + MyScene.prototype.create = function () { + var sprite = this.add.sprite(400, 300, 'cards', 'clubs3'); + sprite.setInteractive(); + this.input.on('pointerdown', function () { + sprite.setFrame('hearts4'); + }); + }; + return MyScene; +}(Phaser.Scene)); +var config = { + type: Phaser.AUTO, + parent: 'phaser-example', + width: 800, + height: 600, + scene: MyScene +}; +var game = new Phaser.Game(config); +//# sourceMappingURL=game.js.map \ No newline at end of file diff --git a/scripts/tsgen/test/bin/game.js.map b/scripts/tsgen/test/bin/game.js.map new file mode 100644 index 000000000..5a1d5b9ec --- /dev/null +++ b/scripts/tsgen/test/bin/game.js.map @@ -0,0 +1 @@ +{"version":3,"file":"game.js","sourceRoot":"","sources":["../src/game.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA;IAAsB,2BAAY;IAAlC;;IAoBA,CAAC;IAlBU,yBAAO,GAAd;QAEI,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,OAAO,EAAE,wBAAwB,EAAE,yBAAyB,CAAC,CAAC;IAClF,CAAC;IAEM,wBAAM,GAAb;QAEI,IAAI,MAAM,GAAG,IAAI,CAAC,GAAG,CAAC,MAAM,CAAC,GAAG,EAAE,GAAG,EAAE,OAAO,EAAE,QAAQ,CAAC,CAAC;QAE1D,MAAM,CAAC,cAAc,EAAE,CAAC;QAExB,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC,aAAa,EAAE;YAEzB,MAAM,CAAC,QAAQ,CAAC,SAAS,CAAC,CAAC;QAE/B,CAAC,CAAC,CAAC;IACP,CAAC;IAEL,cAAC;AAAD,CAAC,AApBD,CAAsB,MAAM,CAAC,KAAK,GAoBjC;AAED,IAAI,MAAM,GAAG;IACT,IAAI,EAAE,MAAM,CAAC,IAAI;IACjB,MAAM,EAAE,gBAAgB;IACxB,KAAK,EAAE,GAAG;IACV,MAAM,EAAE,GAAG;IACX,KAAK,EAAE,OAAO;CACjB,CAAC;AAEF,IAAI,IAAI,GAAG,IAAI,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC"} \ No newline at end of file diff --git a/scripts/tsgen/test/output.txt b/scripts/tsgen/test/output.txt new file mode 100644 index 000000000..e69de29bb