Game...Start!
This commit is contained in:
parent
24caa2223c
commit
317e18431a
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -346,8 +346,8 @@ game.import('card',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
else{
|
||||
var list=[];
|
||||
for(var i=0;i<=Math.min(num,damaged);i++){
|
||||
list.push('摸'+i+'回'+(num-i));
|
||||
for(var i=Math.min(num,damaged);i>=0;i--){
|
||||
list.push('摸'+(num-i)+'回'+i);
|
||||
}
|
||||
target.chooseControl(list).set('prompt','请分配自己的摸牌数和回复量').ai=function(){
|
||||
if(player.hasSkill('diaohulishan')) return 0;
|
||||
|
|
|
@ -64,7 +64,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
ns_caoshuang:['male','wei',4,['nsjiquan','nsfuwei']],
|
||||
// diy_caocao:['male','wei',4,['xicai','diyjianxiong','hujia']],
|
||||
// diy_hanlong:['male','wei',4,['siji','ciqiu']],
|
||||
diy_feishi:['male','shu',3,['shuaiyan','moshou']],
|
||||
diy_feishi:['male','shu',3,['nsshuaiyan','moshou']],
|
||||
diy_liuyan:['male','shu',3,['juedao','geju']],
|
||||
// diy_luxun:['male','wu',3,['shaoying','zonghuo']],
|
||||
diy_yuji:['male','qun',3,['diyguhuo','diychanyuan']],
|
||||
|
@ -3357,6 +3357,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
},
|
||||
saya_powei:{
|
||||
audio:2,
|
||||
trigger:{player:'phaseAfter'},
|
||||
direct:true,
|
||||
locked:true,
|
||||
|
@ -3445,6 +3446,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
},
|
||||
saya_shouji:{
|
||||
audio:2,
|
||||
trigger:{player:'useCardAfter'},
|
||||
filter:function(event,player){
|
||||
return !player.getStat('skill').saya_shouji&&event.cards.filterInD().length>0;
|
||||
|
@ -9744,7 +9746,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
trigger.player.identityShown=true;
|
||||
}
|
||||
},
|
||||
shuaiyan:{
|
||||
nsshuaiyan:{
|
||||
trigger:{global:'recoverAfter'},
|
||||
filter:function(event,player){
|
||||
return event.player!=player&&_status.currentPhase!=player;
|
||||
|
@ -9982,7 +9984,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
xicai:'惜才',
|
||||
diyjianxiong:'奸雄',
|
||||
diy_feishi:'费诗',
|
||||
shuaiyan:'率言',
|
||||
nsshuaiyan:'率言',
|
||||
moshou:'墨守',
|
||||
diy_hanlong:'韩龙',
|
||||
diy_luxun:'陆伯言',
|
||||
|
@ -10595,7 +10597,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
geju_info:'准备阶段开始时,你可以摸X张牌(X为攻击范围内不含有你的势力数)。',
|
||||
siji_info:'弃牌阶段结束后,你可以摸2X张牌(X为你于此阶段内弃置的【杀】的数量)。',
|
||||
ciqiu_info:'锁定技,每当你使用【杀】对目标角色造成伤害时,若该角色未受伤,你令此伤害+1;若其因此进入濒死状态,你令其死亡,然后你失去“刺酋”。 ',
|
||||
shuaiyan_info:'每当其他角色于你的回合外回复体力后,你可以令该角色选择一项:1.令你摸一张牌;2.令你弃置其一张牌。',
|
||||
nsshuaiyan_info:'每当其他角色于你的回合外回复体力后,你可以令该角色选择一项:1.令你摸一张牌;2.令你弃置其一张牌。',
|
||||
moshou_info:'锁定技,你不能成为乐不思蜀和兵粮寸断的目标。',
|
||||
xicai_info:'你可以立即获得对你造成伤害的牌',
|
||||
diyjianxiong_info:'锁定技,在身份局中,在你回合内死亡的角色均视为反贼,国战中,在你回合内死亡的角色若与你势力相同则随机改为另一个势力',
|
||||
|
|
|
@ -8,11 +8,12 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
mobile:{
|
||||
mobile_default:["miheng","taoqian","lingcao","sunru","lifeng","zhuling","liuye","zhaotongzhaoguang","majun","simazhao","wangyuanji","pangdegong","shenpei","hujinding","zhangyì","jiakui","yangbiao","chendeng","dongcheng","yangyi","dengzhi","zhengxuan","sp_sufei"],
|
||||
mobile_yijiang:["yj_zhanghe","yj_zhangliao","yj_xuhuang","yj_ganning"],
|
||||
mobile_others:["re_jikang","old_bulianshi","old_yuanshu","re_wangyun","re_baosanniang","re_weiwenzhugezhi","re_zhanggong","re_xugong","xin_yuanshao","re_liushan","xin_xiahoudun","re_sp_zhugeliang","re_heqi","re_guanqiujian","re_pangtong","old_liuzan","xin_chengpu","re_sunjian"],
|
||||
mobile_others:["re_jikang","old_bulianshi","old_yuanshu","re_wangyun","re_baosanniang","re_weiwenzhugezhi","re_zhanggong","re_xugong","xin_yuanshao","re_liushan","xin_xiahoudun","re_sp_zhugeliang","re_heqi","re_guanqiujian","re_pangtong","old_liuzan","xin_chengpu","re_sunjian","re_xusheng"],
|
||||
mobile_sunben:["re_sunben"],
|
||||
},
|
||||
},
|
||||
character:{
|
||||
re_xusheng:['male','wu',4,['repojun']],
|
||||
sp_sufei:['male','qun',4,['zhengjian','gaoyuan']],
|
||||
yj_zhangliao:['male','qun',4,['weifeng']],
|
||||
yj_zhanghe:['male','qun',4,['xinzhilve']],
|
||||
|
@ -32,7 +33,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
re_sp_zhugeliang:["male","shu",3,["bazhen","rehuoji","rekanpo"],[]],
|
||||
xin_xiahoudun:['male','wei',4,['reganglie','xinqingjian']],
|
||||
zhangyì:['male','shu',4,['zhiyi']],
|
||||
jiakui:['male','wei',3,['tongqu','xinwanlan']],
|
||||
jiakui:['male','wei',3,['zhongzuo','wanlan']],
|
||||
re_jikang:["male","wei",3,["new_qingxian","new_juexiang"]],
|
||||
old_bulianshi:['female','wu',3,['anxu','zhuiyi']],
|
||||
miheng:['male','qun',3,['kuangcai','shejian']],
|
||||
|
@ -338,7 +339,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
tongqu2:{
|
||||
trigger:{player:'phaseDrawEnd'},
|
||||
forced:true,
|
||||
silent:false,
|
||||
silent:true,
|
||||
filter:function(event,player){
|
||||
var bool=game.hasPlayer(function(current){
|
||||
return current!=player&¤t.hasMark('tongqu');
|
||||
|
@ -402,7 +403,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
trigger:{global:'damageBegin4'},
|
||||
filter:function(event,player){
|
||||
return event.player.hp<=event.num&&player.countCards('he',function(card){
|
||||
return get.type(card)!='basic';
|
||||
return lib.filter.cardDiscardable(card,player)&&get.type(card)!='basic';
|
||||
})>=1;
|
||||
},
|
||||
logTarget:'player',
|
||||
|
@ -416,13 +417,13 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
var savable=get.info(card).savable;
|
||||
if(typeof savable=='function') savable=savable(card,player,event.player);
|
||||
return savable;
|
||||
})>=1+trigger.num-event.player.hp) return false;
|
||||
})>=1+event.num-event.player.hp) return false;
|
||||
if(event.player==player||event.player==get.zhu(player)) return true;
|
||||
return !player.hasUnknown();
|
||||
},
|
||||
content:function(){
|
||||
player.discard(player.getCards('he',function(card){
|
||||
return get.type(card)!='basic';
|
||||
return lib.filter.cardDiscardable(card,player)&&get.type(card)!='basic';
|
||||
}));
|
||||
trigger.cancel();
|
||||
},
|
||||
|
@ -5070,8 +5071,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
intro:{
|
||||
content:'当前“惧”标记名称:$',
|
||||
onunmark:function(storage,player){
|
||||
game.log(player,'移去了一个','#g【惧('+get.translation(storage)+')】','标记')
|
||||
delete player.storage.weifeng2;
|
||||
if(player.storage.weifeng2){
|
||||
game.log(player,'移去了一个','#g【惧('+get.translation(player.storage.weifeng2)+')】','标记')
|
||||
delete player.storage.weifeng2;
|
||||
}
|
||||
},
|
||||
},
|
||||
marktext:'惧',
|
||||
|
@ -5664,6 +5667,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
tongqu_info:'游戏开始时,你获得一个“渠”。出牌阶段开始时,你可令一名没有“渠”的角色获得一个“渠”。有“渠”的角色摸牌阶段,其多摸一张牌,然后其将一张牌交给一名有“渠”的其他角色或弃置一张牌。有“渠”的角色受到伤害后,其弃置“渠”',
|
||||
xinwanlan:'挽澜',
|
||||
xinwanlan_info:'当有角色受到伤害时,若伤害点数大于其体力值,则你可以弃置所有非基本牌(至少两张)并防止此伤害。',
|
||||
re_xusheng:'手杀徐盛',
|
||||
}
|
||||
};
|
||||
});
|
||||
|
|
|
@ -17,7 +17,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
},
|
||||
character:{
|
||||
old_jiakui:['male','wei',3,['zhongzuo','wanlan']],
|
||||
old_jiakui:['male','wei',3,['tongqu','xinwanlan']],
|
||||
pangde:['male','qun',4,['mashu','mengjin']],
|
||||
ol_huaxiong:["male","qun",6,["new_reyaowu"]],
|
||||
old_wangyun:['male','qun',4,['wylianji','moucheng']],
|
||||
|
|
|
@ -9,11 +9,12 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
refresh_huo:["ol_sp_zhugeliang","re_xunyu","re_dianwei","re_yanwen","ol_pangtong","ol_yuanshao","ol_pangde","re_taishici"],
|
||||
refresh_lin:['re_zhurong','re_menghuo','re_dongzhuo','ol_sunjian','re_caopi','re_xuhuang'],
|
||||
refresh_shan:['re_dengai','re_jiangwei','re_caiwenji','ol_liushan','re_zhangzhang','re_zuoci','re_sunce'],
|
||||
refresh_yijiang:['re_xusheng','re_wuguotai','re_gaoshun','re_zhangyi','re_caozhi','re_zhuran','re_wuyi','re_liaohua','re_guohuai','re_zhuran','re_chengpu','re_caozhang','re_quancong','yujin_yujin','re_lingtong','re_handang','re_zhonghui','re_sunluban','re_masu'],
|
||||
refresh_yijiang:['re_wuguotai','re_gaoshun','re_zhangyi','re_caozhi','re_zhuran','re_wuyi','re_liaohua','re_guohuai','re_zhuran','re_chengpu','re_caozhang','re_quancong','yujin_yujin','re_lingtong','re_handang','re_zhonghui','re_sunluban','re_masu','re_jianyong','xin_xusheng'],
|
||||
},
|
||||
},
|
||||
connect:true,
|
||||
character:{
|
||||
xin_xusheng:['male','wu',4,['decadepojun']],
|
||||
re_taishici:['male','wu',4,['tianyi','hanzhan']],
|
||||
re_masu:['male','shu',3,['resanyao','rezhiman']],
|
||||
re_sunluban:['female','wu',3,['rechanhui','rejiaojin']],re_zhonghui:['male','wei',4,['requanji','zili']],
|
||||
|
@ -30,7 +31,6 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
re_caozhi:['male','wei',3,['reluoying','rejiushi','chengzhang']],
|
||||
ol_pangtong:['male','shu',3,['xinlianhuan','olniepan'],[]],
|
||||
re_zhangyi:['male','shu',4,['rewurong','shizhi']],
|
||||
re_xusheng:['male','wu',4,['repojun']],
|
||||
re_wuguotai:['female','wu',3,['reganlu','buyi']],
|
||||
re_gaoshun:['male','qun',4,['rexianzhen','rejinjiu']],
|
||||
re_caocao:['male','wei',4,['new_rejianxiong','hujia'],['zhu']],
|
||||
|
@ -92,6 +92,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
re_zhangzhang:['male','wu',3,['rezhijian','guzheng']],
|
||||
|
||||
re_sunce:['male','wu',4,['jiang','olhunzi','olzhiba'],['zhu']],
|
||||
re_jianyong:['male','shu',3,['reqiaoshui','jyzongshi']],
|
||||
},
|
||||
characterIntro:{
|
||||
re_gongsunzan:'群雄之一。出身贵族,因母地位卑贱,只当了郡中小吏。他貌美,声音洪亮,机智善辩。后随卢植于缑氏山中读书,粗通经传。',
|
||||
|
@ -107,6 +108,89 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
sunben:['zhouyu','taishici','daqiao'],
|
||||
},
|
||||
skill:{
|
||||
decadepojun:{
|
||||
shaRelated:true,
|
||||
audio:2,
|
||||
trigger:{player:'useCardToPlayered'},
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
return event.card.name=='sha'&&event.target.hp>0&&event.target.countCards('he')>0;
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
var next=player.choosePlayerCard(trigger.target,'he',[1,Math.min(trigger.target.hp,trigger.target.countCards('he'))],get.prompt('decadepojun',trigger.target));
|
||||
next.set('ai',function(button){
|
||||
if(!_status.event.goon) return 0;
|
||||
var val=get.value(button.link);
|
||||
if(button.link==_status.event.target.getEquip(2)) return 2*(val+3);
|
||||
return val;
|
||||
});
|
||||
next.set('goon',get.attitude(player,trigger.target)<=0);
|
||||
next.set('forceAuto',true);
|
||||
'step 1'
|
||||
if(result.bool){
|
||||
event.cards=result.cards;
|
||||
var target=trigger.target;
|
||||
player.logSkill('decadepojun',trigger.target);
|
||||
target.addSkill('decadepojun2');
|
||||
target.markAuto('decadepojun2',result.cards);
|
||||
target.lose(result.cards,ui.special,'toStorage');
|
||||
game.log(target,'失去了'+get.cnNumber(result.cards.length)+'张牌');;
|
||||
}
|
||||
else event.finish();
|
||||
'step 2'
|
||||
var discard=false,draw=false;
|
||||
for(var i of cards){
|
||||
var type=get.type2(i);
|
||||
if(type=='equip') discard=true;
|
||||
if(type=='trick') draw=true;
|
||||
}
|
||||
if(discard){
|
||||
event.equip=true;
|
||||
player.chooseButton(['选择一张牌置入弃牌堆',cards],true).set('ai',function(button){
|
||||
return get.value(button.link,_status.event.getTrigger().target);
|
||||
});
|
||||
}
|
||||
if(draw) event.draw=true;
|
||||
'step 3'
|
||||
if(event.equip&&result.links&&result.links.length){
|
||||
trigger.target.unmarkAuto('decadepojun2',result.links);
|
||||
trigger.target.$throw(result.links,1000);
|
||||
game.log(player,'将',result.links,'置入了弃牌堆');
|
||||
game.cardsDiscard(result.links);
|
||||
if(!event.draw) game.delayx();
|
||||
}
|
||||
if(event.draw) player.draw();
|
||||
},
|
||||
ai:{
|
||||
unequip_ai:true,
|
||||
skillTagFilter:function(player,tag,arg){
|
||||
if(arg&&arg.name=='sha'&&arg.target.getEquip(2)) return true;
|
||||
return false;
|
||||
}
|
||||
},
|
||||
},
|
||||
decadepojun2:{
|
||||
init:function(player,skill){
|
||||
if(!player.storage[skill]) player.storage[skill]=[];
|
||||
},
|
||||
trigger:{global:'phaseEnd'},
|
||||
forced:true,
|
||||
popup:false,
|
||||
charlotte:true,
|
||||
filter:function(event,player){
|
||||
return player.storage.decadepojun2&&player.storage.decadepojun2.length>0;
|
||||
},
|
||||
content:function(){
|
||||
game.log(player,'收回了'+get.cnNumber(player.gain(player.storage.decadepojun2,'draw','fromStorage').cards.length)+'张〖破军〗牌');
|
||||
player.storage.decadepojun2.length=0;
|
||||
player.removeSkill('decadepojun2');
|
||||
},
|
||||
intro:{
|
||||
onunmark:'throw',
|
||||
content:'cardCount',
|
||||
},
|
||||
},
|
||||
hanzhan:{
|
||||
audio:2,
|
||||
trigger:{
|
||||
|
@ -6884,7 +6968,6 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
refangquan_info:'你可跳过你的出牌阶段,若如此做,你本回合的手牌上限为你的体力上限,且回合结束时,你可以弃置一张手牌并令一名其他角色进行一个额外的回合。',
|
||||
re_wuguotai:'界吴国太',
|
||||
re_gaoshun:'界高顺',
|
||||
re_xusheng:'界徐盛',
|
||||
reganlu:'甘露',
|
||||
reganlu_info:'出牌阶段限一次,你可以选择装备区牌数之差的绝对值不小于X的两名角色或包含你在内的两名角色,然后交换这两名角色装备区内的牌。(X为你已损失的体力值)',
|
||||
repojun:'破军',
|
||||
|
@ -6970,6 +7053,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
re_taishici:'界太史慈',
|
||||
hanzhan:'酣战',
|
||||
hanzhan_info:'当你发起拼点时,或成为拼点的目标时,你可以令对方选择拼点牌的方式改为随机选择一张手牌。',
|
||||
re_jianyong:'界简雍',
|
||||
xin_xusheng:'界徐盛',
|
||||
decadepojun:'破军',
|
||||
decadepojun2:'破军',
|
||||
decadepojun_info:'当你使用【杀】指定目标后,你可以将其的至多X张牌置于其武将牌上。若这些牌中:有装备牌,你将这些牌中的一张置于弃牌堆;有锦囊牌,你摸一张牌。其于回合结束时获得其武将牌上的这些牌。',
|
||||
|
||||
refresh_standard:'界限突破·标',
|
||||
refresh_feng:'界限突破·风',
|
||||
|
|
155
character/sp.js
155
character/sp.js
|
@ -5,7 +5,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
connect:true,
|
||||
characterSort:{
|
||||
sp:{
|
||||
sp_default:["caoying","simahui","yangxiu","chenlin","caohong","xiahouba","yuanshu","sp_diaochan","sp_zhaoyun","liuxie","zhugejin","zhugeke","guanyinping","simalang","zhangxingcai","fuwan","sp_sunshangxiang","caoang","sp_caoren","zhangbao","maliang","zhugedan","sp_jiangwei","sp_machao","sunhao","shixie","mayunlu","zhanglu","wutugu","sp_caiwenji","zhugeguo","lingju","jsp_guanyu","jsp_huangyueying","sunluyu","zumao","wenpin","daxiaoqiao","tadun","yanbaihu","chengyu","wanglang","sp_pangde","sp_jiaxu","litong","mizhu","buzhi","caochun","dongbai","zhaoxiang","mazhong","dongyun","kanze","heqi","wangyun","sunqian","xizhicai","quyi","luzhi","xujing","yuantanyuanshang","sunshao","zhangling",'guansuo','baosanniang'],
|
||||
sp_default:["caoying","simahui","yangxiu","chenlin","caohong","xiahouba","yuanshu","sp_diaochan","sp_zhaoyun","liuxie","zhugejin","zhugeke","guanyinping","simalang","zhangxingcai","fuwan","sp_sunshangxiang","caoang","sp_caoren","zhangbao","maliang","zhugedan","sp_jiangwei","sp_machao","sunhao","shixie","mayunlu","zhanglu","wutugu","sp_caiwenji","zhugeguo","lingju","jsp_guanyu","jsp_huangyueying","sunluyu","zumao","wenpin","daxiaoqiao","tadun","yanbaihu","chengyu","wanglang","sp_pangde","sp_jiaxu","litong","mizhu","buzhi","caochun","dongbai","zhaoxiang","mazhong","dongyun","kanze","heqi","wangyun","sunqian","xizhicai","quyi","luzhi","xujing","yuantanyuanshang","sunshao","zhangling",'guansuo','baosanniang','ol_zhangchangpu'],
|
||||
sp_zhongdan:["cuiyan","huangfusong"],
|
||||
sp_star:["sp_xiahoushi","jsp_zhaoyun","huangjinleishi","sp_pangtong","sp_daqiao","sp_ganning","sp_xiahoudun","sp_lvmeng","sp_zhangfei","sp_liubei"],
|
||||
sp_sticker:['sp_gongsunzan','sp_simazhao','sp_wangyuanji','sp_xinxianying','sp_liuxie'],
|
||||
|
@ -17,6 +17,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
characterFilter:{},
|
||||
character:{
|
||||
ol_zhangchangpu:['female','wei',3,['yanjiao','olxingshen']],
|
||||
zhangling:['male','qun',4,['zlhuji','zlshoufu'],['unseen']],
|
||||
caiyang:['male','qun',1,['yinka'],['forbidai','unseen']],
|
||||
panfeng:['male','qun',4,['kuangfu']],
|
||||
|
@ -389,6 +390,21 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
},
|
||||
skill:{
|
||||
olxingshen:{
|
||||
trigger:{player:'damageEnd'},
|
||||
frequent:true,
|
||||
audio:'xingshen',
|
||||
content:function(){
|
||||
'step 0'
|
||||
var next=player.draw();
|
||||
if(get.isLuckyStar(player)||Math.random()<0.5) next.num=2;
|
||||
player.storage.olxingshen=player.getDamagedHp();
|
||||
player[player.storage.olxingshen?'markSkill':'unmarkSkill']('olxingshen');
|
||||
},
|
||||
intro:{
|
||||
content:'下一次发动〖严教〗时多展示X张牌',
|
||||
},
|
||||
},
|
||||
//张道陵
|
||||
zlhuji:{
|
||||
mod:{
|
||||
|
@ -9089,11 +9105,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
game.addVideo('storage',player,['biluan',player.storage.biluan]);
|
||||
}
|
||||
},
|
||||
rebiluan:{
|
||||
audio:'biluan',
|
||||
trigger:{player:'phaseJieshuBegin'},
|
||||
rebiluan2:{
|
||||
mark:true,
|
||||
//unique:true,
|
||||
charlotte:true,
|
||||
intro:{
|
||||
content:function(storage){
|
||||
if(storage>0){
|
||||
|
@ -9108,10 +9122,21 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
},
|
||||
init:function(player){
|
||||
if(typeof player.storage.rebiluan!='number') player.storage.rebiluan=0;
|
||||
if(typeof player.storage.rebiluan2!='number') player.storage.rebiluan2=0;
|
||||
},
|
||||
mod:{
|
||||
globalTo:function(from,to,distance){
|
||||
if(typeof to.storage.rebiluan2=='number'){
|
||||
return distance+to.storage.rebiluan2;
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
rebiluan:{
|
||||
audio:'biluan',
|
||||
trigger:{player:'phaseJieshuBegin'},
|
||||
checkx:function(player){
|
||||
var ng=Math.min(4,game.players.length);
|
||||
var ng=game.countGroup();
|
||||
if(ng<2) return false;
|
||||
var nai=0;
|
||||
for(var i=0;i<game.players.length;i++){
|
||||
|
@ -9138,20 +9163,14 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
});
|
||||
"step 1"
|
||||
if(result.bool){
|
||||
var ng=Math.min(4,game.players.length);
|
||||
player.addSkill('rebiluan2');
|
||||
var ng=game.countGroup();
|
||||
player.$damagepop(ng,'unknownx');
|
||||
player.storage.rebiluan+=ng;
|
||||
player.markSkill('rebiluan');
|
||||
game.addVideo('storage',player,['rebiluan',player.storage.rebiluan]);
|
||||
player.storage.rebiluan2+=ng;
|
||||
player.markSkill('rebiluan2');
|
||||
game.addVideo('storage',player,['rebiluan2',player.storage.rebiluan2]);
|
||||
}
|
||||
},
|
||||
mod:{
|
||||
globalTo:function(from,to,distance){
|
||||
if(typeof to.storage.rebiluan=='number'){
|
||||
return distance+to.storage.rebiluan;
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
relixia:{
|
||||
audio:'lixia',
|
||||
|
@ -9162,19 +9181,87 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
forced:true,
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.chooseTarget(function(card,player,target){
|
||||
return target==player||target==_status.event.source;
|
||||
},true,'礼下:摸一张牌或令对方摸两张牌').set('ai',function(target){
|
||||
return get.attitude(player,target);
|
||||
}).set('source',trigger.player);
|
||||
'step 1'
|
||||
if(result.targets.length){
|
||||
result.targets[0].draw(result.targets[0]==player?1:2);
|
||||
player.line(result.targets[0],'green');
|
||||
if(trigger.player.isDead()){
|
||||
event._result={bool:true,links:[0]};
|
||||
return;
|
||||
}
|
||||
player.storage.rebiluan--;
|
||||
player.markSkill('rebiluan');
|
||||
game.addVideo('storage',player,['rebiluan',player.storage.rebiluan]);
|
||||
event.videoId=lib.status.videoId++;
|
||||
var func=function(card,id,bool){
|
||||
var list=[
|
||||
'令自己摸一张牌',
|
||||
'令XXX摸两张牌',
|
||||
'令XXX回复1点体力',
|
||||
];
|
||||
var choiceList=ui.create.dialog('【礼下】:请选择一至两项','forcebutton');
|
||||
choiceList.videoId=id;
|
||||
for(var i=0;i<list.length;i++){
|
||||
list[i]=list[i].replace(/XXX/g,card);
|
||||
var str='<div class="popup text" style="width:calc(100% - 10px);display:inline-block">';
|
||||
if(i==2&&!bool) str+='<div style="opacity:0.5">';
|
||||
str+=list[i];
|
||||
if(i==2&&!bool) str+='</div>';
|
||||
str+='</div>';
|
||||
var next=choiceList.add(str);
|
||||
next.firstChild.addEventListener(lib.config.touchscreen?'touchend':'click',ui.click.button);
|
||||
next.firstChild.link=i;
|
||||
for(var j in lib.element.button){
|
||||
next[j]=lib.element.button[i];
|
||||
}
|
||||
choiceList.buttons.add(next.firstChild);
|
||||
}
|
||||
return choiceList;
|
||||
};
|
||||
if(player.isOnline2()){
|
||||
player.send(func,get.translation(trigger.player),event.videoId,trigger.player.isDamaged());
|
||||
}
|
||||
event.dialog=func(get.translation(trigger.player),event.videoId,trigger.player.isDamaged());
|
||||
if(player!=game.me||_status.auto){
|
||||
event.dialog.style.display='none';
|
||||
}
|
||||
var next=player.chooseButton(true,[1,2]);
|
||||
next.set('dialog',event.videoId);
|
||||
next.set('filterButton',function(button){
|
||||
if(button.link==2){
|
||||
return _status.event.bool1;
|
||||
};
|
||||
return true;
|
||||
});
|
||||
next.set('bool1',trigger.player.isDamaged());
|
||||
next.set('ai',function(button){
|
||||
var player=_status.event.player;
|
||||
var event=_status.event.getTrigger();
|
||||
if(button.link&&get.attitude(player,event.player)<=0) return 0;
|
||||
return button.link*Math.random();
|
||||
});
|
||||
"step 1"
|
||||
if(event.videoId!=undefined){
|
||||
if(player.isOnline2()){
|
||||
player.send('closeDialog',event.videoId);
|
||||
}
|
||||
event.dialog.close();
|
||||
}
|
||||
var map=[
|
||||
function(trigger,player,event){
|
||||
player.draw();
|
||||
},
|
||||
function(trigger,player,event){
|
||||
if(!result.links.contains(2)) player.line(trigger.player);
|
||||
trigger.player.draw(2);
|
||||
},
|
||||
function(trigger,player,event){
|
||||
player.line(trigger.player);
|
||||
trigger.player.recover();
|
||||
}
|
||||
];
|
||||
result.links.sort();
|
||||
for(var i=0;i<result.links.length;i++){
|
||||
game.log(player,'选择了','#g【礼下】','的','#y选项'+get.cnNumber(result.links[i]+1,true));
|
||||
map[result.links[i]](trigger,player,event);
|
||||
}
|
||||
player.addSkill('rebiluan2');
|
||||
player.storage.rebiluan2-=result.links.length;
|
||||
player.markSkill('rebiluan2');
|
||||
game.addVideo('storage',player,['rebiluan2',player.storage.rebiluan2]);
|
||||
}
|
||||
},
|
||||
fuji:{
|
||||
|
@ -14601,9 +14688,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
lixia:'礼下',
|
||||
lixia_info:'锁定技,其他角色的结束阶段开始时,若你不在其攻击范围内,你摸一张牌或令其摸一张牌。本局内其他角色计算与你的距离时-1。',
|
||||
rebiluan:'避乱',
|
||||
rebiluan_info:'结束阶段开始时,若有与你距离不大于1的其他角色,你可以弃置一张牌。若如此做,本局内其他角色计算与你的距离时+X。(X为场上人数且至多为4)',
|
||||
rebiluan2:'避乱',
|
||||
rebiluan_info:'结束阶段开始时,若有与你距离不大于1的其他角色,你可以弃置一张牌。若如此做,本局内其他角色计算与你的距离时+X。(X为场上势力数)',
|
||||
relixia:'礼下',
|
||||
relixia_info:'锁定技,其他角色的结束阶段开始时,若你不在其攻击范围内,你摸一张牌或令其摸两张牌。本局内其他角色计算与你的距离时-1。',
|
||||
relixia_info:'锁定技,其他角色的结束阶段开始时,若你不在其攻击范围内,你选择一至两项:1.摸一张牌;2.其摸两张牌;3.其回复1点体力。本局内其他角色计算与你的距离时-X(X为你选择的选项数)。',
|
||||
yishe:'义舍',
|
||||
yishe_bg:'米',
|
||||
yishe_info:'结束阶段开始时,若你的武将牌上没有「米」,则你可以摸两张牌。若如此做,你将两张牌置于武将牌上,称为「米」;当有「米」移至其他区域后,若你的武将牌上没有「米」,则你回复1点体力。',
|
||||
|
@ -14872,6 +14960,9 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
zlshoufu:'授符',
|
||||
zlshoufu2:'授符',
|
||||
zlshoufu_info:'出牌阶段限一次,你可摸一张牌,然后将一张手牌置于一名没有【箓】的角色的武将牌上,称为【箓】;其不能使用和打出与【箓】同类型的牌。该角色受伤后,或于弃牌阶段弃置至少2张与【箓】同类型的牌后,将【箓】置入弃牌堆。',
|
||||
ol_zhangchangpu:'OL张昌蒲',
|
||||
olxingshen:'省身',
|
||||
olxingshen_info:'当你受到伤害后,你可以随机摸两张牌。若如此做,你移去所有“省”并获得X个“省”,且下一次发动〖严教〗展示牌时移去所有“省”并多展示等量的牌。(X为你已损失的体力值)',
|
||||
|
||||
sp_default:"常规",
|
||||
sp_zhongdan:"忠胆英杰",
|
||||
|
|
127
character/sp2.js
127
character/sp2.js
|
@ -2,7 +2,10 @@
|
|||
game.import('character',function(lib,game,ui,get,ai,_status){
|
||||
return {
|
||||
name:'sp2',
|
||||
connect:true,
|
||||
character:{
|
||||
//sp_zhangliao:['male','qun',4,['mubing','diaoling']],
|
||||
sp_key_yuri:['female','qun',4,['mubing','diaoling'],['unseen']],
|
||||
re_sunluyu:['female','wu',3,['remeibu','remumu']],
|
||||
liuzan:['male','wu',4,['refenyin','liji']],
|
||||
wenyang:['male','wei',5,['xinlvli','choujue']],
|
||||
|
@ -58,7 +61,104 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
},
|
||||
skill:{
|
||||
|
||||
mubing:{
|
||||
trigger:{player:'phaseUseBegin'},
|
||||
direct:true,
|
||||
filter:function(event,player){
|
||||
return player.countCards('he')>0;
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
var num=player.storage.mubing2?3:2;
|
||||
event.num=num+1;
|
||||
player.chooseToDiscard(true,[1,num],'he',get.prompt('mubing'),'弃置至多'+get.cnNumber(num)+'张牌,然后展示牌堆顶的'+get.cnNumber(num+1)+'张牌').logSkill='mubing';
|
||||
'step 1'
|
||||
if(!result.bool){
|
||||
event.finish();return;
|
||||
}
|
||||
var numx=0;
|
||||
for(var i of result.cards){
|
||||
numx+=get.number(i);
|
||||
}
|
||||
event.numx=numx;
|
||||
event.cards=game.cardsGotoOrdering(get.cards(num)).cards;
|
||||
event.videoId=lib.status.videoId++;
|
||||
game.broadcastAll(function(player,id,cards,numx){
|
||||
var str;
|
||||
if(player==game.me&&!_status.auto){
|
||||
str='募兵:选择任意张点数不大于'+numx+'的牌';
|
||||
}
|
||||
else{
|
||||
str='募兵';
|
||||
}
|
||||
var dialog=ui.create.dialog(str,cards);
|
||||
dialog.videoId=id;
|
||||
},player,event.videoId,event.cards,numx);
|
||||
event.time=get.utc();
|
||||
game.addVideo('showCards',player,['募兵',get.cardsInfo(event.cards)]);
|
||||
game.addVideo('delay',null,2);
|
||||
'step 2'
|
||||
var next=player.chooseButton([0,num]);
|
||||
next.set('dialog',event.videoId);
|
||||
next.set('filterButton',function(button){
|
||||
var num=0
|
||||
for(var i=0;i<ui.selected.buttons.length;i++){
|
||||
num+=get.number(ui.selected.buttons[i].link);
|
||||
}
|
||||
return (num+get.number(button.link)<=_status.event.maxNum);
|
||||
});
|
||||
next.set('maxNum',event.numx);
|
||||
next.set('ai',function(button){
|
||||
return get.value(button.link,_status.event.player);
|
||||
});
|
||||
'step 3'
|
||||
if(!result.bool) event.cards=[];
|
||||
else event.cards=result.links;
|
||||
var time=1000-(get.utc()-event.time);
|
||||
if(time>0){
|
||||
game.delay(0,time);
|
||||
}
|
||||
'step 4'
|
||||
game.broadcastAll('closeDialog',event.videoId);
|
||||
if(!cards.length){event.finish();return;}
|
||||
if(player.storage.mubing2) player.chooseTarget('请选择一名角色获得'+get.translation(cards),true);
|
||||
else event._result={bool:true,targets:[player]};
|
||||
'step 5'
|
||||
var target=result.targets[0];
|
||||
player.line(target);
|
||||
target.gain(cards,'log','gain2');
|
||||
},
|
||||
},
|
||||
mubing_rewrite:{
|
||||
mark:true,
|
||||
intro:{
|
||||
content:'出牌阶段开始时,你可以弃置至多三张牌,然后展示牌堆顶的四张牌,并可令一名角色获得任意张点数之和不大于你弃置的牌点数之和的牌。',
|
||||
},
|
||||
},
|
||||
diaoling:{
|
||||
trigger:{player:'phaseZhunbeiBegin'},
|
||||
forced:true,
|
||||
juexingji:true,
|
||||
skillAnimation:true,
|
||||
animationColor:'metal',
|
||||
filter:function(event,player){
|
||||
var num=0;
|
||||
player.getAllHistory('gain',function(evt){
|
||||
var evt2=evt.getParent();
|
||||
if(evt.name=='mubing'&&evt.player==player) num+=evt.cards.filter(function(card){
|
||||
return card.name=='sha'||get.subtype(card,false)=='equip1'||(get.type2(card,false)=='trick'&&get.tag({name:card.name},'damage'));
|
||||
}).length;
|
||||
});
|
||||
return num>=6;
|
||||
},
|
||||
content:function(){
|
||||
player.awakenSkill('diaoling');
|
||||
player.storage.mubing2=true;
|
||||
player.markSkill('mubing_rewrite');
|
||||
player.chooseDrawRecover(2,true);
|
||||
},
|
||||
derivation:'mubing_rewrite',
|
||||
},
|
||||
remeibu:{
|
||||
audio:"meibu",
|
||||
trigger:{
|
||||
|
@ -1045,11 +1145,12 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
if(!map[id]) map[id]=[];
|
||||
map[id].push(i);
|
||||
if(get.color(i)!=event.color) continue;
|
||||
map2[id]=true;
|
||||
if(!map2[id]) map2[id]=[];
|
||||
map2[id].push(i);
|
||||
}
|
||||
for(var i in map){
|
||||
var source=(_status.connectMode?lib.playerOL:game.playerMap)[i];
|
||||
if(map2[i]) player.gain(map[i],source,'bySelf','give');
|
||||
if(map2[i]) player.gain(map2[i],source,'bySelf','give');
|
||||
player.line(source);
|
||||
game.log(player,'展示了',source,'的',map[i]);
|
||||
}
|
||||
|
@ -2061,6 +2162,11 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
player.storage.xingshen=0;
|
||||
player.unmarkSkill('xingshen');
|
||||
}
|
||||
if(player.storage.olxingshen){
|
||||
num+=player.storage.olxingshen;
|
||||
player.storage.olxingshen=0;
|
||||
player.unmarkSkill('olxingshen');
|
||||
}
|
||||
event.cards=get.cards(num);
|
||||
player.showCards(event.cards);
|
||||
"step 1"
|
||||
|
@ -3165,8 +3271,10 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
if(['basic','trick'].contains(type)) list.push([type,'',name]);
|
||||
}
|
||||
player.chooseButton(['选择至多两种牌',[list,'vcard']],true,[1,2]).set('ai',function(button){
|
||||
var target=_status.event.getParent('busuan').target;
|
||||
return get.attitude(_status.event.player,target)*get.useful({name:button.link[2]})+0.1;
|
||||
var target=_status.event.getParent().target;
|
||||
var card={name:button.link[2]};
|
||||
if(get.type(card)=='basic'||!target.hasUseTarget(card)) return false;
|
||||
return get.attitude(_status.event.player,target)*(target.getUseValue(card)-0.1);
|
||||
});
|
||||
'step 1'
|
||||
target.storage.busuan_angelbeats=result.links.slice(0);
|
||||
|
@ -4851,6 +4959,15 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
rezhixi_info:'锁定技,当你使用【杀】或普通锦囊牌时,你弃置一张手牌。',
|
||||
remumu:'穆穆',
|
||||
remumu_info:'出牌阶段开始时,你可以选择一项:1.弃置一名其他角色装备区里的一张牌,然后你本回合可使用【杀】的次数+1;2.获得一名角色装备区里的一张防具牌,然后你本回合可使用【杀】的次数-1。',
|
||||
sp_zhangliao:'SP张辽',
|
||||
//这俩技能给SP仲村由理毫无违和感好吗!!!
|
||||
sp_key_yuri:'SP仲村由理',
|
||||
mubing:'募兵',
|
||||
mubing_info:'出牌阶段开始时,你可以弃置至多两张牌,然后展示牌堆顶的三张牌,并可获得任意张点数之和不大于你弃置的牌点数之和的牌。',
|
||||
diaoling:'调令',
|
||||
diaoling_info:'觉醒技,准备阶段,若你已经获得了6张或更多的【杀】或武器牌或伤害锦囊牌,则你回复1点体力或摸两张牌,然后修改【募兵】。',
|
||||
mubing_rewrite:'募兵·改',
|
||||
mubing_rewrite_info:'出牌阶段开始时,你可以弃置至多三张牌,然后展示牌堆顶的四张牌,并可令一名角色获得任意张点数之和不大于你弃置的牌点数之和的牌。',
|
||||
|
||||
sp_whlw:"文和乱武",
|
||||
sp_zlzy:"逐鹿中原",
|
||||
|
|
|
@ -37,7 +37,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
handang:['male','wu',4,['gongji','jiefan']],
|
||||
fuhuanghou:['female','qun',3,['qiuyuan','zhuikong']],
|
||||
zhonghui:['male','wei',4,['quanji','zili']],
|
||||
jianyong:['male','shu',3,['reqiaoshui','jyzongshi']],
|
||||
jianyong:['male','shu',3,['qiaoshui','jyzongshi']],
|
||||
madai:['male','shu',4,['mashu','qianxi']],
|
||||
liufeng:['male','shu',4,['xiansi']],
|
||||
manchong:['male','wei',3,['xinjunxing','yuce']],
|
||||
|
@ -11135,18 +11135,19 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
content:function(){
|
||||
"step 0"
|
||||
event.cards=get.cards(4);
|
||||
game.cardsGotoOrdering(event.cards);
|
||||
event.videoId=lib.status.videoId++;
|
||||
game.broadcastAll(function(player,id,cards){
|
||||
game.broadcastAll(function(player,id,cards,num){
|
||||
var str;
|
||||
if(player==game.me&&!_status.auto){
|
||||
str='称象:选择任意张点数不大于1'+(event.name=='chengxiang'?3:2)+'的牌';
|
||||
str='称象:选择任意张点数不大于'+num+'的牌';
|
||||
}
|
||||
else{
|
||||
str='称象';
|
||||
}
|
||||
var dialog=ui.create.dialog(str,cards);
|
||||
dialog.videoId=id;
|
||||
},player,event.videoId,event.cards);
|
||||
},player,event.videoId,event.cards,event.name=='chengxiang'?13:12);
|
||||
event.time=get.utc();
|
||||
game.addVideo('showCards',player,['称象',get.cardsInfo(event.cards)]);
|
||||
game.addVideo('delay',null,2);
|
||||
|
@ -11172,7 +11173,6 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
cards2.push(result.links[i]);
|
||||
cards.remove(result.links[i]);
|
||||
}
|
||||
game.cardsDiscard(cards);
|
||||
event.cards2=cards2;
|
||||
}
|
||||
else{
|
||||
|
@ -12310,7 +12310,7 @@ game.import('character',function(lib,game,ui,get,ai,_status){
|
|||
qianxi_info:'准备阶段,你可以摸一张牌,并弃置一张牌,然后令一名距离为1的角色不能使用或打出与你弃置的牌颜色相同的手牌直到回合结束。',
|
||||
zhiman_info:'当你对一名其他角色造成伤害时,你可以防止此伤害,然后获得其装备区或判定区的一张牌。',
|
||||
sanyao_info:'出牌阶段限一次,你可以弃置一张牌并指定一名体力值最多(或之一)的角色,你对其造成1点伤害。',
|
||||
olsanyao_info:'出牌阶段每项各限一次,你可以弃置一张牌并指定一名体力值或手牌数最多(或之一)的其他角色,并对其造成1点伤害。',
|
||||
olsanyao_info:'出牌阶段每项各限一次,你可以弃置一张牌并指定一名体力值或手牌数最多(或之一)的角色,并对其造成1点伤害。',
|
||||
rezhiman_info:'当你对一名其他角色造成伤害时,你可以防止此伤害,然后获得其区域内的一张牌。',
|
||||
resanyao_info:'出牌阶段限一次,你可以弃置任意张牌并指定等量除你外体力值最多(或之一)的其他角色。你对这些角色依次造成1点伤害。',
|
||||
paiyi_info:'出牌阶段限一次,你可以移去一张“权”并选择一名角色,令其摸两张牌,然后若其手牌数大于你,你对其造成1伤害。',
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
window.noname_asset_list=[
|
||||
'v1.9.102',
|
||||
'v1.9.102.1',
|
||||
'audio/background/aozhan_chaoming.mp3',
|
||||
'audio/background/aozhan_online.mp3',
|
||||
'audio/background/aozhan_rewrite.mp3',
|
||||
|
@ -588,6 +588,7 @@ window.noname_asset_list=[
|
|||
'audio/die/leitong.mp3',
|
||||
'audio/die/sp_sufei.mp3',
|
||||
'audio/die/wulan.mp3',
|
||||
'audio/die/key_saya.mp3',
|
||||
|
||||
'audio/skill/anguo1.mp3',
|
||||
'audio/skill/anguo2.mp3',
|
||||
|
@ -2604,6 +2605,10 @@ window.noname_asset_list=[
|
|||
'audio/skill/yuri_xingdong2.mp3',
|
||||
'audio/skill/zhengjian1.mp3',
|
||||
'audio/skill/zhengjian2.mp3',
|
||||
'audio/skill/saya_shouji1.mp3',
|
||||
'audio/skill/saya_shouji2.mp3',
|
||||
'audio/skill/saya_powei1.mp3',
|
||||
'audio/skill/saya_powei2.mp3',
|
||||
|
||||
'font/huangcao.ttf',
|
||||
'font/shousha.ttf',
|
||||
|
@ -3212,6 +3217,10 @@ window.noname_asset_list=[
|
|||
'image/character/old_jiakui.jpg',
|
||||
'image/character/sp_sufei.jpg',
|
||||
'image/character/wulan.jpg',
|
||||
'image/character/ol_zhangchangpu.jpg',
|
||||
'image/character/re_jianyong.jpg',
|
||||
'image/character/sp_key_yuri.jpg',
|
||||
'image/character/xin_xusheng.jpg',
|
||||
|
||||
'image/character/baiwuchang.jpg',
|
||||
'image/character/baosanniang.jpg',
|
||||
|
|
41
game/game.js
41
game/game.js
|
@ -5529,7 +5529,24 @@
|
|||
doudizhu:{
|
||||
name:'斗地主',
|
||||
connect:{
|
||||
update:function(config,map){},
|
||||
update:function(config,map){
|
||||
if(config.connect_doudizhu_mode=='kaihei'){
|
||||
map.connect_double_character.hide();
|
||||
}
|
||||
else{
|
||||
map.connect_double_character.show();
|
||||
}
|
||||
},
|
||||
connect_doudizhu_mode:{
|
||||
name:'游戏模式',
|
||||
init:'normal',
|
||||
item:{
|
||||
normal:'标准',
|
||||
kaihei:'开黑',
|
||||
},
|
||||
restart:true,
|
||||
frequent:true,
|
||||
},
|
||||
connect_double_character:{
|
||||
name:'双将模式',
|
||||
init:false,
|
||||
|
@ -5545,13 +5562,29 @@
|
|||
},
|
||||
config:{
|
||||
update:function(config,map){
|
||||
if(config.double_character){
|
||||
if(config.doudizhu_mode=='kaihei'){
|
||||
map.double_character.hide();
|
||||
}
|
||||
else{
|
||||
map.double_character.show();
|
||||
}
|
||||
if(config.double_character&&config.doudizhu_mode!='kaihei'){
|
||||
map.double_hp.show();
|
||||
}
|
||||
else{
|
||||
map.double_hp.hide();
|
||||
}
|
||||
},
|
||||
doudizhu_mode:{
|
||||
name:'游戏模式',
|
||||
init:'normal',
|
||||
item:{
|
||||
normal:'标准',
|
||||
kaihei:'开黑',
|
||||
},
|
||||
restart:true,
|
||||
frequent:true,
|
||||
},
|
||||
double_character:{
|
||||
name:'双将模式',
|
||||
init:false,
|
||||
|
@ -47819,7 +47852,7 @@
|
|||
}
|
||||
},
|
||||
modetrans:function(config,server){
|
||||
if(config.mode=='doudizhu') return '欢乐斗地主';
|
||||
if(config.mode=='doudizhu') return config.doudizhu_mode=='kaihei'?'开黑斗地主':'欢乐斗地主';
|
||||
if(config.mode=='versus'){
|
||||
switch(config.versus_mode){
|
||||
case '1v1':return '单人对决';
|
||||
|
@ -51127,7 +51160,7 @@
|
|||
}
|
||||
targets=get.selectableTargets();
|
||||
if(targets.length==0){
|
||||
return ok;
|
||||
return range[0]==0||ok;
|
||||
}
|
||||
targets2=targets.slice(0);
|
||||
// targets.sort(function(a,b){
|
||||
|
|
|
@ -1,28 +1,28 @@
|
|||
window.noname_update={
|
||||
version:'1.9.102',
|
||||
update:'1.9.101.1',
|
||||
version:'1.9.102.1',
|
||||
update:'1.9.102',
|
||||
changeLog:[
|
||||
'仲村由理、神山识语音',
|
||||
'SP武将再分包',
|
||||
'吴兰、雷铜、群苏飞、削弱版贾逵',
|
||||
'朱鹭户沙耶语音',
|
||||
'开黑斗地主模式',
|
||||
'OL张昌蒲、OL士燮、界简雍、界徐盛',
|
||||
'bug修复',
|
||||
|
||||
],
|
||||
files:[
|
||||
'card/extra.js',
|
||||
//'card/extra.js',
|
||||
//'card/huanlekapai.js',
|
||||
//'card/sp.js',
|
||||
'card/standard.js',
|
||||
//'card/standard.js',
|
||||
//'card/swd.js',
|
||||
//'card/mtg.js',
|
||||
//'card/gujian.js',
|
||||
//'card/guozhan.js',
|
||||
'card/guozhan.js',
|
||||
//'card/gwent.js',
|
||||
//'card/yunchou.js',
|
||||
//'card/zhenfa.js',
|
||||
//'card/zhulu.js',
|
||||
'character/diy.js',
|
||||
'character/extra.js',
|
||||
//'character/extra.js',
|
||||
//'character/hearth.js',
|
||||
//'character/gujian.js',
|
||||
//'character/gwent.js',
|
||||
|
@ -45,21 +45,21 @@ window.noname_update={
|
|||
//'layout/default/layout.css',
|
||||
//'layout/nova/layout.css',
|
||||
//'mode/identity.js',
|
||||
//'mode/doudizhu.js',
|
||||
//'mode/guozhan.js',
|
||||
'mode/doudizhu.js',
|
||||
'mode/guozhan.js',
|
||||
//'mode/chess.js',
|
||||
//'mode/tafang.js',
|
||||
//'mode/single.js',
|
||||
//'mode/stone.js',
|
||||
'mode/brawl.js',
|
||||
'mode/versus.js',
|
||||
//'mode/brawl.js',
|
||||
//'mode/versus.js',
|
||||
//'mode/boss.js',
|
||||
'game/game.js',
|
||||
//'game/NoSleep.js',
|
||||
'game/config.js',
|
||||
'game/package.js',
|
||||
//'game/config.js',
|
||||
//'game/package.js',
|
||||
//'game/asset.js',
|
||||
'game/source.js',
|
||||
//'game/source.js',
|
||||
//'theme/style/hp/xinglass.css',
|
||||
//'theme/style/hp/xinround.css',
|
||||
//'theme/style/hp/image/xinglass1.png',
|
||||
|
|
Binary file not shown.
After Width: | Height: | Size: 228 KiB |
Binary file not shown.
After Width: | Height: | Size: 171 KiB |
Binary file not shown.
After Width: | Height: | Size: 223 KiB |
Binary file not shown.
After Width: | Height: | Size: 227 KiB |
238
mode/doudizhu.js
238
mode/doudizhu.js
|
@ -27,7 +27,9 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
game.prepareArena(3);
|
||||
}
|
||||
"step 1"
|
||||
_status.mode=get.config('doudizhu_mode');
|
||||
if(_status.connectMode){
|
||||
_status.mode=lib.configOL.doudizhu_mode;
|
||||
game.waitForPlayer(function(){
|
||||
lib.configOL.number=3;
|
||||
});
|
||||
|
@ -76,6 +78,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
_status.videoInited=true;
|
||||
game.addVideo('init',null,info);
|
||||
if(_status.mode=='kaihei') game.addGlobalSkill('kaihei');
|
||||
|
||||
game.gameDraw(game.zhu||_status.firstAct||game.me);
|
||||
if(_status.connectMode&&lib.configOL.change_card) game.replaceHandcards(game.players.slice(0));
|
||||
|
@ -190,7 +193,75 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
}
|
||||
else return player.identity=='fan';
|
||||
},
|
||||
chooseCharacterKaihei:function(){
|
||||
var next=game.createEvent('chooseCharacter',false);
|
||||
next.setContent(function(){
|
||||
"step 0"
|
||||
ui.arena.classList.add('choose-character');
|
||||
var i;
|
||||
var identityList=['zhu','fan','fan'];
|
||||
game.saveConfig('continue_name');
|
||||
event.list=[];
|
||||
identityList.randomSort();
|
||||
for(i=0;i<game.players.length;i++){
|
||||
game.players[i].identity=identityList[i];
|
||||
game.players[i].showIdentity();
|
||||
if(identityList[i]=='zhu'){
|
||||
game.zhu=game.players[i];
|
||||
}
|
||||
}
|
||||
|
||||
if(!game.zhu) game.zhu=game.me;
|
||||
else{
|
||||
game.zhu.setIdentity();
|
||||
game.zhu.identityShown=true;
|
||||
game.zhu.isZhu=(game.zhu.identity=='zhu');
|
||||
game.zhu.node.identity.classList.remove('guessing');
|
||||
game.me.setIdentity();
|
||||
game.me.node.identity.classList.remove('guessing');
|
||||
}
|
||||
for(i in lib.character){
|
||||
if(lib.filter.characterDisabled(i)) continue;
|
||||
event.list.push(i);
|
||||
}
|
||||
event.list.randomSort();
|
||||
_status.characterlist=event.list.slice(0);
|
||||
for(var player of game.players){
|
||||
player._characterChoice=event.list.randomRemove(player.identity=='zhu'?5:3);
|
||||
if(player.identity=='fan') player._friend=(player.next.identity=='fan'?player.next:player.previous);
|
||||
}
|
||||
var createDialog=['选择武将'];
|
||||
createDialog.push([game.me._characterChoice,'character']);
|
||||
if(game.me._friend){
|
||||
createDialog.push('队友的武将');
|
||||
createDialog.push([game.me._friend._characterChoice,'character']);
|
||||
}
|
||||
game.me.chooseButton(createDialog,true).set('onfree',true).set('filterButton',function(button){
|
||||
return _status.event.player._characterChoice.contains(button.link);
|
||||
});
|
||||
"step 1"
|
||||
game.me.init(result.links[0]);
|
||||
for(var i=0;i<game.players.length;i++){
|
||||
if(game.players[i]!=game.me) game.players[i].init(game.players[i]._characterChoice.randomGet());
|
||||
_status.characterlist.remove(game.players[i].name);
|
||||
_status.characterlist.remove(game.players[i].name2);
|
||||
if(game.players[i]==game.zhu){
|
||||
game.players[i].hp++;
|
||||
game.players[i].maxHp++;
|
||||
game.players[i].update();
|
||||
}
|
||||
}
|
||||
setTimeout(function(){
|
||||
ui.arena.classList.remove('choose-character');
|
||||
},500);
|
||||
|
||||
});
|
||||
},
|
||||
chooseCharacter:function(){
|
||||
if(_status.mode=='kaihei'){
|
||||
game.chooseCharacterKaihei();
|
||||
return;
|
||||
}
|
||||
var next=game.createEvent('chooseCharacter',false);
|
||||
next.showConfig=true;
|
||||
next.addPlayer=function(player){
|
||||
|
@ -211,9 +282,9 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
player.init(list[0]);
|
||||
}
|
||||
if(player==game.zhu){
|
||||
player.hp++;
|
||||
player.maxHp++;
|
||||
player.update();
|
||||
player.hp++;
|
||||
player.maxHp++;
|
||||
player.update();
|
||||
}
|
||||
if(back){
|
||||
list.remove(player.name);
|
||||
|
@ -225,12 +296,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
if(typeof lib.config.test_game=='string'&&player==game.me.next){
|
||||
player.init(lib.config.test_game);
|
||||
}
|
||||
if(get.config('choose_group')&&player.group=='shen'){
|
||||
var list=lib.group.slice(0);
|
||||
list.remove('shen');
|
||||
if(list.length) player.group=list.randomGet();
|
||||
}
|
||||
player.node.name.dataset.nature=get.groupnature(player.group);
|
||||
player.node.name.dataset.nature=get.groupnature(player.group);
|
||||
}
|
||||
next.setContent(function(){
|
||||
"step 0"
|
||||
|
@ -418,12 +484,6 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
if(chosen.contains(i)) continue;
|
||||
if(lib.filter.characterDisabled(i)) continue;
|
||||
event.list.push(i);
|
||||
if(lib.character[i][4]&&lib.character[i][4].contains('zhu')){
|
||||
list2.push(i);
|
||||
}
|
||||
else{
|
||||
list3.push(i);
|
||||
}
|
||||
}
|
||||
event.list.randomSort();
|
||||
_status.characterlist=event.list.slice(0);
|
||||
|
@ -611,7 +671,118 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
|
||||
});
|
||||
},
|
||||
|
||||
chooseCharacterKaiheiOL:function(){
|
||||
var next=game.createEvent('chooseCharacter',false);
|
||||
next.setContent(function(){
|
||||
"step 0"
|
||||
ui.arena.classList.add('choose-character');
|
||||
var i;
|
||||
var identityList=['fan','fan','fan'];
|
||||
var aiList=game.filterPlayer(function(current){
|
||||
return current!=game.me&&!current.isOnline();
|
||||
});
|
||||
if(aiList.length==1){
|
||||
identityList[game.players.indexOf(aiList[0])]='zhu';
|
||||
}
|
||||
else{
|
||||
identityList[0]='zhu';
|
||||
identityList.randomSort();
|
||||
}
|
||||
for(i=0;i<game.players.length;i++){
|
||||
game.players[i].identity=identityList[i];
|
||||
game.players[i].showIdentity();
|
||||
game.players[i].identityShown=true;
|
||||
if(identityList[i]=='zhu') game.zhu=game.players[i];
|
||||
}
|
||||
event.list=[];
|
||||
|
||||
var libCharacter={};
|
||||
for(var i=0;i<lib.configOL.characterPack.length;i++){
|
||||
var pack=lib.characterPack[lib.configOL.characterPack[i]];
|
||||
for(var j in pack){
|
||||
if(j=='zuoci') continue;
|
||||
if(lib.character[j]) libCharacter[j]=pack[j];
|
||||
}
|
||||
}
|
||||
for(var i in libCharacter){
|
||||
if(lib.filter.characterDisabled(i,libCharacter)) continue;
|
||||
event.list.push(i);
|
||||
}
|
||||
_status.characterlist=event.list.slice(0);
|
||||
|
||||
var map={};
|
||||
for(var player of game.players){
|
||||
player._characterChoice=event.list.randomRemove(player.identity=='zhu'?5:3);
|
||||
if(player.identity=='fan') player._friend=(player.next.identity=='fan'?player.next:player.previous);
|
||||
map[player.playerid]=player._characterChoice;
|
||||
}
|
||||
game.broadcast(function(map){
|
||||
for(var i in map){
|
||||
lib.playerOL[i]._characterChoice=map[i];
|
||||
}
|
||||
},map);
|
||||
"step 1"
|
||||
var list=[];
|
||||
for(var i=0;i<game.players.length;i++){
|
||||
var dialog=['请选择武将',[game.players[i]._characterChoice,'character']];
|
||||
if(game.players[i]._friend){
|
||||
dialog.push('队友的武将');
|
||||
dialog.push([game.players[i]._friend._characterChoice,'character']);
|
||||
}
|
||||
list.push([game.players[i],dialog,true,function(){return Math.random()},function(button){
|
||||
return _status.event.player._characterChoice.contains(button.link);
|
||||
}]);
|
||||
}
|
||||
game.me.chooseButtonOL(list,function(player,result){
|
||||
if(game.online||player==game.me) player.init(result.links[0]);
|
||||
});
|
||||
"step 2"
|
||||
for(var i in lib.playerOL){
|
||||
if(!result[i]||result[i]=='ai'||!result[i].links||!result[i].links.length){
|
||||
result[i]=lib.playerOL[i]._characterChoice.randomGet();
|
||||
}
|
||||
else{
|
||||
result[i]=result[i].links[0];
|
||||
}
|
||||
if(!lib.playerOL[i].name){
|
||||
lib.playerOL[i].init(result[i]);
|
||||
}
|
||||
}
|
||||
|
||||
game.zhu.maxHp++;
|
||||
game.zhu.hp++;
|
||||
game.zhu.update();
|
||||
|
||||
game.broadcast(function(result,zhu){
|
||||
for(var i in result){
|
||||
if(!lib.playerOL[i].name){
|
||||
lib.playerOL[i].init(result[i]);
|
||||
}
|
||||
}
|
||||
game.zhu=zhu;
|
||||
zhu.maxHp++;
|
||||
zhu.hp++;
|
||||
zhu.update();
|
||||
|
||||
setTimeout(function(){
|
||||
ui.arena.classList.remove('choose-character');
|
||||
},500);
|
||||
},result,game.zhu);
|
||||
for(var i=0;i<game.players.length;i++){
|
||||
_status.characterlist.remove(game.players[i].name);
|
||||
_status.characterlist.remove(game.players[i].name2);
|
||||
}
|
||||
setTimeout(function(){
|
||||
ui.arena.classList.remove('choose-character');
|
||||
},500);
|
||||
});
|
||||
},
|
||||
chooseCharacterOL:function(){
|
||||
if(_status.mode=='kaihei'){
|
||||
game.chooseCharacterKaiheiOL();
|
||||
return;
|
||||
}
|
||||
var next=game.createEvent('chooseCharacter',false);
|
||||
next.setContent(function(){
|
||||
"step 0"
|
||||
|
@ -728,6 +899,8 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
_bahu:"跋扈",
|
||||
_feiyang_info:"判定阶段开始时,若你的判定区有牌,则你可以弃置两张手牌,然后弃置你判定区的一张牌。每回合限一次。",
|
||||
_bahu_info:"锁定技,准备阶段开始时,你摸一张牌。出牌阶段,你可以多使用一张【杀】。",
|
||||
kaihei:'强易',
|
||||
kaihei_info:'出牌阶段,你可以获得一名其他角色的至多两张牌,然后交给其等量的牌。每名角色每局游戏限一次。',
|
||||
},
|
||||
element:{
|
||||
player:{
|
||||
|
@ -789,6 +962,41 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
},
|
||||
},
|
||||
skill:{
|
||||
kaihei:{
|
||||
enable:'phaseUse',
|
||||
filter:function(event,player){
|
||||
return player==game.zhu&&game.hasPlayer(function(current){
|
||||
return lib.skill.kaihei.filterTarget(null,player,current);
|
||||
});
|
||||
},
|
||||
filterTarget:function(card,player,target){
|
||||
return player!=target&&!target.storage.kaihei&&target.countGainableCards(player,'he')>0;
|
||||
},
|
||||
content:function(){
|
||||
'step 0'
|
||||
player.gainPlayerCard(target,[1,2],'he',true);
|
||||
target.storage.kaihei=true;
|
||||
'step 1'
|
||||
if(!result.bool||!result.cards.length){
|
||||
event.finish();return;
|
||||
}
|
||||
var num=result.cards.length;
|
||||
var hs=player.getCards('he');
|
||||
if(hs.length){
|
||||
if(hs.length<=num) event._result={bool:true,cards:hs};
|
||||
else player.chooseCard('he',true,num,'选择交给'+get.translation(target)+get.cnNumber(num)+'张牌');
|
||||
}
|
||||
else event.finish();
|
||||
'step 2'
|
||||
if(result.bool&&result.cards&&result.cards.length) target.gain(result.cards,player,'giveAuto');
|
||||
},
|
||||
ai:{
|
||||
viewHandcard:true,
|
||||
skillTagFilter:function(player,tag,target){
|
||||
if(player==target||player.identity!='fan'||target.identity!='fan') return false;
|
||||
},
|
||||
},
|
||||
},
|
||||
_feiyang:{
|
||||
trigger:{player:'phaseJudgeBegin'},
|
||||
direct:true,
|
||||
|
|
|
@ -8145,6 +8145,7 @@ game.import('mode',function(lib,game,ui,get,ai,_status){
|
|||
else if(source&&source.identity!='unknown'){
|
||||
if(source.identity=='ye') source.draw(3);
|
||||
else if(source.shijun2){
|
||||
delete source.shijun2;
|
||||
source.draw(1+game.countPlayer(function(current){
|
||||
return current.group==that.group
|
||||
}));
|
||||
|
|
Loading…
Reference in New Issue