1.7.9
This commit is contained in:
parent
9795055550
commit
f8e171e45c
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.
|
@ -831,6 +831,7 @@ character.boss={
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
boss_gongshenjg:{
|
boss_gongshenjg:{
|
||||||
|
audio:2,
|
||||||
trigger:{player:'phaseEnd'},
|
trigger:{player:'phaseEnd'},
|
||||||
mode:['versus'],
|
mode:['versus'],
|
||||||
filter:function(event,player){
|
filter:function(event,player){
|
||||||
|
@ -966,6 +967,7 @@ character.boss={
|
||||||
trigger:{player:'phaseBegin'},
|
trigger:{player:'phaseBegin'},
|
||||||
forced:true,
|
forced:true,
|
||||||
unique:true,
|
unique:true,
|
||||||
|
audio:false,
|
||||||
group:'boss_biantian4',
|
group:'boss_biantian4',
|
||||||
content:function(){
|
content:function(){
|
||||||
"step 0"
|
"step 0"
|
||||||
|
@ -987,6 +989,7 @@ character.boss={
|
||||||
"step 1"
|
"step 1"
|
||||||
var targets=[];
|
var targets=[];
|
||||||
if(result.color=='red'){
|
if(result.color=='red'){
|
||||||
|
game.playAudio('boss_biantianx2');
|
||||||
for(var i=0;i<game.players.length;i++){
|
for(var i=0;i<game.players.length;i++){
|
||||||
if(!game.players[i].isFriendOf(player)){
|
if(!game.players[i].isFriendOf(player)){
|
||||||
game.players[i].addSkill('boss_biantian3');
|
game.players[i].addSkill('boss_biantian3');
|
||||||
|
@ -997,6 +1000,7 @@ character.boss={
|
||||||
player.logSkill('kuangfeng',targets,'fire');
|
player.logSkill('kuangfeng',targets,'fire');
|
||||||
}
|
}
|
||||||
else if(result.suit=='spade'){
|
else if(result.suit=='spade'){
|
||||||
|
game.playAudio('boss_biantianx1');
|
||||||
for(var i=0;i<game.players.length;i++){
|
for(var i=0;i<game.players.length;i++){
|
||||||
if(game.players[i].isFriendOf(player)){
|
if(game.players[i].isFriendOf(player)){
|
||||||
game.players[i].addSkill('boss_biantian2');
|
game.players[i].addSkill('boss_biantian2');
|
||||||
|
@ -1012,6 +1016,7 @@ character.boss={
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
boss_biantian2:{
|
boss_biantian2:{
|
||||||
|
audio:false,
|
||||||
trigger:{player:'damageBefore'},
|
trigger:{player:'damageBefore'},
|
||||||
filter:function(event){
|
filter:function(event){
|
||||||
if(event.nature!='thunder') return true;
|
if(event.nature!='thunder') return true;
|
||||||
|
@ -1061,6 +1066,7 @@ character.boss={
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
boss_jizhen:{
|
boss_jizhen:{
|
||||||
|
audio:2,
|
||||||
trigger:{player:'phaseEnd'},
|
trigger:{player:'phaseEnd'},
|
||||||
forced:true,
|
forced:true,
|
||||||
filter:function(event,player){
|
filter:function(event,player){
|
||||||
|
@ -1088,6 +1094,7 @@ character.boss={
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
boss_lingfeng:{
|
boss_lingfeng:{
|
||||||
|
audio:2,
|
||||||
trigger:{player:'phaseDrawBefore'},
|
trigger:{player:'phaseDrawBefore'},
|
||||||
content:function(){
|
content:function(){
|
||||||
"step 0"
|
"step 0"
|
||||||
|
@ -1118,6 +1125,7 @@ character.boss={
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
boss_jueji:{
|
boss_jueji:{
|
||||||
|
audio:2,
|
||||||
trigger:{global:'phaseDrawBegin'},
|
trigger:{global:'phaseDrawBegin'},
|
||||||
filter:function(event,player){
|
filter:function(event,player){
|
||||||
if(event.player.isFriendOf(player)){
|
if(event.player.isFriendOf(player)){
|
||||||
|
@ -1138,6 +1146,7 @@ character.boss={
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
boss_huodi:{
|
boss_huodi:{
|
||||||
|
audio:2,
|
||||||
trigger:{player:'phaseEnd'},
|
trigger:{player:'phaseEnd'},
|
||||||
direct:true,
|
direct:true,
|
||||||
filter:function(event,player){
|
filter:function(event,player){
|
||||||
|
@ -1166,6 +1175,7 @@ character.boss={
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
boss_chuanyun:{
|
boss_chuanyun:{
|
||||||
|
audio:true,
|
||||||
trigger:{player:'phaseEnd'},
|
trigger:{player:'phaseEnd'},
|
||||||
direct:true,
|
direct:true,
|
||||||
content:function(){
|
content:function(){
|
||||||
|
@ -1183,6 +1193,7 @@ character.boss={
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
boss_leili:{
|
boss_leili:{
|
||||||
|
audio:2,
|
||||||
trigger:{source:'damageEnd'},
|
trigger:{source:'damageEnd'},
|
||||||
direct:true,
|
direct:true,
|
||||||
filter:function(event){
|
filter:function(event){
|
||||||
|
@ -1208,6 +1219,7 @@ character.boss={
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
boss_fengxing:{
|
boss_fengxing:{
|
||||||
|
audio:true,
|
||||||
trigger:{player:'phaseBegin'},
|
trigger:{player:'phaseBegin'},
|
||||||
direct:true,
|
direct:true,
|
||||||
content:function(){
|
content:function(){
|
||||||
|
@ -1230,6 +1242,7 @@ character.boss={
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
boss_xuanlei:{
|
boss_xuanlei:{
|
||||||
|
audio:true,
|
||||||
trigger:{player:'phaseBegin'},
|
trigger:{player:'phaseBegin'},
|
||||||
forced:true,
|
forced:true,
|
||||||
filter:function(event,player){
|
filter:function(event,player){
|
||||||
|
@ -1256,6 +1269,7 @@ character.boss={
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
boss_fanshi:{
|
boss_fanshi:{
|
||||||
|
audio:true,
|
||||||
trigger:{player:'phaseEnd'},
|
trigger:{player:'phaseEnd'},
|
||||||
forced:true,
|
forced:true,
|
||||||
check:function(){
|
check:function(){
|
||||||
|
@ -1266,9 +1280,11 @@ character.boss={
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
boss_skonghun:{
|
boss_skonghun:{
|
||||||
|
audio:true,
|
||||||
trigger:{player:'phaseUseBegin'},
|
trigger:{player:'phaseUseBegin'},
|
||||||
filter:function(event,player){
|
filter:function(event,player){
|
||||||
var num=player.maxHp-player.hp;
|
var num=player.maxHp-player.hp;
|
||||||
|
if(num==0) return false;
|
||||||
for(var i=0;i<game.players.length;i++){
|
for(var i=0;i<game.players.length;i++){
|
||||||
if(game.players[i].side!=player.side){
|
if(game.players[i].side!=player.side){
|
||||||
num--;
|
num--;
|
||||||
|
@ -1306,6 +1322,7 @@ character.boss={
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
boss_chiying:{
|
boss_chiying:{
|
||||||
|
audio:2,
|
||||||
trigger:{global:'damageBegin'},
|
trigger:{global:'damageBegin'},
|
||||||
forced:true,
|
forced:true,
|
||||||
filter:function(event,player){
|
filter:function(event,player){
|
||||||
|
@ -2431,6 +2448,7 @@ character.boss={
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
boss_yuhuojg:{
|
boss_yuhuojg:{
|
||||||
|
audio:true,
|
||||||
trigger:{player:'damageBefore'},
|
trigger:{player:'damageBefore'},
|
||||||
filter:function(event){
|
filter:function(event){
|
||||||
return event.nature=='fire';
|
return event.nature=='fire';
|
||||||
|
@ -2547,6 +2565,7 @@ character.boss={
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
boss_qiwu:{
|
boss_qiwu:{
|
||||||
|
audio:true,
|
||||||
trigger:{player:'useCard'},
|
trigger:{player:'useCard'},
|
||||||
direct:true,
|
direct:true,
|
||||||
filter:function(event,player){
|
filter:function(event,player){
|
||||||
|
|
|
@ -1644,6 +1644,7 @@ character.shenhua={
|
||||||
},
|
},
|
||||||
yinghun:{
|
yinghun:{
|
||||||
audio:2,
|
audio:2,
|
||||||
|
audioname:['sunce'],
|
||||||
trigger:{player:'phaseBegin'},
|
trigger:{player:'phaseBegin'},
|
||||||
filter:function(event,player){
|
filter:function(event,player){
|
||||||
return player.hp<player.maxHp;
|
return player.hp<player.maxHp;
|
||||||
|
@ -1651,7 +1652,7 @@ character.shenhua={
|
||||||
direct:true,
|
direct:true,
|
||||||
content:function(){
|
content:function(){
|
||||||
"step 0"
|
"step 0"
|
||||||
player.chooseTarget(function(card,player,target){
|
player.chooseTarget('是否发动【英魂】?',function(card,player,target){
|
||||||
return player!=target;
|
return player!=target;
|
||||||
}).ai=function(target){
|
}).ai=function(target){
|
||||||
if(player.maxHp-player.hp==1&&target.num('he')==0){
|
if(player.maxHp-player.hp==1&&target.num('he')==0){
|
||||||
|
|
|
@ -520,6 +520,7 @@ character.standard={
|
||||||
},
|
},
|
||||||
jijiang1:{
|
jijiang1:{
|
||||||
audio:2,
|
audio:2,
|
||||||
|
audioname:['liushan'],
|
||||||
trigger:{player:'chooseToRespondBegin'},
|
trigger:{player:'chooseToRespondBegin'},
|
||||||
filter:function(event,player){
|
filter:function(event,player){
|
||||||
if(event.responded) return false;
|
if(event.responded) return false;
|
||||||
|
@ -568,6 +569,7 @@ character.standard={
|
||||||
},
|
},
|
||||||
jijiang2:{
|
jijiang2:{
|
||||||
audio:2,
|
audio:2,
|
||||||
|
audioname:['liushan'],
|
||||||
enable:'chooseToUse',
|
enable:'chooseToUse',
|
||||||
filter:function(event,player){
|
filter:function(event,player){
|
||||||
if(event.filterCard&&!event.filterCard({name:'sha'},player)) return false;
|
if(event.filterCard&&!event.filterCard({name:'sha'},player)) return false;
|
||||||
|
@ -672,6 +674,7 @@ character.standard={
|
||||||
},
|
},
|
||||||
guanxing:{
|
guanxing:{
|
||||||
audio:2,
|
audio:2,
|
||||||
|
audioname:['jiangwei'],
|
||||||
trigger:{player:'phaseBegin'},
|
trigger:{player:'phaseBegin'},
|
||||||
frequent:true,
|
frequent:true,
|
||||||
content:function(){
|
content:function(){
|
||||||
|
@ -901,6 +904,7 @@ character.standard={
|
||||||
},
|
},
|
||||||
jizhi:{
|
jizhi:{
|
||||||
audio:2,
|
audio:2,
|
||||||
|
audioname:['jianyong'],
|
||||||
trigger:{player:'useCard'},
|
trigger:{player:'useCard'},
|
||||||
frequent:true,
|
frequent:true,
|
||||||
filter:function(event){
|
filter:function(event){
|
||||||
|
|
|
@ -4206,12 +4206,43 @@ character.yijiang={
|
||||||
order:5,
|
order:5,
|
||||||
result:{
|
result:{
|
||||||
player:function(player){
|
player:function(player){
|
||||||
|
if(_status.event.parent.name=='phaseUse'){
|
||||||
|
if(player.num('h','jiu')>0) return 0;
|
||||||
|
if(player.num('e','zhuge')&&player.num('h','sha')>1) return 0;
|
||||||
|
if(!player.num('h','sha')) return 0;
|
||||||
|
for(var i=0;i<game.players.length;i++){
|
||||||
|
if(ai.get.attitude(player,game.players[i])<0){
|
||||||
|
var target=game.players[i];
|
||||||
|
if(player.canUse('sha',target)&&ai.get.effect(target,{name:'sha'},player,player)>0){
|
||||||
|
var e2=target.get('e','2');
|
||||||
|
if(e2){
|
||||||
|
if(e2.name=='tengjia'){
|
||||||
|
if(!player.num('h',{name:'sha',nature:'fire'})&&!player.num('e','zhuque')) return 0;
|
||||||
|
}
|
||||||
|
if(e2.name=='renwang'){
|
||||||
|
if(!player.num('h',{name:'sha',color:'red'})) return 0;
|
||||||
|
}
|
||||||
|
if(e2.name=='baiyin') return 0;
|
||||||
|
}
|
||||||
|
if(player.num('e','guanshi')&&player.num('he')>2) return 1;
|
||||||
|
return target.num('h')>3?0:1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
if(player==_status.event.dying||player.isTurnedOver()) return 3;
|
if(player==_status.event.dying||player.isTurnedOver()) return 3;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
effect:{
|
effect:{
|
||||||
target:function(card){
|
target:function(card,player,target){
|
||||||
if(card.name=='guiyoujie') return [0,0.5];
|
if(card.name=='guiyoujie') return [0,0.5];
|
||||||
|
if(target.isTurnedOver()){
|
||||||
|
if(get.tag(card,'damage')){
|
||||||
|
if(player.skills.contains('jueqing')) return [1,-2];
|
||||||
|
if(target.hp==1) return;
|
||||||
|
return [1,target.num('h')/2];
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
36
game/game.js
36
game/game.js
|
@ -18,7 +18,9 @@
|
||||||
var lib={
|
var lib={
|
||||||
version:1.79,
|
version:1.79,
|
||||||
changeLog:[
|
changeLog:[
|
||||||
|
'修bug',
|
||||||
'自动标身份',
|
'自动标身份',
|
||||||
|
'配音支持与人名关联',
|
||||||
],
|
],
|
||||||
configprefix:'noname_0.9_',
|
configprefix:'noname_0.9_',
|
||||||
updates:[],
|
updates:[],
|
||||||
|
@ -32,6 +34,7 @@
|
||||||
characterPack:{},
|
characterPack:{},
|
||||||
cardPack:{},
|
cardPack:{},
|
||||||
onresize:[],
|
onresize:[],
|
||||||
|
onwash:[],
|
||||||
onDB:function(func){
|
onDB:function(func){
|
||||||
if(lib.db){
|
if(lib.db){
|
||||||
func();
|
func();
|
||||||
|
@ -4434,6 +4437,17 @@
|
||||||
audioname=audioinfo[0];
|
audioname=audioinfo[0];
|
||||||
audioinfo=audioinfo[1];
|
audioinfo=audioinfo[1];
|
||||||
}
|
}
|
||||||
|
if(Array.isArray(info.audioname)){
|
||||||
|
if(info.audioname.contains(player.name)){
|
||||||
|
audioname+='_'+player.name;
|
||||||
|
}
|
||||||
|
else if(info.audioname.contains(player.name1)){
|
||||||
|
audioname+='_'+player.name1;
|
||||||
|
}
|
||||||
|
else if(info.audioname.contains(player.name2)){
|
||||||
|
audioname+='_'+player.name2;
|
||||||
|
}
|
||||||
|
}
|
||||||
if(typeof audioinfo=='number'){
|
if(typeof audioinfo=='number'){
|
||||||
game.playAudio('skill',audioname+Math.ceil(audioinfo*Math.random()));
|
game.playAudio('skill',audioname+Math.ceil(audioinfo*Math.random()));
|
||||||
}
|
}
|
||||||
|
@ -6977,6 +6991,17 @@
|
||||||
audioname=audioinfo[0];
|
audioname=audioinfo[0];
|
||||||
audioinfo=audioinfo[1];
|
audioinfo=audioinfo[1];
|
||||||
}
|
}
|
||||||
|
if(Array.isArray(info.audioname)){
|
||||||
|
if(info.audioname.contains(this.name)){
|
||||||
|
audioname+='_'+this.name;
|
||||||
|
}
|
||||||
|
else if(info.audioname.contains(this.name1)){
|
||||||
|
audioname+='_'+this.name1;
|
||||||
|
}
|
||||||
|
else if(info.audioname.contains(this.name2)){
|
||||||
|
audioname+='_'+this.name2;
|
||||||
|
}
|
||||||
|
}
|
||||||
if(typeof audioinfo==='number'){
|
if(typeof audioinfo==='number'){
|
||||||
game.playAudio('skill',audioname+Math.ceil(audioinfo*Math.random()));
|
game.playAudio('skill',audioname+Math.ceil(audioinfo*Math.random()));
|
||||||
}
|
}
|
||||||
|
@ -10931,6 +10956,7 @@
|
||||||
},
|
},
|
||||||
reloadCurrent:function(){
|
reloadCurrent:function(){
|
||||||
game.saveConfig('continue_name',[game.me.name1||game.me.name,game.me.name2]);
|
game.saveConfig('continue_name',[game.me.name1||game.me.name,game.me.name2]);
|
||||||
|
game.saveConfig('mode',lib.config.mode);
|
||||||
localStorage.setItem(lib.configprefix+'directstart',true);
|
localStorage.setItem(lib.configprefix+'directstart',true);
|
||||||
game.reload();
|
game.reload();
|
||||||
},
|
},
|
||||||
|
@ -11846,6 +11872,7 @@
|
||||||
map.links.push(pointer.name);
|
map.links.push(pointer.name);
|
||||||
}
|
}
|
||||||
game.saveConfig('continue_name_boss',map);
|
game.saveConfig('continue_name_boss',map);
|
||||||
|
game.saveConfig('mode',lib.config.mode);
|
||||||
localStorage.setItem(lib.configprefix+'directstart',true);
|
localStorage.setItem(lib.configprefix+'directstart',true);
|
||||||
game.reload();
|
game.reload();
|
||||||
});
|
});
|
||||||
|
@ -11858,6 +11885,7 @@
|
||||||
enemy:_status.enemyBackup,
|
enemy:_status.enemyBackup,
|
||||||
color:_status.color
|
color:_status.color
|
||||||
});
|
});
|
||||||
|
game.saveConfig('mode',lib.config.mode);
|
||||||
localStorage.setItem(lib.configprefix+'directstart',true);
|
localStorage.setItem(lib.configprefix+'directstart',true);
|
||||||
game.reload();
|
game.reload();
|
||||||
});
|
});
|
||||||
|
@ -20128,7 +20156,9 @@
|
||||||
_status.maxShuffle--;
|
_status.maxShuffle--;
|
||||||
}
|
}
|
||||||
var cards=[],i;
|
var cards=[],i;
|
||||||
if(game.onWash) game.onWash();
|
for(var i=0;i<lib.onwash.length;i++){
|
||||||
|
lib.onwash[i]();
|
||||||
|
}
|
||||||
for(i=0;i<ui.discardPile.childNodes.length;i++){
|
for(i=0;i<ui.discardPile.childNodes.length;i++){
|
||||||
cards.push(ui.discardPile.childNodes[i]);
|
cards.push(ui.discardPile.childNodes[i]);
|
||||||
}
|
}
|
||||||
|
@ -22233,6 +22263,10 @@
|
||||||
for(i in mode[lib.config.mode].get){
|
for(i in mode[lib.config.mode].get){
|
||||||
get[i]=lib.init.eval(mode[lib.config.mode].get[i]);
|
get[i]=lib.init.eval(mode[lib.config.mode].get[i]);
|
||||||
}
|
}
|
||||||
|
if(game.onwash){
|
||||||
|
lib.onwash.push(game.onwash);
|
||||||
|
delete game.onwash;
|
||||||
|
}
|
||||||
lib.config.current_mode=mode[lib.config.mode].config||[];
|
lib.config.current_mode=mode[lib.config.mode].config||[];
|
||||||
lib.config.mode_choice=mode[lib.config.mode].config;
|
lib.config.mode_choice=mode[lib.config.mode].config;
|
||||||
lib.config.banned=get.config('banned')||[];
|
lib.config.banned=get.config('banned')||[];
|
||||||
|
|
|
@ -712,7 +712,7 @@ mode.stone={
|
||||||
game:{
|
game:{
|
||||||
reserveDead:true,
|
reserveDead:true,
|
||||||
bannedcards:['lebu','guiyoujie'],
|
bannedcards:['lebu','guiyoujie'],
|
||||||
onWash:function(){
|
onwash:function(){
|
||||||
if(_status.mode!='deck') return;
|
if(_status.mode!='deck') return;
|
||||||
var list=[];
|
var list=[];
|
||||||
for(var i=0;i<ui.discardPile.childElementCount;i++){
|
for(var i=0;i<ui.discardPile.childElementCount;i++){
|
||||||
|
|
Loading…
Reference in New Issue