若干调整

1.彭羕【嚣翻】技能id修改
2.彭羕【侻失】bugfix
3.添加步骘【定叛】、黄皓【寝情】的斗地主模式技能
4.族吴乔阵亡配音补充
This commit is contained in:
mengxinzxz 2024-03-15 12:21:17 +08:00
parent b60340b214
commit cac8062d4f
3 changed files with 46 additions and 31 deletions

BIN
audio/die/clan_wuqiao.mp3 Normal file

Binary file not shown.

View File

@ -46,7 +46,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
lvboshe:['male','qun',4,['olfushi','oldongdao']], lvboshe:['male','qun',4,['olfushi','oldongdao']],
ol_luyusheng:['female','wu',3,['olcangxin','olrunwei']], ol_luyusheng:['female','wu',3,['olcangxin','olrunwei']],
caoxi:['male','wei',3,['olgangshu','oljianxuan']], caoxi:['male','wei',3,['olgangshu','oljianxuan']],
ol_pengyang:['male','shu',3,['olqifan','oltuishi','nzry_cunmu']], ol_pengyang:['male','shu',3,['olxiaofan','oltuishi','nzry_cunmu']],
ol_qianzhao:['male','wei',4,['olweifu','olkuansai']], ol_qianzhao:['male','wei',4,['olweifu','olkuansai']],
niujin:['male','wei',4,['olcuorui','liewei']], niujin:['male','wei',4,['olcuorui','liewei']],
hejin:['male','qun',4,['mouzhu','olyanhuo']], hejin:['male','qun',4,['mouzhu','olyanhuo']],
@ -2537,8 +2537,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}, },
check:function(card){ check:function(card){
var player=_status.event.player; var player=_status.event.player;
if(player.hasSkill('hezhong')){ if(player.hasSkill('hezhong')&&(!(player.hasSkill('hezhong_0')&&player.hasSkill('hezhong_1')))){
if(player.countCards('h')-ui.selected.cards.length>1) return 1/(get.value(card)||0.5); if(player.countCards('h')-ui.selected.cards.length>2) return 1/(get.value(card)||0.5);
return 0; return 0;
} }
if(ui.selected.cards.length<player.countCards('h')/2) return 5-get.value(card); if(ui.selected.cards.length<player.countCards('h')/2) return 5-get.value(card);
@ -2558,7 +2558,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
'step 1' 'step 1'
player.chooseToDiscard('h','宴如:弃置至少一半手牌',[Math.floor(player.countCards('h')/2),Infinity],true).set('ai',card=>{ player.chooseToDiscard('h','宴如:弃置至少一半手牌',[Math.floor(player.countCards('h')/2),Infinity],true).set('ai',card=>{
var player=_status.event.player; var player=_status.event.player;
if(player.hasSkill('hezhong')&&player.countCards('h')-ui.selected.cards.length>1) return 1/(get.value(card)||0.5); if(player.hasSkill('hezhong')&&(!(player.hasSkill('hezhong_0')&&player.hasSkill('hezhong_1')))&&player.countCards('h')-ui.selected.cards.length>2) return 1/(get.value(card)||0.5);
if(!player.hasSkill('hezhong')&&ui.selected.cards.length<Math.floor(player.countCards('h')/2)) return 1/(get.value(card)||0.5); if(!player.hasSkill('hezhong')&&ui.selected.cards.length<Math.floor(player.countCards('h')/2)) return 1/(get.value(card)||0.5);
return 0; return 0;
}); });
@ -3324,15 +3324,15 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}, },
}, },
//OL彭羕 //OL彭羕
olqifan:{ olxiaofan:{
audio:2, audio:2,
enable:'chooseToUse', enable:'chooseToUse',
hiddenCard:function(player,name){ hiddenCard:function(player,name){
if(name!='wuxie'&&lib.inpile.includes(name)) return true; if(name!='wuxie'&&lib.inpile.includes(name)) return true;
}, },
getNum:()=>game.getGlobalHistory('useCard').reduce((list,evt)=>list.add(get.type2(evt.card)),[]).length, getNum:(player)=>player.getHistory('useCard').reduce((list,evt)=>list.add(get.type2(evt.card)),[]).length,
filter:function(event,player){ filter:function(event,player){
if(event.responded||event.type=='wuxie'||event.olqifan) return false; if(event.responded||event.type=='wuxie'||event.olxiaofan) return false;
for(var i of lib.inpile){ for(var i of lib.inpile){
if(i!='wuxie'&&event.filterCard(get.autoViewAs({name:i},'unsure'),player,event)) return true; if(i!='wuxie'&&event.filterCard(get.autoViewAs({name:i},'unsure'),player,event)) return true;
} }
@ -3342,8 +3342,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){
content:function(){ content:function(){
'step 0' 'step 0'
var evt=event.getParent(2); var evt=event.getParent(2);
evt.set('olqifan',true); evt.set('olxiaofan',true);
var cards=get.bottomCards(lib.skill.olqifan.getNum()+1,true); var cards=get.bottomCards(lib.skill.olxiaofan.getNum(player)+1,true);
var aozhan=player.hasSkill('aozhan'); var aozhan=player.hasSkill('aozhan');
player.chooseButton(['嚣翻:选择要使用的牌',cards]).set('filterButton',function(button){ player.chooseButton(['嚣翻:选择要使用的牌',cards]).set('filterButton',function(button){
return _status.event.cards.includes(button.link); return _status.event.cards.includes(button.link);
@ -3380,11 +3380,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
},evt.player,evt)?'sha':'shan'; },evt.player,evt)?'sha':'shan';
} }
game.broadcastAll(function(result,name){ game.broadcastAll(function(result,name){
lib.skill.olqifan_backup.viewAs={name:name,cards:[result],isCard:true}; lib.skill.olxiaofan_backup.viewAs={name:name,cards:[result],isCard:true};
},card,name); },card,name);
evt.set('_backupevent','olqifan_backup'); evt.set('_backupevent','olxiaofan_backup');
evt.set('openskilldialog',('请选择'+get.translation(card)+'的目标')) evt.set('openskilldialog',('请选择'+get.translation(card)+'的目标'))
evt.backup('olqifan_backup'); evt.backup('olxiaofan_backup');
} }
evt.goto(0); evt.goto(0);
}, },
@ -3406,8 +3406,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){
} }
}, },
}, },
olqifan_backup:{ olxiaofan_backup:{
sourceSkill:'olqifan', sourceSkill:'olxiaofan',
precontent:function(){ precontent:function(){
delete event.result.skill; delete event.result.skill;
var name=event.result.card.name,cards=event.result.card.cards.slice(0); var name=event.result.card.name,cards=event.result.card.cards.slice(0);
@ -3418,9 +3418,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
event.result.card=card; event.result.card=card;
var id=get.id(); var id=get.id();
player.when('chooseToUseAfter').filter((evt)=>evt==event.getParent()).then(()=>{ player.when('chooseToUseAfter').filter((evt)=>evt==event.getParent()).then(()=>{
var num=lib.skill.olqifan.getNum(),pos=('jeh').slice(0,num); var num=lib.skill.olxiaofan.getNum(player),pos=('jeh').slice(0,num);
if(num>0&&player.countCards(pos)>0){ if(num>0&&player.countCards(pos)>0){
event.maxNum=Math.min(3,lib.skill.olqifan.getNum()); event.maxNum=Math.min(3,num);
event.num=0; event.num=0;
} }
else event.finish(); else event.finish();
@ -3490,7 +3490,15 @@ game.import('character',function(lib,game,ui,get,ai,_status){
trigger:{player:'useCard1'}, trigger:{player:'useCard1'},
filter:function(event,player){ filter:function(event,player){
if(!event.targets||!event.targets.length) return false; if(!event.targets||!event.targets.length) return false;
return event.targets.some(target=>player.countCards('h')+event.cards.length>target.countCards('h')); let num=0;
if(event.cards&&event.cards.length){
const history=player.getHistory('lose',evt=>{
if(evt.getParent()!=event) return false;
return event.cards.some(card=>evt.hs.includes(card));
});
if(history.length) num+=event.cards.filter(card=>history[0].hs.includes(card)).length;
}
return event.targets.some(target=>player.countCards('h')+num>target.countCards('h')+(target==player?num:0));
}, },
forced:true, forced:true,
popup:false, popup:false,
@ -18754,8 +18762,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){
filter:function(event,player){ filter:function(event,player){
var num; var num;
var mode=get.mode(); var mode=get.mode();
if(mode=='identity'){ if(mode=='identity'||mode=='doudizhu'){
if(_status.mode=='purple') num=player.getEnemies().length; if(mode=='identity'&&_status.mode=='purple') num=player.getEnemies().length;
else num=get.population('fan'); else num=get.population('fan');
} }
else if(mode=='versus'){ else if(mode=='versus'){
@ -26879,6 +26887,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
hongde_info:'当你一次获得或失去至少两张牌后,你可以令一名其他角色摸一张牌。', hongde_info:'当你一次获得或失去至少两张牌后,你可以令一名其他角色摸一张牌。',
dingpan:'定叛', dingpan:'定叛',
dingpan_info_identity:'出牌阶段限X次你可以令一名装备区里有牌的角色摸一张牌然后其选择一项1.令你弃置其装备区里的一张牌2.获得其装备区里的所有牌若如此做你对其造成1点伤害。X为场上存活的反贼数', dingpan_info_identity:'出牌阶段限X次你可以令一名装备区里有牌的角色摸一张牌然后其选择一项1.令你弃置其装备区里的一张牌2.获得其装备区里的所有牌若如此做你对其造成1点伤害。X为场上存活的反贼数',
dingpan_info_doudizhu:'出牌阶段限X次你可以令一名装备区里有牌的角色摸一张牌然后其选择一项1.令你弃置其装备区里的一张牌2.获得其装备区里的所有牌若如此做你对其造成1点伤害。X为场上存活的农民数',
dingpan_info_versus_two:'出牌阶段限X次你可以令一名装备区里有牌的角色摸一张牌然后其选择一项1.令你弃置其装备区里的一张牌2.获得其装备区里的所有牌若如此做你对其造成1点伤害。X为场上存活的最大阵营角色数', dingpan_info_versus_two:'出牌阶段限X次你可以令一名装备区里有牌的角色摸一张牌然后其选择一项1.令你弃置其装备区里的一张牌2.获得其装备区里的所有牌若如此做你对其造成1点伤害。X为场上存活的最大阵营角色数',
dingpan_info_versus:'出牌阶段限X次你可以令一名装备区里有牌的角色摸一张牌然后其选择一项1.令你弃置其装备区里的一张牌2.获得其装备区里的所有牌若如此做你对其造成1点伤害。X为场上存活的敌方角色数', dingpan_info_versus:'出牌阶段限X次你可以令一名装备区里有牌的角色摸一张牌然后其选择一项1.令你弃置其装备区里的一张牌2.获得其装备区里的所有牌若如此做你对其造成1点伤害。X为场上存活的敌方角色数',
dingpan_info:'出牌阶段限一次你可以令一名装备区里有牌的角色摸一张牌然后其选择一项1.令你弃置其装备区里的一张牌2.获得其装备区里的所有牌若如此做你对其造成1点伤害。', dingpan_info:'出牌阶段限一次你可以令一名装备区里有牌的角色摸一张牌然后其选择一项1.令你弃置其装备区里的一张牌2.获得其装备区里的所有牌若如此做你对其造成1点伤害。',
@ -27665,8 +27674,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){
oljianxuan:'谏旋', oljianxuan:'谏旋',
oljianxuan_info:'当你受到伤害后,你可以令一名角色摸一张牌,然后若其手牌数等于你〖刚述①〗中的任意一项对应的数值,其重复此流程。', oljianxuan_info:'当你受到伤害后,你可以令一名角色摸一张牌,然后若其手牌数等于你〖刚述①〗中的任意一项对应的数值,其重复此流程。',
ol_pengyang:'彭羕', ol_pengyang:'彭羕',
olqifan:'嚣翻', olxiaofan:'嚣翻',
olqifan_info:'当你需要使用不为【无懈可击】的牌时你可以观看牌堆底的X+1张牌并使用其中的一张。此牌结算结束时你依次弃置以下前X个区域中的所有牌⒈判定区、⒉装备区、⒊手牌区X为本回合使用过的牌中包含的类型数)。', olxiaofan_info:'当你需要使用不为【无懈可击】的牌时你可以观看牌堆底的X+1张牌并使用其中的一张。此牌结算结束时你依次弃置以下前X个区域中的所有牌⒈判定区、⒉装备区、⒊手牌区X为本回合使用过的牌中包含的类型数)。',
oltuishi:'侻失', oltuishi:'侻失',
oltuishi_info:'锁定技。①你不能使用【无懈可击】。②当你使用点数为字母的牌时,你令此牌无效并摸一张牌,且你对手牌数小于你的角色使用的下一张牌无距离和次数限制。', oltuishi_info:'锁定技。①你不能使用【无懈可击】。②当你使用点数为字母的牌时,你令此牌无效并摸一张牌,且你对手牌数小于你的角色使用的下一张牌无距离和次数限制。',
ol_tw_zhangji:'张既', ol_tw_zhangji:'张既',

View File

@ -5569,37 +5569,43 @@ game.import('character',function(lib,game,ui,get,ai,_status){
}, },
qinqing:{ qinqing:{
audio:2, audio:2,
mode:['identity','versus'], mode:['identity','versus','doudizhu'],
available:function(mode){ available:function(mode){
if(mode=='versus'&&_status.mode!='four') return false; if(mode=='versus'&&_status.mode!='four') return false;
if(mode=='identity'&&_status.mode=='purple') return false; if(mode=='identity'&&_status.mode=='purple') return false;
}, },
getZhu:(player)=>{
if(get.mode=='doudizhu') return game.findPlayer(i=>i.identity=='zhu');
return get.zhu(player);
},
trigger:{player:'phaseJieshuBegin'}, trigger:{player:'phaseJieshuBegin'},
direct:true, direct:true,
filter:function(event,player){ filter:function(event,player){
var zhu=get.zhu(player); var zhu=get.info('qinqing').getZhu(player);
if(!zhu||!zhu.isZhu) return false; if(!zhu||(get.mode!='doudizhu'&&!zhu.isZhu)) return false;
return game.hasPlayer(function(current){ return game.hasPlayer(function(current){
return current!=zhu&&current.inRange(zhu); return current!=zhu&&current.inRange(zhu);
}); });
}, },
content:function(){ content:function(){
'step 0' 'step 0'
event.zhu=get.info('qinqing').getZhu(player);
player.chooseTarget(get.prompt2('qinqing'),[1,Infinity],function(card,player,target){ player.chooseTarget(get.prompt2('qinqing'),[1,Infinity],function(card,player,target){
var zhu=get.zhu(player); var zhu=get.event('zhu');
if(target==zhu) return false; if(target==zhu) return false;
return target.inRange(zhu); return target.inRange(zhu);
}).set('ai',function(target){ }).set('ai',function(target){
var he=target.countCards('he') var he=target.countCards('he');
var zhu=get.event('zhu');
if(get.attitude(_status.event.player,target)>0){ if(get.attitude(_status.event.player,target)>0){
if(he==0) return 1; if(he==0) return 1;
if(target.countCards('h')>get.zhu(player).countCards('h')) return 1; if(target.countCards('h')>zhu.countCards('h')) return 1;
} }
else{ else{
if(he>0) return 1; if(he>0) return 1;
} }
return 0; return 0;
}); }).set('zhu',event.zhu);
'step 1' 'step 1'
if(result.bool){ if(result.bool){
event.targets=result.targets.slice(0).sortBySeat(); event.targets=result.targets.slice(0).sortBySeat();
@ -5620,9 +5626,8 @@ game.import('character',function(lib,game,ui,get,ai,_status){
} }
'step 3' 'step 3'
var num=0; var num=0;
var zhu=get.zhu(player); if(event.zhu){
if(zhu){ var nh=event.zhu.countCards('h');
var nh=zhu.countCards('h');
for(var i=0;i<event.list.length;i++){ for(var i=0;i<event.list.length;i++){
if(event.list[i].countCards('h')>nh){ if(event.list[i].countCards('h')>nh){
num++; num++;
@ -14151,6 +14156,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
jiyu_info:'出牌阶段限一次你可以令一名角色弃置一张手牌。若如此做你不能使用与之相同花色的牌直到回合结束。若其以此法弃置的牌为黑桃你翻面并令其失去1点体力。若你有未被〖讥谀〗限制的手牌则你可以继续发动此技能但不能选择本回合已经选择过的目标。', jiyu_info:'出牌阶段限一次你可以令一名角色弃置一张手牌。若如此做你不能使用与之相同花色的牌直到回合结束。若其以此法弃置的牌为黑桃你翻面并令其失去1点体力。若你有未被〖讥谀〗限制的手牌则你可以继续发动此技能但不能选择本回合已经选择过的目标。',
qinqing:'寝情', qinqing:'寝情',
qinqing_info:'结束阶段你可以选择任意名攻击范围内含有主公的角色然后弃置这些角色各一张牌并令其摸一张牌无牌则不弃若如此做你摸X张牌X为其中手牌比主公多的角色数。', qinqing_info:'结束阶段你可以选择任意名攻击范围内含有主公的角色然后弃置这些角色各一张牌并令其摸一张牌无牌则不弃若如此做你摸X张牌X为其中手牌比主公多的角色数。',
qinqing_info_doudizhu:'结束阶段你可以选择任意名攻击范围内含有地主的角色然后弃置这些角色各一张牌并令其摸一张牌无牌则不弃若如此做你摸X张牌X为其中手牌比地主多的角色数。',
huisheng:'贿生', huisheng:'贿生',
huisheng_info:'当你受到其他角色对你造成的伤害时你可以令其观看你任意数量的牌并令其选择一项1.获得这些牌中的一张防止此伤害然后你不能再对其发动〖贿生〗2.弃置等量的牌。', huisheng_info:'当你受到其他角色对你造成的伤害时你可以令其观看你任意数量的牌并令其选择一项1.获得这些牌中的一张防止此伤害然后你不能再对其发动〖贿生〗2.弃置等量的牌。',
jishe:'极奢', jishe:'极奢',