From 9dd535c6b9b21474adb4a3348493fccdc0b1c6f9 Mon Sep 17 00:00:00 2001 From: TJH Date: Mon, 4 Aug 2025 10:15:01 +0800 Subject: [PATCH] =?UTF-8?q?=E5=85=8D=E8=B4=B9=E8=B5=A0=E9=80=81=E5=8A=9F?= =?UTF-8?q?=E8=83=BD=E7=BB=86=E8=8A=82=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- assets/Game/prefabs/SlotScene.prefab | 242 +++++++++++++-------------- assets/Game/scripts/SlotScene.ts | 130 +++++++++++--- assets/Game/scripts/game/SysGift.ts | 84 +++++----- assets/Loading/scripts/comm.ts | 2 +- 4 files changed, 269 insertions(+), 189 deletions(-) diff --git a/assets/Game/prefabs/SlotScene.prefab b/assets/Game/prefabs/SlotScene.prefab index ed722d5..f59cd8e 100644 --- a/assets/Game/prefabs/SlotScene.prefab +++ b/assets/Game/prefabs/SlotScene.prefab @@ -1255,7 +1255,7 @@ "__id__": 48 }, "asset": { - "__uuid__": "31e7557b-3a6b-4d2d-9daf-5a5e4b522638", + "__uuid__": "c2de34b1-99b2-49c4-a6ec-44eeb63b12cd", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -1266,7 +1266,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "edyZC6gXpDqJzAX1XSDyUV", + "fileId": "60B+NB9CtO7JuStFVpsy2Q", "prefabRootNode": { "__id__": 1 }, @@ -1292,7 +1292,7 @@ "__id__": 51 }, "asset": { - "__uuid__": "c2de34b1-99b2-49c4-a6ec-44eeb63b12cd", + "__uuid__": "09ec107b-880c-45b8-ad98-84592e637c0b", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -1303,7 +1303,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "27ick3P2dLCa+ebG7n+Gt6", + "fileId": "03IvIOaK5Jv60YgCLyMEUv", "prefabRootNode": { "__id__": 1 }, @@ -1329,7 +1329,7 @@ "__id__": 54 }, "asset": { - "__uuid__": "a4cde73d-6ad9-430a-9b55-6f16ff2da91e", + "__uuid__": "55a879b3-2ccd-48e3-bd43-c984e67f1637", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -1340,7 +1340,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "a4PK5o6xFG0Lyoo0BoFCA7", + "fileId": "18RpQbJ3NAHLS+ex1inlRu", "prefabRootNode": { "__id__": 1 }, @@ -1366,7 +1366,7 @@ "__id__": 57 }, "asset": { - "__uuid__": "5347ef5a-5046-4c36-be8f-bb27dc475204", + "__uuid__": "e218006e-19e0-486f-b9db-e13d4c1f6cad", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -1377,7 +1377,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "edDP+bLKVPa7xvxRrdQEBj", + "fileId": "a4iLgQJepI8bSyhj/Go7oE", "prefabRootNode": { "__id__": 1 }, @@ -1412,7 +1412,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "3aJrA6ZItA7qEyMRzb8WkH" + "fileId": "a0Td+hHpdCyIxnZLCQ02Yb" }, { "__type__": "cc.PrefabInfo", @@ -1422,7 +1422,7 @@ "asset": { "__id__": 0 }, - "fileId": "3azUQKiehNXpUUkxAMypD3", + "fileId": "e9RtV2WZpFjo8S71G8Q+YD", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null @@ -1453,7 +1453,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "70p9xAx2tNzZ1lC5KtYAso" + "fileId": "65M00RFZRE+440a9rsp9Cu" }, { "__type__": "cc.PrefabInfo", @@ -1463,7 +1463,7 @@ "asset": { "__id__": 0 }, - "fileId": "b5kfXC1hJA+6cspAbDV8Ec", + "fileId": "5cNaqTwUFBc6NrKtzHgw3F", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null @@ -1494,7 +1494,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "b2NItdEDtGe6MB+g18sEbg" + "fileId": "438crO3blDkZ2UzdYr6qAA" }, { "__type__": "5fc10Zl7lVO97/rr2J1uxWH", @@ -1519,7 +1519,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "c0F9gYYUpA8bmUcsFdlp1B" + "fileId": "858hPdaEBBpbaTmUOc0j0N" }, { "__type__": "5fd13+Xa69CZogb3Q/F1lnC", @@ -1692,7 +1692,7 @@ "asset": { "__id__": 0 }, - "fileId": "8fks/qkQdGkqzKge940ZKl", + "fileId": "24iiuhmWNItLhjz2qeZKlH", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null @@ -1717,7 +1717,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "e6dQa0i7VKIJjC5plV5+W/" + "fileId": "4aDk8DRtdCYa2rYzUTmNKJ" }, { "__type__": "cc.UITransform", @@ -1745,7 +1745,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "03o4ayUB1C35tdSmSSm+f6" + "fileId": "3fPppWaH9IaZvE/svVLmbE" }, { "__type__": "cc.Sprite", @@ -1790,7 +1790,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "c71XWsxFRNIJayqe1cGdYL" + "fileId": "0a/zB59gFJjZ3P9BaDuEmU" }, { "__type__": "cc.PrefabInfo", @@ -1800,7 +1800,7 @@ "asset": { "__id__": 0 }, - "fileId": "c4vcsDf11FXLSV8lsPMzMG", + "fileId": "85c9k9DqVESLvqH+17iUn9", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null @@ -2062,7 +2062,7 @@ "__id__": 88 }, "asset": { - "__uuid__": "a185ad99-a791-4309-9851-549c756647b9", + "__uuid__": "31e7557b-3a6b-4d2d-9daf-5a5e4b522638", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -2073,7 +2073,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "2dsmhB8sJHnodlSQle3mh5", + "fileId": "38HmbseoVDtah8DTKgrwEo", "prefabRootNode": { "__id__": 1 }, @@ -2099,7 +2099,7 @@ "__id__": 91 }, "asset": { - "__uuid__": "c2de34b1-99b2-49c4-a6ec-44eeb63b12cd", + "__uuid__": "e218006e-19e0-486f-b9db-e13d4c1f6cad", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -2110,7 +2110,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "e0DzDVrLxI+74EMYtC+TSp", + "fileId": "a1kT1+SWRCDLG9kt0u4QwY", "prefabRootNode": { "__id__": 1 }, @@ -2147,7 +2147,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "ae1yVo/d9KOrGWprebTnfc", + "fileId": "3eWa1A+nlEoIG0aSb3djKT", "prefabRootNode": { "__id__": 1 }, @@ -2173,7 +2173,7 @@ "__id__": 97 }, "asset": { - "__uuid__": "79c428b2-5899-404c-8495-991b407ef71b", + "__uuid__": "2c62af7c-9b93-48ff-bd76-a2dfd799659e", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -2184,7 +2184,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "fbF5ASAtRL0avxq6gyNbod", + "fileId": "6bayjDSYNFF5DCuP9erL86", "prefabRootNode": { "__id__": 1 }, @@ -2210,7 +2210,7 @@ "__id__": 100 }, "asset": { - "__uuid__": "09ec107b-880c-45b8-ad98-84592e637c0b", + "__uuid__": "79c428b2-5899-404c-8495-991b407ef71b", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -2221,7 +2221,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "5ahDBu4itObLAZtfsvoHv1", + "fileId": "dfy1nVFY9DxK2gNi3g3w8Y", "prefabRootNode": { "__id__": 1 }, @@ -2256,7 +2256,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "7dtPznv6VE575muUGUx6YN" + "fileId": "dapB3FIqxFlqCaJwgdg3OS" }, { "__type__": "cc.PrefabInfo", @@ -2266,7 +2266,7 @@ "asset": { "__id__": 0 }, - "fileId": "26HlIKMFJNYrXMdBMd2UqA", + "fileId": "1fA4S3g5NAhZkbDwsfejX/", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null @@ -2297,7 +2297,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "71rQ1FsOdFeIGy3ovbxwnY" + "fileId": "e1FIh+8V5IP6NHeCOoXFPP" }, { "__type__": "cc.PrefabInfo", @@ -2307,7 +2307,7 @@ "asset": { "__id__": 0 }, - "fileId": "2a1MaRXrxHiLM/Xn40Eoif", + "fileId": "capXuVhHdP8bgBVHJohSbo", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null @@ -2338,7 +2338,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "01ppDKrKdGj7/Wb+6ZnT8f" + "fileId": "0dXl5ctI9LGIA6lLjUejCk" }, { "__type__": "45522uB1sdFu4FJAojtnha4", @@ -2363,7 +2363,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "74R/vfaH9HWbP43hjxOWly" + "fileId": "e9LoCh7j1PU4KnJ+tHNIlE" }, { "__type__": "cc.PrefabInfo", @@ -2373,7 +2373,7 @@ "asset": { "__id__": 0 }, - "fileId": "3eECYAb4ROxI6zUIf6A2T4", + "fileId": "59FC87uDFGrp5XoR5MlNX3", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null @@ -2563,7 +2563,7 @@ "__id__": 117 }, "asset": { - "__uuid__": "5347ef5a-5046-4c36-be8f-bb27dc475204", + "__uuid__": "31e7557b-3a6b-4d2d-9daf-5a5e4b522638", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -2574,7 +2574,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "397uzG1v9N+Z8/ZaQvmOSD", + "fileId": "3409eRiMBKioitxHZQT7ly", "prefabRootNode": { "__id__": 1 }, @@ -2600,7 +2600,7 @@ "__id__": 120 }, "asset": { - "__uuid__": "a4cde73d-6ad9-430a-9b55-6f16ff2da91e", + "__uuid__": "55a879b3-2ccd-48e3-bd43-c984e67f1637", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -2611,7 +2611,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "c5e9+J3exM37IMvAtc766X", + "fileId": "36l4CT4sRLyoM5V1er/ebH", "prefabRootNode": { "__id__": 1 }, @@ -2637,7 +2637,7 @@ "__id__": 123 }, "asset": { - "__uuid__": "e50482a2-447d-46ce-91f0-488953dda75c", + "__uuid__": "f8999765-2b3b-4d22-8a12-dd5165927db7", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -2648,7 +2648,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "a3om878qpK3KEIEljUSiVC", + "fileId": "c7npQOzCVHL4VeYxecULBV", "prefabRootNode": { "__id__": 1 }, @@ -2674,7 +2674,7 @@ "__id__": 126 }, "asset": { - "__uuid__": "e50482a2-447d-46ce-91f0-488953dda75c", + "__uuid__": "c2de34b1-99b2-49c4-a6ec-44eeb63b12cd", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -2685,7 +2685,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "596FrIxtZFH6ejTOX7LrhR", + "fileId": "3eOYa/XJlJVIAtyPrd+ak5", "prefabRootNode": { "__id__": 1 }, @@ -2711,7 +2711,7 @@ "__id__": 129 }, "asset": { - "__uuid__": "f8999765-2b3b-4d22-8a12-dd5165927db7", + "__uuid__": "5347ef5a-5046-4c36-be8f-bb27dc475204", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -2722,7 +2722,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "65CQeGMKFHbaveVBm6WLmL", + "fileId": "12i+vs8IpClohh96lWatgd", "prefabRootNode": { "__id__": 1 }, @@ -2757,7 +2757,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "e5ar+nn3hMmaJdQ9vZ5lk7" + "fileId": "b5TLeaMYlL1qpucA7tGNaA" }, { "__type__": "cc.PrefabInfo", @@ -2767,7 +2767,7 @@ "asset": { "__id__": 0 }, - "fileId": "efMgLBMbFBSoeZR2LZhAVO", + "fileId": "78n9NMslZGqYmbGZWjVzI5", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null @@ -2798,7 +2798,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "17E9TQgydOyozjU5PjZzqp" + "fileId": "6fDeYNovhOaab0T8eD1EW4" }, { "__type__": "cc.PrefabInfo", @@ -2808,7 +2808,7 @@ "asset": { "__id__": 0 }, - "fileId": "e6W8iVXvlP1JF28PmgetZ7", + "fileId": "59mmZfh+RFMKT9P8u0s6v/", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null @@ -2839,7 +2839,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "f4B4HDGWlNrKsdWOhyruaE" + "fileId": "93MG3jrHZH8JK0OEjBodhF" }, { "__type__": "45522uB1sdFu4FJAojtnha4", @@ -2864,7 +2864,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "64icp9EJVKM7DW87GH1prI" + "fileId": "539J/sRI9PBK3gv1rrfFiK" }, { "__type__": "cc.PrefabInfo", @@ -2874,7 +2874,7 @@ "asset": { "__id__": 0 }, - "fileId": "8aKbcHmXlFq4g4f4plAvEW", + "fileId": "ba1B6qpSVBu7OhN7AMwFZB", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null @@ -3075,7 +3075,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "680AGjB8pDtppAbY2BH/GA", + "fileId": "f9+osh/vVAH4o6vYs9yZi2", "prefabRootNode": { "__id__": 1 }, @@ -3112,7 +3112,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "37xQ32/7pOJp7cvwGwCY6j", + "fileId": "b5lrWEGiNNt72AI4+6OoBJ", "prefabRootNode": { "__id__": 1 }, @@ -3138,7 +3138,7 @@ "__id__": 152 }, "asset": { - "__uuid__": "09ec107b-880c-45b8-ad98-84592e637c0b", + "__uuid__": "a4cde73d-6ad9-430a-9b55-6f16ff2da91e", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -3149,7 +3149,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "865vGZ/3hIgqs0ImwbfC4n", + "fileId": "20vP16IvRDq5RxR2vwSSwc", "prefabRootNode": { "__id__": 1 }, @@ -3175,7 +3175,7 @@ "__id__": 155 }, "asset": { - "__uuid__": "a0fd2fb6-af52-4b80-a9fc-93d543fa2acd", + "__uuid__": "31e7557b-3a6b-4d2d-9daf-5a5e4b522638", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -3186,7 +3186,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "f43Q9Z0eBO1IOICcQc60qG", + "fileId": "e23WJ11GRNkqLekKuhj5vl", "prefabRootNode": { "__id__": 1 }, @@ -3212,7 +3212,7 @@ "__id__": 158 }, "asset": { - "__uuid__": "c2de34b1-99b2-49c4-a6ec-44eeb63b12cd", + "__uuid__": "31e7557b-3a6b-4d2d-9daf-5a5e4b522638", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -3223,7 +3223,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "65jWHpduZCa5wYpeakHHJm", + "fileId": "84CHoDsX1KULGEDsmGuioc", "prefabRootNode": { "__id__": 1 }, @@ -3258,7 +3258,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "93WeKhjlZKuKYK0zla+qYG" + "fileId": "ac6W4Z2WBDnJPZCAUIkhdo" }, { "__type__": "cc.PrefabInfo", @@ -3268,7 +3268,7 @@ "asset": { "__id__": 0 }, - "fileId": "04/Smhf0ZNqK0H8QQwC62b", + "fileId": "84/fS9Iw5JpLSVJk9sWh8O", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null @@ -3299,7 +3299,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "0bp+Wjp+pB96WyWglDCuNm" + "fileId": "58cPSigkpNz7zMYNrxzTyo" }, { "__type__": "cc.PrefabInfo", @@ -3309,7 +3309,7 @@ "asset": { "__id__": 0 }, - "fileId": "e2O3vkCmpFdbJrpMpniFxe", + "fileId": "a39yMjQlFGnpRDq7s8923f", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null @@ -3340,7 +3340,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "0atooVlBBPcb4cFS7cSL2X" + "fileId": "b93sO3A4VJH7vmE2cJZf+6" }, { "__type__": "45522uB1sdFu4FJAojtnha4", @@ -3365,7 +3365,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "2drKZfwAFIbpn6OKvyEnDI" + "fileId": "eeSDv08bVK3YSuLsRxX4nC" }, { "__type__": "cc.PrefabInfo", @@ -3375,7 +3375,7 @@ "asset": { "__id__": 0 }, - "fileId": "e35+O3t0xAU4C6uOsa/eg1", + "fileId": "d2nFEXIaFE6L6BxjLDy+5q", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null @@ -3565,7 +3565,7 @@ "__id__": 175 }, "asset": { - "__uuid__": "e50482a2-447d-46ce-91f0-488953dda75c", + "__uuid__": "a4cde73d-6ad9-430a-9b55-6f16ff2da91e", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -3576,7 +3576,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "225/w1un5PD77/4w60rm+w", + "fileId": "3e9wGuBIFCf5CF/dRCbm0/", "prefabRootNode": { "__id__": 1 }, @@ -3613,7 +3613,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "d9WNhCVjBOu5A7VrmLNJB2", + "fileId": "9dYRE5MuhAjLccjRYjSKtj", "prefabRootNode": { "__id__": 1 }, @@ -3639,7 +3639,7 @@ "__id__": 181 }, "asset": { - "__uuid__": "55a879b3-2ccd-48e3-bd43-c984e67f1637", + "__uuid__": "09ec107b-880c-45b8-ad98-84592e637c0b", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -3650,7 +3650,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "fcad+GhTZJOZQkCSgPsBGM", + "fileId": "99Fqjz43xH0YVWSOgPPE40", "prefabRootNode": { "__id__": 1 }, @@ -3676,7 +3676,7 @@ "__id__": 184 }, "asset": { - "__uuid__": "5347ef5a-5046-4c36-be8f-bb27dc475204", + "__uuid__": "55a879b3-2ccd-48e3-bd43-c984e67f1637", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -3687,7 +3687,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "d7GWuVMIBEULb2H9IDWq1P", + "fileId": "b97SdYln5Ggb7w7mcKUr1l", "prefabRootNode": { "__id__": 1 }, @@ -3713,7 +3713,7 @@ "__id__": 187 }, "asset": { - "__uuid__": "c2de34b1-99b2-49c4-a6ec-44eeb63b12cd", + "__uuid__": "55a879b3-2ccd-48e3-bd43-c984e67f1637", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -3724,7 +3724,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "3eJEN50eFDkpaSt9PGqmQm", + "fileId": "31ciY0bTdKr5vwVvU8oDXJ", "prefabRootNode": { "__id__": 1 }, @@ -3759,7 +3759,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "c2ux6xk3xKgK9A+alLNEum" + "fileId": "4dAVT80jpFL4vbMdsrLBmt" }, { "__type__": "cc.PrefabInfo", @@ -3769,7 +3769,7 @@ "asset": { "__id__": 0 }, - "fileId": "75qevR81hKxou595BOnu7M", + "fileId": "425IAvx11Huaclh5FtU/Ay", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null @@ -3800,7 +3800,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "13D/ycr1BPJrmxRjcnnfix" + "fileId": "7f+ELMcG5BobYaQZwrlNDI" }, { "__type__": "cc.PrefabInfo", @@ -3810,7 +3810,7 @@ "asset": { "__id__": 0 }, - "fileId": "e1xS+uVwVPl4M1c+rabQUe", + "fileId": "e6KRXEBR9J94LOAm4LTM7O", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null @@ -3841,7 +3841,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "e00qbgbTlNBIWItLa9am84" + "fileId": "78+Ex2guJAzLSFEuitLtvn" }, { "__type__": "45522uB1sdFu4FJAojtnha4", @@ -3866,7 +3866,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "98a9Sp/klDzZIeSNAGlfAP" + "fileId": "c5zPLp0/JOuaDxLFWJ92NE" }, { "__type__": "cc.PrefabInfo", @@ -3876,7 +3876,7 @@ "asset": { "__id__": 0 }, - "fileId": "689pN2xXNPtZrdt+zBRKlv", + "fileId": "25nIY/F5lK0LmR912djCzc", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null @@ -4066,7 +4066,7 @@ "__id__": 204 }, "asset": { - "__uuid__": "e218006e-19e0-486f-b9db-e13d4c1f6cad", + "__uuid__": "09ec107b-880c-45b8-ad98-84592e637c0b", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -4077,7 +4077,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "8far8rRA9JZLVkbdu6zBtz", + "fileId": "aaxv9MmFRC05L2JVEZxZUr", "prefabRootNode": { "__id__": 1 }, @@ -4103,7 +4103,7 @@ "__id__": 207 }, "asset": { - "__uuid__": "a185ad99-a791-4309-9851-549c756647b9", + "__uuid__": "09ec107b-880c-45b8-ad98-84592e637c0b", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -4114,7 +4114,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "d3CQec15ZNKJdinZl1jIvB", + "fileId": "29E0am2qBAIIYy9baUZq3f", "prefabRootNode": { "__id__": 1 }, @@ -4140,7 +4140,7 @@ "__id__": 210 }, "asset": { - "__uuid__": "f8999765-2b3b-4d22-8a12-dd5165927db7", + "__uuid__": "09ec107b-880c-45b8-ad98-84592e637c0b", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -4151,7 +4151,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "e6/sFZ+KhKdq0Ca8teUh+9", + "fileId": "06uTDrkZ1BIKF2IWkenDT+", "prefabRootNode": { "__id__": 1 }, @@ -4177,7 +4177,7 @@ "__id__": 213 }, "asset": { - "__uuid__": "09ec107b-880c-45b8-ad98-84592e637c0b", + "__uuid__": "e218006e-19e0-486f-b9db-e13d4c1f6cad", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -4188,7 +4188,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "d3Yf+CtxVCtKLYZaJrMKQM", + "fileId": "5cGICXSqRNj4+WrpRPdBm/", "prefabRootNode": { "__id__": 1 }, @@ -4214,7 +4214,7 @@ "__id__": 216 }, "asset": { - "__uuid__": "09ec107b-880c-45b8-ad98-84592e637c0b", + "__uuid__": "a185ad99-a791-4309-9851-549c756647b9", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -4225,7 +4225,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "98aYz94mFE7K4IF492PY6+", + "fileId": "bfYIgHTVJO85YiGPcEiy3P", "prefabRootNode": { "__id__": 1 }, @@ -4260,7 +4260,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "27wczlQq5F56UPzqrAxTF2" + "fileId": "8fAa0EyRtMUqOM4LH7GYTA" }, { "__type__": "cc.PrefabInfo", @@ -4270,7 +4270,7 @@ "asset": { "__id__": 0 }, - "fileId": "c0/HjywB1J7YpaclACoVTx", + "fileId": "5c7ELprg9EoIwvQKQl9wHH", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null @@ -4301,7 +4301,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "d6qa4+qwtIsYLDr41LLLzl" + "fileId": "cbVPtdwJ5DBroECLuXz3xt" }, { "__type__": "cc.PrefabInfo", @@ -4311,7 +4311,7 @@ "asset": { "__id__": 0 }, - "fileId": "1advgpd2hOVpF7pXdBJ163", + "fileId": "33+iAvSphC646GLZUI+nYO", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null @@ -4342,7 +4342,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "17eH+JfpJM8KJm1/hp3bS/" + "fileId": "238b17e6VPd4FCF6cCZG7W" }, { "__type__": "45522uB1sdFu4FJAojtnha4", @@ -4367,7 +4367,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "321+kgpw1LFL+VcUAafdgR" + "fileId": "dbpDGYl5BBi7qb3EdFJKa+" }, { "__type__": "cc.PrefabInfo", @@ -4377,7 +4377,7 @@ "asset": { "__id__": 0 }, - "fileId": "682L5Q/HJGnoxfc+T2V16o", + "fileId": "28CTp2OERP2qg1kAxyHqTl", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null @@ -4567,7 +4567,7 @@ "__id__": 233 }, "asset": { - "__uuid__": "79c428b2-5899-404c-8495-991b407ef71b", + "__uuid__": "a0fd2fb6-af52-4b80-a9fc-93d543fa2acd", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -4578,7 +4578,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "2e5MuDXRlAJK77z8SXPq8E", + "fileId": "e4IFMkvz5KHZpHjaDRj0k+", "prefabRootNode": { "__id__": 1 }, @@ -4604,7 +4604,7 @@ "__id__": 236 }, "asset": { - "__uuid__": "5347ef5a-5046-4c36-be8f-bb27dc475204", + "__uuid__": "a4cde73d-6ad9-430a-9b55-6f16ff2da91e", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -4615,7 +4615,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "afdW+qaGhObKUr63xhTo2p", + "fileId": "44oKfPnNFPEa+ePO+lANuy", "prefabRootNode": { "__id__": 1 }, @@ -4641,7 +4641,7 @@ "__id__": 239 }, "asset": { - "__uuid__": "09ec107b-880c-45b8-ad98-84592e637c0b", + "__uuid__": "e50482a2-447d-46ce-91f0-488953dda75c", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -4652,7 +4652,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "22BEOm/AdIi6zMJI1Zw/Hi", + "fileId": "09rnGwEPlA7JCuDkycMpmU", "prefabRootNode": { "__id__": 1 }, @@ -4678,7 +4678,7 @@ "__id__": 242 }, "asset": { - "__uuid__": "e50482a2-447d-46ce-91f0-488953dda75c", + "__uuid__": "5347ef5a-5046-4c36-be8f-bb27dc475204", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -4689,7 +4689,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "8cNkdSXrlKzoiRBD0kSpXj", + "fileId": "d18unNL9tNT7dsVIMmoeLQ", "prefabRootNode": { "__id__": 1 }, @@ -4715,7 +4715,7 @@ "__id__": 245 }, "asset": { - "__uuid__": "e218006e-19e0-486f-b9db-e13d4c1f6cad", + "__uuid__": "a185ad99-a791-4309-9851-549c756647b9", "__expectedType__": "cc.Prefab" }, "fileId": "fchELCmEtHhb3lT1fagDGR", @@ -4726,7 +4726,7 @@ }, { "__type__": "cc.PrefabInstance", - "fileId": "4fyMTknlVLHoajPf9gdyye", + "fileId": "9f/lSmgvZBb6kJTYQK0H39", "prefabRootNode": { "__id__": 1 }, @@ -4761,7 +4761,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "14UR2QYnlCN79VGbp//5bz" + "fileId": "edVkhyVyRITqXCBO4mZmCa" }, { "__type__": "cc.PrefabInfo", @@ -4771,7 +4771,7 @@ "asset": { "__id__": 0 }, - "fileId": "bdl+tkiS1JppZm7Bw35KPi", + "fileId": "24EQU2l9ZA0J6ehvOHqEyj", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null @@ -4802,7 +4802,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "74dpJmRYNKzKxi1bx38h0b" + "fileId": "c6eip2ouVDIYFaUHQ1YwLW" }, { "__type__": "cc.PrefabInfo", @@ -4812,7 +4812,7 @@ "asset": { "__id__": 0 }, - "fileId": "ebjNBQYgxPhoPevzbqfQ8T", + "fileId": "53hS15IrZCHbqTjX3Ae0Nh", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null @@ -4843,7 +4843,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "dfu/ShxTZBzpm7O4yueS7g" + "fileId": "6ew5S7c1VMFI00lNWj7V+g" }, { "__type__": "45522uB1sdFu4FJAojtnha4", @@ -4868,7 +4868,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "8dfsHFRthE366RnOIVs2a8" + "fileId": "7b+/qgNxdLsJyh05LAPYmr" }, { "__type__": "cc.PrefabInfo", @@ -4878,7 +4878,7 @@ "asset": { "__id__": 0 }, - "fileId": "922McXvAhBEqXZRNiHTZdX", + "fileId": "51CFhX/bFMoZ98SNK6F+QR", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null @@ -4903,7 +4903,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "5bW1ww1tlBHoBagEm2QdPh" + "fileId": "b08OScNzlJjJRu377WU6RL" }, { "__type__": "cc.UITransform", @@ -4931,7 +4931,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "c9y/fmAnFHnpowY5hdwyq7" + "fileId": "ccuDkAoJxKl6YXBvxPFd0T" }, { "__type__": "cc.Sprite", @@ -4976,7 +4976,7 @@ }, { "__type__": "cc.CompPrefabInfo", - "fileId": "55tuVn8ThN4bqgc3Tt1gq8" + "fileId": "ffk5xN+KRLQJcZc9QYoucK" }, { "__type__": "cc.PrefabInfo", @@ -4986,7 +4986,7 @@ "asset": { "__id__": 0 }, - "fileId": "e2y1ztB75IUqft5yQoynlt", + "fileId": "dbhGM9kpRHeK3TUHUFym7U", "instance": null, "targetOverrides": null, "nestedPrefabInstanceRoots": null diff --git a/assets/Game/scripts/SlotScene.ts b/assets/Game/scripts/SlotScene.ts index 79393f1..4c2214f 100644 --- a/assets/Game/scripts/SlotScene.ts +++ b/assets/Game/scripts/SlotScene.ts @@ -19,11 +19,13 @@ let { ccclass, property } = _decorator; // 游戏状态接口 interface GameState { + isOnReconnect: boolean; isAutoSpin: boolean; isEliminating: boolean; isFastSpin: boolean; isFirstFreeSpin: boolean; isInFreeSpin: boolean; + isOneRoundEnd: boolean; isDebug: boolean; } @@ -77,11 +79,13 @@ export class SlotScene extends Component { // 游戏状态管理 private gameState: GameState = { + isOnReconnect: false, isAutoSpin: false, isEliminating: false, isFastSpin: false, isFirstFreeSpin: false, isInFreeSpin: false, + isOneRoundEnd: false, isDebug: false }; @@ -142,29 +146,44 @@ export class SlotScene extends Component { // 处理断线重连 private async handleReconnect() { + this.gameState.isOnReconnect = true; + this.gameState.isOneRoundEnd = false; this.slotGame.showWinScore(false, false, false, false, false); - // 设置滚轮规则 let mode = this.gameInfo.Data.Mode; let rollerIconRule = mode == 0 ? ROLLER_RULE : FREE_SPIN_ROLLER_RULE; this.checkHasGame(); + this.checkHasEliminate() if (this.gameState.isInFreeSpin) { this.slotBar.enterFreeSpin(this.spinData.FreeSpin.LeftCount); } - this.slotBar.reconnectState(true); - this.slotGame.changeBg(this.gameState.isInFreeSpin); if (this.gameState.isInFreeSpin) { AudioManager.instance.playBGM('Free_Mode_BGM'); } else { AudioManager.instance.playBGM('Normal_Mode_BGM'); } - this.slotGame.setWaysCount(this.spinData.WaysNum); this.slotGame.setMultiLabel(this.spinData.WinMultiPlier); this.slotGame.setRollerIconRule(rollerIconRule); + + + let frb = GameDataManager.instance.frb; + if (frb && frb.Ongoing?.Popup) { + let frb = GameDataManager.instance.frb; + if (frb && (frb.Finished || frb.Ongoing)) { + this.slotBar.systemGiftContinue(); + } + this.SysGift.showOngingPopup(); + } else { + this.goNextReconnect(false); + } + } + + goNextReconnect(isTwice: boolean) { + if (isTwice) return; // 当前盘面有分数,有消除,则播放消除动画 if (this.spinData.Score != 0 && this.spinData.WinPosition != null) { this.slotGame.deleteIconNode(); @@ -174,9 +193,11 @@ export class SlotScene extends Component { } } + clickFeatureBuy() { if (this.gameState.isInFreeSpin) return; if (this.gameState.isEliminating) return; + if (!this.gameState.isOneRoundEnd) return; if (this.slotGame.isScroll()) return; AudioManager.instance.playSFX('Feature_Buy_Sound'); let panel = NodePoolManager.instance.getNodeFromPoolStatic('FeatureBuy', this.FeatureBuyPre); @@ -190,18 +211,29 @@ export class SlotScene extends Component { async spinBtnClick(isFreeSpin: boolean = false, isFeatureBuy: boolean = false) { try { + this.gameState.isOnReconnect = false; this.isReceiveMsg = false; + this.slotGame.spin(this.gameState.isInFreeSpin); + this.gameState.isOneRoundEnd = false; this.slotGame.changeBg(this.gameState.isInFreeSpin); this.slotGame.hideIconMsg(); + if (!isFreeSpin) { + this.slotBar.setWin(0); + } + // 如果有frb就不会扣除金额 let frb = GameDataManager.instance.frb; - if (frb && (frb.Ongoing != null || frb.Finished != null)) { - + if (frb && frb.Ongoing != null) { + if (!isFreeSpin) { + let count = frb.Ongoing.Frn - 1; + if (count <= 0) { + count = 0; + } + this.SysGift.handleSysInfoFreeCount(count); + } } else { if (!isFreeSpin) { - this.slotBar.setWin(0); - if (!isFeatureBuy) { this.slotBar.setBalance(this.slotBar.getBalance() - this.slotBar.getBet()); } else { @@ -226,7 +258,17 @@ export class SlotScene extends Component { if (!this.gameState.isDebug) { this.spinInfo = await callGameApi("spin", msg); + if (this.spinInfo.Frb.Ongoing) { + if (this.gameState.isAutoSpin) { + this.slotBar.closeAutoSpin(); + } + } + GameDataManager.instance.frb = this.spinInfo.Frb; + // if (frb?.Ongoing?.Frn - 1 != GameDataManager.instance.frb?.Ongoing?.Frn) { + // this.SysGift.handleSysInfoFreeCount(this.spinInfo.Frb.Ongoing.Frn); + // } + } else { this.spinInfo = winTestData; } @@ -304,19 +346,20 @@ export class SlotScene extends Component { } } - private onAutoSpinClick(isAuto: boolean) { + private onAutoSpinClick(isAuto: boolean, isReconnect: boolean) { this.gameState.isAutoSpin = isAuto; this.autoSpinConfig.count = GameDataManager.instance.autoCount; // 只有在不旋转的时候才可以设置自动旋转,所以不需要额外处理 if (isAuto) { - this.checkAutoSpin(); + this.checkAutoSpin(false, isReconnect); } } - private checkAutoSpin(hasWin: boolean = false) { + private checkAutoSpin(hasWin: boolean = false, isReconnect: boolean) { // 处理自动旋转 let handleAutoSpin = () => { + this.gameState.isOneRoundEnd = true; if (this.autoSpinConfig.count > 0) { this.autoSpinConfig.count--; this.slotBar.setLeftAutoCount(this.autoSpinConfig.count); @@ -329,19 +372,40 @@ export class SlotScene extends Component { } // 处理自动旋转已经走到最后一步了和当前一轮流程走完最后的逻辑 - let handleNonAutoSpin = (hasWin: boolean) => { + let handleNonAutoSpin = (hasWin: boolean, isReconnect: boolean) => { let delay = hasWin ? 1 : 0; this.scheduleOnce(() => { - this.slotBar.resetAllState(); - let frb = GameDataManager.instance.frb; - if (frb && (frb.Finished || frb.Ongoing)) { - this.slotBar.systemGiftContinue(); - this.SysGift.handleSpinInfo(); + if (frb.Finished?.Popup) { + this.SysGift.showSysFreeWinSettle(); + } + + if (frb.Ongoing?.Popup) { + this.SysGift.showOngingPopup(); + } + + if (frb.Finished == null && frb.Ongoing?.Popup == false) { + this.slotBar.resetAllState(); + if (frb && (frb.Finished || frb.Ongoing)) { + this.slotBar.systemGiftContinue(); + this.SysGift.handleSysInfoFreeWin(); + } + } + + if (frb.Finished == null && frb.Ongoing == null) { + this.slotBar.resetAllState(); + this.gameState.isOneRoundEnd = true; } + if (frb.Ongoing?.Popup) { + this.slotBar.resetAllState(); + this.slotBar.systemGiftContinue(); + } + + this.gameState.isOnReconnect = false; }, delay); + this.autoSpinConfig.count = 0; } @@ -359,7 +423,7 @@ export class SlotScene extends Component { handleAutoSpin(); }, delay); } else { - handleNonAutoSpin(hasWin); + handleNonAutoSpin(hasWin, isReconnect); } } @@ -553,14 +617,13 @@ export class SlotScene extends Component { let winType = this.slotGame.checkWinType(this.spinData.AllScore); await this.handleWinResult(winType, isReconnect, false, () => { - this.checkAutoSpin(winType !== WIN_TYPE.NONE); + this.checkAutoSpin(winType !== WIN_TYPE.NONE, isReconnect); }); } private async freeSpinStop(isReconnect: boolean = false) { let leftCount = this.spinData.FreeSpin.LeftCount; - if (leftCount >= 1) { let score = 0; if (this.spinData.RoundInfo != null) { @@ -618,7 +681,7 @@ export class SlotScene extends Component { this.slotGame.showWinScore(true, false, true, isReconnect, false, this.spinData.AllScore); this.slotBar.setWin(this.spinData.AllScore); this.slotGame.changeBg(false); - this.checkAutoSpin(true); + this.checkAutoSpin(true, isReconnect); AudioManager.instance.playBGM('Normal_Mode_BGM'); }); } else { @@ -626,12 +689,12 @@ export class SlotScene extends Component { this.slotBar.setWin(this.spinData.AllScore); this.slotBar.setBalance(this.spinData.Balance); this.slotGame.changeBg(false); - this.checkAutoSpin(true); + this.checkAutoSpin(true, isReconnect); AudioManager.instance.playBGM('Normal_Mode_BGM'); } } else { - this.checkAutoSpin(true); + this.checkAutoSpin(true, isReconnect); this.slotGame.changeBg(false); } } @@ -787,14 +850,35 @@ export class SlotScene extends Component { } onSysGiftClickContinue(bet: number) { + this.gameState.isOnReconnect = false; + // 获取frb对象,并将其Ongoing.Popup设为false + let frb = GameDataManager.instance.frb; + if (frb && frb.Ongoing) { + frb.Ongoing.Popup = false; + } + this.goNextReconnect(false); this.slotBar.systemGiftContinue(); this.slotBar.setSysGiftBet(bet * 10000); this.slotGame.setFeatureBuyInteractable(false); + } + // 进入游戏判断 + // 1.是否有免费赠送, + // 2.如果有免费赠送 ,弹出窗口,继续游戏 + + // 1.当前游戏正在进行中 + // 2.收到赠送消息,这时候在消息的最后一步,需要弹出窗口。 + onSysGiftSettleContinue() { + let frb = GameDataManager.instance.frb; + if (frb && frb.Finished) { + frb.Finished.Popup = false; + } this.slotBar.systemGiftConfirm(); this.slotGame.setFeatureBuyInteractable(true); + this.slotBar.resetAllState(); + this.gameState.isOneRoundEnd = true; } } diff --git a/assets/Game/scripts/game/SysGift.ts b/assets/Game/scripts/game/SysGift.ts index 4bfbb20..0eda00c 100644 --- a/assets/Game/scripts/game/SysGift.ts +++ b/assets/Game/scripts/game/SysGift.ts @@ -30,22 +30,6 @@ export class SysGift extends Component { this.hideAll(); } - protected start(): void { - this.hideAll(); - let frb = GameDataManager.instance.frb - if (frb && frb.Ongoing) { - this.fixedBet = frb.Ongoing.Bet - if (frb.Ongoing?.Popup == true) { - - this.confirm.getChildByName("count").getComponent(Label).string = frb.Ongoing.Frn.toLocaleString() - - this.node.active = true - this.show(this.confirm) - } - } - } - - hideAll() { this.confirm.active = false this.settle.active = false @@ -58,7 +42,7 @@ export class SysGift extends Component { this.hide(this.confirm) let frb = GameDataManager.instance.frb - if(!frb) return; + if (!frb) return; let txt_spin_num = this.info.getChildByName("count") txt_spin_num.getComponent(Label).string = (frb.Ongoing.Frn.toLocaleString()) @@ -83,53 +67,65 @@ export class SysGift extends Component { } onClickConfirm() { - this.hide(this.settle) + this.hide(this.settle); this.node.emit(SYS_GIFT.SETTLE_CONTINUE); } - handleSpinInfo() { - let frb = GameDataManager.instance.frb - if(!frb) return; - if (frb.Finished?.Popup) { + /** 打开confirm的弹窗 */ + showOngingPopup() { + if (this.confirm.active) return; + let frb = GameDataManager.instance.frb; + if (!frb) return; + this.fixedBet = frb.Ongoing.Bet + if (frb.Ongoing.Popup) { + this.confirm.getChildByName("count").getComponent(Label).string = frb.Ongoing.Frn.toLocaleString() + this.show(this.confirm); + } + } - let win = this.settle.getChildByName("win") - let num = Math.round(frb.Finished.Fra * 100 + 1e-6) / 100 + + /** 打开settle的win */ + showSysFreeWinSettle() { + let frb = GameDataManager.instance.frb; + if (!frb) return; + if (frb.Finished?.Popup) { + let win = this.settle.getChildByName('win'); + let num = Math.round(frb.Finished.Fra * 100 + 1e-6) / 100; win.getComponent(Label).string = num.toLocaleString('en-US', { minimumFractionDigits: 2, maximumFractionDigits: 2 }) - - this.show(this.settle) - - this.info.active = false + this.show(this.settle); + this.info.active = false; } + } - if (frb.Ongoing?.Popup) { - this.fixedBet = frb.Ongoing.Bet - if (frb.Ongoing.Popup) { - this.confirm.getChildByName("count").getComponent(Label).string = frb.Ongoing.Frn.toLocaleString() - this.show(this.confirm) - } + /** 设置info的count */ + handleSysInfoFreeCount(countNum: number) { + let frb = GameDataManager.instance.frb; + if (!frb) return; + if (frb.Finished == null) { + let count = this.info.getChildByName('count'); + count.getComponent(Label).string = (countNum).toLocaleString(); + this.show(count); } + } + + /** 设置info的win */ + handleSysInfoFreeWin() { + let frb = GameDataManager.instance.frb; + if (!frb) return; if (frb.Finished == null && frb.Ongoing?.Popup == false) { - - let count = this.info.getChildByName("count") - count.getComponent(Label).string = frb.Ongoing.Frn.toLocaleString() - this.show(count) - let win = this.info.getChildByName("win") let num = Math.round(frb.Ongoing.Fra * 100 + 1e-6) / 100 win.getComponent(Label).string = num.toLocaleString('en-US', { minimumFractionDigits: 2, maximumFractionDigits: 2 }) - this.show(win) - - this.info.active = true + this.show(win); + this.info.active = true; } - - this.node.active = true } show(node: Node, scale: number = 1) { diff --git a/assets/Loading/scripts/comm.ts b/assets/Loading/scripts/comm.ts index 1b90056..f1c80bb 100644 --- a/assets/Loading/scripts/comm.ts +++ b/assets/Loading/scripts/comm.ts @@ -7,7 +7,7 @@ import { PREVIEW } from "cc/env" const gameId = "rp_10003"; // let apiaddr = "https://rpgames-api.rpfafafahkdev.com"; let apiaddr = ""; -let token = "eyJQIjoxMDA5NDksIkUiOjE3NTMzMDA3ODIsIlMiOjk5NywiRCI6InJwXzEwMDAzIn0.ShFl3rCL5UPd5QmY797X2msHnSWLDW4W-1AqPUQCxDc"; +let token = "eyJQIjoxMDIyNDksIkUiOjE3NTQzMTU2NTQsIlMiOjEwMDEsIkQiOiJycF8xMDAwMyJ9.dLje43B9JF1J5BEosXpadwjiv_0HgQzPjGZzRMDSxOI"; let language = "en" let currency = "THB" let supportUrl = ""