Commit 16059a17 authored by Friends233's avatar Friends233

迭代修改

parent 66c90dc3
......@@ -1895,6 +1895,12 @@
"miniBlockPre": {
"__uuid__": "b73e2b92-c61e-42a6-84d4-532e39360a8d"
},
"setAudio": {
"__uuid__": "ab7658ee-b5c2-4b4f-9585-67efbf32a929"
},
"clearAudio": {
"__uuid__": "4dcd318c-9ada-4f5b-8109-e323cb680f54"
},
"_id": "e1NYQ2/S9BD7g4hT7ebUgR"
},
{
......@@ -1970,6 +1976,12 @@
"miniBlockPre": {
"__uuid__": "b73e2b92-c61e-42a6-84d4-532e39360a8d"
},
"setAudio": {
"__uuid__": "ab7658ee-b5c2-4b4f-9585-67efbf32a929"
},
"clearAudio": {
"__uuid__": "4dcd318c-9ada-4f5b-8109-e323cb680f54"
},
"_id": "1dBFEaOAVJPpaGFB7eTcUh"
},
{
......@@ -2045,6 +2057,12 @@
"miniBlockPre": {
"__uuid__": "b73e2b92-c61e-42a6-84d4-532e39360a8d"
},
"setAudio": {
"__uuid__": "ab7658ee-b5c2-4b4f-9585-67efbf32a929"
},
"clearAudio": {
"__uuid__": "4dcd318c-9ada-4f5b-8109-e323cb680f54"
},
"_id": "d4c7EtXIhGc4Ie7aBB+Ym/"
},
{
......
......@@ -20,7 +20,7 @@ export const CUSTOM_EVENT = {
/** 开始新手引导 */
START_GUIDE: 'START_GUIDE',
/** 新手引导结束 */
GUIDE_OVER:'GUIDE_OVER',
GUIDE_OVER: 'GUIDE_OVER',
}
export const Config = {
......@@ -28,18 +28,20 @@ export const Config = {
maxRow: 10,
/** 块矩阵最大列 */
maxCol: 10,
/** 填入方块颜色,小方块颜色 */
miniBlockColor: '#58D9B3',
/** 填入方块颜色 */
setBlockColor : '#ffd84f',
/** 小方块初始颜色 */
miniBlockColor: '#ffc34f',
/** 小方块被禁用的颜色 */
miniBlockDisabledColor: '#A0CDC0',
miniBlockDisabledColor: '#CB9C42',
/** 默认方块颜色,空白方块颜色 */
defaultColor: '#8FBABA',
/** 每一个方块动画播放延时 ms*/
blockAniDelay: 35,
/** 方块拖拽判定放置的最大距离 */
blockMaxOffset: 58,
blockMaxOffset:29,
/** 拿起方块与手指直接的间隔 */
blockManagerDragOffsetY:0,
blockManagerDragOffsetY: 150,
/** 下方小方块间隔 */
miniBlockOffset: 2,
/** 小方块大小 */
......
......@@ -49,7 +49,7 @@ export default class Block extends cc.Component {
changeBlockState(type: BLOCK_STATE) {
this.node.scale = 1
this.blockState = type
this.node.color = cc.color(type === BLOCK_STATE.NON_EMPTY ? Config.miniBlockColor : Config.defaultColor)
this.node.color = cc.color(type === BLOCK_STATE.NON_EMPTY ? Config.setBlockColor : Config.defaultColor)
}
// update (dt) {}
......
......@@ -47,6 +47,14 @@ export default class BlockManager extends cc.Component {
/** 消除动画是否执行中 */
isBlcokClearAni = false
/** 放置音效 */
@property(cc.AudioClip)
setAudio:cc.AudioClip = null
/** 清除音效 */
@property(cc.AudioClip)
clearAudio:cc.AudioClip = null
start() {
this.viewHeight = cc.view.getVisibleSize().height
this.viewWidth = cc.view.getVisibleSize().width
......@@ -126,6 +134,9 @@ export default class BlockManager extends cc.Component {
})
this.clearAllChildren()
this.checkBlockMatrix()
cc.audioEngine.play(this.setAudio,false,1)
cc.find('Canvas').dispatchEvent(this.setBlockEvent)
// this.refreshMiniBlock()
return
......@@ -204,6 +215,7 @@ export default class BlockManager extends cc.Component {
if (els.length === 0) return
const { script } = els.pop()
script.playClearAni(() => {
cc.audioEngine.play(this.clearAudio,false,1)
cc.find('Canvas').dispatchEvent(this.addScoreEvent)
if (els.length == 0) {
cc.find('Canvas').dispatchEvent(this.checkIsSet)
......
{
"ver": "1.1.3",
"uuid": "e7f412b9-35d9-4773-bfdb-00ca5068b7cf",
"importer": "folder",
"isBundle": false,
"bundleName": "",
"priority": 1,
"compressionType": {},
"optimizeHotUpdate": {},
"inlineSpriteFrames": {},
"isRemoteBundle": {},
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.3",
"uuid": "4dcd318c-9ada-4f5b-8109-e323cb680f54",
"importer": "audio-clip",
"downloadMode": 0,
"duration": 1.776,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.3",
"uuid": "ab7658ee-b5c2-4b4f-9585-67efbf32a929",
"importer": "audio-clip",
"downloadMode": 0,
"duration": 0.78065,
"subMetas": {}
}
\ No newline at end of file
This diff is collapsed.
{"paths":{"0":["prefab/blockFab",3],"1":["images/guide1",1],"2":["images/bg",1],"3":["images/hand",1],"4":["images/matrix",1],"5":["images/return",1],"6":["images/box_wrp",1],"7":["images/guide2",1],"8":["images/pre_img",1],"9":["images/score",1],"10":["images/title",1],"11":["ani/blockBoom",0],"12":["images/scroll",1],"14":["images/return",2,1],"15":["images/score",2,1],"16":["images/scroll",2,1],"17":["images/guide2",2,1],"18":["images/hand",2,1],"19":["images/title",2,1],"20":["images/matrix",2,1],"21":["prefab/sp",3],"22":["images/box_wrp",2,1],"24":["prefab/miniBlock",3],"25":["images/pre_img",2,1],"26":["images/bg",2,1],"27":["images/guide1",2,1],"29":["ani/guide",0]},"types":["cc.AnimationClip","cc.Texture2D","cc.SpriteFrame","cc.Prefab"],"uuids":["000rncAmFPGYVOsk5KQKWm","13PQHVlD9HqL/li+vWb8bT","25BnCMaRNBooxsQ/xU//UJ","25pBOV4x1KUbIEmAflT/AX","26RwVQm4lCY5JskLEqQSg4","63Ae3XaU9OM4wglVYkCsXf","68P6ZccQpFiYIepVzoFLFw","6deUS4Ov5M64R7nZNCQqmf","744iKQpDFNmafmCOGEdt//","81jna9BnBOoJzUQX4lfkeH","beZWVv60VIpIeFXgbiShUy","bfOJkeVm1OHq1n3U+DS/8j","fbZFWy/F5IJrA5hKcut/6J","02delMVqdBD70a/HSD99FK","14YsExCkNENIQdtfyyai4e","1andMTBd9G/KAdcCymEkkB","39/P5mMitAN6TMYs6jhqgr","3cq0q1IUBFkKpkwA95FOP/","50wFiywwtHj5CnU8PS/4pi","57/OZVuiVAuKekTp5qJCy9","6415YBqTJPO5ZBcKeJykPr","6fL9mhgY5DcY21Cq+NYSKy","86vE51OHZPdb27D4mbUYku","a2MjXRFdtLlYQ5ouAFv/+R","b7PiuSxh5CpoTUUy45NgqN","cauoEsLwNIvYGiGvaW89A4","ccZ87dBnVKaaHVYXZEXW/l","daOBfF74FAi4lE99MzDZyA","ecpdLyjvZBwrvm+cedCcQy","edAyRIN65CBoUcc2rVXFB+"],"scenes":{},"redirect":[13,0,28,0],"deps":["internal"],"packs":{"02637d9f6":[1,2,3,4,5,6,7,8,9,10,12],"03d9ecbbd":[0,11]},"name":"resources","importBase":"import","nativeBase":"native","debug":false,"isZip":false,"encrypted":false}
\ No newline at end of file
{"paths":{"0":["prefab/blockFab",4],"1":["images/guide1",2],"2":["images/bg",2],"3":["images/hand",2],"4":["images/matrix",2],"5":["images/return",2],"6":["images/box_wrp",2],"7":["images/guide2",2],"8":["images/pre_img",2],"9":["images/score",2],"10":["images/title",2],"11":["ani/blockBoom",0],"12":["images/scroll",2],"14":["images/return",3,1],"15":["images/score",3,1],"16":["images/scroll",3,1],"17":["images/guide2",3,1],"18":["audio/clear",1],"19":["images/hand",3,1],"20":["images/title",3,1],"21":["images/matrix",3,1],"22":["prefab/sp",4],"23":["images/box_wrp",3,1],"25":["audio/set",1],"26":["prefab/miniBlock",4],"27":["images/pre_img",3,1],"28":["images/bg",3,1],"29":["images/guide1",3,1],"31":["ani/guide",0]},"types":["cc.AnimationClip","cc.AudioClip","cc.Texture2D","cc.SpriteFrame","cc.Prefab"],"uuids":["000rncAmFPGYVOsk5KQKWm","13PQHVlD9HqL/li+vWb8bT","25BnCMaRNBooxsQ/xU//UJ","25pBOV4x1KUbIEmAflT/AX","26RwVQm4lCY5JskLEqQSg4","63Ae3XaU9OM4wglVYkCsXf","68P6ZccQpFiYIepVzoFLFw","6deUS4Ov5M64R7nZNCQqmf","744iKQpDFNmafmCOGEdt//","81jna9BnBOoJzUQX4lfkeH","beZWVv60VIpIeFXgbiShUy","bfOJkeVm1OHq1n3U+DS/8j","fbZFWy/F5IJrA5hKcut/6J","02delMVqdBD70a/HSD99FK","14YsExCkNENIQdtfyyai4e","1andMTBd9G/KAdcCymEkkB","39/P5mMitAN6TMYs6jhqgr","3cq0q1IUBFkKpkwA95FOP/","4dzTGMmtpPW4EJ4yPLaA9U","50wFiywwtHj5CnU8PS/4pi","57/OZVuiVAuKekTp5qJCy9","6415YBqTJPO5ZBcKeJykPr","6fL9mhgY5DcY21Cq+NYSKy","86vE51OHZPdb27D4mbUYku","a2MjXRFdtLlYQ5ouAFv/+R","abdljutcJLT5WFZ++/Mqkp","b7PiuSxh5CpoTUUy45NgqN","cauoEsLwNIvYGiGvaW89A4","ccZ87dBnVKaaHVYXZEXW/l","daOBfF74FAi4lE99MzDZyA","ecpdLyjvZBwrvm+cedCcQy","edAyRIN65CBoUcc2rVXFB+"],"scenes":{},"redirect":[13,0,30,0],"deps":["internal"],"packs":{"02637d9f6":[1,2,3,4,5,6,7,8,9,10,12],"03d9ecbbd":[0,11]},"name":"resources","importBase":"import","nativeBase":"native","debug":false,"isZip":false,"encrypted":false}
\ No newline at end of file
[1,0,0,[["cc.AudioClip",["_name","_native","duration"],0]],[[0,0,1,2,4]],[[0,"clear",".mp3",1.776],-1],0,0,[],[],[]]
\ No newline at end of file
[1,0,0,[["cc.AudioClip",["_name","_native","duration"],0]],[[0,0,1,2,4]],[[0,"set",".mp3",0.78065],-1],0,0,[],[],[]]
\ No newline at end of file
......@@ -40,7 +40,7 @@
<!-- <script src="//yun.duiba.com.cn/db_games/libs0924/svgaParser.minWeb.js" crossorigin="anonymous"></script>-->
<link rel="stylesheet" type="text/css" href="https://yun.duiba.com.cn/db_games/ccc_game/template/1685171703132/style-mobile.css"/>
<link rel="stylesheet" type="text/css" href="https://yun.duiba.com.cn/db_games/ccc_game/template/1685504746558/style-mobile.css"/>
<style>
......@@ -90,9 +90,9 @@
</div>
</div>
<script src="https://yun.duiba.com.cn/db_games/ccc_game/template/1685171703132/src/settings.js" charset="utf-8"></script>
<script src="https://yun.duiba.com.cn/db_games/ccc_game/template/1685504746558/src/settings.js" charset="utf-8"></script>
<script src="https://yun.duiba.com.cn/db_games/ccc_game/template/1685171703132/main.js" charset="utf-8"></script>
<script src="https://yun.duiba.com.cn/db_games/ccc_game/template/1685504746558/main.js" charset="utf-8"></script>
<script type="text/javascript">
(function () {
......
window.__remoteUrl__ = "https://yun.duiba.com.cn/db_games/ccc_game/template/1685171703132/";
window.__remoteUrl__ = "https://yun.duiba.com.cn/db_games/ccc_game/template/1685504746558/";
window.__remoteAssets__ = window.__remoteUrl__ + "assets/";
window.__version__ = 1685171703132;
window.__version__ = 1685504746558;
window.__ENV__ = "prod";
window.boot = function () {
......
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