不错,挺好玩
感谢肯定
mark 一下
恭喜你自己的小游戏上线,怎么联系你啊~~
你小游戏不错哦,我们可以帮忙推广. 怎么联系你
要不要换量
我的qq号。157354966
适配好像有点问题
可以详细说下吗?感谢
你好 ,我想问一下你的IOS微信 自动播放声音是如何解决的?我遇到一个问题就是IOS没有办法自动播放声音,安卓的一切正常,IOS只有交互后才会播放声音!!
我没有遇到这个问题,启动起来,我会主动调用一下play,然后就有声音了。我用的是1.10
mark下 玩了下小游戏界面适配需要优化下
不对啊 我看你的是进去就自动播放背景音乐了啊,遇到的问题就是即使调了play也不能主动播放
感谢,能说下机型吗?
const DataEnum = require('./data/DataEnum');
cc.Class({
extends: cc.Component,
properties: {
target: {
default: null,
type: cc.Node
},
bgm: {
type: cc.AudioClip,
default: null
},
},
onLoad() {
dd.audio = this;
this.mute(dd.data.get(DataEnum.isMute));
this.bgmId = -1;
},
onEnable() {
this.node.on('mutex', this.onMutex, this);
this.target.on('isPause', this.onPause, this);
this.target.on('isStart', this.onStart, this);
},
onDisable() {
this.node.off('mutex', this.onMutex, this);
this.target.off('isStart', this.onStart, this);
this.target.off('isPause', this.onPause, this);
},
onPause(event) {
let isPause = event.detail;
this._toogleBGM(!isPause);
},
onStart() {
this._toogleBGM(true);
},
play(filePath, loop, volume) {
if(dd.isMute){
return -1;
}
return cc.audioEngine.play(filePath, loop, volume);
},
stop(audioId) {
cc.audioEngine.stop(audioId);
},
onMutex(event){
this.mute(event.detail);
this._toogleBGM(!event.detail);
},
mute(bool) {
this.node.mutex = bool;
dd.isMute = bool;
dd.data.set(DataEnum.isMute, bool);
dd.data.save(DataEnum.isMute);
if (bool) {
cc.audioEngine.pauseAll();
} else {
cc.audioEngine.resumeAll();
}
},
_toogleBGM(bool) {
if(dd.isMute) return;
if (this.bgmId !== -1) {
this.bmgId = -1;
this.stop(this.bgmId);
}
if (bool) {
this.bgmId = this.play(this.bgm, true, 1);
}
}
});
我代码在这里,我也不知道为啥不一样。
我换了最新的版本,就可以播放了,之前是1.9.2
好文一篇
想请问一下,你的软著是自己申请的吗?怎么做的?
iphone xs 下,上方一大块黑色区域
推广的方式:
1.死缠烂打
2.哭
3.上吊