消除掉落时从右往左依次掉落

This commit is contained in:
TJH 2025-10-13 15:53:48 +08:00
parent 2c359d799a
commit 976da48cc7
4 changed files with 1867 additions and 1588 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 32 KiB

View File

@ -0,0 +1,134 @@
{
"ver": "1.0.27",
"importer": "image",
"imported": true,
"uuid": "3e745b7e-8b21-4d64-ac9c-07a9f3923d87",
"files": [
".json",
".png"
],
"subMetas": {
"6c48a": {
"importer": "texture",
"uuid": "3e745b7e-8b21-4d64-ac9c-07a9f3923d87@6c48a",
"displayName": "按钮1",
"id": "6c48a",
"name": "texture",
"userData": {
"wrapModeS": "clamp-to-edge",
"wrapModeT": "clamp-to-edge",
"imageUuidOrDatabaseUri": "3e745b7e-8b21-4d64-ac9c-07a9f3923d87",
"isUuid": true,
"visible": false,
"minfilter": "linear",
"magfilter": "linear",
"mipfilter": "none",
"anisotropy": 0
},
"ver": "1.0.22",
"imported": true,
"files": [
".json"
],
"subMetas": {}
},
"f9941": {
"importer": "sprite-frame",
"uuid": "3e745b7e-8b21-4d64-ac9c-07a9f3923d87@f9941",
"displayName": "按钮1",
"id": "f9941",
"name": "spriteFrame",
"userData": {
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 223,
"height": 223,
"rawWidth": 223,
"rawHeight": 223,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"packable": true,
"pixelsToUnit": 100,
"pivotX": 0.5,
"pivotY": 0.5,
"meshType": 0,
"vertices": {
"rawPosition": [
-111.5,
-111.5,
0,
111.5,
-111.5,
0,
-111.5,
111.5,
0,
111.5,
111.5,
0
],
"indexes": [
0,
1,
2,
2,
1,
3
],
"uv": [
0,
223,
223,
223,
0,
0,
223,
0
],
"nuv": [
0,
0,
1,
0,
0,
1,
1,
1
],
"minPos": [
-111.5,
-111.5,
0
],
"maxPos": [
111.5,
111.5,
0
]
},
"isUuid": true,
"imageUuidOrDatabaseUri": "3e745b7e-8b21-4d64-ac9c-07a9f3923d87@6c48a",
"atlasUuid": ""
},
"ver": "1.0.12",
"imported": true,
"files": [
".json"
],
"subMetas": {}
}
},
"userData": {
"type": "sprite-frame",
"hasAlpha": true,
"fixAlphaTransparencyArtifacts": false,
"redirect": "3e745b7e-8b21-4d64-ac9c-07a9f3923d87@6c48a"
}
}

File diff suppressed because it is too large Load Diff

View File

@ -829,13 +829,19 @@ export class RollerManager extends Component {
this._crossSymbols = data.CrossSymbols; this._crossSymbols = data.CrossSymbols;
let processedCrossSymbols = this.processCrossSymbolsForRollers(); let processedCrossSymbols = this.processCrossSymbolsForRollers();
//从右到左掉落
this.allRollers.forEach((roller, index) => { this.allRollers.forEach((roller, index) => {
let stopData = this._resultStopData[index]; let idx = this.allRollers.length - index - 1
let rollerCrossSymbols = processedCrossSymbols[index]; let roll = this.allRollers[idx]
roller.setCrossSymbols(rollerCrossSymbols);
this.scheduleOnce(() => { this.scheduleOnce(() => {
roller.iconFallDown(stopData, rollerCrossSymbols) let stopData = this._resultStopData[idx];
}, 0.03 * index) let rollerCrossSymbols = processedCrossSymbols[idx];
roll.setCrossSymbols(rollerCrossSymbols);
this.scheduleOnce(() => {
roll.iconFallDown(stopData, rollerCrossSymbols)
}, 0.01 * index)
}, 0.06 * index)
}) })
// 在第一个图标开始掉落时播放音效 // 在第一个图标开始掉落时播放音效