倍率显示动画的修改

This commit is contained in:
TJH 2026-04-22 15:20:51 +08:00
parent 5365884190
commit 48d25fbeb6
28 changed files with 5662 additions and 5799 deletions

View File

@ -467,7 +467,7 @@
},
{
"__type__": "cc.CompPrefabInfo",
"fileId": "ef0vHgVmRPXKsAmgH3DxG6"
"fileId": "96LZuDoBNP+6qegZOp++Je"
},
{
"__type__": "sp.Skeleton",
@ -512,7 +512,7 @@
},
{
"__type__": "cc.CompPrefabInfo",
"fileId": "24TQjxadlK3LgLd1rx0Ohr"
"fileId": "13zQuQcJxERaYB97zbxMNw"
},
{
"__type__": "cc.PrefabInfo",
@ -522,7 +522,7 @@
"asset": {
"__id__": 0
},
"fileId": "63b/FbdZZDgI8CHIKWf9bZ",
"fileId": "7en/thVdREoox32Kh3WWwU",
"instance": null,
"targetOverrides": null,
"nestedPrefabInstanceRoots": null

View File

@ -417,7 +417,7 @@ export class SlotBar extends Component {
onClickSpin(event, buyType: number = 0, changeDiff: boolean = false) {
if (!this.hasClickSpin && !this.hasClickManualStop) {
AudioManager.instance.playSFX("Click_Spin");
this.node.emit(SLOT_BAR_EVENT.ON_SPIN_CLICK, buyType, changeDiff);
this.node.emit(SLOT_BAR_EVENT.ON_SPIN_CLICK, buyType, changeDiff, true);
this.firstClickSpinState();
}
// 第二次手动停止

View File

@ -201,11 +201,17 @@ export class SlotGame extends Component {
.start();
}
setFreeTotalMulti(mul: number) {
this.node.getChildByPath('FreeGameBg1/totalMulti').getComponent(Label).string = mul > 1 ? 'x' + mul : ''
}
updateGameBg(isFreeGame: boolean) {
this.normalGameBg.active = !isFreeGame;
this.freeGameBg.active = isFreeGame;
this.node.getChildByName('NormalGameBg1').active = !isFreeGame;
this.node.getChildByName('FreeGameBg1').active = isFreeGame;
this.setFreeTotalMulti(this.spinData.WinMultiPlier)
this.refreshBuyBtnState(isFreeGame);

View File

@ -114,8 +114,12 @@ export class SlotMsg extends Component {
tweenFun();
}
setTotaleMulti(mul: number) {
this.currTotaleMulti = mul
}
showTotalWinAnimaiton(startScore: number, endScore: number, cb) {
this.currTotaleMulti = 0
this.smallMsgSpine.node.active = false;
this.middleMsgSpine.node.active = false;
@ -143,7 +147,7 @@ export class SlotMsg extends Component {
.to(0.2, { scale: v3(1, 1, 1) })
.start()
this.scheduleOnce(() => {
this.node.getChildByName('totalMulti').getComponent(Label).string = '';
director.getScene()?.getComponentInChildren(SlotGame).setFreeTotalMulti(1)
if (cb) cb();
}, 1)
})
@ -265,7 +269,7 @@ export class SlotMsg extends Component {
// 这部分run内部就是完整的队列模式所有动画/节点操作都是await同步执行
let run = async () => {
// 1. 确认总倍率节点,并首先飞入信息栏
let centerMulNode = this.node.getChildByName('totalMulti');
let centerMulNode = slotGame.node.getChildByPath('FreeGameBg1/totalMulti');
// this.node.addChild(centerMulNode);
// centerMulNode.setPosition(centerLocalPos);
// centerMulNode.setScale(1, 1, 1);
@ -274,8 +278,8 @@ export class SlotMsg extends Component {
//总倍率有值时要第一个参与倍率计算
if (this.currTotaleMulti > 0) {
let flyNode = instantiate(centerMulNode)
this.node.addChild(flyNode)
flyNode.setPosition(centerMulNode.getPosition())
this.node.addChild(flyNode)
await tweenToAsync(flyNode, centerLocalPos, 0.6);
flyNode.destroy()
this.showRoundWinMsg(1, this.currTotaleMulti)
@ -330,9 +334,22 @@ export class SlotMsg extends Component {
// centerMulNode.destroy();
// 5. 展示最终总分获胜弹窗和新的总倍率
let showCurrMulti = () => {
return new Promise<void>((resolve) => {
this.setTotaleMulti(sumMul)
let totalMultiBgSpin = slotGame.node.getChildByPath('FreeGameBg1/qiu')
tween(totalMultiBgSpin)
.to(0.2, { scale: v3(1.2, 1.2, 1) })
.to(0.2, { scale: v3(1, 1, 1) })
.call(() => {
slotGame.setFreeTotalMulti(this.currTotaleMulti)
resolve()
})
.start()
});
}
if (spinData.IsFree) {
this.currTotaleMulti = sumMul
setMulText(centerMulNode, this.currTotaleMulti)
await showCurrMulti()
}
this.showTotalWinMsg(multiedScore);

View File

@ -151,6 +151,8 @@ export class SlotScene extends Component {
}
async handleReconnect() {
this.slotMsg.setTotaleMulti(this.spinData.WinMultiPlier)
if (this.hasEliminate) {
this.slotBar.manualStop(this.hasEliminate);
this.slotGame.playIconWinAni(this.spinData);
@ -174,7 +176,7 @@ export class SlotScene extends Component {
this.slotBar.setDisplayBet(displayBet);
}
async onClickSpin(buyType: number = 0, changeDiff: boolean = false) {
async onClickSpin(buyType: number = 0, changeDiff: boolean = false, isNewSpin: boolean) {
GameDataManager.instance.canClickIconMsg = false;
this.nextSpinInfo = null;
this.nextSpinInfoPromise = null;
@ -184,6 +186,9 @@ export class SlotScene extends Component {
this.slotGame.startScroll(this.isFreeSpin);
// 重置
this.slotMsg.hideWinSpine();
if (isNewSpin) {
this.slotMsg.setTotaleMulti(0)
}
if (!this.isFreeSpin) { this.slotBar.setWin(0); }
let msg = !this.isFeatureBuySpin && buyType == 0 ?
@ -306,7 +311,7 @@ export class SlotScene extends Component {
this.slotBar.setLeftAutoCount(this.autoSpinConfig.count);
this.slotBar.hasClickSpin = false;
this.slotBar.hasClickManualStop = false;
this.onClickSpin(0, false);
this.onClickSpin(0, false, true);
if (this.autoSpinConfig.count === 0) {
this.slotBar.closeAutoSpin();
}
@ -359,7 +364,7 @@ export class SlotScene extends Component {
onFeatureBuy() {
this.isFeatureBuySpin = true;
this.slotBar.featureBuySpin();
this.onClickSpin(1, false);
this.onClickSpin(1, false, true);
}
async allRollerStop() {
@ -708,7 +713,7 @@ export class SlotScene extends Component {
this.isFreeSpin = true;
this.slotBar.setLeftCount(leftCount);
this.onClickSpin(0, false);
this.onClickSpin(0, false, false);
this.slotBar.node.getChildByName("stopBtn").active = true;
}

File diff suppressed because it is too large Load Diff

View File

@ -2,7 +2,7 @@
"ver": "1.2.0",
"importer": "directory",
"imported": true,
"uuid": "e65f84fc-4bfd-413b-a14e-f95261e34bac",
"uuid": "7ff63d06-428f-490d-a4a0-119ad8c5464e",
"files": [],
"subMetas": {},
"userData": {}

View File

@ -2,7 +2,7 @@
"ver": "1.0.0",
"importer": "*",
"imported": true,
"uuid": "a6ea9ccc-636d-4bb0-a88e-395eea5f78e2",
"uuid": "cc4cd8e2-52a9-466a-a3e7-63b564c5a4c3",
"files": [
".atlas",
".json"

View File

@ -2,7 +2,7 @@
"ver": "1.2.6",
"importer": "spine-data",
"imported": true,
"uuid": "d62a8256-af0c-4b19-881a-5b853fedc053",
"uuid": "99118768-e5f4-4766-a85f-31671b2d8f46",
"files": [
".json"
],

View File

@ -2,7 +2,7 @@
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "bf545cb7-09c7-4060-bef5-2d1c1a4aad88",
"uuid": "06a97b00-2863-4826-a517-c33c0b601043",
"files": [
".json",
".png"
@ -10,14 +10,14 @@
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "bf545cb7-09c7-4060-bef5-2d1c1a4aad88@6c48a",
"uuid": "06a97b00-2863-4826-a517-c33c0b601043@6c48a",
"displayName": "multiplier_stack_animation_1",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "bf545cb7-09c7-4060-bef5-2d1c1a4aad88",
"imageUuidOrDatabaseUri": "06a97b00-2863-4826-a517-c33c0b601043",
"isUuid": true,
"visible": false,
"minfilter": "linear",
@ -34,7 +34,7 @@
},
"f9941": {
"importer": "sprite-frame",
"uuid": "bf545cb7-09c7-4060-bef5-2d1c1a4aad88@f9941",
"uuid": "06a97b00-2863-4826-a517-c33c0b601043@f9941",
"displayName": "multiplier_stack_animation_1",
"id": "f9941",
"name": "spriteFrame",
@ -114,7 +114,7 @@
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "bf545cb7-09c7-4060-bef5-2d1c1a4aad88@6c48a",
"imageUuidOrDatabaseUri": "06a97b00-2863-4826-a517-c33c0b601043@6c48a",
"atlasUuid": ""
},
"ver": "1.0.12",
@ -129,6 +129,6 @@
"type": "sprite-frame",
"hasAlpha": true,
"fixAlphaTransparencyArtifacts": false,
"redirect": "bf545cb7-09c7-4060-bef5-2d1c1a4aad88@6c48a"
"redirect": "06a97b00-2863-4826-a517-c33c0b601043@6c48a"
}
}

View File

@ -2,7 +2,7 @@
"ver": "1.0.0",
"importer": "*",
"imported": true,
"uuid": "3c2c6589-2d31-4a29-82a3-8a44d01b6efc",
"uuid": "2c4c896f-1d04-4a22-b07b-d849084c40b8",
"files": [
".atlas",
".json"

View File

@ -2,7 +2,7 @@
"ver": "1.2.6",
"importer": "spine-data",
"imported": true,
"uuid": "ca4781bc-b566-48cf-9fca-bc70569272dc",
"uuid": "a209929d-0be0-432f-b47e-d2e7e7b54337",
"files": [
".json"
],

View File

@ -2,7 +2,7 @@
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "85ec3128-2378-4847-8ff5-494efd2ff347",
"uuid": "fe7e6801-dfd0-46c3-8d32-e2d7a79de008",
"files": [
".json",
".png"
@ -10,14 +10,14 @@
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "85ec3128-2378-4847-8ff5-494efd2ff347@6c48a",
"uuid": "fe7e6801-dfd0-46c3-8d32-e2d7a79de008@6c48a",
"displayName": "multiplier_stack_animation_2",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "85ec3128-2378-4847-8ff5-494efd2ff347",
"imageUuidOrDatabaseUri": "fe7e6801-dfd0-46c3-8d32-e2d7a79de008",
"isUuid": true,
"visible": false,
"minfilter": "linear",
@ -34,7 +34,7 @@
},
"f9941": {
"importer": "sprite-frame",
"uuid": "85ec3128-2378-4847-8ff5-494efd2ff347@f9941",
"uuid": "fe7e6801-dfd0-46c3-8d32-e2d7a79de008@f9941",
"displayName": "multiplier_stack_animation_2",
"id": "f9941",
"name": "spriteFrame",
@ -114,7 +114,7 @@
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "85ec3128-2378-4847-8ff5-494efd2ff347@6c48a",
"imageUuidOrDatabaseUri": "fe7e6801-dfd0-46c3-8d32-e2d7a79de008@6c48a",
"atlasUuid": ""
},
"ver": "1.0.12",
@ -129,6 +129,6 @@
"type": "sprite-frame",
"hasAlpha": true,
"fixAlphaTransparencyArtifacts": false,
"redirect": "85ec3128-2378-4847-8ff5-494efd2ff347@6c48a"
"redirect": "fe7e6801-dfd0-46c3-8d32-e2d7a79de008@6c48a"
}
}

View File

@ -2,7 +2,7 @@
"ver": "1.0.0",
"importer": "*",
"imported": true,
"uuid": "15f4b63c-dfc7-468f-a4e2-a50cdf860bf1",
"uuid": "ca0dfc7d-6e1c-40af-82c5-963aa8f9513c",
"files": [
".atlas",
".json"

View File

@ -2,7 +2,7 @@
"ver": "1.2.6",
"importer": "spine-data",
"imported": true,
"uuid": "4c13e3d0-fde8-414e-9eeb-8354dc49325f",
"uuid": "ac135226-de68-4371-bf95-8f215a208e1a",
"files": [
".json"
],

View File

@ -2,7 +2,7 @@
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "a55d43c5-a7ae-4ff4-bb4a-4eff0aeb7759",
"uuid": "3bcbbf03-b67b-4cdb-b9ae-36dc561d2b6d",
"files": [
".json",
".png"
@ -10,14 +10,14 @@
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "a55d43c5-a7ae-4ff4-bb4a-4eff0aeb7759@6c48a",
"uuid": "3bcbbf03-b67b-4cdb-b9ae-36dc561d2b6d@6c48a",
"displayName": "multiplier_stack_animation_3",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "a55d43c5-a7ae-4ff4-bb4a-4eff0aeb7759",
"imageUuidOrDatabaseUri": "3bcbbf03-b67b-4cdb-b9ae-36dc561d2b6d",
"isUuid": true,
"visible": false,
"minfilter": "linear",
@ -34,7 +34,7 @@
},
"f9941": {
"importer": "sprite-frame",
"uuid": "a55d43c5-a7ae-4ff4-bb4a-4eff0aeb7759@f9941",
"uuid": "3bcbbf03-b67b-4cdb-b9ae-36dc561d2b6d@f9941",
"displayName": "multiplier_stack_animation_3",
"id": "f9941",
"name": "spriteFrame",
@ -114,7 +114,7 @@
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "a55d43c5-a7ae-4ff4-bb4a-4eff0aeb7759@6c48a",
"imageUuidOrDatabaseUri": "3bcbbf03-b67b-4cdb-b9ae-36dc561d2b6d@6c48a",
"atlasUuid": ""
},
"ver": "1.0.12",
@ -129,6 +129,6 @@
"type": "sprite-frame",
"hasAlpha": true,
"fixAlphaTransparencyArtifacts": false,
"redirect": "a55d43c5-a7ae-4ff4-bb4a-4eff0aeb7759@6c48a"
"redirect": "3bcbbf03-b67b-4cdb-b9ae-36dc561d2b6d@6c48a"
}
}

View File

@ -2,7 +2,7 @@
"ver": "1.0.0",
"importer": "*",
"imported": true,
"uuid": "949e68ae-35d0-429b-be91-536040348017",
"uuid": "5ec8b67f-909d-4b5a-a9d2-9dc135121b8f",
"files": [
".atlas",
".json"

View File

@ -2,7 +2,7 @@
"ver": "1.2.6",
"importer": "spine-data",
"imported": true,
"uuid": "08b145b0-ca97-4c01-ac1a-d3b24aefe145",
"uuid": "688e668a-8498-455f-995c-937e692c04c6",
"files": [
".json"
],

View File

@ -2,7 +2,7 @@
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "1a77b236-0b32-4341-9fc7-9816afa33766",
"uuid": "05627019-88cb-46c5-82ec-87a6a5348f2a",
"files": [
".json",
".png"
@ -10,14 +10,14 @@
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "1a77b236-0b32-4341-9fc7-9816afa33766@6c48a",
"uuid": "05627019-88cb-46c5-82ec-87a6a5348f2a@6c48a",
"displayName": "multiplier_stack_animation_4",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "1a77b236-0b32-4341-9fc7-9816afa33766",
"imageUuidOrDatabaseUri": "05627019-88cb-46c5-82ec-87a6a5348f2a",
"isUuid": true,
"visible": false,
"minfilter": "linear",
@ -34,7 +34,7 @@
},
"f9941": {
"importer": "sprite-frame",
"uuid": "1a77b236-0b32-4341-9fc7-9816afa33766@f9941",
"uuid": "05627019-88cb-46c5-82ec-87a6a5348f2a@f9941",
"displayName": "multiplier_stack_animation_4",
"id": "f9941",
"name": "spriteFrame",
@ -114,7 +114,7 @@
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "1a77b236-0b32-4341-9fc7-9816afa33766@6c48a",
"imageUuidOrDatabaseUri": "05627019-88cb-46c5-82ec-87a6a5348f2a@6c48a",
"atlasUuid": ""
},
"ver": "1.0.12",
@ -129,6 +129,6 @@
"type": "sprite-frame",
"hasAlpha": true,
"fixAlphaTransparencyArtifacts": false,
"redirect": "1a77b236-0b32-4341-9fc7-9816afa33766@6c48a"
"redirect": "05627019-88cb-46c5-82ec-87a6a5348f2a@6c48a"
}
}

View File

@ -2,7 +2,7 @@
"ver": "1.0.0",
"importer": "*",
"imported": true,
"uuid": "0c1841b8-f3b9-4fe2-a3d7-3cdc4eff41cd",
"uuid": "06e80cf9-1cf9-4ce7-a5f1-cc129d6781bb",
"files": [
".atlas",
".json"

View File

@ -2,7 +2,7 @@
"ver": "1.2.6",
"importer": "spine-data",
"imported": true,
"uuid": "70ea8190-8a0c-41ef-805d-c9a28d71f491",
"uuid": "75443df4-2b37-44d8-b9e7-90e45d80e127",
"files": [
".json"
],

View File

@ -2,7 +2,7 @@
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "4a33d740-6361-4453-a1c8-07754e05dd86",
"uuid": "816a6715-a681-4350-827d-3cdbf258945e",
"files": [
".json",
".png"
@ -10,14 +10,14 @@
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "4a33d740-6361-4453-a1c8-07754e05dd86@6c48a",
"uuid": "816a6715-a681-4350-827d-3cdbf258945e@6c48a",
"displayName": "multiplier_stack_animation_5",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "4a33d740-6361-4453-a1c8-07754e05dd86",
"imageUuidOrDatabaseUri": "816a6715-a681-4350-827d-3cdbf258945e",
"isUuid": true,
"visible": false,
"minfilter": "linear",
@ -34,7 +34,7 @@
},
"f9941": {
"importer": "sprite-frame",
"uuid": "4a33d740-6361-4453-a1c8-07754e05dd86@f9941",
"uuid": "816a6715-a681-4350-827d-3cdbf258945e@f9941",
"displayName": "multiplier_stack_animation_5",
"id": "f9941",
"name": "spriteFrame",
@ -114,7 +114,7 @@
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "4a33d740-6361-4453-a1c8-07754e05dd86@6c48a",
"imageUuidOrDatabaseUri": "816a6715-a681-4350-827d-3cdbf258945e@6c48a",
"atlasUuid": ""
},
"ver": "1.0.12",
@ -129,6 +129,6 @@
"type": "sprite-frame",
"hasAlpha": true,
"fixAlphaTransparencyArtifacts": false,
"redirect": "4a33d740-6361-4453-a1c8-07754e05dd86@6c48a"
"redirect": "816a6715-a681-4350-827d-3cdbf258945e@6c48a"
}
}

View File

@ -4896,7 +4896,7 @@
"__id__": 2
},
"_children": [],
"_active": true,
"_active": false,
"_components": [
{
"__id__": 130
@ -4909,7 +4909,7 @@
"_lpos": {
"__type__": "cc.Vec3",
"x": 0,
"y": -155.04,
"y": 0,
"z": 0
},
"_lrot": {
@ -4947,13 +4947,13 @@
"__prefab": null,
"_contentSize": {
"__type__": "cc.Size",
"width": 1082,
"height": 2362
"width": 2258,
"height": 2530.5
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
"x": 0.433348095659876,
"y": 0.603635645129421
},
"_id": "d7h41v8UxIZ4ItxMyPmPlz"
},
@ -4978,11 +4978,11 @@
"a": 255
},
"_skeletonData": {
"__uuid__": "d62a8256-af0c-4b19-881a-5b853fedc053",
"__uuid__": "d1890f1e-0118-4ca2-a363-c9e53337bc89",
"__expectedType__": "sp.SkeletonData"
},
"defaultSkin": "default",
"defaultAnimation": "xiaoshi",
"defaultAnimation": "",
"_premultipliedAlpha": false,
"_timeScale": 1,
"_preCacheMode": 0,