添加部分奖杯获得动画
This commit is contained in:
@@ -3,8 +3,8 @@
|
||||
"_$id": "6l8gfnd1",
|
||||
"_$type": "Box",
|
||||
"name": "TrophyClaim",
|
||||
"width": 1080,
|
||||
"height": 1920,
|
||||
"width": 1920,
|
||||
"height": 1080,
|
||||
"left": 0,
|
||||
"right": 0,
|
||||
"top": 0,
|
||||
@@ -29,8 +29,8 @@
|
||||
"_$id": "l3kqo0ly",
|
||||
"_$type": "Image",
|
||||
"name": "Image",
|
||||
"width": 1080,
|
||||
"height": 1920,
|
||||
"width": 1920,
|
||||
"height": 1080,
|
||||
"alpha": 0.8,
|
||||
"left": 0,
|
||||
"right": 0,
|
||||
@@ -43,9 +43,12 @@
|
||||
"_$id": "21y8h6ei",
|
||||
"_$type": "Box",
|
||||
"name": "center",
|
||||
"y": 264,
|
||||
"x": 960,
|
||||
"y": 384,
|
||||
"width": 1080,
|
||||
"height": 1080,
|
||||
"anchorX": 0.5,
|
||||
"anchorY": 0.5,
|
||||
"centerX": 0,
|
||||
"centerY": -156,
|
||||
"_$child": [
|
||||
@@ -53,13 +56,24 @@
|
||||
"_$id": "vngawy58",
|
||||
"_$type": "Image",
|
||||
"name": "img_light_yellow",
|
||||
"x": 540,
|
||||
"y": 540,
|
||||
"width": 1080,
|
||||
"height": 1080,
|
||||
"anchorX": 0.5,
|
||||
"anchorY": 0.5,
|
||||
"centerX": 0,
|
||||
"centerY": 0,
|
||||
"skin": "res://0403c03d-0fbb-4930-8cf7-c4bf0f4d45b9",
|
||||
"useSourceSize": true,
|
||||
"color": "#ffffff"
|
||||
"color": "#ffffff",
|
||||
"_$comp": [
|
||||
{
|
||||
"_$type": "b4f67ca3-86fe-409d-a439-63a715243fb7",
|
||||
"scriptPath": "../src/views/common/AutoRotate.ts",
|
||||
"speed": 1
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"_$id": "ta6ji66s",
|
||||
|
||||
@@ -43,10 +43,12 @@
|
||||
"_$id": "74q7qe1w",
|
||||
"_$type": "Box",
|
||||
"name": "center",
|
||||
"x": 480,
|
||||
"y": -58,
|
||||
"x": 960,
|
||||
"y": 422,
|
||||
"width": 960,
|
||||
"height": 960,
|
||||
"anchorX": 0.5,
|
||||
"anchorY": 0.5,
|
||||
"centerX": 0,
|
||||
"centerY": -118,
|
||||
"_$child": [
|
||||
@@ -58,10 +60,19 @@
|
||||
"y": 30,
|
||||
"width": 900,
|
||||
"height": 900,
|
||||
"anchorX": 0.5,
|
||||
"anchorY": 0.5,
|
||||
"centerX": 0,
|
||||
"centerY": 0,
|
||||
"skin": "res://0403c03d-0fbb-4930-8cf7-c4bf0f4d45b9",
|
||||
"color": "#ffffff"
|
||||
"color": "#ffffff",
|
||||
"_$comp": [
|
||||
{
|
||||
"_$type": "b4f67ca3-86fe-409d-a439-63a715243fb7",
|
||||
"scriptPath": "../src/views/common/AutoRotate.ts",
|
||||
"speed": 1
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"_$id": "wiyybdn9",
|
||||
|
||||
@@ -2,6 +2,7 @@ import type { TrophyRecord } from "../../types/global"
|
||||
import { config } from "../../constants/config"
|
||||
import { MONTH_LIST } from "../../models/DCManager"
|
||||
import { ResourceManager } from "../../models/ResourceManager"
|
||||
import { Utility_EaseOut_2 } from "../../utils/utility"
|
||||
|
||||
const { regClass, property } = Laya
|
||||
|
||||
@@ -18,6 +19,28 @@ export class TrophyClaim extends Laya.Script {
|
||||
@property(Laya.Box)
|
||||
public btn_close: Laya.Box
|
||||
|
||||
private mask: Laya.Image
|
||||
private center: Laya.Box
|
||||
|
||||
onAwake(): void {
|
||||
this.mask = this.owner.getChildByName("Image") as Laya.Image
|
||||
this.mask.alpha = 0
|
||||
Laya.Tween.to(this.mask, {alpha: 0.8}, 600)
|
||||
|
||||
this.center = this.owner.getChildByName("center") as Laya.Box
|
||||
this.center.scaleX = 0
|
||||
this.center.scaleY = 0
|
||||
Laya.Tween.to(this.center, {scaleX: 1, scaleY: 1}, 200, Utility_EaseOut_2, null, 200)
|
||||
|
||||
const label_titlle = this.center.getChildByName("label_titlle") as Laya.Label
|
||||
label_titlle.alpha = 0
|
||||
Laya.Tween.to(label_titlle, {alpha: 1}, 600, Laya.Ease.linearNone, null, 600)
|
||||
|
||||
const btn_close = this.center.getChildByName("btn_close") as Laya.Box
|
||||
btn_close.alpha = 0
|
||||
Laya.Tween.to(btn_close, {alpha: 1}, 600, Laya.Ease.linearNone, null, 800)
|
||||
}
|
||||
|
||||
public onSetShow(record: TrophyRecord): void {
|
||||
for (let i = 0; i < MONTH_LIST.length; i++) {
|
||||
const obj = MONTH_LIST[i]
|
||||
|
||||
Reference in New Issue
Block a user