62164bffde26a064612116b1cf2a16a8b180acda.js 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510
  1. System.register(["__unresolved_0", "cc", "__unresolved_1", "__unresolved_2", "__unresolved_3", "__unresolved_4", "__unresolved_5", "__unresolved_6", "__unresolved_7"], function (_export, _context) {
  2. "use strict";
  3. var _reporterNs, _cclegacy, __checkObsolete__, __checkObsoleteInNamespace__, _decorator, BoxCollider, Component, instantiate, Node, NodePool, Prefab, Quat, RigidBody, table_idiom, ch_util, CreateIdiom, Cube_Infor, Cube_State, UI_Idioms, gui, GameCtl, _dec, _dec2, _dec3, _dec4, _class, _class2, _descriptor, _descriptor2, _descriptor3, _class3, _crd, ccclass, property, Container_Manager;
  4. function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
  5. function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
  6. function _initializerDefineProperty(target, property, descriptor, context) { if (!descriptor) return; Object.defineProperty(target, property, { enumerable: descriptor.enumerable, configurable: descriptor.configurable, writable: descriptor.writable, value: descriptor.initializer ? descriptor.initializer.call(context) : void 0 }); }
  7. function _applyDecoratedDescriptor(target, property, decorators, descriptor, context) { var desc = {}; Object.keys(descriptor).forEach(function (key) { desc[key] = descriptor[key]; }); desc.enumerable = !!desc.enumerable; desc.configurable = !!desc.configurable; if ('value' in desc || desc.initializer) { desc.writable = true; } desc = decorators.slice().reverse().reduce(function (desc, decorator) { return decorator(target, property, desc) || desc; }, desc); if (context && desc.initializer !== void 0) { desc.value = desc.initializer ? desc.initializer.call(context) : void 0; desc.initializer = undefined; } if (desc.initializer === void 0) { Object.defineProperty(target, property, desc); desc = null; } return desc; }
  8. function _initializerWarningHelper(descriptor, context) { throw new Error('Decorating class property failed. Please ensure that ' + 'transform-class-properties is enabled and runs after the decorators transform.'); }
  9. function _reportPossibleCrUseOftable_idiom(extras) {
  10. _reporterNs.report("table_idiom", "../module_extra/table_ts/table_idiom", _context.meta, extras);
  11. }
  12. function _reportPossibleCrUseOfch_util(extras) {
  13. _reporterNs.report("ch_util", "../ch/ch_util", _context.meta, extras);
  14. }
  15. function _reportPossibleCrUseOfCreateIdiom(extras) {
  16. _reporterNs.report("CreateIdiom", "./CreateIdiom", _context.meta, extras);
  17. }
  18. function _reportPossibleCrUseOfCube_Infor(extras) {
  19. _reporterNs.report("Cube_Infor", "./Cube_Infor", _context.meta, extras);
  20. }
  21. function _reportPossibleCrUseOfCube_State(extras) {
  22. _reporterNs.report("Cube_State", "./Cube_Infor", _context.meta, extras);
  23. }
  24. function _reportPossibleCrUseOfUI_Idioms(extras) {
  25. _reporterNs.report("UI_Idioms", "../module_game/ui/UI_Idioms/UI_Idioms", _context.meta, extras);
  26. }
  27. function _reportPossibleCrUseOfgui(extras) {
  28. _reporterNs.report("gui", "../core/ui/ui", _context.meta, extras);
  29. }
  30. function _reportPossibleCrUseOfGameCtl(extras) {
  31. _reporterNs.report("GameCtl", "./GameCtl", _context.meta, extras);
  32. }
  33. return {
  34. setters: [function (_unresolved_) {
  35. _reporterNs = _unresolved_;
  36. }, function (_cc) {
  37. _cclegacy = _cc.cclegacy;
  38. __checkObsolete__ = _cc.__checkObsolete__;
  39. __checkObsoleteInNamespace__ = _cc.__checkObsoleteInNamespace__;
  40. _decorator = _cc._decorator;
  41. BoxCollider = _cc.BoxCollider;
  42. Component = _cc.Component;
  43. instantiate = _cc.instantiate;
  44. Node = _cc.Node;
  45. NodePool = _cc.NodePool;
  46. Prefab = _cc.Prefab;
  47. Quat = _cc.Quat;
  48. RigidBody = _cc.RigidBody;
  49. }, function (_unresolved_2) {
  50. table_idiom = _unresolved_2.table_idiom;
  51. }, function (_unresolved_3) {
  52. ch_util = _unresolved_3.default;
  53. }, function (_unresolved_4) {
  54. CreateIdiom = _unresolved_4.CreateIdiom;
  55. }, function (_unresolved_5) {
  56. Cube_Infor = _unresolved_5.Cube_Infor;
  57. Cube_State = _unresolved_5.Cube_State;
  58. }, function (_unresolved_6) {
  59. UI_Idioms = _unresolved_6.UI_Idioms;
  60. }, function (_unresolved_7) {
  61. gui = _unresolved_7.gui;
  62. }, function (_unresolved_8) {
  63. GameCtl = _unresolved_8.GameCtl;
  64. }],
  65. execute: function () {
  66. _crd = true;
  67. _cclegacy._RF.push({}, "e84de8IXbZDjZbYlbQpevuI", "Container_Manager", undefined);
  68. __checkObsolete__(['_decorator', 'BoxCollider', 'Component', 'instantiate', 'Node', 'NodePool', 'Prefab', 'Quat', 'random', 'RigidBody']);
  69. ({
  70. ccclass,
  71. property
  72. } = _decorator);
  73. _export("Container_Manager", Container_Manager = (_dec = ccclass('Container_Manager'), _dec2 = property(Prefab), _dec3 = property(_crd && CreateIdiom === void 0 ? (_reportPossibleCrUseOfCreateIdiom({
  74. error: Error()
  75. }), CreateIdiom) : CreateIdiom), _dec4 = property([Node]), _dec(_class = (_class2 = (_class3 = class Container_Manager extends Component {
  76. constructor() {
  77. super(...arguments);
  78. _initializerDefineProperty(this, "prefab", _descriptor, this);
  79. this.config = null;
  80. //成语库
  81. this.idioms = [];
  82. //生成的成语
  83. this.index = [];
  84. //生成的成语角标,避免生成重复成语
  85. _initializerDefineProperty(this, "create_node", _descriptor2, this);
  86. _initializerDefineProperty(this, "nodes", _descriptor3, this);
  87. //位置节点 用于成语放入
  88. this.node_isIdiom = new Array(10).fill(false);
  89. this.idiom_combine = new Map();
  90. this.Cube_Pool = new NodePool();
  91. this.nodeReferences = [];
  92. }
  93. // 额外维护的节点引用数组
  94. instantiateCube() {
  95. for (var i = 0; i < 10; i++) {
  96. var newCube = instantiate(this.prefab);
  97. newCube.active = true; // 初始时设置为非激活状态
  98. // 按顺序为节点赋值文字内容
  99. var idiomIndex = Math.floor(i / 2);
  100. var isPiece1 = i % 2 === 0;
  101. newCube.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  102. error: Error()
  103. }), Cube_Infor) : Cube_Infor).Text = isPiece1 ? this.idioms[idiomIndex].piece_1_word : this.idioms[idiomIndex].piece_2_word;
  104. console.log("生成第" + i + "个节点:" + newCube.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  105. error: Error()
  106. }), Cube_Infor) : Cube_Infor).Text);
  107. this.Cube_Pool.put(newCube);
  108. }
  109. }
  110. getCube() {
  111. var cube = this.Cube_Pool.get();
  112. if (cube) cube.active = true;
  113. return cube;
  114. } // 将方块回收到对象池
  115. recycleCube(cube) {
  116. cube.active = false; // 将方块设置为非激活状态
  117. this.Cube_Pool.put(cube);
  118. } //合成规则导入
  119. start() {
  120. if (!find('Container').getComponent(Container_Manager)) {
  121. find('Container').getComponent(Container_Manager) = this;
  122. }
  123. this.config = (_crd && table_idiom === void 0 ? (_reportPossibleCrUseOftable_idiom({
  124. error: Error()
  125. }), table_idiom) : table_idiom).getList();
  126. if (this.config.length === 95) {
  127. console.log("合成规则导入成功");
  128. }
  129. this.level_idioms();
  130. }
  131. update(deltaTime) {}
  132. checkIdiom_Combine(matchedcube2, outMatchedCubes) {
  133. var _this = this;
  134. if (this.idiom_combine.size < 2) {
  135. return false; // 至少需要两个方块
  136. }
  137. var _loop = function _loop(cube) {
  138. // 遍历 idioms 列表,检查是否匹配成语
  139. var matchedIdiom = _this.idioms.find(idiom => idiom.piece_1_word === cube.Text && idiom.piece_2_word === matchedcube2.Text);
  140. if (matchedIdiom) {
  141. // 匹配成功
  142. outMatchedCubes.push(cube, matchedcube2);
  143. _this.nodeReferences = _this.nodeReferences.filter(el => el !== matchedcube2.node && el !== cube.node);
  144. console.log("成功拼成成语: " + matchedIdiom.piece_1_word + matchedIdiom.piece_2_word);
  145. return {
  146. v: true
  147. };
  148. } // 再检查逆序组合是否匹配
  149. var reverseMatchedIdiom = _this.idioms.find(idiom => idiom.piece_1_word === matchedcube2.Text && idiom.piece_2_word === cube.Text);
  150. if (reverseMatchedIdiom) {
  151. // 匹配成功
  152. outMatchedCubes.push(matchedcube2, cube);
  153. _this.nodeReferences = _this.nodeReferences.filter(el => el !== matchedcube2.node && el !== cube.node);
  154. console.log("成功拼成成语: " + reverseMatchedIdiom.piece_1_word + reverseMatchedIdiom.piece_2_word);
  155. return {
  156. v: true
  157. };
  158. }
  159. },
  160. _ret;
  161. for (var cube of this.idiom_combine.keys()) {
  162. _ret = _loop(cube);
  163. if (_ret) return _ret.v;
  164. }
  165. return false; // 没有匹配到成语
  166. }
  167. level_idioms() {
  168. var _this2 = this;
  169. return _asyncToGenerator(function* () {
  170. // 筛选满足条件的元素
  171. var validConfig = _this2.config.filter(item => (item.idiom_type === "一" || item.idiom_type === "二") && ( // 可以加多个条件
  172. item.piece_1_word === "一" || item.piece_2_word === "二") // 可以加多个筛选条件
  173. );
  174. if (validConfig.length < 5) {
  175. console.error("满足条件的成语数量不足 5 个");
  176. } else {
  177. // 从筛选结果中随机选择
  178. for (var i = 0; i < 5;) {
  179. var rand = (_crd && ch_util === void 0 ? (_reportPossibleCrUseOfch_util({
  180. error: Error()
  181. }), ch_util) : ch_util).getRandomInt(0, validConfig.length - 1); // 使用 indexOf 检查是否已存在
  182. if (_this2.index.indexOf(rand) === -1) {
  183. _this2.index[i] = rand;
  184. _this2.idioms[i] = validConfig[rand];
  185. i++;
  186. }
  187. }
  188. }
  189. yield (_crd && gui === void 0 ? (_reportPossibleCrUseOfgui({
  190. error: Error()
  191. }), gui) : gui).show(_crd && UI_Idioms === void 0 ? (_reportPossibleCrUseOfUI_Idioms({
  192. error: Error()
  193. }), UI_Idioms) : UI_Idioms);
  194. yield _this2.instantiateCube();
  195. yield _this2.create_node.nodeMoving();
  196. })();
  197. } //消除一组
  198. eliminate() {
  199. var _this3 = this;
  200. //先判断槽内是否有方块,如果有,匹配槽内最前面一个与散落方块中的
  201. var cube;
  202. for (var [key, value] of this.idiom_combine) {
  203. if (value === 0) {
  204. cube = key;
  205. break;
  206. }
  207. } //槽中有方块
  208. if (cube) {
  209. var originalReferences = [...this.nodeReferences];
  210. var _loop2 = function _loop2(element) {
  211. if (_this3.idioms.find(c => c.idiom == element.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  212. error: Error()
  213. }), Cube_Infor) : Cube_Infor).Text + cube.Text) && element.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  214. error: Error()
  215. }), Cube_Infor) : Cube_Infor) !== cube) {
  216. console.log(element.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  217. error: Error()
  218. }), Cube_Infor) : Cube_Infor).Text);
  219. element.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  220. error: Error()
  221. }), Cube_Infor) : Cube_Infor).state = (_crd && Cube_State === void 0 ? (_reportPossibleCrUseOfCube_State({
  222. error: Error()
  223. }), Cube_State) : Cube_State).wait;
  224. element.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  225. error: Error()
  226. }), Cube_Infor) : Cube_Infor).rigidbody.type = RigidBody.Type.STATIC;
  227. element.getComponent(BoxCollider).enabled = false;
  228. var targetRotation = new Quat();
  229. Quat.fromEuler(targetRotation, -90, 0, 0);
  230. element.rotation = targetRotation; // 使用filter过滤掉当前元素
  231. (_crd && GameCtl === void 0 ? (_reportPossibleCrUseOfGameCtl({
  232. error: Error()
  233. }), GameCtl) : GameCtl).instance.combine_ani(element.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  234. error: Error()
  235. }), Cube_Infor) : Cube_Infor), cube);
  236. _this3.nodeReferences = _this3.nodeReferences.filter(el => el !== element && el !== cube.node);
  237. return 0; // break
  238. } else if (_this3.idioms.find(c => c.idiom == cube.Text + element.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  239. error: Error()
  240. }), Cube_Infor) : Cube_Infor).Text) && element.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  241. error: Error()
  242. }), Cube_Infor) : Cube_Infor) !== cube) {
  243. console.log(element.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  244. error: Error()
  245. }), Cube_Infor) : Cube_Infor).Text);
  246. element.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  247. error: Error()
  248. }), Cube_Infor) : Cube_Infor).state = (_crd && Cube_State === void 0 ? (_reportPossibleCrUseOfCube_State({
  249. error: Error()
  250. }), Cube_State) : Cube_State).wait;
  251. element.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  252. error: Error()
  253. }), Cube_Infor) : Cube_Infor).rigidbody.type = RigidBody.Type.STATIC;
  254. element.getComponent(BoxCollider).enabled = false;
  255. var _targetRotation = new Quat();
  256. Quat.fromEuler(_targetRotation, -90, 0, 0);
  257. element.rotation = _targetRotation;
  258. (_crd && GameCtl === void 0 ? (_reportPossibleCrUseOfGameCtl({
  259. error: Error()
  260. }), GameCtl) : GameCtl).instance.combine_ani(cube, element.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  261. error: Error()
  262. }), Cube_Infor) : Cube_Infor));
  263. _this3.nodeReferences = _this3.nodeReferences.filter(el => el !== element && el !== cube.node);
  264. return 0; // break
  265. }
  266. },
  267. _ret2;
  268. for (var element of originalReferences) {
  269. _ret2 = _loop2(element);
  270. if (_ret2 === 0) break;
  271. }
  272. } //槽中没有方块
  273. else {
  274. var flag = false;
  275. var originalReferences1 = [...this.nodeReferences];
  276. var originalReferences2 = [...this.nodeReferences];
  277. var _loop3 = function _loop3(element1) {
  278. var _loop4 = function _loop4(element2) {
  279. if (_this3.idioms.find(c => c.idiom == element1.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  280. error: Error()
  281. }), Cube_Infor) : Cube_Infor).Text + element2.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  282. error: Error()
  283. }), Cube_Infor) : Cube_Infor).Text)) {
  284. element1.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  285. error: Error()
  286. }), Cube_Infor) : Cube_Infor).state = (_crd && Cube_State === void 0 ? (_reportPossibleCrUseOfCube_State({
  287. error: Error()
  288. }), Cube_State) : Cube_State).wait;
  289. element1.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  290. error: Error()
  291. }), Cube_Infor) : Cube_Infor).rigidbody.type = RigidBody.Type.STATIC;
  292. var targetRotation = new Quat();
  293. Quat.fromEuler(targetRotation, -90, 0, 0);
  294. element1.rotation = targetRotation;
  295. element2.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  296. error: Error()
  297. }), Cube_Infor) : Cube_Infor).state = (_crd && Cube_State === void 0 ? (_reportPossibleCrUseOfCube_State({
  298. error: Error()
  299. }), Cube_State) : Cube_State).wait;
  300. element2.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  301. error: Error()
  302. }), Cube_Infor) : Cube_Infor).rigidbody.type = RigidBody.Type.STATIC;
  303. element2.getComponent(BoxCollider).enabled = false;
  304. element2.rotation = targetRotation; // 使用filter过滤掉当前元素
  305. (_crd && GameCtl === void 0 ? (_reportPossibleCrUseOfGameCtl({
  306. error: Error()
  307. }), GameCtl) : GameCtl).instance.combine_ani(element1.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  308. error: Error()
  309. }), Cube_Infor) : Cube_Infor), element2.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  310. error: Error()
  311. }), Cube_Infor) : Cube_Infor));
  312. _this3.nodeReferences = _this3.nodeReferences.filter(el => el !== element1 && el !== element2);
  313. flag = true;
  314. return 0; // break
  315. }
  316. if (_this3.idioms.find(c => c.idiom == element2.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  317. error: Error()
  318. }), Cube_Infor) : Cube_Infor).Text + element1.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  319. error: Error()
  320. }), Cube_Infor) : Cube_Infor).Text)) {
  321. element1.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  322. error: Error()
  323. }), Cube_Infor) : Cube_Infor).state = (_crd && Cube_State === void 0 ? (_reportPossibleCrUseOfCube_State({
  324. error: Error()
  325. }), Cube_State) : Cube_State).wait;
  326. element1.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  327. error: Error()
  328. }), Cube_Infor) : Cube_Infor).rigidbody.type = RigidBody.Type.STATIC;
  329. var _targetRotation2 = new Quat();
  330. Quat.fromEuler(_targetRotation2, -90, 0, 0);
  331. element1.rotation = _targetRotation2;
  332. element2.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  333. error: Error()
  334. }), Cube_Infor) : Cube_Infor).state = (_crd && Cube_State === void 0 ? (_reportPossibleCrUseOfCube_State({
  335. error: Error()
  336. }), Cube_State) : Cube_State).wait;
  337. element2.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  338. error: Error()
  339. }), Cube_Infor) : Cube_Infor).rigidbody.type = RigidBody.Type.STATIC;
  340. element2.getComponent(BoxCollider).enabled = false;
  341. element2.rotation = _targetRotation2; // 使用filter过滤掉当前元素
  342. (_crd && GameCtl === void 0 ? (_reportPossibleCrUseOfGameCtl({
  343. error: Error()
  344. }), GameCtl) : GameCtl).instance.combine_ani(element2.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  345. error: Error()
  346. }), Cube_Infor) : Cube_Infor), element1.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  347. error: Error()
  348. }), Cube_Infor) : Cube_Infor));
  349. _this3.nodeReferences = _this3.nodeReferences.filter(el => el !== element1 && el !== element2);
  350. flag = true;
  351. return 0; // break
  352. }
  353. },
  354. _ret3;
  355. for (var element2 of originalReferences2) {
  356. _ret3 = _loop4(element2);
  357. if (_ret3 === 0) break;
  358. }
  359. if (flag === true) {
  360. return 1; // break
  361. }
  362. };
  363. for (var element1 of originalReferences1) {
  364. if (_loop3(element1)) break;
  365. }
  366. }
  367. }
  368. shuffle() {
  369. var _this4 = this;
  370. return _asyncToGenerator(function* () {
  371. // 回收所有非槽内的活跃节点
  372. _this4.nodeReferences.forEach(node => {
  373. var cubeInfo = node.getComponent(_crd && Cube_Infor === void 0 ? (_reportPossibleCrUseOfCube_Infor({
  374. error: Error()
  375. }), Cube_Infor) : Cube_Infor);
  376. if (cubeInfo.state === (_crd && Cube_State === void 0 ? (_reportPossibleCrUseOfCube_State({
  377. error: Error()
  378. }), Cube_State) : Cube_State).live) {
  379. _this4.recycleCube(node); // 回收到池中
  380. }
  381. }); // 等待节点移动完成后执行后续逻辑
  382. yield _this4.create_node.nodeMoving();
  383. })();
  384. } //清空槽子
  385. Empty() {
  386. for (var idiom of this.idiom_combine.keys()) {
  387. idiom.rigidbody.type = RigidBody.Type.DYNAMIC;
  388. idiom.state = (_crd && Cube_State === void 0 ? (_reportPossibleCrUseOfCube_State({
  389. error: Error()
  390. }), Cube_State) : Cube_State).live;
  391. idiom.node.position = this.create_node.node.position;
  392. }
  393. this.idiom_combine.clear();
  394. this.node_isIdiom.fill(false);
  395. (_crd && gui === void 0 ? (_reportPossibleCrUseOfgui({
  396. error: Error()
  397. }), gui) : gui).get(_crd && UI_Idioms === void 0 ? (_reportPossibleCrUseOfUI_Idioms({
  398. error: Error()
  399. }), UI_Idioms) : UI_Idioms).all_light_Hide();
  400. }
  401. }, _class3.instance = null, _class3), (_descriptor = _applyDecoratedDescriptor(_class2.prototype, "prefab", [_dec2], {
  402. configurable: true,
  403. enumerable: true,
  404. writable: true,
  405. initializer: function initializer() {
  406. return null;
  407. }
  408. }), _descriptor2 = _applyDecoratedDescriptor(_class2.prototype, "create_node", [_dec3], {
  409. configurable: true,
  410. enumerable: true,
  411. writable: true,
  412. initializer: function initializer() {
  413. return null;
  414. }
  415. }), _descriptor3 = _applyDecoratedDescriptor(_class2.prototype, "nodes", [_dec4], {
  416. configurable: true,
  417. enumerable: true,
  418. writable: true,
  419. initializer: function initializer() {
  420. return [];
  421. }
  422. })), _class2)) || _class));
  423. _cclegacy._RF.pop();
  424. _crd = false;
  425. }
  426. };
  427. });
  428. //# sourceMappingURL=62164bffde26a064612116b1cf2a16a8b180acda.js.map