Commit 67a15cb4 authored by haiyoucuv's avatar haiyoucuv

init

parent 588d74d7
......@@ -45,11 +45,11 @@
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"trimY": 30,
"width": 1620,
"height": 450,
"rawWidth": 1620,
"rawHeight": 450,
"rawHeight": 510,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
......@@ -84,23 +84,23 @@
],
"uv": [
0,
450,
480,
1620,
450,
0,
480,
0,
30,
1620,
0
30
],
"nuv": [
0,
0,
0.058823529411764705,
1,
0.058823529411764705,
0,
0,
1,
0.9411764705882353,
1,
1
0.9411764705882353
],
"minPos": [
-810,
......
import Panel from "../../Module/Panel";
import { _decorator, Button, Label, Node, Sprite } from "cc";
import { observer } from "../store/decorators";
import { changeScene } from "../../Module/UIFast";
import { HomeScene } from "../Scenes/HomeScene";
const { ccclass, property } = _decorator;
......@@ -21,6 +23,8 @@ export default class GameFailPanel extends Panel {
}
clickBack() {
this.hidePanel();
changeScene(HomeScene);
}
// @render
......
......@@ -14,7 +14,6 @@ import { Global, SkinName } from "./Global";
import { Events, GameState } from "./Common/Enums";
import { changeScene, showPanel, showToast } from "../../../Module/UIFast";
import Scene from "../../../Module/Scene";
import { executePreFrame, getItemGenerator } from "../../Utils/ExecutePreFrame";
import { Player } from "./Player";
import { AISnake } from "./AISnake";
import { aiPool, clearAllPool } from "./Manager/CommonPool";
......@@ -110,7 +109,7 @@ export class MainGame extends Scene {
} else if (currentStage == 2) {
} else {
this.gameOver();
await this.gameOver();
}
......@@ -124,7 +123,7 @@ export class MainGame extends Scene {
const { currentStage } = gameStore.startInfo;
if (currentStage == 1) {
const submitSuc = await gameStore.submitOne(this.player.length);
const submitSuc = await gameStore.submitOne();
const gameSuc = await gameStore.startGame();
if (gameSuc) {
// await changeScene(GameLoading, {
......@@ -139,8 +138,9 @@ export class MainGame extends Scene {
}
};
gameOver() {
d
async gameOver() {
const success = await gameStore.finalSubmit();
}
......
......@@ -60,7 +60,9 @@ class GameStore {
return success;
}
async submitOne(score: number) {
async submitOne() {
const { length: score, killNum } = this.gameInfo;
const params = {
startId: this.startInfo.startId,
score,
......@@ -77,7 +79,9 @@ class GameStore {
return success;
}
async submitTwo(score: number) {
async submitTwo() {
const { length: score, killNum } = this.gameInfo;
const params = {
startId: this.startInfo.startId,
score,
......@@ -94,12 +98,14 @@ class GameStore {
return success;
}
async finalSubmit(score: number, finalKill: number) {
async finalSubmit() {
const { length: score, killNum } = this.gameInfo;
const param: any = {
startId: this.startInfo.startId,
score,
finalKill,
finalKill: killNum,
composeSpList: [],
};
......
......@@ -2,5 +2,5 @@
"success": true,
"code": "",
"message": "",
"data": "Dn22D8mkVmDOfP4ajNWcqtUT2BWK7hLAEHSofRAnITI23/h6M5dk9MJ+cY56DvHjlsXFGC8q3BgSsz56SCAcO6LiZx8tbmrjStn4UcGZq6/W+ZIm0IEma+v0iYkjGBT6bqBnMhA+9JKPvWXKnFJiNR2b8kEDC1Mjt2MH2penAaujIPcM6SAvaaZuTB04+Jtkg598ulZEVdSadszHW0WSzCDjzyl9pUo3ai58aja/O6OPNCmasxQ2HN3MhUZceEZHYRQUj2wA4OgIbGAl86/PLgcfqBnXV2NFox1DfZ4aKKTJxlYOJCrfKM2nx8RaONLCeCqVn3U1bzFqJ1Upn8vKObxrVTSrMYASXNC27cTuH9bGK3lkY+rfXa0jRKAuxSnQRC0SkOJyFz+ZuXZxqKGVhPG5Pnh3iLaYvhyTvYuLynmU7PO4shaMtAaGi6nOlRz0Rd1agq4+8RfQW6PUkemr0Zn2pR4otRBTZw6odXswdwp1mZgl82nZzIwi5NiXaKTCzMDTfBVaeczzUpZLnXt/rPBh4Zn4qyzhNVLBq5/dbt6Minb+7gbX3xMYqpSUiiZD0zfGA25L+dGBa5EjC0/Pkac4Q1mUiVY6CkmqqbRVVC/pxBYdTd7O/xfwfSz5GLrDePkIIE/IsMYx5ovf9DueVQ=="
"data": "Dn22D8mkVmDOfP4ajNWcqtUT2BWK7hLAEHSofRAnITI23/h6M5dk9MJ+cY56DvHjlsXFGC8q3BgSsz56SCAcO6LiZx8tbmrjStn4UcGZq6/W+ZIm0IEma+v0iYkjGBT6bqBnMhA+9JKPvWXKnFJiNR2b8kEDC1Mjt2MH2penAaujIPcM6SAvaaZuTB04+Jtk5VSYZXauvq4KmXW3GGRumeiiyEIA+ZXAopsUzjcknsRY6nZmKVj0NjiFtVGF84qiZnISqNrmwNrdHOQONlI0TLVPx0Bzlpich1zyMUMMkZ/7cV2CeMi6Sm84oR/risQdMtm7d9EPsIDnoL6i0TO+JLCfvbc2r4yxr3qVSjSnK8A2DqxrtTBtXV8BLNwPLVjtZLVP0MnLPT6PXS5TNsD/jRswCJPga523j5LQgkXjJLlRl83WRQ8/SrcECSAoTF0gHG0+rm8WuFVrvQadxzK8kWZertwqJhAKkAlaj5rOJIgfS7rfoxrqPFSG7JvnMFNyCJ5Z8e4SSC6R/G8pBB1js45fXO6HvLg1QrYCZp+yxNAhcvDgXSPMIHVQns9RFNrw5cC0a4gSW8qIqzNbbl12pfq/OYvV0TjVFIZuGGYAlDrmSifBtQbh3yuT4pd6NH/inb/RXr6U3M6zCet4l0foaQ=="
}
\ No newline at end of file
......@@ -52,7 +52,7 @@ const startInfo = {
limitLuckNum: 5, // 当日上限可获得福袋数
downArea: [3, 2, 1], // 掉落分布,集合,比如每日上限6个,这里配置返回1、2、3
currentAcquireNum: 3, // 当局剩余可获得福袋数,不包含accumulateLuckNum,当局累计获得福袋数量
currentStage: 1, // 当前应该进入的阶段(1-一阶段 2-二阶段 3-无尽模式)
currentStage: 3, // 当前应该进入的阶段(1-一阶段 2-二阶段 3-无尽模式)
spCardList: [ // 道具卡集合
{ spId: "sp_bag_silver", num: 1 },
{ spId: "sp_revival_card", num: 2 },
......
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