Commit ac7a34bb authored by haiyoucuv's avatar haiyoucuv

init

parent 803c4914
This diff is collapsed.
......@@ -42,8 +42,6 @@ export class HomeScene extends Scene {
async start() {
AudioMgr.ins.play("audio/背景音乐");
await store.updateIndex();
// showPanel(GamePosterPanel);
......
import { _decorator } from "cc";
const { ccclass } = _decorator;
/**
* 游戏配置类
*/
@ccclass("Config")
export class Config {
/** 皮肤样式配置 */
public static readonly SKIN_STYLE = [
{
name: "赤蛇",
len: 20,
taitLen: 0,
isLock: false
},
{
name: "紫蛇",
len: 20,
taitLen: 0,
isLock: true
},
{
name: "黄蛇",
len: 20,
taitLen: 0,
isLock: true
},
{
name: "青蛇",
len: 20,
taitLen: 0,
isLock: true
},
{
name: "蛙蛙",
len: 20,
taitLen: 1,
isLock: true
},
{
name: "鸭鸭",
len: 20,
taitLen: 1,
isLock: true
},
{
name: "小蛟",
len: 20,
taitLen: 2,
isLock: true
},
{
name: "小鲤",
len: 20,
taitLen: 10,
isLock: true
},
{
name: "小鳄",
len: 20,
taitLen: 2,
isLock: true
},
{
name: "大鲇鱼",
len: 20,
taitLen: 2,
isLock: true
},
{
name: "红金鱼",
len: 20,
taitLen: 10,
isLock: true
},
{
name: "彩带鱼",
len: 20,
taitLen: 10,
isLock: true
},
{
name: "大眼怪",
len: 20,
taitLen: 2,
isLock: true
},
{
name: "长尾怪",
len: 20,
taitLen: 19,
isLock: true
},
{
name: "青蛙王子",
len: 20,
taitLen: 0,
isLock: true
}
];
}
{
"ver": "4.0.24",
"importer": "typescript",
"imported": true,
"uuid": "fdc2e6d8-9a05-4472-8389-06b3a181ffa5",
"files": [],
"subMetas": {},
"userData": {}
}
import { _decorator, Component, Graphics, Label, lerp, macro, misc, Node, Sprite, tween, UI, UITransform } from "cc";
import { Global } from "../Global";
const { ccclass, property, executeInEditMode } = _decorator;
......@@ -80,7 +81,18 @@ export class PropBtn extends Component {
totalCd = 0;
cd = 0;
startCd(cd = 5) {
startCd() {
const ps = this.node.parent
.getComponentsInChildren(PropBtn)
.map((v) => {
v.startCdSelf(Global.PROP_CD);
});
return Promise.all(ps);
}
startCdSelf(cd = 5) {
return new Promise<void>((resolve) => {
this.cdTxt.node.active = true;
this.cdMask.node.active = true;
......
This diff is collapsed.
This diff is collapsed.
{"ver":"4.0.24","importer":"typescript","imported":true,"uuid":"fc6bed6e-d45f-4fe4-921d-2296b85d48d0","files":[],"subMetas":{},"userData":{}}
This diff is collapsed.
{"ver":"4.0.24","importer":"typescript","imported":true,"uuid":"9bdc541a-921a-4cb3-bd33-0d3e21faed2b","files":[],"subMetas":{},"userData":{}}
This diff is collapsed.
{"ver":"4.0.24","importer":"typescript","imported":true,"uuid":"30822890-bd80-4cd4-822b-e929ff68d316","files":[],"subMetas":{},"userData":{}}
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment