修复一点BUG,恢复地图底图, 增加按钮重复点击控制
This commit is contained in:
parent
cea68a233e
commit
96ec9d395d
File diff suppressed because it is too large
Load Diff
|
@ -79,6 +79,7 @@ export default class MapConroler extends cc.Component {
|
|||
mapHeight: number = 0;
|
||||
wallNum: number = 0;
|
||||
blockNum: number = 0;
|
||||
reviewState: boolean = false;
|
||||
mapBlocksWall: any; //地图的所有底块
|
||||
mapInfo: any; //地图除了底块的其他信息
|
||||
blocks: any; //方块数组
|
||||
|
@ -135,6 +136,7 @@ export default class MapConroler extends cc.Component {
|
|||
this.gameWin = false;
|
||||
this.gameOver = false;
|
||||
this.gameStart = false;
|
||||
this.reviewState = false;
|
||||
this.homeCanTouch = true;
|
||||
this.againCanTouch = true;
|
||||
this.new_mode = 0;
|
||||
|
@ -1314,6 +1316,12 @@ export default class MapConroler extends cc.Component {
|
|||
}
|
||||
|
||||
winLevel() {
|
||||
if(this.node.parent.parent.getChildByName("Win").
|
||||
getChildByName("nextBtn").getComponent("btnControl")._touch == false){
|
||||
return;
|
||||
}
|
||||
this.node.parent.parent.getChildByName("Win").
|
||||
getChildByName("nextBtn").getComponent("btnControl").setTouch(false);
|
||||
cc.fx.AudioManager._instance.playEffect("anniu_Big", null);
|
||||
if (cc.fx.GameConfig.GM_INFO.level > 156) {
|
||||
cc.fx.GameConfig.GM_INFO.level = 156;
|
||||
|
@ -1402,6 +1410,10 @@ export default class MapConroler extends cc.Component {
|
|||
}
|
||||
|
||||
reviewLevel() {
|
||||
if(this.reviewState == true){
|
||||
return;
|
||||
}
|
||||
this.reviewState = true;
|
||||
cc.fx.AudioManager._instance.playEffect("anniu_Big", null);
|
||||
let coin = 900;
|
||||
if (cc.fx.GameConfig.GM_INFO.review == 1) coin = 1900;
|
||||
|
@ -1409,6 +1421,7 @@ export default class MapConroler extends cc.Component {
|
|||
// console.log("自身金币:",cc.fx.GameConfig.GM_INFO.coin,"消耗金币:",coin);
|
||||
if (cc.fx.GameConfig.GM_INFO.coin < Math.abs(coin)) {
|
||||
MiniGameSdk.API.showToast("金币不足,无法加时间");
|
||||
this.reviewState = false;
|
||||
return;
|
||||
}
|
||||
else {
|
||||
|
@ -1429,6 +1442,9 @@ export default class MapConroler extends cc.Component {
|
|||
this.add_Time += 20;
|
||||
this.pause = false;
|
||||
this.node.parent.parent.getChildByName("Lose").active = false;
|
||||
setTimeout(() => {
|
||||
this.reviewState = false;
|
||||
}, 200);
|
||||
this.startTimeCutDown();
|
||||
}
|
||||
|
||||
|
@ -1463,7 +1479,7 @@ export default class MapConroler extends cc.Component {
|
|||
return;
|
||||
}
|
||||
// MiniGameSdk.API.showToast("体力值减少");
|
||||
// MapConroler._instance = null;
|
||||
MapConroler._instance = null;
|
||||
cc.fx.GameConfig.LEVEL_INFO_init(false, 0);
|
||||
if (this.new_mode == 3) {
|
||||
this.node.parent.parent.getChildByName("Win").active = false;
|
||||
|
|
|
@ -314,7 +314,9 @@
|
|||
],
|
||||
"_srcBlendFactor": 770,
|
||||
"_dstBlendFactor": 771,
|
||||
"_spriteFrame": null,
|
||||
"_spriteFrame": {
|
||||
"__uuid__": "a4e3a13a-44b8-4fc2-9b34-e72554a59deb"
|
||||
},
|
||||
"_type": 0,
|
||||
"_sizeMode": 1,
|
||||
"_fillType": 0,
|
||||
|
@ -326,7 +328,9 @@
|
|||
"_fillStart": 0,
|
||||
"_fillRange": 0,
|
||||
"_isTrimmedMode": true,
|
||||
"_atlas": null,
|
||||
"_atlas": {
|
||||
"__uuid__": "d2adfa00-68ea-4d63-97a0-44fca153a2d7"
|
||||
},
|
||||
"_id": ""
|
||||
},
|
||||
{
|
||||
|
|
25
project.config.json
Normal file
25
project.config.json
Normal file
|
@ -0,0 +1,25 @@
|
|||
{
|
||||
"setting": {
|
||||
"es6": true,
|
||||
"postcss": true,
|
||||
"minified": true,
|
||||
"uglifyFileName": false,
|
||||
"enhance": true,
|
||||
"packNpmRelationList": [],
|
||||
"babelSetting": {
|
||||
"ignore": [],
|
||||
"disablePlugins": [],
|
||||
"outputPath": ""
|
||||
},
|
||||
"useCompilerPlugins": false
|
||||
},
|
||||
"compileType": "game",
|
||||
"simulatorPluginLibVersion": {},
|
||||
"packOptions": {
|
||||
"ignore": [],
|
||||
"include": []
|
||||
},
|
||||
"isGameTourist": false,
|
||||
"appid": "wxdd145ced49158a1e",
|
||||
"editorSetting": {}
|
||||
}
|
14
project.private.config.json
Normal file
14
project.private.config.json
Normal file
|
@ -0,0 +1,14 @@
|
|||
{
|
||||
"libVersion": "3.8.10",
|
||||
"projectname": "colorBlcok",
|
||||
"setting": {
|
||||
"urlCheck": true,
|
||||
"coverView": true,
|
||||
"lazyloadPlaceholderEnable": false,
|
||||
"skylineRenderEnable": false,
|
||||
"preloadBackgroundData": false,
|
||||
"autoAudits": false,
|
||||
"showShadowRootInWxmlPanel": true,
|
||||
"compileHotReLoad": true
|
||||
}
|
||||
}
|
|
@ -12,7 +12,7 @@
|
|||
"webOrientation": "portrait",
|
||||
"inlineSpriteFrames": true,
|
||||
"inlineSpriteFrames_native": true,
|
||||
"mainCompressionType": "default",
|
||||
"mainCompressionType": "subpackage",
|
||||
"mainIsRemote": false,
|
||||
"optimizeHotUpdate": false,
|
||||
"md5Cache": true,
|
||||
|
|
Loading…
Reference in New Issue
Block a user