123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172 |
- System.register("chunks:///_virtual/Barricade.ts", ["./rollupPluginModLoBabelHelpers.js", "cc"], (function (t) { var o, i, e, n, r, a, s, c; return { setters: [function (t) { o = t.inheritsLoose }, function (t) { i = t.cclegacy, e = t._decorator, n = t.view, r = t.Tween, a = t.tween, s = t.Vec3, c = t.Component }], execute: function () { var l; i._RF.push({}, "03f715l77hNHIDKFdm2ykJZ", "Barricade", void 0); var d = e.ccclass; e.property, t("Barricade", d("Barricade")(l = function (t) { function i() { for (var o, i = arguments.length, e = new Array(i), n = 0; n < i; n++)e[n] = arguments[n]; return (o = t.call.apply(t, [this].concat(e)) || this).originPosition = new s, o } o(i, t); var e = i.prototype; return e.start = function () { this.originPosition = this.node.getWorldPosition().clone() }, e.tick = function () { var t = this; this.node.getChildByName("Ad").active = !1; var o = n.getVisibleSize(); r.stopAllByTarget(this.node), a(this.node).to(.5, { worldPosition: new s(o.width, this.node.worldPosition.y + 200, 0), angle: 1 * Math.random() > .5 ? 360 : -360 }).call((function () { t.node.active = !1, t.node.angle = 0, t.node.setWorldPosition(t.originPosition) })).start() }, i }(c)) || l); i._RF.pop() } } }));
- System.register("chunks:///_virtual/ButtonComponent.ts", ["./rollupPluginModLoBabelHelpers.js", "cc", "./GameEvent.ts", "./EventDispatcher.ts", "./CarColorsGlobalTypes.ts", "./GlobalConfig.ts", "./AdvertMgr.ts", "./AliensAudioMgr.ts"], (function (t) { var n, e, i, o, r, a, c, s, u, l, f, E, p, d, h; return { setters: [function (t) { n = t.applyDecoratedDescriptor, e = t.inheritsLoose, i = t.initializerDefineProperty, o = t.assertThisInitialized }, function (t) { r = t.cclegacy, a = t._decorator, c = t.Button, s = t.NodeEventType, u = t.Component }, function (t) { l = t.GameEvent }, function (t) { f = t.EventDispatcher }, function (t) { E = t.TYPE_ITEM }, function (t) { p = t.GlobalConfig }, function (t) { d = t.AdvertMgr }, function (t) { h = t.AliensAudioMgr }], execute: function () { var b, g, v, C, R, m, T; r._RF.push({}, "b9f6afE/WpI+YialF/qvmW4", "ButtonComponent", void 0); var M = a.ccclass, y = a.property; t("ButtonComponent", (b = M("ButtonComponent"), g = y(c), v = y(c), b((m = n((R = function (t) { function n() { for (var n, e = arguments.length, r = new Array(e), a = 0; a < e; a++)r[a] = arguments[a]; return n = t.call.apply(t, [this].concat(r)) || this, i(n, "btRefresh", m, o(n)), i(n, "btMagnet", T, o(n)), n } e(n, t); var r = n.prototype; return r.start = function () { this.addUIEvent() }, r.addUIEvent = function () { var t = this; this.btRefresh.node.on(s.TOUCH_END, (function () { return t.onClickHandler(E.REFRESH) }), this), this.btMagnet.node.on(s.TOUCH_END, (function () { return t.onClickHandler(E.MAGNET) }), this) }, r.onClickHandler = function (t) { h.playOneShot(h.getMusicIdName(3), 1), t == E.REFRESH ? p.isDebug ? f.instance.emit(l.EVENT_REFRESH_COLOR) : d.instance.showReawardVideo((function () { f.instance.emit(l.EVENT_REFRESH_COLOR) })) : t == E.MAGNET && (p.isDebug ? f.instance.emit(l.EVENT_MAGNET) : d.instance.showReawardVideo((function () { f.instance.emit(l.EVENT_MAGNET) }))) }, n }(u)).prototype, "btRefresh", [g], { configurable: !0, enumerable: !0, writable: !0, initializer: function () { return null } }), T = n(R.prototype, "btMagnet", [v], { configurable: !0, enumerable: !0, writable: !0, initializer: function () { return null } }), C = R)) || C)); r._RF.pop() } } }));
- System.register("chunks:///_virtual/CarBoxComponent.ts", ["./rollupPluginModLoBabelHelpers.js", "cc", "./GameUtil.ts"], (function (e) { var t, n, r, i, o, a, l, s, c, u, p, f, m, h, y; return { setters: [function (e) { t = e.applyDecoratedDescriptor, n = e.inheritsLoose, r = e.initializerDefineProperty, i = e.assertThisInitialized, o = e.createClass }, function (e) { a = e.cclegacy, l = e._decorator, s = e.Label, c = e.CCInteger, u = e.v2, p = e.find, f = e.tween, m = e.v3, h = e.Component }, function (e) { y = e.GameUtil }], execute: function () { var C, d, v, g, b, w, P, _; a._RF.push({}, "97e7c2lkdxKt7llYHflbATo", "CarBoxComponent", void 0); var x = l.ccclass, A = l.property; e("CarBoxComponent", (C = x("CarBoxComponent"), d = A(s), v = A(c), g = A(c), C((P = t((w = function (e) { function t() { for (var t, n = arguments.length, o = new Array(n), a = 0; a < n; a++)o[a] = arguments[a]; return t = e.call.apply(e, [this].concat(o)) || this, r(t, "label", P, i(t)), r(t, "_num", _, i(t)), t.isAnimateOut = !1, t } return n(t, e), t.prototype.outCarTween = function () { var e = this; console.log("outCarTween 盒子出车"), this.isAnimateOut = !0; var t = this.node.getChildByName("cars").children[0], n = t.angle; this.num -= 1; var r = u(0, 0); if (-90 === n) r = u(1, 0); else if (0 === n) r = u(0, 1); else if (90 === n) r = u(-1, 0); else if (180 === n) r = u(0, -1); else { var i = n - 90; r = u(-Math.cos(i * (Math.PI / 180)), Math.sin(-i * (Math.PI / 180))) } var o = y.getWorldPositionAsVec2(t).add(r.multiplyScalar(300)); t.setParent(p("Canvas/Scene/Levels").children[0], !0), f(t).to(.2, { worldPosition: m(o.x, o.y, 0) }).call((function () { e.isAnimateOut = !1 })).start() }, o(t, [{ key: "num", get: function () { return this._num }, set: function (e) { this._num = e, this.label.string = "" + e } }]), t }(h)).prototype, "label", [d], { configurable: !0, enumerable: !0, writable: !0, initializer: function () { return null } }), t(w.prototype, "num", [v], Object.getOwnPropertyDescriptor(w.prototype, "num"), w.prototype), _ = t(w.prototype, "_num", [g], { configurable: !0, enumerable: !0, writable: !0, initializer: function () { return 3 } }), b = w)) || b)); a._RF.pop() } } }));
- System.register("chunks:///_virtual/CarCarColorsComponent.ts", ["./rollupPluginModLoBabelHelpers.js", "cc", "./EventDispatcher.ts", "./tgx.ts", "./UIDef.ts", "./AliensGlobalInstance.ts", "./CarColorsGlobalTypes.ts", "./GameEvent.ts", "./LevelAction.ts", "./LevelMgr.ts", "./GameUtil.ts", "./AliensAudioMgr.ts", "./ResourcePool.ts", "./PinComponent.ts", "./UIMgr.ts"], (function (e) { var t, n, o, i, r, a, s, l, c, u, h, d, p, C, y, f, m, g, v, T, E, P, w, N, _, b, S, M, R, I, D, L; return { setters: [function (e) { t = e.applyDecoratedDescriptor, n = e.inheritsLoose, o = e.initializerDefineProperty, i = e.assertThisInitialized, r = e.createClass }, function (e) { a = e.cclegacy, s = e._decorator, l = e.Enum, c = e.CCFloat, u = e.Input, h = e.find, d = e.instantiate, p = e.tween, C = e.Vec3, y = e.view, f = e.PhysicsSystem2D, m = e.ERaycast2DType, g = e.Component }, function (e) { v = e.EventDispatcher }, null, function (e) { T = e.UI_BattleResult }, function (e) { E = e.AliensGlobalInstance }, function (e) { P = e.CarTypes, w = e.CarDir, N = e.CarColors }, function (e) { _ = e.GameEvent }, function (e) { b = e.LevelAction }, function (e) { S = e.LevelManager }, function (e) { M = e.GameUtil }, function (e) { R = e.AliensAudioMgr }, function (e) { I = e.ResourcePool }, function (e) { D = e.PinComponent }, function (e) { L = e.UIMgr }], execute: function () { var B, F, U, A, O, x, k, z, G, W, V, H; a._RF.push({}, "a6cccMMrm5Pu7sgn7cIa5vc", "CarCarColorsComponent", void 0); var j = s.ccclass, K = s.property, q = s.executeInEditMode; e("CarCarColorsComponent", (B = j("CarCarColorsComponent"), F = K({ type: l(P) }), U = K({ type: l(w) }), A = K({ type: l(N) }), O = K({ type: l(N) }), x = K({ type: c, displayName: "可承载人数" }), B(k = q((G = t((z = function (e) { function t() { for (var t, n = arguments.length, r = new Array(n), a = 0; a < n; a++)r[a] = arguments[a]; return t = e.call.apply(e, [this].concat(r)) || this, o(t, "carType", G, i(t)), o(t, "carDir", W, i(t)), o(t, "_carColor", V, i(t)), o(t, "roleMax", H, i(t)), t.halfLen = 2, t.roleNum = 0, t.isFull = !1, t } n(t, e); var a = t.prototype; return a.onLoad = function () { this.changeColor(), this.carType === P.Minivan ? this.halfLen = 1.6 : this.carType === P.Sedan && (this.halfLen = 1.4), this.roleNum = 0, this.isFull = !1 }, a.start = function () { this.node.on(u.EventType.TOUCH_START, this.onTouchStart, this) }, a.onTouchStart = function (e) { S.instance.levelModel.isEnd || v.instance.emit(_.EVENT_CLICK_CAR, this.node) }, a.changeColor = function () { var e = this; this.node.getChildByName("Color").children.forEach((function (t) { t.name === N[e._carColor] ? t.active = !0 : t.active = !1 })), this.node.getChildByName("Cover").children.forEach((function (t) { t.name === N[e._carColor] ? t.active = !0 : t.active = !1 })), this.node.getChildByName("Cover").active = !0 }, a.addRole = function (e) { var t = this; R.playOneShot(R.getMusicIdName(6), 1); var n = h("Canvas/Scene/Levels"), o = this.node.parent, i = this.node.getChildByName("Seets").children[this.roleNum], r = d(I.instance.get_prefab("pin")), a = e.getWorldPosition().clone(), s = i.getWorldPosition().clone(), l = e.getComponent(D).pin_color; return n.addChild(r), r.getComponent(D).pin_color = l, r.setWorldPosition(a), e.removeFromParent(), e.destroy(), p(r).to(.4, { worldPosition: new C(s.x, s.y, 0) }).call((function () { t.isFull && (o.name = "empty", t.carOutTween()), r.setParent(i), r.setPosition(C.ZERO), r.getComponent(D).pin_color = t.carColor, v.instance.emit(_.EVENT_CHECK_ELEMENT_CHILDREN) })).start(), this.roleNum += 1, this.carType === P.Minivan ? this.isFull = this.roleNum > 5 : this.carType === P.Sedan ? this.isFull = this.roleNum > 3 : this.carType === P.Bus ? this.isFull = this.roleNum > 7 : this.carType === P.Single && (this.isFull = this.roleNum > 0), this.isFull }, a.openCover = function () { var e = this.node.getChildByName("Cover"); e.active = !0; var t = e.scale; p(e).to(.1, { scale: new C(0, t.y, t.z) }, { easing: "quadOut" }).start() }, a.carOut = function () { (this.node.getChildByName("Seets").children.forEach((function (e) { e.children.length })), E.instance.carSysterm.removeCar(this.node), this.node.removeFromParent(), this.node.destroy(), 0 === E.instance.carSysterm.activeCar.size) && (0 == E.instance.levels.children[0].getComponent(b).get_pin_color().length && (L.inst.getUI(T) || (S.instance.levelModel.isWin = !0, S.instance.levelModel.isEnd = !0, L.inst.showUI(T)))) }, a.getRemainSeat = function () { var e = 0; switch (this.carType) { case P.Minivan: e = 6; break; case P.Sedan: e = 4; break; case P.Bus: e = 8; break; case P.Single: e = 1; break; default: throw new Error("Unknown car type: " + this.carType) }return e - this.roleNum }, a.onDestroy = function () { this.node.off(u.EventType.TOUCH_START, this.onTouchStart) }, a.carOutTween = function () { var e = this, t = h("Canvas/Scene/Grounds/PhysicRoodTop/RightPoint").getWorldPosition(), n = this.node.getWorldPosition().clone(); p(this.node).to(.2, { worldPosition: new C(n.x, n.y - 50, n.z) }).call((function () { var n = e.node.getChildByName("Exhaust"), o = e.node.getChildByName("Exhaust1"); n && (n.active = !0, o.active = !0); var i = new C(t.x, t.y, 0), r = new C(0, 0, -1); e.node.lookAt(i, r) })).delay(.1).to(.4, { worldPosition: new C(y.getVisibleSize().x + 200, t.y, 0) }).call((function () { e.carOut() })).start() }, a.checkCollision = function () { var e = M.getWorldPositionAsVec2(this.node), t = M.calculateRayEnd(this.node, 1e3), n = f.instance.raycast(e, t, m.Closest); if (n.length > 0 && 2 == n[0].collider.group) return !0; return !1 }, a.checkCollisionNum = function () { var e = M.getWorldPositionAsVec2(this.node), t = M.calculateRayEnd(this.node, 1e3), n = f.instance.raycast(e, t, m.All); if (n.length > 0) { if (!n[0]) return; if (2 == n[0].collider.group) return n.length - 1 } }, r(t, [{ key: "carColor", get: function () { return this._carColor }, set: function (e) { this._carColor = e, this.changeColor() } }]), t }(g)).prototype, "carType", [F], { configurable: !0, enumerable: !0, writable: !0, initializer: function () { return P.Bus } }), W = t(z.prototype, "carDir", [U], { configurable: !0, enumerable: !0, writable: !0, initializer: function () { return w.TOP } }), t(z.prototype, "carColor", [A], Object.getOwnPropertyDescriptor(z.prototype, "carColor"), z.prototype), V = t(z.prototype, "_carColor", [O], { configurable: !0, enumerable: !0, writable: !0, initializer: function () { return N.Purple } }), H = t(z.prototype, "roleMax", [x], { configurable: !0, enumerable: !0, writable: !0, initializer: function () { return 4 } }), k = z)) || k) || k)); a._RF.pop() } } }));
- System.register("chunks:///_virtual/CarCarColorsSysterm.ts", ["./rollupPluginModLoBabelHelpers.js", "cc", "./CarColorsGlobalTypes.ts", "./CarBoxComponent.ts", "./CarCarColorsComponent.ts", "./EventDispatcher.ts", "./GameEvent.ts", "./AliensGlobalInstance.ts", "./LevelAction.ts", "./PinComponent.ts", "./GameUtil.ts"], (function (t) { var n, e, o, r, a, c, i, s, l, C, f, u, h, p, v, d; return { setters: [function (t) { n = t.inheritsLoose }, function (t) { e = t.cclegacy, o = t._decorator, r = t.find, a = t.PhysicsSystem2D, c = t.ERaycast2DType, i = t.Component }, function (t) { s = t.CarTypes }, function (t) { l = t.CarBoxComponent }, function (t) { C = t.CarCarColorsComponent }, function (t) { f = t.EventDispatcher }, function (t) { u = t.GameEvent }, function (t) { h = t.AliensGlobalInstance }, function (t) { p = t.LevelAction }, function (t) { v = t.PinComponent }, function (t) { d = t.GameUtil }], execute: function () { var m; e._RF.push({}, "b4436AgwkdO/obxQcs6cCbM", "CarCarColorsSysterm", void 0); var y = o.ccclass; o.property, t("CarCarColorsSysterm", y("CarCarColorsSysterm")(m = function (t) { function e() { for (var n, e = arguments.length, o = new Array(e), r = 0; r < e; r++)o[r] = arguments[r]; return (n = t.call.apply(t, [this].concat(o)) || this).activeCar = new Map, n.carSeats = [], n.carBoxMap = [], n.pinColorIndex = 0, n } n(e, t); var o = e.prototype; return o.start = function () { f.instance.on(u.EVENT_REFRESH_COLOR, this.refreshCarColor, this) }, o.onDestroy = function () { f.instance.off(u.EVENT_REFRESH_COLOR, this.refreshCarColor) }, o.addCar = function (t) { var n = this, e = t.getComponent(l); if (e) return this.carBoxMap.push(e), void t.getChildByName("cars").children.forEach((function (t) { n.addCar(t) })); if (this.activeCar.set(t.uuid, t), t.getComponent(C)) { var o = t.getComponent(C).carColor, r = t.getComponent(C).carType, a = 0; for (r === s.Bus ? a = 8 : r === s.Minivan ? a = 6 : r === s.Sedan ? a = 4 : r === s.Single && (a = 1); a--;)this.carSeats.push(o) } }, o.sortCarSeatsByDifficulty = function () { var t = this, n = []; this.activeCar.forEach((function (e, o) { var r = e.getComponent(C); if (r) { var a = t.calculateCarDifficulty(e), c = 0; r.carType === s.Bus ? c = 8 : r.carType === s.Minivan ? c = 6 : r.carType === s.Sedan ? c = 4 : r.carType === s.Single && (c = 1), n.push({ color: r.carColor, difficultyScore: a, seats: c }) } })), n.sort((function (t, n) { return n.difficultyScore - t.difficultyScore })), this.carSeats = [], n.forEach((function (n) { for (var e = 0; e < n.seats; e++)t.carSeats.push(n.color) })) }, o.calculateCarDifficulty = function (t) { var n = t.getComponent(C); return n ? (n.checkCollision() ? 10 : -10) + 2 * n.checkCollisionNum() : 1 / 0 }, o.removeCar = function (t) { this.activeCar.delete(t.uuid) }, o.clearAll = function () { this.activeCar.clear(), this.carBoxMap.length = 0, this.carBoxMap = [], this.carSeats.length = 0, this.carSeats = [], this.pinColorIndex = 0 }, o.removeColorFromSeats = function (t) { var n = this.carSeats.indexOf(t); n > -1 && this.carSeats.splice(n, 1) }, o.refreshCarColor = function () { var t = [], n = r("Canvas/Scene/Levels").children[0].getComponentsInChildren(C); n.forEach((function (n) { n.getComponent(C).checkCollision() || t.push(n) })); var e = h.instance.levels.children[0].getComponent(p).get_all_layer(), o = new Set; if (e.forEach((function (t) { 1 == t.layer_status && t.node.children.forEach((function (t) { t.getComponentsInChildren(v).forEach((function (t) { var n = t.getComponent(v); n.isBlocked || o.add(n.pin_color) })) })) })), 0 !== o.size) { var a = new Map; n.forEach((function (t) { var n = t.carType; a.has(n) || a.set(n, []), a.get(n).push(t) })); for (var c = function () { var t = s[i], n = a.get(t.carType); if (!n || n.length < 2) return 1; var e = n.find((function (n) { return n !== t && o.has(n.carColor) })); if (e) { var r = t.carColor; t.carColor = e.carColor, e.carColor = r, o.delete(t.carColor) } }, i = 0, s = t; i < s.length; i++)c() } }, o.findCanOutCars = function () { var t = []; return r("Canvas/Scene/Levels").children[0].getComponentsInChildren(C).forEach((function (n) { n.getComponent(C).checkCollision() || t.push(n) })), t }, o.checkCarBox = function () { if (0 !== this.carBoxMap.length) for (var t = this.carBoxMap.length; t--;) { var n = this.carBoxMap[t]; if (!n.isAnimateOut) if (n.num <= 0) this.carBoxMap.splice(t, 1); else { var e = n.node, o = d.getWorldPositionAsVec2(e), r = d.calculateRayEnd(e, 300); 0 == a.instance.raycast(o, r, c.Closest).length && n.outCarTween() } } }, o.lateUpdate = function (t) { this.checkCarBox() }, e }(i)) || m); e._RF.pop() } } }));
- System.register("chunks:///_virtual/AliensGlobalInstance.ts", ["./rollupPluginModLoBabelHelpers.js", "cc", "./ResLoader.ts", "./ResourcePool.ts"], (function (n) { var e, r, t, a, o, s, c, u, i, l, f; return { setters: [function (n) { e = n.inheritsLoose, r = n.createClass, t = n.asyncToGenerator, a = n.regeneratorRuntime }, function (n) { o = n.cclegacy, s = n._decorator, c = n.Component, u = n.assetManager, i = n.Prefab }, function (n) { l = n.resLoader }, function (n) { f = n.ResourcePool }], execute: function () { var p, d; o._RF.push({}, "c56747KDyRNqbIGqHCstitb", "AliensGlobalInstance", void 0); var h = s.ccclass; s.property, n("AliensGlobalInstance", h("AliensGlobalInstance")(((d = function (n) { function o() { for (var e, r = arguments.length, t = new Array(r), a = 0; a < r; a++)t[a] = arguments[a]; return (e = n.call.apply(n, [this].concat(t)) || this).levels = null, e.carSysterm = null, e } e(o, n); var s = o.prototype; return s.loadPinPrefab = function () { var n = t(a().mark((function n() { var e; return a().wrap((function (n) { for (; ;)switch (n.prev = n.next) { case 0: return n.next = 2, this.loadAsyncPin(); case 2: e = n.sent, f.instance.set_prefab(e.name, e); case 4: case "end": return n.stop() } }), n, this) }))); return function () { return n.apply(this, arguments) } }(), s.loadAsyncPin = function () { var n = t(a().mark((function n() { return a().wrap((function (n) { for (; ;)switch (n.prev = n.next) { case 0: return n.abrupt("return", new Promise((function (n, e) { u.getBundle(l.gameBundleName) || (console.error("module_nut is null!"), e()), l.loadAsync(l.gameBundleName, "Prefabs/pin", i).then((function (e) { n(e) })) }))); case 1: case "end": return n.stop() } }), n) }))); return function () { return n.apply(this, arguments) } }(), r(o, null, [{ key: "instance", get: function () { return this._instance || (this._instance = new o), this._instance } }]), o }(c))._instance = void 0, p = d)) || p); o._RF.pop() } } }));
- System.register("chunks:///_virtual/CarColorsGlobalTypes.ts", ["cc"], (function (e) { var r; return { setters: [function (e) { r = e.cclegacy }], execute: function () { var n, l; r._RF.push({}, "aa6c9oh8EtHlrhfkH0+s7i0", "CarColorsGlobalTypes", void 0); e("CarTypes", function (e) { return e[e.Single = 0] = "Single", e[e.Sedan = 1] = "Sedan", e[e.Bus = 2] = "Bus", e[e.Minivan = 3] = "Minivan", e }({})), e("CarDir", function (e) { return e[e.TOP = 0] = "TOP", e[e.BOTTOM = 1] = "BOTTOM", e[e.LEFT = 2] = "LEFT", e[e.RIGHT = 3] = "RIGHT", e }({})); var a = e("CarColors", function (e) { return e[e.Blue = 1] = "Blue", e[e.Green = 2] = "Green", e[e.Red = 3] = "Red", e[e.Cyan = 4] = "Cyan", e[e.Yellow = 5] = "Yellow", e[e.Pink = 6] = "Pink", e[e.Purple = 7] = "Purple", e[e.Brown = 8] = "Brown", e[e.Black = 9] = "Black", e[e.SpriteWhite = 10] = "SpriteWhite", e }({})); e("CarColorLog", ((n = {})[a.Blue] = "蓝色", n[a.Green] = "绿色", n[a.Red] = "红色", n[a.Cyan] = "青色", n[a.Yellow] = "黄色", n[a.Pink] = "粉色", n[a.Purple] = "紫色", n[a.Brown] = "棕色", n[a.Black] = "黑色", n[a.SpriteWhite] = "精灵白色", n)), e("CarColorHex", ((l = {})[a.Blue] = "#1B24F0", l[a.Green] = "#1BF01B", l[a.Red] = "#F0241B", l[a.Cyan] = "#9aeeca", l[a.Yellow] = "#EBF32A", l[a.Pink] = "#EB88BB", l[a.Purple] = "#F32AF3", l[a.Brown] = "#F5A71D", l[a.Black] = "#968a6c", l[a.SpriteWhite] = "#FFFFFF", l)), e("TYPE_ITEM", function (e) { return e[e.REFRESH = 1] = "REFRESH", e[e.MAGNET = 2] = "MAGNET", e }({})); r._RF.pop() } } }));
- System.register("chunks:///_virtual/AliensAudioMgr.ts", ["cc", "./tgx.ts", "./ModuleDef.ts", "./MusicConfigModel.ts", "./AudioMgr.ts"], (function (n) { var i, o, t, u; return { setters: [function (n) { i = n.cclegacy }, null, function (n) { o = n.ModuleDef }, function (n) { t = n.MusicConfigModel }, function (n) { u = n.AudioMgr }], execute: function () { i._RF.push({}, "9ead4gT4hZKLang9kU6TArc", "AliensAudioMgr", void 0); var e = o.MODULE_MOVECAR; n("AliensAudioMgr", function () { function n() { } return n.initilize = function () { this._musicConfigModel = new t }, n.playOneShot = function (n, i) { void 0 === i && (i = 1), u.inst.playOneShot(n, i, e) }, n.play = function (n, i) { void 0 === i && (i = 1), u.inst.play(n, i, e) }, n.getMusicIdName = function (n) { return "Audio/" + this._musicConfigModel.getNameById(n) }, n.stop = function () { u.inst.stop() }, n.pause = function () { u.inst.pause() }, n.resume = function () { u.inst.audioSource.play() }, n }())._musicConfigModel = void 0, i._RF.pop() } } }));
- System.register("chunks:///_virtual/DataModel.ts", ["cc"], (function (r) { var o, l; return { setters: [function (r) { o = r.cclegacy, l = r._decorator }], execute: function () { var e, _; o._RF.push({}, "e74e1M0Ah1NR58LWC1zzzhk", "DataModel", void 0); var n = l.ccclass; l.property, r("DataModel", n("DataModel")(((_ = function () { function r() { } return r.reset_lvl_color_index = function () { r.lvl_color_index = 0 }, r.get_lvl_color = function () { var o = r.lvl_color_arr[r.lvl_color_index]; return r.lvl_color_index += 1, r.lvl_color_index >= r.lvl_color_arr.length && (r.lvl_color_index = 0), o }, r.get_new_group_index = function () { var o = 1 << r.cur_group_index; return r.cur_group_index += 1, r.cur_group_index > 31 && (r.cur_group_index = 3), o }, r }()).lvl_color_arr = [], _.lvl_color_index = 0, _.cur_group_index = 3, e = _)) || e); o._RF.pop() } } }));
- System.register("chunks:///_virtual/ElementAction.ts", ["./rollupPluginModLoBabelHelpers.js", "cc", "./EventDispatcher.ts", "./CarColorsGlobalTypes.ts", "./HoleComponent.ts", "./PinComponent.ts", "./GameEvent.ts", "./AliensGlobalInstance.ts"], (function (n) { var t, o, e, i, c, r, a, s, l, h, p, d, u, m, f, g, C, E, _, y, v; return { setters: [function (n) { t = n.inheritsLoose }, function (n) { o = n.cclegacy, e = n._decorator, i = n.find, c = n.view, r = n.isValid, a = n.RigidBody2D, s = n.ERigidBody2DType, l = n.PolygonCollider2D, h = n.UIOpacity, p = n.tween, d = n.Sprite, u = n.Color, m = n.Component }, function (n) { f = n.EventDispatcher }, function (n) { g = n.CarColorHex, C = n.CarColors }, function (n) { E = n.HoleComponent }, function (n) { _ = n.PinComponent }, function (n) { y = n.GameEvent }, function (n) { v = n.AliensGlobalInstance }], execute: function () { var I; o._RF.push({}, "4351dbdNGdIZK+vsXwTNKTT", "ElementAction", void 0); var D = e.ccclass; e.property, n("ElementAction", D("ElementAction")(I = function (n) { function o() { for (var t, o = arguments.length, e = new Array(o), i = 0; i < o; i++)e[i] = arguments[i]; return (t = n.call.apply(n, [this].concat(e)) || this).ele_color = void 0, t.parking = void 0, t } t(o, n); var e = o.prototype; return e.start = function () { this.parking = i("Canvas/Scene/Parkings"), f.instance.on(y.EVENT_CHECK_ELEMENT_CHILDREN, this.checkElementChildren, this) }, e.update = function (n) { var t = this.node.getPosition().clone(); this.node.getWorldPosition().y, this.parking.getWorldPosition().y, t.y < -c.getVisibleSize().height && this.removeElement() }, e.removeElement = function () { r(this.node) && (this.node.removeFromParent(), this.node.destroy(), f.instance.emit(y.EVENT_UPDATE_LAYER)) }, e.checkElementChildren = function () { this.node && (0 == this.node.getComponentsInChildren(_).length && (this.node.getComponent(a).type = s.Dynamic)) }, e.get_hole_num = function () { var n = 0; return this.node.children.forEach((function (t) { t.getComponent(E) && n++ })), n }, e.init_element = function (n, t) { this.ele_color = t, this.node.getComponent(a).group = n, this.node.getComponents(l).forEach((function (t) { t.group = n })) }, e.init_pin = function (n, t) { this.node.children.forEach((function (o) { if (o.getComponent(E)) { var e = o.getComponentInChildren(_); if (e) { var i = v.instance.carSysterm.pinColorIndex++; e.init_date(n, t[i], o.getComponent(E)) } } })) }, e.change_pin_color = function (n) { this.node.children.forEach((function (t) { if (t.getComponent(E)) { var o = t.getComponentInChildren(_); o && (o.pin_color = n) } })) }, e.get_pin_color = function (n) { this.node.getComponentsInChildren(_).forEach((function (t) { n.push(t) })) }, e.flash_img = function (n) { this.node.children.forEach((function (n) { if ("img" == n.name && n.getComponent(h)) { var t = .3; n.getComponent(h).opacity = 255, p(n.getComponent(h)).to(t, { opacity: 200 }, { easing: "quadInOut" }).to(t, { opacity: 100 }, { easing: "quadInOut" }).to(t, { opacity: 200 }, { easing: "quadInOut" }).to(t, { opacity: 100 }, { easing: "quadInOut" }).to(t, { opacity: 255 }, { easing: "quadInOut" }).call((function () { n.getComponent(h).opacity = 255 })) } })) }, e.set_img_color = function (n, t) { this.node.children.forEach((function (t) { "img" == t.name && n && (t.getComponent(d).color = (new u).fromHEX(g[n])) })) }, e.set_layer_bg_or_orgin = function (n) { var t = this; n ? (this.node.getComponent(a).type = s.Static, this.node.children.forEach((function (n) { n.active = !1, "img" == n.name && (n.active = !0, t.set_img_color(C.Black, 180)) }))) : (this.node.children.forEach((function (n) { n.active = !0 })), this.set_img_color(C.SpriteWhite, 190), this.node.getComponent(a).type = s.Dynamic) }, e.onDestroy = function () { f.instance.off(y.EVENT_CHECK_ELEMENT_CHILDREN, this.checkElementChildren) }, o }(m)) || I); o._RF.pop() } } }));
- System.register("chunks:///_virtual/GameEvent.ts", ["cc"], (function (E) { var _; return { setters: [function (E) { _ = E.cclegacy }], execute: function () { _._RF.push({}, "a0710IA/bJN5K2C9LYXLCXm", "GameEvent", void 0); var T = E("GameEvent", (function () { })); T.EVENT_UI_INITILIZE = "EVENT_UI_INITILIZE", T.EVENT_GAME_START = "EVENT_GAME_START", T.EVENT_CLICK_CAR = "EVENT_CLICK_CAR", T.EVENT_UPDATE_LAYER = "EVENT_UPDATE_LAYER", T.EVENT_CHECK_LAYER_CHILD = "EVENT_CHECK_LAYER_CHILD", T.EVENT_UPDATE_LEFT_NAIL = "EVENT_UPDATE_LEFT_NAIL", T.EVENT_CHECK_MOVE_TO_CAR = "EVENT_CHECK_MOVE_TO_CAR", T.EVENT_CHECK_ELEMENT_CHILDREN = "EVENT_CHECK_ELEMENT_CHILDREN", T.EVENT_MAGNET = "EVENT_MAGNET", T.EVENT_REFRESH_PIN_COLORS = "EVENT_REFRESH_PIN_COLORS", T.EVENT_REFRESH_COLOR = "EVENT_REFRESH_COLOR", T.EVENT_CHECK_GAME_OVER = "EVENT_CHECK_GAME_OVER", T.EVENT_BATTLE_SUCCESS_LEVEL_UP = "EVENT_BATTLE_SUCCESS_LEVEL_UP", T.EVENT_BATTLE_FAIL_LEVEL_RESET = "EVENT_BATTLE_FAIL_LEVEL_RESET", _._RF.pop() } } }));
- System.register("chunks:///_virtual/GameUtil.ts", ["cc"], (function (n) { var t, e, r, i; return { setters: [function (n) { t = n.cclegacy, e = n.v2, r = n.Rect, i = n.Vec2 }], execute: function () { t._RF.push({}, "c41c2anOIRLkbHSc6iWasZv", "GameUtil", void 0); n("GameUtil", function () { function n() { } return n.formatWeight = function (n) { return n < 1e3 ? n + "KG" : Math.floor(n / 1e3 * 100) / 100 + "T" }, n.hexToRGBA = function (n, t) { return void 0 === t && (t = 255), 3 === (n = n.replace(/^#/, "")).length && (n = n.split("").map((function (n) { return n + n })).join("")), { r: parseInt(n.substring(0, 2), 16), g: parseInt(n.substring(2, 4), 16), b: parseInt(n.substring(4, 6), 16), a: t } }, n.getWorldPositionAsVec2 = function (n) { var t = n.getWorldPosition().clone(); return e(t.x, t.y) }, n.calculateRayEnd = function (n, t) { var r = n.angle, i = e(0, 0); if (-90 === r) i = e(1, 0); else if (0 === r) i = e(0, 1); else if (90 === r) i = e(-1, 0); else if (180 === r) i = e(0, -1); else { var o = r - 90; i = e(-Math.cos(o * (Math.PI / 180)), Math.sin(-o * (Math.PI / 180))) } return this.getWorldPositionAsVec2(n).add(i.multiplyScalar(t)) }, n.isAABBIntersecting = function (n, t) { return !(n.xMax < t.xMin || n.xMin > t.xMax || n.yMax < t.yMin || n.yMin > t.yMax) }, n.isPointInPolygon = function (n, t) { for (var e = !1, r = 0, i = t.length - 1; r < t.length; i = r++) { var o = t[r].x, s = t[r].y, a = t[i].x, u = t[i].y; s > n.y != u > n.y && n.x < (a - o) * (n.y - s) / (u - s) + o && (e = !e) } return e }, n.isCircleIntersectingLine = function (n, t, e, r) { var i = r.subtract(e), o = n.subtract(e).dot(i.normalize()), s = e.add(i.normalize().multiplyScalar(o)); return n.subtract(s).length() <= t }, n.getCircleAABB = function (n) { var t = n.radius, e = n.worldPosition, i = e.x - t, o = e.y - t, s = 2 * t; return new r(i, o, s, s) }, n.getPolygonAABB = function (n) { for (var t = n.worldPoints, e = t[0].x, i = t[0].x, o = t[0].y, s = t[0].y, a = 1; a < t.length; a++) { var u = t[a]; u.x < e && (e = u.x), u.x > i && (i = u.x), u.y < o && (o = u.y), u.y > s && (s = u.y) } return new r(e, o, i - e, s - o) }, n.isPolygonAndCircleIntersecting = function (n, t) { var e = new i(t.node.worldPosition.x, t.node.worldPosition.y), r = t.radius; if (this.isPointInPolygon(e, n.worldPoints)) return !0; for (var o = n.worldPoints, s = 0; s < o.length; s++) { var a = o[s], u = o[(s + 1) % o.length]; if (this.isCircleIntersectingLine(e, r, a, u)) return !0 } return !1 }, n.delay = function (n) { return new Promise((function (t) { return setTimeout(t, 1e3 * n) })) }, n }()); t._RF.pop() } } }));
- System.register("chunks:///_virtual/HoleComponent.ts", ["./rollupPluginModLoBabelHelpers.js", "cc"], (function (o) { var t, n, e, r; return { setters: [function (o) { t = o.inheritsLoose }, function (o) { n = o.cclegacy, e = o._decorator, r = o.Component }], execute: function () { var c; n._RF.push({}, "d8867Cfo51BxqdtXLdvD8Ux", "HoleComponent", void 0); var i = e.ccclass; e.property, o("HoleComponent", i("HoleComponent")(c = function (o) { function n() { return o.apply(this, arguments) || this } t(n, o); var e = n.prototype; return e.start = function () { }, e.hide = function () { }, n }(r)) || c); n._RF.pop() } } }));
- System.register("chunks:///_virtual/LayerAction.ts", ["./rollupPluginModLoBabelHelpers.js", "cc", "./ElementAction.ts", "./DataModel.ts"], (function (n) { var t, e, o, i, r, c; return { setters: [function (n) { t = n.inheritsLoose }, function (n) { e = n.cclegacy, o = n._decorator, i = n.Component }, function (n) { r = n.ElementAction }, function (n) { c = n.DataModel }], execute: function () { var a; e._RF.push({}, "bcd4a2CGtNE7p9TRN+IJ1yK", "LayerAction", void 0); var l = o.ccclass; o.property, n("LayerAction", l("LayerAction")(a = function (n) { function e() { for (var t, e = arguments.length, o = new Array(e), i = 0; i < e; i++)o[i] = arguments[i]; return (t = n.call.apply(n, [this].concat(o)) || this).layer_group_id = 0, t.layer_color = null, t.layer_status = 0, t } t(e, n); var o = e.prototype; return o.start = function () { }, o.update = function (n) { }, o.get_hole_num = function () { var n = 0; return this.node.children.forEach((function (t) { n += t.getComponent(r).get_hole_num() })), n }, o.init_layer = function () { var n = this; this.layer_group_id = c.get_new_group_index(), this.node.children.forEach((function (t) { t.getComponent(r).init_element(n.layer_group_id, n.layer_color) })) }, o.init_pin = function (n) { var t = this; this.node.children.forEach((function (e) { e.getComponent(r).init_pin(t.layer_group_id, n) })) }, o.change_pin_color = function (n) { this.node.children.forEach((function (t) { t.getComponent(r).change_pin_color(n) })) }, o.get_pin_color = function (n) { this.node.children.forEach((function (t) { t.getComponent(r).get_pin_color(n) })) }, o.get_element_num = function () { return this.node.children.length }, o.set_status = function (n) { var t = this; switch (n) { case 0: this.node.active = !1; break; case 1: this.node.active = !0, 0 == this.layer_status && this.node.children.forEach((function (n) { var t; null == (t = n.getComponent(r)) || t.flash_img() })), 2 == this.layer_status && this.node.children.forEach((function (n) { var t, e; null == (t = n.getComponent(r)) || t.set_layer_bg_or_orgin(!1), null == (e = n.getComponent(r)) || e.flash_img() })); break; case 2: 2 != this.layer_status && (this.node.children.forEach((function (n) { var t; null == (t = n.getComponent(r)) || t.set_layer_bg_or_orgin(!0) })), this.scheduleOnce((function () { t.node.active = !0 }), 1)) }this.layer_status = n }, e }(i)) || a); e._RF.pop() } } }));
- System.register("chunks:///_virtual/Layout_BattleResult.ts", ["./rollupPluginModLoBabelHelpers.js", "cc"], (function (e) { var t, i, r, l, n, a, o, u, c; return { setters: [function (e) { t = e.applyDecoratedDescriptor, i = e.inheritsLoose, r = e.initializerDefineProperty, l = e.assertThisInitialized }, function (e) { n = e.cclegacy, a = e._decorator, o = e.Button, u = e.Node, c = e.Component }], execute: function () { var p, s, b, y, f, g, d, h, w, R, m, z, _, B, N; n._RF.push({}, "24a1aVlAVBATpkR3PjyDH79", "Layout_BattleResult", void 0); var v = a.ccclass, L = a.property; e("Layout_BattleResult", (p = v("Layout_BattleResult"), s = L(o), b = L(o), y = L(u), f = L(u), g = L(u), d = L(u), p((R = t((w = function (e) { function t() { for (var t, i = arguments.length, n = new Array(i), a = 0; a < i; a++)n[a] = arguments[a]; return t = e.call.apply(e, [this].concat(n)) || this, r(t, "btNext", R, l(t)), r(t, "btRestart", m, l(t)), r(t, "light", z, l(t)), r(t, "winNode", _, l(t)), r(t, "loseNode", B, l(t)), r(t, "rain", N, l(t)), t } return i(t, e), t }(c)).prototype, "btNext", [s], { configurable: !0, enumerable: !0, writable: !0, initializer: null }), m = t(w.prototype, "btRestart", [b], { configurable: !0, enumerable: !0, writable: !0, initializer: null }), z = t(w.prototype, "light", [y], { configurable: !0, enumerable: !0, writable: !0, initializer: null }), _ = t(w.prototype, "winNode", [f], { configurable: !0, enumerable: !0, writable: !0, initializer: null }), B = t(w.prototype, "loseNode", [g], { configurable: !0, enumerable: !0, writable: !0, initializer: null }), N = t(w.prototype, "rain", [d], { configurable: !0, enumerable: !0, writable: !0, initializer: function () { return null } }), h = w)) || h)); n._RF.pop() } } }));
- System.register("chunks:///_virtual/LevelAction.ts", ["./rollupPluginModLoBabelHelpers.js", "cc", "./EventDispatcher.ts", "./AliensGlobalInstance.ts", "./CarCarColorsComponent.ts", "./PinComponent.ts", "./GameEvent.ts", "./UnitAction.ts", "./tgx.ts", "./UIDef.ts", "./LevelMgr.ts", "./CarBoxComponent.ts", "./CarColorsGlobalTypes.ts", "./GameUtil.ts", "./GtagMgr.ts", "./GlobalConfig.ts", "./AdvertMgr.ts", "./UIMgr.ts"], (function (e) { var n, t, r, a, i, o, s, c, l, u, h, f, p, d, m, g, v, C, _, y, k, b, E, x; return { setters: [function (e) { n = e.inheritsLoose, t = e.createForOfIteratorHelperLoose, r = e.asyncToGenerator, a = e.regeneratorRuntime }, function (e) { i = e.cclegacy, o = e._decorator, s = e.find, c = e.Component }, function (e) { l = e.EventDispatcher }, function (e) { u = e.AliensGlobalInstance }, function (e) { h = e.CarCarColorsComponent }, function (e) { f = e.PinComponent }, function (e) { p = e.GameEvent }, function (e) { d = e.UnitAction }, null, function (e) { m = e.UI_BattleResult }, function (e) { g = e.LevelManager }, function (e) { v = e.CarBoxComponent }, function (e) { C = e.CarTypes }, function (e) { _ = e.GameUtil }, function (e) { y = e.GtagMgr, k = e.GtagType }, function (e) { b = e.GlobalConfig }, function (e) { E = e.AdvertMgr }, function (e) { x = e.UIMgr }], execute: function () { var I; i._RF.push({}, "251b1LD9rlAbJPtECp8FoYX", "LevelAction", void 0); var L = o.ccclass, w = (o.property, function (e) { return e.Empty = "empty", e.InUse = "inuse", e.Locked = "empty-lock", e }(w || {})); e("LevelAction", L("LevelAction")(I = function (e) { function i() { return e.apply(this, arguments) || this } n(i, e); var o = i.prototype; return o.start = function () { this.registerListener(), this.init_level(), this.schedule(this.moveToCar, 1.2), this.reportInformation() }, o.reportInformation = function () { var e = g.instance.levelModel.level; y.inst.doGameDot(k.level_start, { level: e }), b.isDebug || E.instance.showInterstitial() }, o.registerListener = function () { l.instance.on(p.EVENT_UPDATE_LAYER, this.hide_element, this) }, o.get_lvl = function () { var e = this.node.name.split("_"); return Number(e[1].trim()) }, o.get_hole_num = function () { var e = 0; return this.node.children.forEach((function (n) { var t = n.getComponent(d).get_hole_num(); e += t })), e }, o.init_level = function () { var e = r(a().mark((function e() { var n, t, r; return a().wrap((function (e) { for (; ;)switch (e.prev = e.next) { case 0: for (n = 0; n < this.node.children.length; n++)((t = this.node.children[n]).getComponent(h) || t.getComponent(v)) && u.instance.carSysterm.addCar(this.node.children[n]); return this.node.children.forEach((function (e) { e.getComponent(d) && e.getComponent(d).init_layer() })), e.next = 4, _.delay(.2); case 4: return u.instance.carSysterm.sortCarSeatsByDifficulty(), r = u.instance.carSysterm.carSeats, this.node.children.forEach((function (e) { e.getComponent(d) && e.getComponent(d).init_pin(r) })), this.init_parking(), e.next = 10, _.delay(.2); case 10: this.set_default_layer(); case 11: case "end": return e.stop() } }), e, this) }))); return function () { return e.apply(this, arguments) } }(), o.init_parking = function () { for (var e = s("Canvas/Scene/Parkings").children, n = 0; n < e.length; n++) { var t = e[n]; if (t.name = "empty", n > 3) t.name = "empty-lock" + n, t.getChildByName("Barricade").active = !0, t.getChildByName("Barricade").getChildByName("Ad").active = !0, t.children.slice(1).forEach((function (e) { return e.destroy() })); else t.removeAllChildren() } }, o.set_default_layer = function () { this.get_all_layer().forEach((function (e) { e.set_status(0) })), this.hide_element() }, o.get_all_layer = function () { var e = []; if (this.node) { for (var n = this.node.children.length - 1; n >= 0; n--) { if (this.node.children[n].getComponent(d)) this.node.children[n].getComponent(d).get_layer(e) } return e } }, o.hide_element = function () { var e = r(a().mark((function e() { var n, t, r, i, o; return a().wrap((function (e) { for (; ;)switch (e.prev = e.next) { case 0: if (n = 2, t = 0, r = this.get_all_layer()) { e.next = 5; break } return e.abrupt("return"); case 5: i = 0; case 6: if (!(i < r.length)) { e.next = 15; break } if (!((o = r[i]).get_element_num() <= 0)) { e.next = 10; break } return e.abrupt("continue", 12); case 10: ++t <= n ? 1 != o.layer_status && o.set_status(1) : t == n + 1 ? 2 != o.layer_status && o.set_status(2) : o.set_status(0); case 12: i++, e.next = 6; break; case 15: case "end": return e.stop() } }), e, this) }))); return function () { return e.apply(this, arguments) } }(), o.getCarSeatCount = function (e) { switch (e) { case C.Sedan: return 4; case C.Minivan: return 6; case C.Bus: return 8; default: return 4 } }, o.check_pins_block = function () { var e = r(a().mark((function e() { return a().wrap((function (e) { for (; ;)switch (e.prev = e.next) { case 0: this.get_all_layer().forEach((function (e) { 1 == e.layer_status && e.node.children.forEach((function (e) { e.getComponentsInChildren(f).forEach(r(a().mark((function e(n) { return a().wrap((function (e) { for (; ;)switch (e.prev = e.next) { case 0: n.getComponent(f).checkBlocking(); case 2: case "end": return e.stop() } }), e) })))) })) })); case 2: case "end": return e.stop() } }), e, this) }))); return function () { return e.apply(this, arguments) } }(), o.get_pin_color = function () { var e = []; return this.node.getComponentsInChildren(d).forEach((function (n) { n.get_pin_color(e) })), e }, o.moveToCar = function () { var e = r(a().mark((function e() { var n, t, i, o, c; return a().wrap((function (e) { for (; ;)switch (e.prev = e.next) { case 0: if (!g.instance.levelModel.isEnd) { e.next = 3; break } return e.abrupt("return"); case 3: n = s("Canvas/Scene/Parkings").children, t = [], i = !1, o = n.length; case 7: if (!o--) { e.next = 20; break } if ("inuse" !== n[o].name || 1 !== n[o].children.length) { e.next = 11; break } return t.push(n[o].children[0]), e.abrupt("continue", 18); case 11: if ("inuse" !== n[o].name || 2 !== n[o].children.length) { e.next = 15; break } return t.push(n[o].children[1]), i = !0, e.abrupt("continue", 18); case 15: if ("empty" !== n[o].name) { e.next = 18; break } return i = !0, e.abrupt("continue", 18); case 18: e.next = 7; break; case 20: if (0 !== t.length) { e.next = 22; break } return e.abrupt("return"); case 22: c = null, this.get_all_layer().forEach((function (e) { 1 == e.layer_status && e.node.children.forEach((function (e) { e.getComponentsInChildren(f).forEach(r(a().mark((function e(n) { var r, i, o, l, p; return a().wrap((function (e) { for (; ;)switch (e.prev = e.next) { case 0: if (!(c = n.getComponent(f)).isBlocked) { e.next = 3; break } return e.abrupt("return"); case 3: r = null, i = t.length; case 5: if (!i--) { e.next = 18; break } if (o = t[i], !(l = o.getComponent(h)) || !l.isFull) { e.next = 10; break } return e.abrupt("continue", 16); case 10: if (!l || !c) { e.next = 16; break } if (l.carColor !== c.pin_color) { e.next = 16; break } if (null !== r) { e.next = 15; break } return r = o, e.abrupt("continue", 16); case 15: 0 === r.getComponent(h).roleNum && (r = o); case 16: e.next = 5; break; case 18: null !== r && (p = c.pin_color, u.instance.carSysterm.removeColorFromSeats(p), r.getComponent(h).addRole(c.node) && r.setParent(s("Canvas/Scene/Levels"), !0)); case 19: case "end": return e.stop() } }), e) })))) })) })), i || this.checkGameOver(); case 26: case "end": return e.stop() } }), e, this) }))); return function () { return e.apply(this, arguments) } }(), o.checkGameOver = function () { var e = r(a().mark((function e() { var n, t = this; return a().wrap((function (e) { for (; ;)switch (e.prev = e.next) { case 0: n = function () { if (!g.instance.levelModel.isEnd && !t.checkParkingEmpty()) { if (t.hasMatchingNails()) return !1; x.inst.getUI(m) || (g.instance.levelModel.isWin = !1, g.instance.levelModel.isEnd = !0, x.inst.showUI(m)) } }, this.unschedule(n), this.scheduleOnce(n, 3); case 3: case "end": return e.stop() } }), e, this) }))); return function () { return e.apply(this, arguments) } }(), o.checkParkingEmpty = function () { for (var e = s("Canvas/Scene/Parkings").children, n = 0; n < e.length; n++) { var t = e[n]; if (this.getParkingStatus(n, t) === w.Empty) return !0 } return !1 }, o.getParkingStatus = function (e, n) { if (n.name.startsWith(w.Locked)) { var t = n.getChildByName("Barricade"); return t && !t.active ? w.Empty : w.Locked } if (e <= 3) { if (n.name === w.InUse && n.children.length > 0) return w.InUse } else if (n.name === w.InUse && n.children.length > 1) return w.InUse; return w.Empty }, o.hasMatchingNails = function () { for (var e, n = s("Canvas/Scene/Parkings").children, r = this.get_all_layer(), a = t(n); !(e = a()).done;) { var i = e.value; if ("inuse" === i.name && i.children.length > 0) { var o = i.children[0].getComponent(h); if (!o || o.isFull) continue; for (var c, l = o.carColor, u = t(r); !(c = u()).done;) { var p = c.value; if (1 === p.layer_status) for (var d, m = t(p.node.children); !(d = m()).done;)for (var g, v = d.value.getComponentsInChildren(f), C = t(v); !(g = C()).done;) { var _ = g.value.getComponent(f); if (!_.isBlocked && _.pin_color === l) return !0 } } } } return !1 }, o.onDestroy = function () { l.instance.off(p.EVENT_UPDATE_LAYER, this.hide_element), this.unscheduleAllCallbacks() }, o.update = function (e) { }, i }(c)) || I); i._RF.pop() } } }));
- System.register("chunks:///_virtual/LevelMgr.ts", ["./rollupPluginModLoBabelHelpers.js", "cc", "./ResLoader.ts", "./EventDispatcher.ts", "./GlobalConfig.ts", "./GameEvent.ts", "./LevelModel.ts", "./GameUtil.ts"], (function (e) { var t, n, r, l, a, s, i, o, c, u, v, h, f, d, p, L; return { setters: [function (e) { t = e.createClass, n = e.asyncToGenerator, r = e.regeneratorRuntime }, function (e) { l = e.cclegacy, a = e._decorator, s = e.sys, i = e.assetManager, o = e.Prefab, c = e.instantiate, u = e.find }, function (e) { v = e.resLoader }, function (e) { h = e.EventDispatcher }, function (e) { f = e.GlobalConfig }, function (e) { d = e.GameEvent }, function (e) { p = e.LevelModel }, function (e) { L = e.GameUtil }], execute: function () { var m, g; l._RF.push({}, "d8df8/0FEdJ8ItD7vCAkvpi", "LevelMgr", void 0); var M = a.ccclass; a.property, e("LevelManager", M("LevelManager")(((g = function () { function e() { this.levelModel = null, this.currentLevel = null, this.randomLevel = 0 } var l = e.prototype; return l.initilizeModel = function () { this.levelModel = new p, this.preloadLevel(), this.registerEvent() }, l.registerEvent = function () { h.instance.on(d.EVENT_BATTLE_FAIL_LEVEL_RESET, this.restartLevelHandler, this) }, l.loadAsyncLevel = function () { var e = n(r().mark((function e(t) { return r().wrap((function (e) { for (; ;)switch (e.prev = e.next) { case 0: return e.abrupt("return", new Promise((function (e, n) { i.getBundle(v.gameBundleName) || (console.error("module_nut is null!"), n()), v.loadAsync(v.gameBundleName, "Prefabs/CarColorsLevels/lvl_" + t, o).then((function (t) { e(t) })) }))); case 1: case "end": return e.stop() } }), e) }))); return function (t) { return e.apply(this, arguments) } }(), l.preloadLevel = function () { var e = n(r().mark((function e() { var t, n; return r().wrap((function (e) { for (; ;)switch (e.prev = e.next) { case 0: for (t = i.getBundle(v.gameBundleName), n = 1; n <= f.levelTotal; n++)t.preload("Prefabs/CarColorsLevels/lvl_" + n, o, null, (function () { })); case 2: case "end": return e.stop() } }), e) }))); return function () { return e.apply(this, arguments) } }(), l.levelUpHandler = function () { var e = n(r().mark((function e() { return r().wrap((function (e) { for (; ;)switch (e.prev = e.next) { case 0: return this.clearLevelData(), this.upgradeLevel(), e.next = 4, this.gameStart(); case 4: case "end": return e.stop() } }), e, this) }))); return function () { return e.apply(this, arguments) } }(), l.restartLevelHandler = function () { var e = n(r().mark((function e() { return r().wrap((function (e) { for (; ;)switch (e.prev = e.next) { case 0: return this.clearLevelData(), e.next = 3, this.gameStart(); case 3: case "end": return e.stop() } }), e, this) }))); return function () { return e.apply(this, arguments) } }(), l.gameStart = function () { var e = n(r().mark((function e() { var t; return r().wrap((function (e) { for (; ;)switch (e.prev = e.next) { case 0: return t = this.levelModel.level, e.next = 3, this.loadLevel(t); case 3: return e.next = 5, L.delay(.2); case 5: h.instance.emit(d.EVENT_UPDATE_LEFT_NAIL); case 6: case "end": return e.stop() } }), e, this) }))); return function () { return e.apply(this, arguments) } }(), l.clearLevelData = function () { this.levelModel.clearLevel() }, l.upgradeLevel = function (e) { if (void 0 === e && (e = 1), this.levelModel.level += e, s.localStorage.setItem("Rescuethecar_level", this.levelModel.level.toString()), this.levelModel.level > f.levelTotal) { for (var t = this.levelModel.randomLevelList, n = Math.floor(Math.random() * t.length), r = t[n]; r === this.randomLevel && t.length > 1;)r = t[n = Math.floor(Math.random() * t.length)]; this.randomLevel = r, this.levelModel.levelConfig.init(this.randomLevel) } else this.levelModel.levelConfig.init(this.levelModel.level); h.instance.emit(d.EVENT_BATTLE_SUCCESS_LEVEL_UP) }, l.loadLevel = function () { var e = n(r().mark((function e(t) { var n; return r().wrap((function (e) { for (; ;)switch (e.prev = e.next) { case 0: if (n = null, !(this.levelModel.level > f.levelTotal)) { e.next = 7; break } return e.next = 4, this.loadAsyncLevel(this.randomLevel); case 4: n = e.sent, e.next = 10; break; case 7: return e.next = 9, this.loadAsyncLevel(t); case 9: n = e.sent; case 10: if (this.currentLevel && this.currentLevel.destroy(), n) { e.next = 13; break } return e.abrupt("return"); case 13: return this.currentLevel = c(n), u("Canvas/Scene/Levels").removeAllChildren(), u("Canvas/Scene/Levels").addChild(this.currentLevel), e.abrupt("return", this.currentLevel); case 17: case "end": return e.stop() } }), e, this) }))); return function (t) { return e.apply(this, arguments) } }(), t(e, null, [{ key: "instance", get: function () { return this._instance || (this._instance = new e), this._instance } }]), e }())._instance = null, m = g)) || m); l._RF.pop() } } }));
- System.register("chunks:///_virtual/LevelModel.ts", ["cc", "./JsonUtil.ts", "./Tablelevels_config.ts", "./GlobalConfig.ts", "./AliensGlobalInstance.ts"], (function (e) { var t, l, i, n, s, o; return { setters: [function (e) { t = e.cclegacy, l = e.sys }, function (e) { i = e.JsonUtil }, function (e) { n = e.Tablelevels_config }, function (e) { s = e.GlobalConfig }, function (e) { o = e.AliensGlobalInstance }], execute: function () { t._RF.push({}, "2655e5Cq2JG0qLO/zyZVxzy", "LevelModel", void 0); e("TYPE_ITEM", function (e) { return e[e.REVOKE = 1] = "REVOKE", e[e.ADDNUT = 2] = "ADDNUT", e }({})); var a = e("TYPE_GAME_STATE", function (e) { return e[e.GAME_STATE_INIT = 0] = "GAME_STATE_INIT", e[e.GAME_STATE_START = 1] = "GAME_STATE_START", e[e.GAME_STATE_END = 2] = "GAME_STATE_END", e[e.GAME_STATE_RESULT = 3] = "GAME_STATE_RESULT", e[e.GAME_STATE_PAUSE = 4] = "GAME_STATE_PAUSE", e }({})); e("LevelModel", function () { function e() { if (this.levelConfig = void 0, this.level = 1, this.star = 3, this.levelStarsMap = new Map, this.randomLevelList = [], this.isWin = !1, this.isEnd = !1, this.curGameState = a.GAME_STATE_INIT, this.levelConfig = new n, this.getRandomLevelList(), s.isDebug) this.level = s.initilizeLevel; else { var e = l.localStorage.getItem("Rescuethecar_level"); if (e) if (e > s.levelTotal) { var t = this.randomLevelList[Math.floor(Math.random() * this.randomLevelList.length - 1)]; this.level = t } else this.level = parseInt(e); else this.level = 1 } this.levelConfig.init(this.level) } var t = e.prototype; return t.getRandomLevelList = function () { var e = i.get(n.TableName); e || console.warn("Get level table is fail!"), this.randomLevelList = Object.values(e).filter((function (e) { return 1 == e.random })).map((function (e) { return e.level })) }, t.clearLevel = function () { o.instance.carSysterm.clearAll(), this.isWin = !1, this.isEnd = !1, this.star = 3 }, e }()); t._RF.pop() } } }));
- System.register("chunks:///_virtual/module_movecar", ["./Layout_BattleResult.ts", "./UI_BattleResult_Impl.ts", "./RoosterMoveCar.ts", "./AliensGlobalInstance.ts", "./CarColorsGlobalTypes.ts", "./Barricade.ts", "./ButtonComponent.ts", "./CarBoxComponent.ts", "./CarCarColorsComponent.ts", "./HoleComponent.ts", "./PinComponent.ts", "./RainEffect.ts", "./ElementAction.ts", "./GameEvent.ts", "./GameUtil.ts", "./LayerAction.ts", "./LevelAction.ts", "./AliensAudioMgr.ts", "./LevelMgr.ts", "./DataModel.ts", "./LevelModel.ts", "./MusicConfigModel.ts", "./ResourcePool.ts", "./CarCarColorsSysterm.ts", "./UnitColorsSysterm.ts", "./UnitAction.ts"], (function () { return { setters: [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null], execute: function () { } } }));
- System.register("chunks:///_virtual/MusicConfigModel.ts", ["./rollupPluginModLoBabelHelpers.js", "cc", "./Tablemusic_config.ts"], (function (n) { var i, t, e; return { setters: [function (n) { i = n.createClass }, function (n) { t = n.cclegacy }, function (n) { e = n.Tablemusic_config }], execute: function () { t._RF.push({}, "807a0fEbhdDWpvUekcCKkdZ", "MusicConfigModel", void 0); n("MusicConfigModel", function () { function n(n) { void 0 === n && (n = 1), this.config = void 0, this.id = void 0, this.id = n, this.config = new e } return n.prototype.getNameById = function (n) { return void 0 === n && (n = 1), this.config.init(n), this.name }, i(n, [{ key: "content", get: function () { return this.config.content } }, { key: "name", get: function () { return this.config.name } }]), n }()); t._RF.pop() } } }));
- System.register("chunks:///_virtual/PinComponent.ts", ["./rollupPluginModLoBabelHelpers.js", "cc", "./CarColorsGlobalTypes.ts", "./UnitAction.ts", "./GameUtil.ts"], (function (n) { var e, t, o, r, i, c, a, s, l, p, u, h, f, g, d, y; return { setters: [function (n) { e = n.applyDecoratedDescriptor, t = n.inheritsLoose, o = n.initializerDefineProperty, r = n.assertThisInitialized, i = n.createClass }, function (n) { c = n.cclegacy, a = n._decorator, s = n.Enum, l = n.CircleCollider2D, p = n.Rect, u = n.PolygonCollider2D, h = n.RigidBody2D, f = n.Component }, function (n) { g = n.CarColors }, function (n) { d = n.UnitAction }, function (n) { y = n.GameUtil }], execute: function () { var _, m, C, v, P, B; c._RF.push({}, "ae62fmLVEdJ+qdTnV4YGIwE", "PinComponent", void 0); var L = a.ccclass, I = a.property, w = a.executeInEditMode; n("PinComponent", (_ = L("PinComponent"), m = I({ type: s(g) }), C = I({ type: s(g) }), _(v = w((e((P = function (n) { function e() { for (var e, t = arguments.length, i = new Array(t), c = 0; c < t; c++)i[c] = arguments[c]; return e = n.call.apply(n, [this].concat(i)) || this, o(e, "_pin_color", B, r(e)), e.isBlocked = !1, e.isProcessing = !1, e.pos_hole = null, e } t(e, n); var c = e.prototype; return c.start = function () { }, c.getParentLayer = function (n) { for (var e = n.parent; e;) { var t; if (null != (t = e.parent) && t.getComponent(d)) return e; e = e.parent } return null }, c.getHigherLayers = function (n) { var e = this, t = [], o = n.parent; if (!o) return t; var r = this.getLayerIndex(n.name); return isNaN(r) || o.children.forEach((function (n) { var o = e.getLayerIndex(n.name); !isNaN(o) && o > r && t.push(n) })), t }, c.getLayerIndex = function (n) { var e = n.match(/layer_(\d+)/); return e ? parseInt(e[1], 10) : NaN }, c.getWorldBoundingBox = function () { var n = this.node.getComponent(l); if (!n) return null; var e = n.worldAABB; return new p(e.xMin, e.yMin, e.width, e.height) }, c.checkBlocking = function () { var n = this.node.getComponent(l); if (n) { var e = this.getParentLayer(this.node); if (e) { var t = this.getHigherLayers(e); 0 !== t.length && (this.isBlocked = t.some((function (e) { return e.getComponentsInChildren(u).some((function (e) { return y.isPolygonAndCircleIntersecting(e, n) })) })), this.isBlocked) } else console.warn("无法获取当前钉子所在的 layer") } }, c.init_date = function (n, e, t) { this.pos_hole = t, this.node.getComponent(h).group = n, this._pin_color = e, this.reset_img() }, c.reset_img = function () { this._pin_color ? this.changeColor() : console.log("被return的颜色" + this._pin_color) }, c.changeColor = function () { var n = this; this.node.children.forEach((function (e) { e.name === g[n._pin_color] ? e.active = !0 : e.active = !1 })) }, c.onDestroy = function () { }, i(e, [{ key: "pin_color", get: function () { return this._pin_color }, set: function (n) { this._pin_color = n, this.changeColor() } }]), e }(f)).prototype, "pin_color", [m], Object.getOwnPropertyDescriptor(P.prototype, "pin_color"), P.prototype), B = e(P.prototype, "_pin_color", [C], { configurable: !0, enumerable: !0, writable: !0, initializer: function () { return g.Purple } }), v = P)) || v) || v)); c._RF.pop() } } }));
- System.register("chunks:///_virtual/RainEffect.ts", ["./rollupPluginModLoBabelHelpers.js", "cc"], (function (t) { var e, i, n, r, o, s, a, p, c, f, h; return { setters: [function (t) { e = t.applyDecoratedDescriptor, i = t.inheritsLoose, n = t.initializerDefineProperty, r = t.assertThisInitialized, o = t.createForOfIteratorHelperLoose }, function (t) { s = t.cclegacy, a = t._decorator, p = t.Vec3, c = t.UITransform, f = t.randomRangeInt, h = t.Component }], execute: function () { var u, l, d, R, g, v; s._RF.push({}, "5ade39TXTBLhavCAiPa8H8E", "RainEffect", void 0); var y = a.ccclass, D = a.property; t("RainEffect", (u = y("RainEffect"), l = D(p), u((g = e((R = function (t) { function e() { for (var e, i = arguments.length, o = new Array(i), s = 0; s < i; s++)o[s] = arguments[s]; return e = t.call.apply(t, [this].concat(o)) || this, n(e, "speed", g, r(e)), n(e, "resetY", v, r(e)), e.isRaining = !1, e.rainDrops = [], e } i(e, t); var s = e.prototype; return s.start = function () { this.rainDrops = this.node.children, this.resetRainDrops(), this.startRain() }, s.startRain = function () { this.isRaining = !0 }, s.stopRain = function () { this.isRaining = !1 }, s.clearRain = function () { this.stopRain(), this.resetRainDrops() }, s.resetRainDrops = function () { for (var t, e = this.node.getComponent(c).width, i = this.node.getComponent(c).height, n = o(this.rainDrops); !(t = n()).done;) { var r = t.value, s = f(-e / 2, e / 2), a = f(0, i / 2); r.setPosition(s, a, 0) } }, s.update = function (t) { if (this.isRaining) for (var e, i = o(this.rainDrops); !(e = i()).done;) { var n = e.value, r = n.position; r.add3f(this.speed.x * t, this.speed.y * t, this.speed.z * t), n.setPosition(r); var s = this.node.getComponent(c).width, a = this.node.getComponent(c).height; if (n.position.y < -a / 2) { var p = f(-s / 2, a / 2); n.setPosition(p, this.resetY, 0) } } }, s.onDestroy = function () { }, e }(h)).prototype, "speed", [l], { configurable: !0, enumerable: !0, writable: !0, initializer: function () { return new p(0, -100, 0) } }), v = e(R.prototype, "resetY", [D], { configurable: !0, enumerable: !0, writable: !0, initializer: function () { return 120 } }), d = R)) || d)); s._RF.pop() } } }));
- System.register("chunks:///_virtual/ResourcePool.ts", ["./rollupPluginModLoBabelHelpers.js", "cc"], (function (e) { var o, r, t; return { setters: [function (e) { o = e.createClass }, function (e) { r = e.cclegacy, t = e._decorator }], execute: function () { var c, n; r._RF.push({}, "ec9c4v/u0pDLZmbQWagshcg", "ResourcePool", void 0); var s = t.ccclass; t.property, e("ResourcePool", s("ResourcePool")(((n = function () { function e() { this.prefab_pool = {} } var r = e.prototype; return r.set_prefab = function (e, o) { this.prefab_pool[e] = o }, r.get_prefab = function (e) { return this.prefab_pool[e] }, o(e, null, [{ key: "instance", get: function () { return this.rp || (this.rp = new e, window.rp = this.rp), this.rp } }]), e }()).rp = void 0, c = n)) || c); r._RF.pop() } } }));
- System.register("chunks:///_virtual/RoosterMoveCar.ts", ["./rollupPluginModLoBabelHelpers.js", "cc", "./EventDispatcher.ts", "./AliensGlobalInstance.ts", "./CarColorsGlobalTypes.ts", "./CarCarColorsComponent.ts", "./GameEvent.ts", "./LevelMgr.ts", "./CarCarColorsSysterm.ts", "./GameUtil.ts", "./LevelAction.ts", "./GlobalConfig.ts", "./AdvertMgr.ts", "./Barricade.ts", "./AliensAudioMgr.ts", "./tgx.ts", "./UIDef.ts", "./UIMgr.ts"], (function (t) { var e, n, o, i, a, r, s, l, c, d, u, h, f, g, v, C, p, m, P, y, w, T, R, L, E, S, M, N, b; return { setters: [function (t) { e = t.inheritsLoose, n = t.asyncToGenerator, o = t.regeneratorRuntime }, function (t) { i = t.cclegacy, a = t._decorator, r = t.find, s = t.NodeEventType, l = t.PhysicsSystem2D, c = t.ERaycast2DType, d = t.Vec3, u = t.tween, h = t.Label, f = t.Component, g = t.Tween }, function (t) { v = t.EventDispatcher }, function (t) { C = t.AliensGlobalInstance }, function (t) { p = t.CarDir }, function (t) { m = t.CarCarColorsComponent }, function (t) { P = t.GameEvent }, function (t) { y = t.LevelManager }, function (t) { w = t.CarCarColorsSysterm }, function (t) { T = t.GameUtil }, function (t) { R = t.LevelAction }, function (t) { L = t.GlobalConfig }, function (t) { E = t.AdvertMgr }, function (t) { S = t.Barricade }, function (t) { M = t.AliensAudioMgr }, null, function (t) { N = t.UI_Setting }, function (t) { b = t.UIMgr }], execute: function () { var U; i._RF.push({}, "981c6qxz65Czq+BDylrIn50", "RoosterMoveCar", void 0); var x = a.ccclass, _ = (a.property, .3); t("RoosterMoveCar", x("RoosterMoveCar")(U = function (t) { function i() { return t.apply(this, arguments) || this } e(i, t); var a = i.prototype; return a.onLoad = function () { M.initilize(), M.play(M.getMusicIdName(2), 1), y.instance.initilizeModel(), C.instance.levels = r("Canvas/Scene/Levels"), C.instance.carSysterm = this.node.getComponent(w), C.instance.loadPinPrefab(), this.registerListener() }, a.start = function () { this.startGame() }, a.startGame = function () { var t = n(o().mark((function t() { return o().wrap((function (t) { for (; ;)switch (t.prev = t.next) { case 0: return t.next = 2, y.instance.gameStart(); case 2: case "end": return t.stop() } }), t) }))); return function () { return t.apply(this, arguments) } }(), a.registerListener = function () { var t = this; v.instance.on(P.EVENT_CLICK_CAR, this.onTouchCar, this), v.instance.on(P.EVENT_BATTLE_SUCCESS_LEVEL_UP, this.onUpdateLvl, this), v.instance.on(P.EVENT_UPDATE_LEFT_NAIL, this.onUpdateLeftNail, this), v.instance.on(P.EVENT_CHECK_ELEMENT_CHILDREN, this.onUpdateLeftNail, this); var e = r("Canvas/Scene/Parkings/empty-lock4"), n = r("Canvas/Scene/Parkings/empty-lock5"), o = r("Canvas/Scene/Parkings/empty-lock6"), i = r("Canvas/GameUI/TopLeft/BtnRefresh"), a = r("Canvas/GameUI/TopLeft/BtnSet"); e.on(s.TOUCH_END, (function () { return t.onClickHandler(e) }), this), n.on(s.TOUCH_END, (function () { return t.onClickHandler(n) }), this), o.on(s.TOUCH_END, (function () { return t.onClickHandler(o) }), this), i.on(s.TOUCH_END, (function () { return t.onClickRefresh() }), this), a.on(s.TOUCH_END, (function () { return t.onClickSet() }), this) }, a.onClickHandler = function (t) { M.playOneShot(M.getMusicIdName(3), 1); var e = function () { t.name = "empty", t.getComponentInChildren(S).tick() }; L.isDebug ? e() : E.instance.showReawardVideo((function () { e() })) }, a.onClickRefresh = function () { var t = n(o().mark((function t() { var e; return o().wrap((function (t) { for (; ;)switch (t.prev = t.next) { case 0: return M.playOneShot(M.getMusicIdName(3), 1), g.stopAll(), y.instance.clearLevelData(), C.instance.carSysterm.clearAll(), e = y.instance.levelModel.level, y.instance.loadLevel(e), t.next = 8, T.delay(.2); case 8: case "end": return t.stop() } }), t) }))); return function () { return t.apply(this, arguments) } }(), a.onClickSet = function () { M.playOneShot(M.getMusicIdName(3), 1), b.inst.isShowing(N) || b.inst.showUI(N) }, a.onTouchCar = function (t) { var e = t, n = e.getComponent(m); if (n) { var o = e.getWorldPosition().clone(), i = T.getWorldPositionAsVec2(e), a = T.calculateRayEnd(e, 1e3), s = l.instance.raycast(i, a, c.Closest); if (s.length > 0) { var h = s[0], f = s[0].collider; if (2 == f.group) { var g = n.halfLen, v = null; v = n.carDir == p.TOP || n.carDir == p.BOTTOM ? new d(0, 1, 0) : new d(1, 0, 0); var C = o.clone().add(v.clone().multiplyScalar(h.fraction - 5 * g)); u(e).to(.1, { worldPosition: C }).to(.1, { worldPosition: o }).call((function () { })).start(), M.playOneShot(M.getMusicIdName(5), 1) } else { var P = this.getEmptyParkPoint(); if (null === P) return void console.log("没有车位了"); var y = s[0].point, w = u(e); if ("PhysicRoodTop" === f.node.name) this.hitPointTween2(e, y, w, f.node, P), this.topRoadTween(e, P, w); else if ("PhysicRoodLeft" === f.node.name) { r("Canvas/Scene/Grounds/PhysicRoodTop/LeftPoint"); this.hitPointTween2(e, y, w, f.node), this.leftRoadTween(e, w), this.leftTopToRight(e, P, w), this.topRoadTween(e, P, w) } else if ("PhysicRoodRight" === f.node.name) { r("Canvas/Scene/Grounds/PhysicRoodTop/RightPoint"); this.hitPointTween2(e, y, w, f.node), this.rightRoadTween(e, w), this.rightTopToleft(e, P, w), this.topRoadTween(e, P, w) } else if ("PhysicRoodBottom" === f.node.name) { var R = r("Canvas/Scene/Grounds/PhysicRoodBottom"), L = R.getChildByName("LeftPoint"), E = R.getChildByName("RightPoint"), S = L.getWorldPosition().subtract(o).normalize(), N = E.getWorldPosition().subtract(o).normalize(); if (Math.abs(S.x) < Math.abs(N.x)) { var b = r("Canvas/Scene/Grounds/PhysicRoodBottom/LeftPoint"); this.hitPointTween2(e, y, w, f.node), this.bottomRoadTween(e, b, w), this.leftRoadTween(e, w), this.leftTopToRight(e, P, w) } else { var U = r("Canvas/Scene/Grounds/PhysicRoodBottom/RightPoint"); this.hitPointTween2(e, y, w, f.node), this.bottomRoadTween(e, U, w), this.rightRoadTween(e, w), this.rightTopToleft(e, P, w) } this.topRoadTween(e, P, w) } P.name = "inuse", w.call((function () { var t = e.getChildByName("Exhaust"), n = e.getChildByName("Exhaust1"); t && (t.active = !1, n.active = !1), e.setParent(P, !0) })).start() } } else console.log("未检测到碰撞物体") } }, a.onUpdateLeftNail = function () { this.updateScrewsLen(), this.onUpdateLvl() }, a.updateScrewsLen = function () { var t = r("Canvas/Scene/Levels"), e = r("Canvas/GameUI/Pai/LbScrews").getComponent(h), n = t.children; if (!(n.length <= 0)) { var o = n[0].getComponent(R).get_pin_color(); e.string = "" + o.length } }, a.onUpdateLvl = function () { var t = r("Canvas/GameUI/TitleLvl/LbLvl").getComponent(h), e = y.instance.levelModel.level; t.string = "" + e }, a.getEmptyParkPoint = function () { for (var t = r("Canvas/Scene/Parkings").children, e = 0; e < t.length; e++)if ("empty" === t[e].name) return t[e]; return null }, a.hitPointTween2 = function (t, e, n, o, i) { void 0 === o && (o = null), M.playOneShot(M.getMusicIdName(4), 1); var a = t.getChildByName("Exhaust"), r = t.getChildByName("Exhaust1"); a && (a.active = !0, r.active = !0); var s = new d(e.x, e.y, 0); n.to(_, { worldPosition: s }, { easing: "quadInOut" }).call((function () { var e, n = t.getWorldPosition().clone(), a = s.subtract(n).normalize(); if (Math.abs(a.x) > Math.abs(a.y)) { var r = o.getChildByName("LeftPoint"), l = o.getChildByName("RightPoint"), c = r.getWorldPosition().subtract(n).normalize(), u = l.getWorldPosition().subtract(n).normalize(); e = Math.abs(c.x) < Math.abs(u.x) ? new d(0, 0, 1) : new d(0, 0, -1) } else if ("PhysicRoodBottom" == o.name || "PhysicRoodTop" == o.name) if ("PhysicRoodTop" == o.name) { var h = t.getWorldPosition().clone(), f = i.getWorldPosition().clone(); e = h.subtract(f).normalize().x > 0 ? new d(0, 0, 1) : new d(0, 0, -1) } else { var g = o.getChildByName("LeftPoint"), v = o.getChildByName("RightPoint"), C = g.getWorldPosition().subtract(s).normalize(), p = v.getWorldPosition().subtract(s).normalize(); e = Math.abs(C.x) <= Math.abs(p.x) ? new d(0, 0, 1) : new d(0, 0, -1) } else e = a.y > 0 ? new d(0, -1, 0) : new d(0, 1, 0); t.lookAt(s, e) })).start() }, a.topRoadTween = function (t, e, n) { var o = e.worldPosition.clone(); n.to(_, { worldPosition: new d(o.x, o.y - 70, o.z) }).delay(.1).to(_, { eulerAngles: new d(0, 0, 0) }).delay(.1).to(_, { worldPosition: e.worldPosition }).call((function () { t.getComponent(m).openCover() })) }, a.leftTopToRight = function (t, e, n) { n.to(.2, { eulerAngles: new d(0, 0, -90) }).start() }, a.leftRoadTween = function (t, e) { var n = r("Canvas/Scene/Grounds/PhysicRoodTop/LeftPoint"); e.to(_, { worldPosition: n.getWorldPosition() }).call((function () { var e = t.forward.clone(); u(e).to(.1, { x: -1, y: 0, z: 0 }, { onUpdate: function () { t.forward = e } }).start() })).delay(.1) }, a.rightTopToleft = function (t, e, n) { n.to(.2, { eulerAngles: new d(0, 0, 90) }).start() }, a.rightRoadTween = function (t, e) { var n = r("Canvas/Scene/Grounds/PhysicRoodTop/RightPoint"); e.to(_, { worldPosition: n.getWorldPosition() }).call((function () { var e = t.forward.clone(); u(e).to(.1, { x: 1, y: 0, z: 0 }, { onUpdate: function () { t.forward = e } }).start() })).delay(.1) }, a.bottomRoadTween = function (t, e, n) { n.to(_, { worldPosition: new d(e.getWorldPosition().x, e.getWorldPosition().y + 20, e.getWorldPosition().z) }).call((function () { var e = t.forward.clone(); u(e).to(.1, { x: 0, y: 0, z: 1 }, { onUpdate: function () { t.forward = e } }).start() })).delay(.1) }, i }(f)) || U); i._RF.pop() } } }));
- System.register("chunks:///_virtual/UI_BattleResult_Impl.ts", ["./rollupPluginModLoBabelHelpers.js", "cc", "./tgx.ts", "./GameUILayers.ts", "./UIDef.ts", "./Layout_BattleResult.ts", "./GtagMgr.ts", "./LevelMgr.ts", "./AliensAudioMgr.ts", "./RainEffect.ts", "./ModuleContext.ts"], (function (t) { var e, n, i, s, a, o, l, r, u, c, f, h, d, v, g, m; return { setters: [function (t) { e = t.inheritsLoose }, function (t) { n = t.cclegacy, i = t.v3, s = t.tween, a = t.Vec3, o = t.Tween, l = t.isValid }, null, function (t) { r = t.GameUILayers }, function (t) { u = t.UI_BattleResult }, function (t) { c = t.Layout_BattleResult }, function (t) { f = t.GtagMgr, h = t.GtagType }, function (t) { d = t.LevelManager }, function (t) { v = t.AliensAudioMgr }, function (t) { g = t.RainEffect }, function (t) { m = t.ModuleContext }], execute: function () { n._RF.push({}, "60a4313NlFJpqUrSRZVVrBe", "UI_BattleResult_Impl", void 0); var w = t("UI_BattleResult_Impl", function (t) { function n() { var e; return (e = t.call(this, "Prefabs/UI/Result/UI_BattleResult", r.POPUP, c) || this).rewardBase = 0, e.rewardAdditional = 0, e.timeoutIds = [], e.win = !0, e } e(n, t); var u = n.prototype; return u.getRes = function () { return [] }, u.onCreated = function () { var t = this; this.win = d.instance.levelModel.isWin; var e = this.win ? 7 : 8; v.playOneShot(v.getMusicIdName(e), 1); var n = this.layout; this.onButtonEvent(n.btNext, (function () { t.onClickRewardBase() })), this.onButtonEvent(n.btRestart, (function () { t.onClickRewardBase() })), n.winNode.active = this.win, n.loseNode.active = !this.win, this.win || this.rainEffect(), this.rotationLight(); var i = d.instance.levelModel.level; f.inst.doGameDot(h.level_end, { level: i }) }, u.rainEffect = function () { this.layout.rain.getComponent(g).startRain() }, u.rotationLight = function () { if (this.win) { var t = this.layout.light; t.eulerAngles = i(0, 0, 0), s(t).repeatForever(s().to(5, { eulerAngles: new a(0, 0, 360) }, { easing: "linear" }).call((function () { t.eulerAngles = new a(0, 0, 0) }))).start() } }, u.emitEvent = function () { this.win ? d.instance.levelUpHandler() : d.instance.restartLevelHandler() }, u.onClickRewardBase = function () { this.destoryMyself(), this.emitEvent() }, u.clearAllTimeouts = function () { this.timeoutIds.forEach((function (t) { return clearTimeout(t) })), this.timeoutIds = [] }, u.destoryMyself = function () { o.stopAllByTarget(this.node), l(this.node) && (this.node.removeFromParent(), this.hide()), this.clearAllTimeouts() }, n }(u)); m.attachImplClass(u, w), n._RF.pop() } } }));
- System.register("chunks:///_virtual/UnitAction.ts", ["./rollupPluginModLoBabelHelpers.js", "cc", "./LayerAction.ts", "./EventDispatcher.ts", "./GameEvent.ts"], (function (n) { var t, e, o, i, r, c, h; return { setters: [function (n) { t = n.inheritsLoose }, function (n) { e = n.cclegacy, o = n._decorator, i = n.Component }, function (n) { r = n.LayerAction }, function (n) { c = n.EventDispatcher }, function (n) { h = n.GameEvent }], execute: function () { var a; e._RF.push({}, "b886bGpOV5EmZwcCJSzq1Ua", "UnitAction", void 0); var u = o.ccclass; o.property, n("UnitAction", u("UnitAction")(a = function (n) { function e() { return n.apply(this, arguments) || this } t(e, n); var o = e.prototype; return o.start = function () { c.instance.on(h.EVENT_UPDATE_LAYER, this.onCheckLayerChild, this) }, o.onCheckLayerChild = function () { this.node && this.node.children.forEach((function (n) { n.children.length <= 0 && (console.log("layer层级没有element元素了,移除layer层----"), n.removeFromParent(), n.destroy()) })) }, o.update = function (n) { }, o.init_layer = function () { this.node.children.forEach((function (n) { n.getComponent(r).init_layer() })) }, o.init_pin = function (n) { this.node.children.forEach((function (t) { t.getComponent(r).init_pin(n) })) }, o.get_pin_color = function (n) { for (var t = this.node.children.length - 1; t >= 0; t--) { this.node.children[t].getComponent(r).get_pin_color(n) } return n }, o.get_layer = function (n) { for (var t = this.node.children.length - 1; t >= 0; t--) { var e = this.node.children[t].getComponent(r); e && n.push(e) } return n }, o.get_hole_num = function () { var n = 0; return this.node.children.forEach((function (t) { var e = t.getComponent(r).get_hole_num(); n += e })), n }, e }(i)) || a); e._RF.pop() } } }));
- System.register("chunks:///_virtual/UnitColorsSysterm.ts", ["./rollupPluginModLoBabelHelpers.js", "cc", "./CarCarColorsComponent.ts", "./PinComponent.ts", "./AliensGlobalInstance.ts", "./EventDispatcher.ts", "./GameEvent.ts", "./LevelAction.ts", "./tgx.ts", "./UITips.ts"], (function (n) { var e, t, r, o, i, s, a, c, l, h, u, C, f, p; return { setters: [function (n) { e = n.inheritsLoose, t = n.asyncToGenerator, r = n.regeneratorRuntime }, function (n) { o = n.cclegacy, i = n._decorator, s = n.find, a = n.Component }, function (n) { c = n.CarCarColorsComponent }, function (n) { l = n.PinComponent }, function (n) { h = n.AliensGlobalInstance }, function (n) { u = n.EventDispatcher }, function (n) { C = n.GameEvent }, function (n) { f = n.LevelAction }, null, function (n) { p = n.UITips }], execute: function () { var d; o._RF.push({}, "66d66fr3PFGY6ppg1RH9ywh", "UnitColorsSysterm", void 0); var g = i.ccclass; i.property, n("UnitColorsSysterm", g("UnitColorsSysterm")(d = function (n) { function o() { for (var e, t = arguments.length, r = new Array(t), o = 0; o < t; o++)r[o] = arguments[o]; return (e = n.call.apply(n, [this].concat(r)) || this).findPins = [], e.selectedCar = null, e } e(o, n); var i = o.prototype; return i.start = function () { this.registerEvent() }, i.registerEvent = function () { u.instance.on(C.EVENT_MAGNET, this.onMagnet, this) }, i.onMagnet = function () { this.findPinsCar(), this.moveToCar() }, i.findPinsCar = function () { for (var n = this, e = h.instance.levels.children[0], o = s("Canvas/Scene/Parkings").children, i = [], a = o.length; a--;)"inuse" !== o[a].name || 1 !== o[a].children.length ? "inuse" !== o[a].name || 2 !== o[a].children.length ? o[a].name : i.push(o[a].children[1]) : i.push(o[a].children[0]); if (i.length <= 0) p.show("No cars in the parking lot!"); else { this.selectedCar = i[i.length - 1]; var u = e.getComponent(f).get_all_layer().reverse(), C = 0; u.forEach((function (e) { e.node.children.forEach((function (e) { e.getComponentsInChildren(l).forEach(t(r().mark((function e(t, o) { var i, s, a; return r().wrap((function (e) { for (; ;)switch (e.prev = e.next) { case 0: i = t.getComponent(l), s = n.selectedCar.getComponent(c), a = s.getRemainSeat(), i.pin_color == s.carColor && ++C <= a && n.findPins.push(i.node); case 4: case "end": return e.stop() } }), e) })))) })) })) } }, i.moveToCar = function () { var n = this; null != this.selectedCar && this.findPins.forEach((function (e) { n.selectedCar.getComponent(c).addRole(e) })), this.clearpinsCar() }, i.findCanOutCars = function () { var n = []; s("Canvas/Scene/Levels").children[0].getComponentsInChildren(c).forEach((function (e) { var t = e.getComponent(c); if (!t.checkCollision()) for (var r = t.getRemainSeat(), o = 0; o < r; o++)n.push(t.carColor) })); for (var e = s("Canvas/Scene/Parkings").children, t = e.length; t--;)if ("inuse" !== e[t].name || 1 !== e[t].children.length) if ("inuse" !== e[t].name || 2 !== e[t].children.length); else for (var r = e[t].children[1].getComponent(c), o = r.getRemainSeat(), i = 0; i < o; i++)n.push(r.carColor); else for (var a = e[t].children[0].getComponent(c), l = a.getRemainSeat(), h = 0; h < l; h++)n.push(a.carColor); return n }, i.clearpinsCar = function () { this.selectedCar = null, this.findPins = [] }, o }(a)) || d); o._RF.pop() } } }));
- (function (r) {
- r('virtual:///prerequisite-imports/module_movecar', 'chunks:///_virtual/module_movecar');
- })(function (mid, cid) {
- System.register(mid, [cid], function (_export, _context) {
- return {
- setters: [function (_m) {
- var _exportObj = {};
- for (var _key in _m) {
- if (_key !== "default" && _key !== "__esModule") _exportObj[_key] = _m[_key];
- }
- _export(_exportObj);
- }],
- execute: function () { }
- };
- });
- });
|