diff --git a/audio/card/female/hongshui.mp3 b/audio/card/female/hongshui.mp3 new file mode 100644 index 000000000..c30a0911f Binary files /dev/null and b/audio/card/female/hongshui.mp3 differ diff --git a/audio/effect/damage.mp3 b/audio/effect/damage.mp3 index 3948a24d2..99c48c207 100644 Binary files a/audio/effect/damage.mp3 and b/audio/effect/damage.mp3 differ diff --git a/audio/effect/damage2.mp3 b/audio/effect/damage2.mp3 new file mode 100644 index 000000000..3e6851a66 Binary files /dev/null and b/audio/effect/damage2.mp3 differ diff --git a/audio/effect/equip1.mp3 b/audio/effect/equip1.mp3 index 02e926a18..582e1d953 100644 Binary files a/audio/effect/equip1.mp3 and b/audio/effect/equip1.mp3 differ diff --git a/audio/effect/equip2.mp3 b/audio/effect/equip2.mp3 index cec4baefd..f848bb796 100644 Binary files a/audio/effect/equip2.mp3 and b/audio/effect/equip2.mp3 differ diff --git a/audio/effect/equip3.mp3 b/audio/effect/equip3.mp3 index 8b10b52c7..ba21f751f 100644 Binary files a/audio/effect/equip3.mp3 and b/audio/effect/equip3.mp3 differ diff --git a/audio/effect/equip4.mp3 b/audio/effect/equip4.mp3 index 8b10b52c7..ba21f751f 100644 Binary files a/audio/effect/equip4.mp3 and b/audio/effect/equip4.mp3 differ diff --git a/audio/effect/equip5.mp3 b/audio/effect/equip5.mp3 index f159b12d9..f848bb796 100644 Binary files a/audio/effect/equip5.mp3 and b/audio/effect/equip5.mp3 differ diff --git a/audio/effect/link.mp3 b/audio/effect/link.mp3 new file mode 100644 index 000000000..8e25ee199 Binary files /dev/null and b/audio/effect/link.mp3 differ diff --git a/audio/effect/lose.mp3 b/audio/effect/lose.mp3 new file mode 100644 index 000000000..497126aac Binary files /dev/null and b/audio/effect/lose.mp3 differ diff --git a/audio/effect/loseHp.mp3 b/audio/effect/loseHp.mp3 new file mode 100644 index 000000000..55feb5b33 Binary files /dev/null and b/audio/effect/loseHp.mp3 differ diff --git a/audio/effect/recover.mp3 b/audio/effect/recover.mp3 index ef55a1d24..1472462d3 100644 Binary files a/audio/effect/recover.mp3 and b/audio/effect/recover.mp3 differ diff --git a/audio/effect/tie.mp3 b/audio/effect/tie.mp3 new file mode 100644 index 000000000..ee2af0b43 Binary files /dev/null and b/audio/effect/tie.mp3 differ diff --git a/audio/effect/win.mp3 b/audio/effect/win.mp3 new file mode 100644 index 000000000..b3ac7ad62 Binary files /dev/null and b/audio/effect/win.mp3 differ diff --git a/audio/skill/bagua_skill.mp3 b/audio/skill/bagua_skill.mp3 new file mode 100644 index 000000000..95b641d79 Binary files /dev/null and b/audio/skill/bagua_skill.mp3 differ diff --git a/audio/skill/cixiong_skill.mp3 b/audio/skill/cixiong_skill.mp3 new file mode 100644 index 000000000..aae4db5b7 Binary files /dev/null and b/audio/skill/cixiong_skill.mp3 differ diff --git a/audio/skill/default/1.mp3 b/audio/skill/default/1.mp3 deleted file mode 100644 index 3cf8a69d7..000000000 Binary files a/audio/skill/default/1.mp3 and /dev/null differ diff --git a/audio/skill/default/2.mp3 b/audio/skill/default/2.mp3 deleted file mode 100644 index 3cf8a69d7..000000000 Binary files a/audio/skill/default/2.mp3 and /dev/null differ diff --git a/audio/skill/default/3.mp3 b/audio/skill/default/3.mp3 deleted file mode 100644 index 3cf8a69d7..000000000 Binary files a/audio/skill/default/3.mp3 and /dev/null differ diff --git a/audio/skill/default/4.mp3 b/audio/skill/default/4.mp3 deleted file mode 100644 index 3cf8a69d7..000000000 Binary files a/audio/skill/default/4.mp3 and /dev/null differ diff --git a/audio/skill/default/5.mp3 b/audio/skill/default/5.mp3 deleted file mode 100644 index 3cf8a69d7..000000000 Binary files a/audio/skill/default/5.mp3 and /dev/null differ diff --git a/audio/skill/default/female/1.mp3 b/audio/skill/default/female/1.mp3 deleted file mode 100644 index 4f9c80c2f..000000000 Binary files a/audio/skill/default/female/1.mp3 and /dev/null differ diff --git a/audio/skill/default/female/2.mp3 b/audio/skill/default/female/2.mp3 deleted file mode 100644 index b34919e55..000000000 Binary files a/audio/skill/default/female/2.mp3 and /dev/null differ diff --git a/audio/skill/default/female/3.mp3 b/audio/skill/default/female/3.mp3 deleted file mode 100644 index f14bd4629..000000000 Binary files a/audio/skill/default/female/3.mp3 and /dev/null differ diff --git a/audio/skill/default/female/4.mp3 b/audio/skill/default/female/4.mp3 deleted file mode 100644 index dc73d9a35..000000000 Binary files a/audio/skill/default/female/4.mp3 and /dev/null differ diff --git a/audio/skill/default/female/5.mp3 b/audio/skill/default/female/5.mp3 deleted file mode 100644 index b34919e55..000000000 Binary files a/audio/skill/default/female/5.mp3 and /dev/null differ diff --git a/audio/skill/default/male/1.mp3 b/audio/skill/default/male/1.mp3 deleted file mode 100644 index f5831031d..000000000 Binary files a/audio/skill/default/male/1.mp3 and /dev/null differ diff --git a/audio/skill/default/male/2.mp3 b/audio/skill/default/male/2.mp3 deleted file mode 100644 index f5831031d..000000000 Binary files a/audio/skill/default/male/2.mp3 and /dev/null differ diff --git a/audio/skill/default/male/3.mp3 b/audio/skill/default/male/3.mp3 deleted file mode 100644 index 22a566982..000000000 Binary files a/audio/skill/default/male/3.mp3 and /dev/null differ diff --git a/audio/skill/default/male/4.mp3 b/audio/skill/default/male/4.mp3 deleted file mode 100644 index 38f50e2d2..000000000 Binary files a/audio/skill/default/male/4.mp3 and /dev/null differ diff --git a/audio/skill/default/male/5.mp3 b/audio/skill/default/male/5.mp3 deleted file mode 100644 index 22a566982..000000000 Binary files a/audio/skill/default/male/5.mp3 and /dev/null differ diff --git a/audio/skill/guanshi_skill.mp3 b/audio/skill/guanshi_skill.mp3 new file mode 100644 index 000000000..450519536 Binary files /dev/null and b/audio/skill/guanshi_skill.mp3 differ diff --git a/audio/skill/guding_skill.mp3 b/audio/skill/guding_skill.mp3 new file mode 100644 index 000000000..2093c2c94 Binary files /dev/null and b/audio/skill/guding_skill.mp3 differ diff --git a/audio/skill/hanbing_skill.mp3 b/audio/skill/hanbing_skill.mp3 new file mode 100644 index 000000000..8dab7e3fb Binary files /dev/null and b/audio/skill/hanbing_skill.mp3 differ diff --git a/audio/skill/qilin_skill.mp3 b/audio/skill/qilin_skill.mp3 new file mode 100644 index 000000000..2f0e9f373 Binary files /dev/null and b/audio/skill/qilin_skill.mp3 differ diff --git a/audio/skill/qinggang_skill.mp3 b/audio/skill/qinggang_skill.mp3 new file mode 100644 index 000000000..972a2ac04 Binary files /dev/null and b/audio/skill/qinggang_skill.mp3 differ diff --git a/audio/skill/renwang_skill.mp3 b/audio/skill/renwang_skill.mp3 new file mode 100644 index 000000000..900b24ab3 Binary files /dev/null and b/audio/skill/renwang_skill.mp3 differ diff --git a/audio/skill/sanjian_skill.mp3 b/audio/skill/sanjian_skill.mp3 new file mode 100644 index 000000000..3948a24d2 Binary files /dev/null and b/audio/skill/sanjian_skill.mp3 differ diff --git a/audio/skill/tengjia1.mp3 b/audio/skill/tengjia1.mp3 new file mode 100644 index 000000000..344e1f9d8 Binary files /dev/null and b/audio/skill/tengjia1.mp3 differ diff --git a/audio/skill/tengjia2.mp3 b/audio/skill/tengjia2.mp3 new file mode 100644 index 000000000..7f7889c42 Binary files /dev/null and b/audio/skill/tengjia2.mp3 differ diff --git a/audio/skill/zhangba_skill.mp3 b/audio/skill/zhangba_skill.mp3 new file mode 100644 index 000000000..3b1fba06a Binary files /dev/null and b/audio/skill/zhangba_skill.mp3 differ diff --git a/audio/skill/zhuque_skill.mp3 b/audio/skill/zhuque_skill.mp3 new file mode 100644 index 000000000..e04db06ef Binary files /dev/null and b/audio/skill/zhuque_skill.mp3 differ diff --git a/card/ex.js b/card/ex.js index 24c93d4ec..9a249048b 100644 --- a/card/ex.js +++ b/card/ex.js @@ -29,12 +29,13 @@ card.ex={ hanbing_skill:{ trigger:{player:'shaHit'}, direct:true, + audio:true, filter:function(event){ return event.target.get('he').length>0; }, content:function(){ "step 0" - player.choosePlayerCard('是否发动【寒冰剑】?','he',trigger.target,[1,2],function(button){ + player.choosePlayerCard('是否发动【寒冰剑】?','he',trigger.target,Math.min(2,trigger.target.num('he')),function(button){ var eff=ai.get.damageEffect(trigger.target,player,player); if(ai.get.attitude(player,trigger.target)>0){ if(eff>=0) return false; @@ -55,7 +56,7 @@ card.ex={ trigger.untrigger(); var cards=[]; for(var i=0;i2; }, @@ -1058,7 +1061,7 @@ card.standard={ }; "step 1" if(result.bool){ - player.logSkill('guanshi'); + player.logSkill('guanshi_skill'); trigger.untrigger(); trigger.trigger('shaHit'); trigger._result.bool=false; @@ -1081,15 +1084,17 @@ card.standard={ }, qilin_skill:{ trigger:{player:'shaHit'}, - popup:false, filter:function(event,player){ return event.target.get('e',{subtype:['equip3','equip4']}).length>0 }, + direct:true, + audio:true, content:function(){ "step 0" player.chooseButton(ui.create.dialog('选择要弃置的马',trigger.target.get('e',{subtype:['equip3','equip4']}))); "step 1" if(result.bool){ + player.logSkill('qilin_skill'); trigger.target.discard(result.buttons[0].link); } } @@ -1101,6 +1106,7 @@ card.standard={ if(event.parent.player.num('s','unequip')) return false; return true; }, + audio:true, content:function(){ "step 0" player.judge('bagua',function(card){return (get.color(card)=='red')?1.5:-0.5}); diff --git a/character/yijiang.js b/character/yijiang.js index a3ab4a24a..903fdf819 100644 --- a/character/yijiang.js +++ b/character/yijiang.js @@ -2445,8 +2445,8 @@ character.yijiang={ content:function(){ "step 0" event.cards=[targets[0].get('e'),targets[1].get('e')]; - targets[0].lose(event.cards[0]); - targets[1].lose(event.cards[1]); + targets[0].lose(event.cards[0],ui.special); + targets[1].lose(event.cards[1],ui.special); if(event.cards[0].length) targets[0].$give(event.cards[0],targets[1]); if(event.cards[1].length) targets[1].$give(event.cards[1],targets[0]); "step 1" diff --git a/game/game.js b/game/game.js index a763f0fb6..422e8c2d3 100644 --- a/game/game.js +++ b/game/game.js @@ -1142,7 +1142,7 @@ window.play={}; game.playAudio('card',sex,card.name); } } - else{ + else if(get.type(card)!='equip'){ game.playAudio('card/default'); } } @@ -1283,16 +1283,15 @@ window.play={}; var info=get.info(event.skill); event._skill=event.skill; if(lib.config.background_speak&&!lib.skill.global.contains(event.skill)){ - if(info.audio){ - game.playAudio('skill',event.skill,Math.ceil(info.audio*Math.random())); + if(typeof info.audio=='number'){ + game.playAudio('skill',event.skill+Math.ceil(info.audio*Math.random())); + } + else if(info.audio){ + game.playAudio('skill',event.skill); } else if(lib.config.background_ogg){ game.playAudio('skill',event.skill); } - else{ - game.playAudio('skill','default', - player.sex=='female'?'female':'male',Math.ceil(Math.random()*5)); - } } if(player.checkShow){ player.checkShow(event.skill); @@ -1611,7 +1610,7 @@ window.play={}; damage:function(){ "step 0" if(lib.config.background_audio){ - game.playAudio('effect','damage_'+(player.sex==='female'?'female':'male')); + game.playAudio('effect','damage'+(num>1?'2':'')); } var str=get.translation(player)+'受到了'; if(source) str+='来自'+(source==player?'自己':get.translation(source)+'的'); @@ -1655,6 +1654,9 @@ window.play={}; }, loseHp:function(){ "step 0" + if(lib.config.background_audio){ + game.playAudio('effect','loseHp'); + } game.log(get.translation(player)+'失去了'+get.cnNumber(num)+'点体力') player.changeHp(-num); "step 1" @@ -1793,9 +1795,9 @@ window.play={}; else if(lib.config.background_ogg){ game.playAudio('die',player.name); } - } - if(lib.config.background_audio){ - game.playAudio('effect','die_'+(player.sex==='female'?'female':'male')); + else if(lib.config.background_audio){ + game.playAudio('effect','die_'+(player.sex==='female'?'female':'male')); + } } if(player==game.me&&!_status.over){ ui.control.show(); @@ -1816,7 +1818,7 @@ window.play={}; }, equip:function(){ "step 0" - if(get.owner(card)) get.owner(card).lose(card); + if(get.owner(card)) get.owner(card).lose(card,ui.special); if(card.clone){ card.clone.moveTo(player,Math.random()<0.8?'flip':'rotate').delete(); @@ -1934,6 +1936,7 @@ window.play={}; game.log(get.translation(player)+'被连环'); } player.classList.toggle('linked'); + game.playAudio('effect','link'); }, }, @@ -3435,16 +3438,16 @@ window.play={}; } var info=lib.skill[name]; if(info&&lib.config.background_speak){ - if(info.audio){ - game.playAudio('skill',name,Math.ceil(info.audio*Math.random())); + if(typeof info.audio==='number'){ + game.playAudio('skill',name+Math.ceil(info.audio*Math.random())); + } + else if(info.audio){ + game.playAudio('skill',name); } else{ if(lib.config.background_ogg){ game.playAudio('skill',name); } - else{ - game.playAudio('skill','default',Math.ceil(Math.random()*5)); - } } } if(lib.config.mode=='chess'){ @@ -5222,6 +5225,17 @@ window.play={}; _status.over=true; ui.control.show(); ui.clear(); + if(lib.config.background_audio){ + if(result===true){ + game.playAudio('effect','win'); + } + else if(result===false){ + game.playAudio('effect','lose'); + } + else{ + game.playAudio('effect','tie'); + } + } if(result===true) result='战斗胜利'; if(result===false) result='战斗失败'; if(result==undefined) result='战斗结束';