This commit is contained in:
parent
b67c2280b0
commit
fda7771ab0
18
game/game.js
18
game/game.js
|
@ -13424,6 +13424,7 @@
|
||||||
this.node.identity.firstChild.innerHTML=get.translation(identity);
|
this.node.identity.firstChild.innerHTML=get.translation(identity);
|
||||||
}
|
}
|
||||||
this.node.identity.dataset.color=identity;
|
this.node.identity.dataset.color=identity;
|
||||||
|
return this;
|
||||||
},
|
},
|
||||||
insertPhase:function(skill){
|
insertPhase:function(skill){
|
||||||
var evt=_status.event.getParent('phase');
|
var evt=_status.event.getParent('phase');
|
||||||
|
@ -21448,7 +21449,13 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
bossSwap:function(player,name){
|
bossSwap:function(player,name){
|
||||||
|
if(player&&name){
|
||||||
player.delete();
|
player.delete();
|
||||||
|
var noboss=false;
|
||||||
|
if(name[0]=='_'){
|
||||||
|
name=name.slice(1);
|
||||||
|
noboss=true;
|
||||||
|
}
|
||||||
var boss=ui.create.player().init(name);
|
var boss=ui.create.player().init(name);
|
||||||
boss.dataset.position=player.dataset.position;
|
boss.dataset.position=player.dataset.position;
|
||||||
game.playerMap[player.dataset.position]=boss;
|
game.playerMap[player.dataset.position]=boss;
|
||||||
|
@ -21457,10 +21464,17 @@
|
||||||
}
|
}
|
||||||
game.players.push(boss);
|
game.players.push(boss);
|
||||||
game.arrangePlayers();
|
game.arrangePlayers();
|
||||||
|
if(!noboss){
|
||||||
game.boss=boss;
|
game.boss=boss;
|
||||||
ui.arena.appendChild(boss.animate('zoominanim'));
|
|
||||||
boss.setIdentity('zhu');
|
boss.setIdentity('zhu');
|
||||||
boss.identity='zhu';
|
boss.identity='zhu';
|
||||||
|
}
|
||||||
|
else{
|
||||||
|
boss.setIdentity('zhong');
|
||||||
|
boss.identity='zhong';
|
||||||
|
}
|
||||||
|
ui.arena.appendChild(boss.animate('zoominanim'));
|
||||||
|
}
|
||||||
},
|
},
|
||||||
stoneSwap:function(info){
|
stoneSwap:function(info){
|
||||||
var player=ui.create.player();
|
var player=ui.create.player();
|
||||||
|
@ -40594,7 +40608,7 @@
|
||||||
td.innerHTML='手牌';
|
td.innerHTML='手牌';
|
||||||
tr.appendChild(td);
|
tr.appendChild(td);
|
||||||
td=document.createElement('td');
|
td=document.createElement('td');
|
||||||
td.innerHTML='轮数';
|
td.innerHTML='行动';
|
||||||
tr.appendChild(td);
|
tr.appendChild(td);
|
||||||
|
|
||||||
tr=document.createElement('tr');
|
tr=document.createElement('tr');
|
||||||
|
|
44
mode/boss.js
44
mode/boss.js
|
@ -463,34 +463,51 @@ mode.boss={
|
||||||
},
|
},
|
||||||
game:{
|
game:{
|
||||||
reserveDead:true,
|
reserveDead:true,
|
||||||
changeBoss:function(name){
|
addBossFellow:function(position,name){
|
||||||
|
var fellow=game.addFellow(position,name,'zoominanim');
|
||||||
|
fellow.directgain(get.cards(4));
|
||||||
|
fellow.side=true;
|
||||||
|
fellow.identity='zhong';
|
||||||
|
fellow.setIdentity('zhong');
|
||||||
|
game.addVideo('setIdentity',fellow,'zhong');
|
||||||
|
},
|
||||||
|
changeBoss:function(name,player){
|
||||||
|
if(!player){
|
||||||
if(game.additionaldead){
|
if(game.additionaldead){
|
||||||
game.additionaldead.push(game.boss);
|
game.additionaldead.push(game.boss);
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
game.additionaldead=[game.boss];
|
game.additionaldead=[game.boss];
|
||||||
}
|
}
|
||||||
game.boss.delete();
|
player=game.boss;
|
||||||
game.dead.remove(game.boss);
|
delete game.boss;
|
||||||
|
}
|
||||||
|
|
||||||
|
player.delete();
|
||||||
|
game.players.remove(player);
|
||||||
|
game.dead.remove(player);
|
||||||
var boss=ui.create.player();
|
var boss=ui.create.player();
|
||||||
boss.getId();
|
boss.getId();
|
||||||
boss.init(name);
|
boss.init(name);
|
||||||
boss.side=true;
|
boss.side=true;
|
||||||
game.addVideo('bossSwap',game.boss,boss.name);
|
game.addVideo('bossSwap',player,(game.boss?'_':'')+boss.name);
|
||||||
if(game.me==game.boss){
|
boss.dataset.position=player.dataset.position;
|
||||||
boss.dataset.position=0;
|
if(game.me==player){
|
||||||
game.swapControl(boss);
|
game.swapControl(boss);
|
||||||
}
|
}
|
||||||
else{
|
|
||||||
boss.dataset.position=7;
|
|
||||||
}
|
|
||||||
game.players.push(boss.animate('zoominanim'));
|
game.players.push(boss.animate('zoominanim'));
|
||||||
game.arrangePlayers();
|
game.arrangePlayers();
|
||||||
|
if(!game.boss){
|
||||||
game.boss=boss;
|
game.boss=boss;
|
||||||
ui.arena.appendChild(boss);
|
|
||||||
boss.directgain(get.cards(4));
|
|
||||||
boss.setIdentity('zhu');
|
boss.setIdentity('zhu');
|
||||||
boss.identity='zhu';
|
boss.identity='zhu';
|
||||||
|
}
|
||||||
|
else{
|
||||||
|
boss.setIdentity('zhong');
|
||||||
|
boss.identity='zhong';
|
||||||
|
}
|
||||||
|
ui.arena.appendChild(boss);
|
||||||
|
boss.directgain(get.cards(4));
|
||||||
},
|
},
|
||||||
checkResult:function(){
|
checkResult:function(){
|
||||||
if(game.boss==game.me){
|
if(game.boss==game.me){
|
||||||
|
@ -960,8 +977,8 @@ mode.boss={
|
||||||
game.players[i].hp=game.players[i].maxHp;
|
game.players[i].hp=game.players[i].maxHp;
|
||||||
game.players[i].update();
|
game.players[i].update();
|
||||||
}
|
}
|
||||||
game.addFellow(game.me==game.boss?1:5,'boss_yanling','zoominanim').directgain(get.cards(4)).side=true;
|
game.addBossFellow(game.me==game.boss?1:5,'boss_yanling');
|
||||||
game.addFellow(7,'boss_yanling','zoominanim').directgain(get.cards(4)).side=true;
|
game.addBossFellow(7,'boss_yanling');
|
||||||
game.animate.window(2);
|
game.animate.window(2);
|
||||||
'step 3'
|
'step 3'
|
||||||
while(_status.event.name!='phaseLoop'){
|
while(_status.event.name!='phaseLoop'){
|
||||||
|
@ -3743,6 +3760,7 @@ mode.boss={
|
||||||
translate:{
|
translate:{
|
||||||
zhu:'神',
|
zhu:'神',
|
||||||
cai:'盟',
|
cai:'盟',
|
||||||
|
zhong:'从',
|
||||||
|
|
||||||
boss_chi:'魑',
|
boss_chi:'魑',
|
||||||
boss_mo:'魅',
|
boss_mo:'魅',
|
||||||
|
|
|
@ -1285,6 +1285,7 @@ mode.stone={
|
||||||
next.player=player;
|
next.player=player;
|
||||||
next.setContent(function(){
|
next.setContent(function(){
|
||||||
"step 0"
|
"step 0"
|
||||||
|
_status.roundStart=game.me;
|
||||||
player.phase();
|
player.phase();
|
||||||
event.num=0;
|
event.num=0;
|
||||||
"step 1"
|
"step 1"
|
||||||
|
|
Loading…
Reference in New Issue