This commit is contained in:
libccy 2016-09-17 12:09:38 +08:00
parent 688d8ba2bb
commit 3a236f6ac5
5 changed files with 215 additions and 115 deletions

View File

@ -2577,7 +2577,9 @@ card.swd={
yiluan:{
enable:'phaseUse',
usable:1,
filterTarget:true,
filterTarget:function(card,player,target){
return get.distance(player,target,'attack')<=1;
},
content:function(){
'step 0'
var card=get.cards(0);
@ -3105,6 +3107,8 @@ card.swd={
_lingjianduanzao:{
enable:'phaseUse',
position:'he',
discard:false,
losetrigger:false,
prompt:function(event){
var lingjians=[],types=[];
var hs=event.player.get('he');
@ -3312,7 +3316,13 @@ card.swd={
}
return false;
},
prepare:function(cards,player){
player.$throw(cards);
},
content:function(){
for(var i=0;i<cards.length;i++){
ui.discardPile.appendChild(cards[i]);
}
var name=lib.skill._lingjianduanzao.process(cards);
player.gain(game.createCard(name),'gain2');
},
@ -4023,7 +4033,7 @@ card.swd={
hslingjian_shijianhuisu_equip4_info:'当你的装备区内没有其他牌时,你的进攻距离+1',
hslingjian_shijianhuisu_equip5_info:'出牌阶段限一次,你可以弃置一张牌,然后令一名其他角色将其装备区内的牌收回手牌',
_lingjianduanzao:'煅造',
_lingjianduanzao_info:'出牌阶段,你可以弃置一张装备牌和一张可煅造的牌,并获得一件强化装备强化装备可以装备给距离1以内的角色',
_lingjianduanzao_info:'出牌阶段,你可以将一张装备牌和一张可煅造的牌合成为一件强化装备强化装备可以装备给距离1以内的角色',
jiguanshu:'机关鼠',
jiguanshu_info:'出牌阶段对一名角色使用,用随机零件强化目标装备区内的装备',
lingjiandai:'零件袋',
@ -4141,9 +4151,9 @@ card.swd={
guangshatianyi_bg:'纱',
guangshatianyi_info:'仅女性可装备,锁定技,每当你即将受到伤害,有三分之一的概率令伤害减一',
sifeizhenmian:'四非真面',
sifeizhenmian_info:'出牌阶段限一次,你可以指定一名角色并亮出牌堆顶的一张牌,若此牌为黑色,该角色进入混乱状态直到下一回合结束;否则该角色摸一张牌',
sifeizhenmian_info:'出牌阶段限一次,你可以指定攻击范围内的一名角色并亮出牌堆顶的一张牌,若此牌为黑色,该角色进入混乱状态直到下一回合结束;否则该角色摸一张牌',
yiluan:'意乱',
yiluan_info:'出牌阶段限一次,你可以指定一名角色并亮出牌堆顶的一张牌,若此牌为黑色,该角色进入混乱状态直到下一回合结束;否则该角色摸一张牌',
yiluan_info:'出牌阶段限一次,你可以指定攻击范围内的一名角色并亮出牌堆顶的一张牌,若此牌为黑色,该角色进入混乱状态直到下一回合结束;否则该角色摸一张牌',
donghuangzhong:'东皇钟',
xuanyuanjian:'轩辕剑',
xuanyuanjian2:'轩辕剑',

View File

@ -65,9 +65,9 @@ character.sp={
sp_pangde:['male','wei',4,['mashu','juesi']],
sp_jiaxu:['male','wei',3,['zhenlue','jianshu','yongdi']],
litong:['male','wei',4,['tuifeng']],
mizhu:['male','shu',4,['ziyuan','jugu']],
buzhi:['male','wu',4,['hongde','dingpan']],
// litong:['male','wei',4,['tuifeng']],
// mizhu:['male','shu',4,['ziyuan','jugu']],
// buzhi:['male','wu',4,['hongde','dingpan']],
},
perfectPair:{
zhugejin:['zhugeke'],

View File

@ -98,7 +98,7 @@ character.swd={
swd_youzhao:['male','shu',4,['longdan','yuchen']],
// swd_qingming:['male','shu',3,['mingfu','tianlun']],
swd_shangzhang:['male','shu',4,['lianwu']],
swd_situqiang:['female','shu',3,['fengze','jidian','jinlin']],
swd_situqiang:['female','shu',3,['fengze','lingyue','jinlin']],
swd_chunyuheng:['male','wei',2,['jueqing','shengshou','xuying']],
swd_hanlong:['male','wei',4,['ciqiu','siji']],
@ -143,6 +143,94 @@ character.swd={
swd_luchengxuan:['swd_xiarou'],
},
skill:{
jinlin:{
enable:'phaseUse',
unique:true,
mark:true,
skillAnimation:true,
animationColor:'metal',
init:function(player){
player.storage.jinlin=false;
},
filter:function(event,player){
if(player.storage.jinlin) return false;
return true;
},
filterTarget:true,
selectTarget:[1,Infinity],
content:function(){
if(target==targets[0]){
player.unmarkSkill('jinlin');
player.storage.jinlin=true;
}
target.changeHujia(3);
target.addSkill('jinlin2');
target.storage.jinlin2=3;
},
ai:{
order:1,
result:{
target:function(player,target){
if(player.hp==1) return 1;
var num=0;
for(var i=0;i<game.players.length;i++){
if(ai.get.attitude(player,game.players[i])>2){
if(game.players[i].hp==1) return 1;
if(game.players[i].hp==2) num++;
}
}
if(player.hasUnknown()) return 0;
if(num>1) return 1;
return 0;
}
},
},
intro:{
content:'limited'
}
},
jinlin2:{
trigger:{player:'phaseBegin'},
forced:true,
popup:false,
content:function(){
if(player.hujia>0){
player.changeHujia(-1);
}
player.storage.jinlin2--;
if(player.hujia==0||player.storage.jinlin2==0){
player.removeSkill('jinlin2');
delete player.storage.jinlin2;
}
},
},
lingyue:{
trigger:{player:'shaBegin'},
check:function(event,player){
return ai.get.attitude(player,event.target)<0;
},
filter:function(event,player){
return event.target.num('he')>0;
},
content:function(){
trigger.target.chooseToDiscard('he',true);
}
},
fengze:{
enable:'phaseUse',
filterCard:true,
selectCard:2,
position:'he',
viewAs:{name:'taoyuan'},
filter:function(event,player){
return player.num('he',{color:'black'})>=2;
},
audio:true,
prompt:'将两张黑色牌当作桃园结义使用',
check:function(card){
return 6-ai.get.useful(card)
}
},
zaowu:{
enable:'chooseToUse',
filter:function(event,player){
@ -4495,15 +4583,10 @@ character.swd={
return 8-ai.get.value(card);
},
content:function(){
if(player.num('e')){
var list=get.typeCard('hslingjian');
if(list.length){
player.gain(game.createCard(list.randomGet()),'gain');
}
}
else{
player.gain(game.createCard(get.inpile('equip').randomGet()),'gain');
}
var card=game.createCard(get.inpile('equip').randomGet());
player.equip(card);
player.$gain2(card);
game.delay();
},
ai:{
result:{
@ -7740,9 +7823,11 @@ character.swd={
swd_xiyan:'犀衍',
fengze:'风泽',
fengze_info:'出牌阶段限一次,你可以将两张黑色牌当作桃园结义使用',
fengze_info:'出牌阶段,你可以将两张黑色牌当作桃园结义使用',
lingyue:'凌月',
lingyue_info:'每当你使用一张杀,你可以令目标弃置一张牌',
jinlin:'金鳞',
jinlin_info:'限定技出牌阶段你可以令至多3名角色各获得3点护甲获得护甲的角色于每个回合开始阶段失去1点护甲直到首次失去所有护甲',
jinlin_info:'限定技,出牌阶段,你可以令任意名角色各获得3点护甲获得护甲的角色于每个回合开始阶段失去1点护甲直到首次失去所有护甲或累计以此法失去3点护甲',
huanxia:'幻霞',
huanxia_info:'你可以将一张红色牌当作杀使用,若此杀未造成伤害,你可以在其进入弃牌堆后收回此牌',
jingjie:'镜界',
@ -8117,7 +8202,7 @@ character.swd={
swd_wuxie_info:'锁定技,你不能成为其他角色的延时锦囊的目标',
qingcheng_info:'回合结束阶段你可以进行判定若为红色则可以继续判定最多判定3次判定结束后将判定成功的牌收入手牌',
xianjiang_old_info:'出牌阶段,你可以将一张装备牌永久转化为任意一张其它装备牌,一张牌在一个阶段只能转化一次',
xianjiang_info:'出牌阶段限一次,你可以弃置一张锦囊牌,若你装备区内没有牌,你获得一张装备牌,否则你获得一张零件牌',
xianjiang_info:'出牌阶段限一次,你可以弃置一张锦囊牌并随机装备一件装备',
shengong_info:'每当你需要打出一张杀或闪时,你可以弃置一名其他角色装备区内的一张武器牌或防具牌,视为打出一张杀或闪,然后该角色摸一张牌,你弃一张牌',
ningjian_info:'你可以将一张红色牌当闪、黑色牌当杀使用或打出',
taixu_info:'限定技你可以弃置你的所有牌至少1张并对一名体力值大于1为其他角色造成X点火焰伤害X为你已损失的体力值且至少为1',

View File

@ -4727,6 +4727,98 @@
window.lib=lib;
window._status=_status;
},
c:function(){
(function(){
var a=0,b=0,c=0,d=0;
var sa=0,sb=0,sc=0,sd=0;
for(var i in lib.character){
switch(lib.character[i][1]){
case 'wei':a++;if(lib.config.forbidall.contains(i)) sa++;break;
case 'shu':b++;if(lib.config.forbidall.contains(i)) sb++;break;
case 'wu':c++;if(lib.config.forbidall.contains(i)) sc++;break;
case 'qun':d++;if(lib.config.forbidall.contains(i)) sd++;break;
}
}
console.log('魏:'+(a-sa)+'/'+a);
console.log('蜀:'+(b-sb)+'/'+b);
console.log('吴:'+(c-sc)+'/'+c);
console.log('群:'+(d-sd)+'/'+d);
console.log(((a+b+c+d)-(sa+sb+sc+sd))+'/'+(a+b+c+d));
}());
(function(){
var a=0,b=0,c=0,d=0;
var aa=0,bb=0,cc=0,dd=0;
var sa=0,sb=0,sc=0,sd=0;
var sha=0,shan=0,tao=0,jiu=0,wuxie=0,heisha=0,hongsha=0;
var num={1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0};
for(var i in lib.card){
if(typeof lib.card[i]=='object'){
switch(lib.card[i].type){
case 'basic':a++;break;
case 'trick':b++;break;
case 'equip':c++;break;
default:d++;break;
}
}
}
for(var i=0;i<lib.card.list.length;i++){
if(typeof lib.card[lib.card.list[i][2]]=='object'){
switch(lib.card[lib.card.list[i][2]].type){
case 'basic':aa++;break;
case 'trick':case 'delay':bb++;break;
case 'equip':cc++;break;
default:dd++;break;
}
switch(lib.card.list[i][0]){
case 'heart':sa++;break;
case 'diamond':sb++;break;
case 'club':sc++;break;
case 'spade':sd++;break;
}
if(lib.card.list[i][2]=='sha'){
sha++;
if(lib.card.list[i][0]=='club'||lib.card.list[i][0]=='spade'){
heisha++;
}
else{
hongsha++;
}
}
if(lib.card.list[i][2]=='shan'){
shan++;
}
if(lib.card.list[i][2]=='tao'){
tao++;
}
if(lib.card.list[i][2]=='jiu'){
jiu++;
}
if(lib.card.list[i][2]=='wuxie'){
wuxie++;
}
num[lib.card.list[i][1]]++;
}
}
var str='基本牌'+aa+' '+'锦囊牌'+bb+' '+'装备牌'+cc+' '+'其它牌'+dd
console.log(str);
str='红桃牌'+sa+' '+'方片牌'+sb+' '+'梅花牌'+sc+' '+'黑桃牌'+sd
console.log(str);
str='杀'+sha+' '+'黑杀'+heisha+' '+'红杀'+hongsha+' '+'闪'+shan+' '+'桃'+tao+' '+'酒'+jiu+' '+'无懈'+wuxie
console.log(str);
if(arguments[1]){
for(var i=1;i<=13;i++){
if(i<10){
console.log(i+' ',num[i]);
}
else{
console.log(i,num[i]);
}
}
}
console.log(a+b+c+d);
console.log(aa+bb+cc+dd);
}());
},
id:function(){
game.showIdentity();
},
@ -7335,7 +7427,12 @@
}
else{
if(info.lose!=false){
if(info.losetrigger==false){
player.lose(cards,ui.special)._triggered=null;
}
else{
player.lose(cards,ui.special);
}
}
if(info.prepare){
info.prepare(cards,player,targets);
@ -33326,100 +33423,6 @@
}
return list;
}
}
window.countGroups=function(){
var a=0,b=0,c=0,d=0;
var sa=0,sb=0,sc=0,sd=0;
for(var i in lib.character){
switch(lib.character[i][1]){
case 'wei':a++;if(lib.config.forbidall.contains(i)) sa++;break;
case 'shu':b++;if(lib.config.forbidall.contains(i)) sb++;break;
case 'wu':c++;if(lib.config.forbidall.contains(i)) sc++;break;
case 'qun':d++;if(lib.config.forbidall.contains(i)) sd++;break;
}
}
console.log('魏:'+(a-sa)+'/'+a);
console.log('蜀:'+(b-sb)+'/'+b);
console.log('吴:'+(c-sc)+'/'+c);
console.log('群:'+(d-sd)+'/'+d);
return ((a+b+c+d)-(sa+sb+sc+sd))+'/'+(a+b+c+d);
}
window.countSkills=function(){
for(var i in lib.skill){
if(lib.translate[i+'_info']){
console.log(lib.translate[i],lib.translate[i+'_info'])
}
}
}
window.countCards=function(){
var a=0,b=0,c=0,d=0;
var aa=0,bb=0,cc=0,dd=0;
var sa=0,sb=0,sc=0,sd=0;
var sha=0,shan=0,tao=0,jiu=0,wuxie=0,heisha=0,hongsha=0;
var num={1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0};
for(var i in lib.card){
if(typeof lib.card[i]=='object'){
switch(lib.card[i].type){
case 'basic':a++;break;
case 'trick':b++;break;
case 'equip':c++;break;
default:d++;break;
}
}
}
for(var i=0;i<lib.card.list.length;i++){
if(typeof lib.card[lib.card.list[i][2]]=='object'){
switch(lib.card[lib.card.list[i][2]].type){
case 'basic':aa++;break;
case 'trick':case 'delay':bb++;break;
case 'equip':cc++;break;
default:dd++;break;
}
switch(lib.card.list[i][0]){
case 'heart':sa++;break;
case 'diamond':sb++;break;
case 'club':sc++;break;
case 'spade':sd++;break;
}
if(lib.card.list[i][2]=='sha'){
sha++;
if(lib.card.list[i][0]=='club'||lib.card.list[i][0]=='spade'){
heisha++;
}
else{
hongsha++;
}
}
if(lib.card.list[i][2]=='shan'){
shan++;
}
if(lib.card.list[i][2]=='tao'){
tao++;
}
if(lib.card.list[i][2]=='jiu'){
jiu++;
}
if(lib.card.list[i][2]=='wuxie'){
wuxie++;
}
num[lib.card.list[i][1]]++;
}
}
var str='基本牌'+aa+' '+'锦囊牌'+bb+' '+'装备牌'+cc+' '+'其它牌'+dd
console.log(str);
str='红桃牌'+sa+' '+'方片牌'+sb+' '+'梅花牌'+sc+' '+'黑桃牌'+sd
console.log(str);
str='杀'+sha+' '+'黑杀'+heisha+' '+'红杀'+hongsha+' '+'闪'+shan+' '+'桃'+tao+' '+'酒'+jiu+' '+'无懈'+wuxie
console.log(str);
for(var i=1;i<=13;i++){
if(i<10){
console.log(i+' ',num[i]);
}
else{
console.log(i,num[i]);
}
}
return aa+bb+cc+dd;
}
window.onkeydown=function(e){
if(!ui.menuContainer||!ui.menuContainer.classList.contains('hidden')){

View File

@ -9064,6 +9064,7 @@ mode.stone={
enable:['chooseToUse','chooseToRespond'],
filterCard:{type:'equip'},
viewAs:{name:'sha'},
nopop:true,
check:function(){return 1},
filter:function(event,player){
return player.num('h',{type:'equip'})>0;
@ -9094,6 +9095,7 @@ mode.stone={
if(get.type(card)=='stonecard') return false;
},
},
nopop:true,
check:function(){return 1},
filter:function(event,player){
return player.num('h',{type:['stonecharacter','stonecard']})>0;