parent
74fd2da1d1
commit
7192fa959b
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -1,26 +1,26 @@
|
|||
character.refresh={
|
||||
character:{
|
||||
re_caocao:['male','wei',4,['hujia','rejianxiong'],['zhu','fullskin','die_audio']],
|
||||
re_simayi:['male','wei',3,['refankui','reguicai'],['fullskin','die_audio']],
|
||||
re_guojia:['male','wei',3,['tiandu','reyiji'],['fullskin','die_audio']],
|
||||
re_caocao:['male','wei',4,['hujia','rejianxiong'],['zhu','fullskin']],
|
||||
re_simayi:['male','wei',3,['refankui','reguicai'],['fullskin']],
|
||||
re_guojia:['male','wei',3,['tiandu','reyiji'],['fullskin']],
|
||||
re_lidian:['male','wei',3,['xunxun','wangxi'],['fullskin']],
|
||||
re_zhangliao:['male','wei',4,['retuxi'],['fullskin','die_audio']],
|
||||
re_xuzhu:['male','wei',4,['reluoyi'],['fullskin','die_audio']],
|
||||
re_xiahoudun:['male','wei',4,['reganglie','qingjian'],['fullskin','die_audio']],
|
||||
re_zhangfei:['male','shu',4,['paoxiao','retishen'],['fullskin','die_audio']],
|
||||
re_zhaoyun:['male','shu',4,['longdan','reyajiao'],['fullskin'],['fullskin','die_audio']],
|
||||
re_guanyu:['male','shu',4,['wusheng','yijue'],['fullskin','die_audio']],
|
||||
re_machao:['male','shu',4,['mashu','retieji'],['fullskin','die_audio']],
|
||||
re_xushu:['male','shu',4,['zhuhai','qianxin'],['fullskin','die_audio']],
|
||||
re_zhouyu:['male','wu',3,['reyingzi','refanjian'],['fullskin','die_audio']],
|
||||
re_lvmeng:['male','wu',4,['keji','qinxue'],['fullskin','die_audio']],
|
||||
re_ganning:['male','wu',4,['qixi','fenwei'],['fullskin','die_audio']],
|
||||
re_luxun:['male','wu',3,['reqianxun','relianying'],['fullskin','die_audio']],
|
||||
re_daqiao:['female','wu',3,['reguose','liuli'],['fullskin','die_audio']],
|
||||
re_huanggai:['male','wu',4,['rekurou','zhaxiang'],['fullskin','die_audio']],
|
||||
re_lvbu:['male','qun',5,['wushuang'],['fullskin','die_audio']],
|
||||
re_zhangliao:['male','wei',4,['retuxi'],['fullskin']],
|
||||
re_xuzhu:['male','wei',4,['reluoyi'],['fullskin']],
|
||||
re_xiahoudun:['male','wei',4,['reganglie','qingjian'],['fullskin']],
|
||||
re_zhangfei:['male','shu',4,['paoxiao','retishen'],['fullskin']],
|
||||
re_zhaoyun:['male','shu',4,['longdan','reyajiao'],['fullskin'],['fullskin']],
|
||||
re_guanyu:['male','shu',4,['wusheng','yijue'],['fullskin']],
|
||||
re_machao:['male','shu',4,['mashu','retieji'],['fullskin']],
|
||||
re_xushu:['male','shu',4,['zhuhai','qianxin'],['fullskin']],
|
||||
re_zhouyu:['male','wu',3,['reyingzi','refanjian'],['fullskin']],
|
||||
re_lvmeng:['male','wu',4,['keji','qinxue'],['fullskin']],
|
||||
re_ganning:['male','wu',4,['qixi','fenwei'],['fullskin']],
|
||||
re_luxun:['male','wu',3,['reqianxun','relianying'],['fullskin']],
|
||||
re_daqiao:['female','wu',3,['reguose','liuli'],['fullskin']],
|
||||
re_huanggai:['male','wu',4,['rekurou','zhaxiang'],['fullskin']],
|
||||
re_lvbu:['male','qun',5,['wushuang'],['fullskin']],
|
||||
re_gongsunzan:['male','qun',4,['qiaomeng','reyicong'],['fullskin']],
|
||||
re_huatuo:['male','qun',3,['chulao','jijiu'],['fullskin','die_audio']],
|
||||
re_huatuo:['male','qun',3,['chulao','jijiu'],['fullskin']],
|
||||
},
|
||||
skill:{
|
||||
reqicai:{
|
||||
|
@ -59,7 +59,6 @@ character.refresh={
|
|||
}
|
||||
},
|
||||
retuxi:{
|
||||
audio:2,
|
||||
trigger:{player:'phaseDrawBefore'},
|
||||
direct:true,
|
||||
content:function(){
|
||||
|
@ -85,7 +84,6 @@ character.refresh={
|
|||
}
|
||||
},
|
||||
reguicai:{
|
||||
audio:2,
|
||||
trigger:{global:'judge'},
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
|
@ -129,7 +127,6 @@ character.refresh={
|
|||
}
|
||||
},
|
||||
refankui:{
|
||||
audio:2,
|
||||
trigger:{player:'damageEnd'},
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
|
@ -165,7 +162,6 @@ character.refresh={
|
|||
}
|
||||
},
|
||||
reluoyi:{
|
||||
audio:2,
|
||||
trigger:{player:'phaseDrawBegin'},
|
||||
check:function(event,player){
|
||||
if(player.num('h','sha')) return true;
|
||||
|
@ -550,7 +546,6 @@ character.refresh={
|
|||
}
|
||||
},
|
||||
rejianxiong:{
|
||||
audio:2,
|
||||
trigger:{player:'damageEnd'},
|
||||
direct:true,
|
||||
content:function(){
|
||||
|
|
|
@ -1,30 +1,30 @@
|
|||
character.standard={
|
||||
character:{
|
||||
caocao:['male','wei',4,['hujia','jianxiong'],['zhu','fullskin','die_audio']],
|
||||
caocao:['male','wei',4,['hujia','jianxiong'],['zhu','fullskin']],
|
||||
simayi:['male','wei',3,['fankui','guicai'],['fullskin']],
|
||||
xiahoudun:['male','wei',4,['ganglie'],['fullskin','die_audio']],
|
||||
zhangliao:['male','wei',4,['tuxi'],['fullskin','die_audio']],
|
||||
xuzhu:['male','wei',4,['luoyi'],['fullskin','die_audio']],
|
||||
guojia:['male','wei',3,['tiandu','yiji'],['fullskin','die_audio']],
|
||||
zhenji:['female','wei',3,['luoshen','qingguo'],['fullskin','die_audio']],
|
||||
liubei:['male','shu',4,['rende','jijiang'],['zhu','fullskin','die_audio']],
|
||||
guanyu:['male','shu',4,['wusheng'],['fullskin','die_audio']],
|
||||
zhangfei:['male','shu',4,['paoxiao'],['fullskin','die_audio']],
|
||||
zhugeliang:['male','shu',3,['guanxing','kongcheng'],['fullskin','die_audio']],
|
||||
zhaoyun:['male','shu',4,['longdan'],['fullskin','die_audio']],
|
||||
machao:['male','shu',4,['mashu','tieji'],['fullskin','die_audio']],
|
||||
huangyueying:['female','shu',3,['jizhi','qicai'],['fullskin','die_audio']],
|
||||
sunquan:['male','wu',4,['zhiheng','jiuyuan'],['zhu','fullskin','die_audio']],
|
||||
ganning:['male','wu',4,['qixi'],['fullskin','die_audio']],
|
||||
lvmeng:['male','wu',4,['keji'],['fullskin','die_audio']],
|
||||
huanggai:['male','wu',4,['kurou'],['fullskin','die_audio']],
|
||||
zhouyu:['male','wu',3,['yingzi','fanjian'],['fullskin','die_audio']],
|
||||
daqiao:['female','wu',3,['guose','liuli'],['fullskin','die_audio']],
|
||||
luxun:['male','wu',3,['qianxun','lianying'],['fullskin','die_audio']],
|
||||
sunshangxiang:['female','wu',3,['xiaoji','jieyin'],['fullskin','die_audio']],
|
||||
huatuo:['male','qun',3,['qingnang','jijiu'],['fullskin','die_audio']],
|
||||
lvbu:['male','qun',4,['wushuang'],['fullskin','die_audio']],
|
||||
diaochan:['female','qun',3,['lijian','biyue'],['fullskin','die_audio']],
|
||||
xiahoudun:['male','wei',4,['ganglie'],['fullskin']],
|
||||
zhangliao:['male','wei',4,['tuxi'],['fullskin']],
|
||||
xuzhu:['male','wei',4,['luoyi'],['fullskin']],
|
||||
guojia:['male','wei',3,['tiandu','yiji'],['fullskin']],
|
||||
zhenji:['female','wei',3,['luoshen','qingguo'],['fullskin']],
|
||||
liubei:['male','shu',4,['rende','jijiang'],['zhu','fullskin']],
|
||||
guanyu:['male','shu',4,['wusheng'],['fullskin']],
|
||||
zhangfei:['male','shu',4,['paoxiao'],['fullskin']],
|
||||
zhugeliang:['male','shu',3,['guanxing','kongcheng'],['fullskin']],
|
||||
zhaoyun:['male','shu',4,['longdan'],['fullskin']],
|
||||
machao:['male','shu',4,['mashu','tieji'],['fullskin']],
|
||||
huangyueying:['female','shu',3,['jizhi','qicai'],['fullskin']],
|
||||
sunquan:['male','wu',4,['zhiheng','jiuyuan'],['zhu','fullskin']],
|
||||
ganning:['male','wu',4,['qixi'],['fullskin']],
|
||||
lvmeng:['male','wu',4,['keji'],['fullskin']],
|
||||
huanggai:['male','wu',4,['kurou'],['fullskin']],
|
||||
zhouyu:['male','wu',3,['yingzi','fanjian'],['fullskin']],
|
||||
daqiao:['female','wu',3,['guose','liuli'],['fullskin']],
|
||||
luxun:['male','wu',3,['qianxun','lianying'],['fullskin']],
|
||||
sunshangxiang:['female','wu',3,['xiaoji','jieyin'],['fullskin']],
|
||||
huatuo:['male','qun',3,['qingnang','jijiu'],['fullskin']],
|
||||
lvbu:['male','qun',4,['wushuang'],['fullskin']],
|
||||
diaochan:['female','qun',3,['lijian','biyue'],['fullskin']],
|
||||
},
|
||||
perfectPair:{
|
||||
xiahoudun:['xiahouyuan'],
|
||||
|
@ -41,7 +41,6 @@ character.standard={
|
|||
},
|
||||
skill:{
|
||||
hujia:{
|
||||
audio:2,
|
||||
unique:true,
|
||||
trigger:{player:'chooseToRespondBegin'},
|
||||
filter:function(event,player){
|
||||
|
@ -88,7 +87,7 @@ character.standard={
|
|||
},
|
||||
},
|
||||
jianxiong:{
|
||||
audio:2,
|
||||
|
||||
trigger:{player:'damageEnd'},
|
||||
filter:function(event,player){
|
||||
return get.itemtype(event.cards)=='cards'&&get.position(event.cards[0])=='d';
|
||||
|
@ -108,7 +107,7 @@ character.standard={
|
|||
}
|
||||
},
|
||||
fankui:{
|
||||
audio:2,
|
||||
|
||||
trigger:{player:'damageEnd'},
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
|
@ -136,7 +135,6 @@ character.standard={
|
|||
}
|
||||
},
|
||||
guicai:{
|
||||
audio:2,
|
||||
trigger:{global:'judge'},
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
|
@ -182,7 +180,6 @@ character.standard={
|
|||
}
|
||||
},
|
||||
ganglie:{
|
||||
audio:2,
|
||||
trigger:{player:'damageEnd'},
|
||||
filter:function(event,player){
|
||||
return (event.source!=undefined);
|
||||
|
@ -218,7 +215,6 @@ character.standard={
|
|||
}
|
||||
},
|
||||
tuxi:{
|
||||
audio:2,
|
||||
trigger:{player:'phaseDrawBefore'},
|
||||
direct:true,
|
||||
content:function(){
|
||||
|
@ -258,7 +254,6 @@ character.standard={
|
|||
}
|
||||
},
|
||||
luoyi:{
|
||||
audio:2,
|
||||
trigger:{player:'phaseDrawBegin'},
|
||||
check:function(event,player){
|
||||
var i,cancel=true;
|
||||
|
@ -729,9 +724,6 @@ character.standard={
|
|||
}
|
||||
},
|
||||
ai:{
|
||||
tag:{
|
||||
// rejudge:0.3
|
||||
},
|
||||
threaten:1.2
|
||||
}
|
||||
},
|
||||
|
|
|
@ -74,6 +74,7 @@ window.config={
|
|||
background_music_config:'背景音乐',
|
||||
background_audio_config:'游戏音效',
|
||||
background_speak_config:'人物配音',
|
||||
background_ogg_config:'补全配音',
|
||||
music_default:'默认',
|
||||
music_diaochan:'貂蝉',
|
||||
music_danji:'单骑',
|
||||
|
|
101
game/game.js
101
game/game.js
|
@ -1130,13 +1130,23 @@ window.play={};
|
|||
player.checkShow(event.skill);
|
||||
}
|
||||
}
|
||||
if(lib.config.background_audio&&lib.card[card.name].audio){
|
||||
if(lib.config.background_audio){
|
||||
var sex=player.sex=='female'?'female':'male';
|
||||
if(card.name=='sha'&&(card.nature=='fire'||card.nature=='thunder')){
|
||||
game.playAudio('card',sex,card.name+'_'+card.nature);
|
||||
if(lib.card[card.name].audio){
|
||||
if(card.name=='sha'&&(card.nature=='fire'||card.nature=='thunder')){
|
||||
game.playAudio('card',sex,card.name+'_'+card.nature);
|
||||
}
|
||||
else{
|
||||
game.playAudio('card',sex,card.name);
|
||||
}
|
||||
}
|
||||
else{
|
||||
game.playAudio('card',sex,card.name);
|
||||
if(lib.config.background_ogg){
|
||||
game.playAudioOgg('card',sex,card.name);
|
||||
}
|
||||
else{
|
||||
game.playAudio('card/default');
|
||||
}
|
||||
}
|
||||
}
|
||||
if(event.animate!=false){
|
||||
|
@ -1274,8 +1284,17 @@ window.play={};
|
|||
useSkill:function(){
|
||||
"step 0"
|
||||
var info=get.info(event.skill);
|
||||
if(lib.config.background_speak&&info.audio){
|
||||
game.playAudio('skill',event.skill,Math.ceil(info.audio*Math.random()));
|
||||
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()));
|
||||
}
|
||||
else if(lib.config.background_ogg){
|
||||
game.playAudioOgg('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);
|
||||
|
@ -1392,6 +1411,9 @@ window.play={};
|
|||
ui.clear();
|
||||
},
|
||||
draw:function(){
|
||||
if(lib.config.background_audio){
|
||||
game.playAudio('effect','draw');
|
||||
}
|
||||
if(event.log!=false){
|
||||
game.log(get.translation(player)+'摸了'+get.cnNumber(num)+'张牌');
|
||||
}
|
||||
|
@ -1406,6 +1428,9 @@ window.play={};
|
|||
},
|
||||
discard:function(){
|
||||
"step 0"
|
||||
if(lib.config.background_audio){
|
||||
game.playAudio('effect','discard');
|
||||
}
|
||||
var str=get.translation(player)+'弃置了';
|
||||
str+=get.translation(cards[0]);
|
||||
for(var i=1;i<cards.length;i++){
|
||||
|
@ -1426,9 +1451,17 @@ window.play={};
|
|||
}
|
||||
}
|
||||
if(event.parent.parent.parent.name=='useCard'){
|
||||
if(lib.config.background_audio&&lib.card[card.name].audio){
|
||||
if(lib.config.background_audio){
|
||||
var sex=player.sex=='female'?'female':'male';
|
||||
game.playAudio('card',sex,card.name);
|
||||
if(lib.card[card.name].audio){
|
||||
game.playAudio('card',sex,card.name);
|
||||
}
|
||||
else{
|
||||
if(lib.config.background_ogg){
|
||||
game.playAudioOgg('card',sex,card.name);
|
||||
}
|
||||
game.playAudio('card/default');
|
||||
}
|
||||
}
|
||||
}
|
||||
var str=get.translation(player)+'打出了';
|
||||
|
@ -1660,6 +1693,9 @@ window.play={};
|
|||
}
|
||||
},
|
||||
recover:function(){
|
||||
if(lib.config.background_audio){
|
||||
game.playAudio('effect','recover');
|
||||
}
|
||||
if(num>player.maxHp-player.hp) num=player.maxHp-player.hp;
|
||||
if(num>0){
|
||||
player.changeHp(num);
|
||||
|
@ -1796,7 +1832,10 @@ window.play={};
|
|||
if(lib.config.background_speak){
|
||||
if(lib.character[player.name]&&lib.character[player.name][4]&&
|
||||
lib.character[player.name][4].contains('die_audio')){
|
||||
game.playAudio('die',player.name)
|
||||
game.playAudio('die',player.name);
|
||||
}
|
||||
else if(lib.config.background_ogg){
|
||||
game.playAudioOgg('die',player.name);
|
||||
}
|
||||
}
|
||||
if(lib.config.background_audio){
|
||||
|
@ -3390,8 +3429,16 @@ window.play={};
|
|||
this.checkShow(name);
|
||||
}
|
||||
var info=lib.skill[name];
|
||||
if(info&&lib.config.background_speak&&info.audio){
|
||||
game.playAudio('skill',name,Math.ceil(info.audio*Math.random()));
|
||||
if(info&&lib.config.background_speak){
|
||||
if(info.audio){
|
||||
game.playAudio('skill',name,Math.ceil(info.audio*Math.random()));
|
||||
}
|
||||
else{
|
||||
if(lib.config.background_ogg){
|
||||
game.playAudioOgg('skill',name);
|
||||
}
|
||||
game.playAudio('skill','default',Math.ceil(Math.random()*5));
|
||||
}
|
||||
}
|
||||
},
|
||||
unprompt:function(){
|
||||
|
@ -4897,6 +4944,25 @@ window.play={};
|
|||
};
|
||||
ui.window.appendChild(audio);
|
||||
},
|
||||
playAudioOgg:function(){
|
||||
var str='';
|
||||
for(var i=0;i<arguments.length;i++){
|
||||
if(typeof arguments[i]==='string'||typeof arguments[i]=='number'){
|
||||
str+='/'+arguments[i];
|
||||
}
|
||||
}
|
||||
var audio=document.createElement('audio');
|
||||
audio.autoplay=true;
|
||||
audio.volume=lib.config.volumn_audio/8;
|
||||
audio.src='audio'+str+'.ogg';
|
||||
audio.addEventListener('ended',function(){
|
||||
this.remove();
|
||||
});
|
||||
audio.onerror=function(e){
|
||||
this.remove();
|
||||
};
|
||||
ui.window.appendChild(audio);
|
||||
},
|
||||
playBackgroundMusic:function(){
|
||||
if(lib.config.background_music=='music_off'){
|
||||
ui.backgroundMusic.src='';
|
||||
|
@ -6711,6 +6777,7 @@ window.play={};
|
|||
gameconfig.push(ui.create.switcher('background_music',lib.config.all.background_music,lib.config.background_music,ui.click.sidebar.background_music));
|
||||
gameconfig.push(ui.create.switcher('background_audio',lib.config.background_audio,ui.click.sidebar.global));
|
||||
gameconfig.push(ui.create.switcher('background_speak',lib.config.background_speak,ui.click.sidebar.global));
|
||||
gameconfig.push(ui.create.switcher('background_ogg',lib.config.background_ogg,ui.click.sidebar.global));
|
||||
gameconfig.push(ui.create.div('.placeholder'));
|
||||
|
||||
if(lib.config.gameconfig){
|
||||
|
@ -7851,13 +7918,15 @@ window.play={};
|
|||
if(e.path[i].classList.contains('selectable')&&
|
||||
!e.path[i].classList.contains('selected')&&
|
||||
!e.path[i].classList.contains('noclick')){
|
||||
_status.mousedragging=e;
|
||||
_status.mousedragorigin=e.path[i];
|
||||
_status.mouseleft=false;
|
||||
_status.clicked=false;
|
||||
_status.selectionfull=false;
|
||||
ui.click[itemtype].call(e.path[i]);
|
||||
_status.multitarget=false;
|
||||
if(e.path[i].classList.contains('selected')){
|
||||
_status.mousedragging=e;
|
||||
_status.mousedragorigin=e.path[i];
|
||||
_status.mouseleft=false;
|
||||
_status.selectionfull=false;
|
||||
_status.multitarget=false;
|
||||
}
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue