main.js 596 B

1234567891011121314151617
  1. "use strict";
  2. //FYI: https://github.com/Tencent/puerts/blob/master/doc/unity/manual.md
  3. Object.defineProperty(exports, "__esModule", { value: true });
  4. exports.onDestroy = exports.onPublish = void 0;
  5. const GenCode_CSharp_1 = require("./GenCode_CSharp");
  6. function onPublish(handler) {
  7. if (!handler.genCode)
  8. return;
  9. handler.genCode = false; //prevent default output
  10. console.log('Handling gen code in plugin');
  11. (0, GenCode_CSharp_1.genCode)(handler); //do it myself
  12. }
  13. exports.onPublish = onPublish;
  14. function onDestroy() {
  15. //do cleanup here
  16. }
  17. exports.onDestroy = onDestroy;