123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127 |
- cc.Class({
- extends: cc.Component,
- properties: {
- },
- statics: {
- EFFECT_NUM: 3,
- AN_GANG_NUM_W: 2,
- RAW_KIND: "",
- GAME_BACKGRUAND: "game",//背景音乐
- EX_SCORE: "score",//金币动画声音
- EX_SENDCARD: "star",//发牌动画声音
- EX_SHOWCARD: "showCard",//显示牌动画声音
- EX_CHIPSTART: "beginBet",//开始下注
- EX_CHIPEND: "stopBet",//停止下注
- EX_GAME_WIN: "game_win",//赢
- EX_GAME_LOSE: "gameLose",//输
- EX_GAME_NO_BET: "gameNoBet",//
- EX_BETLOW: "score0",//
- EX_BETHIGH: "betHigh",//
- EX_TIME: "time",//倒计时声音
- EX_CHANGEBANKER: "changeBanker",
- LG_PATH_SC: "filter-BRTP/",
- LG_FLAG_SC: "local/",
- LG_FLAG_PT: "putong/",
- bgmAudioID: -1,
- setPuTong(puTong) {
- },
- playBackMusic(kName) {
- var path = this.LG_PATH_SC + kName;
- if (cc.vv && cc.vv.audioMgr) {
- this.bgmAudioID = cc.vv.audioMgr.playBGM(path);
- }
- },
- stopBackMusic() {
- if (cc.vv && cc.vv.audioMgr) {
- cc.vv.audioMgr.stopBackMusic();
- }
- },
- playEffect(kName, preload) {
- var path = this.LG_PATH_SC + this.LG_FLAG_PT + kName + this.RAW_KIND;
- if (cc.vv && cc.vv.audioMgr) {
- var audioID = cc.vv.audioMgr.playSFX(path);
- }
- },
- playEffectDefineString(kName, preload) {
- if (cc.vv && cc.vv.audioMgr) {
- var audioID = cc.vv.audioMgr.playSFX(kName);
- }
- },
- playCardTypeByGender(iGender, cardpoint) {
- var path = "";
- if (iGender > 0) {
- path = "man/" + "cow_" + cardpoint;
- } else {
- path = "woman/" + "cow_" + cardpoint;
- }
- return this.playEffect(path, false);
- },
- playTypeByGender(iGender, type) {
- var path = "";
- if (iGender > 0) {
- path = "man/" + "type_" + type;
- } else {
- path = "woman/" + "type_" + type;
- }
- return this.playEffect(path, false);
- },
- playEffectByGender(iGender, kName) {
- var path = "";
- if (iGender > 0) {
- path = "man/" + kName;
- } else {
- path = "woman/" + kName;
- }
- return this.playEffect(path, false);
- },
- playEffectEX(kName) {
- var path = this.LG_PATH_SC + "effect/" + kName + this.RAW_KIND;
- if (cc.vv && cc.vv.audioMgr) {
- var audioID = cc.vv.audioMgr.playSFX(path);
- }
- },
- getDefineSound(iGender, kStr) {
- var value = "fix_msg_" + kStr;
- var path = this.LG_PATH_SC;
- if (iGender > 0) {
- path += "talk/man/" + value + this.RAW_KIND;
- } else {
- path += "talk/woman/" + value + this.RAW_KIND;
- }
- return path;
- },
- },
- start() {
- },
- });
|