Files
youle_cocos/projects/erqiwang/js/02_erqiwang/07_eqw_GameUI.js
T
joywayerandClaude Opus 4.8 7ab748919a chore: 纳入项目全部源码进根仓库统一管理
删除 YouleNexus 内嵌 .git,统一由根仓库唯一管理。提交:
- projects/ 旧 H5 模板 Game_Surface_3 与各子游戏源码
- cocoscreator_projects/YouleNexus 工程 + cocos-creator-mcp 扩展源码
- CLAUDE.md、.mcp.json 等配置
library/temp/node_modules/dist 等缓存由 .gitignore 排除。

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-28 11:55:13 +08:00

4007 lines
139 KiB
JavaScript

var eqw_GameUI=eqw_GameUI||{};
eqw_GameUI.Data={};
eqw_GameUI.Data.CountDown=200;
eqw_GameUI.Data.SumCountDown=0;
eqw_GameUI.Data.CurLocation=0;//倒计时方位
eqw_GameUI.Data.Bankerspid=-1;//庄家头像框精灵号
eqw_GameUI.Data.Main=-1;
eqw_GameUI.Data.Grade1=[];
eqw_GameUI.Data.Grade2=[];
eqw_GameUI.Data.Grade3=[];
eqw_GameUI.Data.canBury=0;//可出牌
eqw_GameUI.Data.canPush=0;//可埋牌
eqw_GameUI.Data.SearchPage=0;//查牌页数
eqw_GameUI.Data.SingleBalancePack=null;//小局结算包
eqw_GameUI.Data.BalancePack=null;//大局结算包
eqw_GameUI.Data.BottomPack=null;//扣底包
eqw_GameUI.Data.GetGrade=0;//本轮捡分
eqw_GameUI.Data.WinPlayer=[];//大局结算大赢家座位号
eqw_GameUI.Data.Video_Step=-1;//回放状态
eqw_GameUI.Data.Video_CallStep=0;//叫分总步数
eqw_GameUI.Data.Video_PushList=[];//出牌列表
eqw_GameUI.Data.Video_Index=0;//回放的局数下标
eqw_GameUI.Data.Video_PlayState=true;
eqw_GameUI.Data.Video_PushRound=0;//出牌总轮数
eqw_GameUI.Data.Video_MaxSeatbTemp=false;
eqw_GameUI.Data.Video_MaxSeat=-1;
eqw_GameUI.Data.Video_MaxSeatLen=0;
eqw_GameUI.Data.Video_Bottom=[];
eqw_GameUI.Data.Video_Burry=[];
eqw_GameUI.Data.Video_TimerID=-1;
eqw_GameUI.jiesuanInit =function(){
eqw_GameUI.Data.Bankerspid=-1;
eqw_GameUI.HideBanker();
eqw_GameUI.Hidebaozhu();
eqw_GameUI.Data.Grade1=[];
eqw_GameUI.Data.Grade2=[];
eqw_GameUI.Data.Grade3=[];
eqw_GameUI.Data.canBury=0;//可出牌
eqw_GameUI.Data.canPush=0;//可埋牌
eqw_GameUI.Data.SearchPage=0;//查牌页数
eqw_GameUI.ShowRound(eqw_Desk.idx,eqw_Desk.count);
eqw_GameUI.Data.Main=-1;
eqw_Desk.Multi = -1;
eqw_GameUI.HideChoseMainBoard();
eqw_GameUI.HideMaiPai();
eqw_GameUI.closeSurrenderBtn();
eqw_GameUI.HideAllCards();
set_self(701,37,0,0,0);
set_self(801,37,0,0,0);
set_self(798,7,0,0,0);
set_self(798,20,22,0,0);
set_self(799,7,0,0,0);
set_self(799,20,22,0,0);
}
//eqw_GameUI.Data.
eqw_GameUI.Init=function(){//发牌时候界面初始化
eqw_GameUI.Data.CurLocation=0;
eqw_GameUI.Data.Bankerspid=-1;
eqw_GameUI.Data.Main=-1;
eqw_GameUI.Data.Grade1=[];
eqw_GameUI.Data.Grade2=[];
eqw_GameUI.Data.Grade3=[];
eqw_GameUI.Data.canBury=0;//可出牌
eqw_GameUI.Data.canPush=0;//可埋牌
eqw_GameUI.Data.SearchPage=0;//查牌页数
eqw_GameUI.Data.SingleBalancePack=null;//小局结算包
eqw_GameUI.Data.BalancePack=null;//大局结算包
eqw_GameUI.Data.BottomPack=null;//扣底包
eqw_GameUI.Data.GetGrade=0;//本轮捡分
eqw_GameUI.Data.WinPlayer=[];//大局结算大赢家座位号
set_self(798,7,0,0,0);
set_self(798,20,22,0,0);
set_self(799,7,0,0,0);
set_self(799,20,22,0,0);
}
eqw_GameUI.VideoInit=function(){
eqw_GameUI.Data.Video_Step=-1;//回放状态
eqw_GameUI.Data.Video_CallStep=0;//叫分总步数
eqw_GameUI.Data.Video_PushList=[];//出牌列表
eqw_GameUI.Data.Video_Index=0;//回放的局数下标
eqw_GameUI.Data.Video_PlayState=true;
eqw_GameUI.Data.Video_PushRound=0;//出牌总轮数
eqw_GameUI.Data.Video_MaxSeatbTemp=false;
eqw_GameUI.Data.Video_MaxSeat=-1;
eqw_GameUI.Data.Video_MaxSeatLen=0;
eqw_GameUI.Data.Video_Bottom=[];
eqw_GameUI.Data.Video_Burry=[];
eqw_GameUI.Data.Video_TimerID=-1;
eqw_Desk.Init();
eqw_GameUI.Init();
}
eqw_GameUI.utlani_doend=function(id,sx,count,allend)
{
//logmessage(id+"/"+sx+"/"+count+"/"+allend);
};
eqw_GameUI.utlgamebegindraw = function(gameid, spid, times, timelong)
{
//if(spid==769){
//if(eqw_GameUI.Data.CountDown<=15){
//set_clip(769,1,0,0,92,92,0,(15-eqw_GameUI.Data.CountDown)*24,0);
//}
//}
};
eqw_GameUI.onloadurl=function(recid,rectype,url,error,count,len){
}
eqw_GameUI.utlgamebegindraw=function(gameid, spid, times, timelong){
//if(spid==769){
//if(eqw_GameUI.Data.CountDown<=15){
//set_clip(769,1,0,0,92,92,0,(15-eqw_GameUI.Data.CountDown)*24,0);
//}
//}
}
eqw_GameUI.utlmousedown=function(gameid, spid, downx, downy, no1, no2, no3, no4, no5, no6){
for(var i=0;i<eqw_Const.ClickBtn.length;i++){
if(spid == eqw_Const.ClickBtn[i]){
set_self(eqw_Const.ClickBtn[i],35,200,0,0);
set_self(eqw_Const.ClickBtn[i],33,105,0,0);
}
}
for(var i=0;i<eqw_Const.ButtonSounds.buttonList.length;i++){
if(spid == eqw_Const.ButtonSounds.buttonList[i]){
Utl.stopSound(eqw_Const.ButtonSounds.src);
}
}
if(spid>=705&&spid<=740){
eqw_Data.isSlide = false;
}
}
eqw_GameUI.utlmousedown_nomove=function(gameid, spid, downx, downy, timelong, no1, no2, no3, no4, no5){
}
eqw_GameUI.utlmouseup=function(gameid, spid_down, downx, downy, spid_up, upx, upy, timelong, no1, no2){
for(var i=0;i<eqw_Const.ClickBtn.length;i++){
if(spid_down == eqw_Const.ClickBtn[i]){
set_self(eqw_Const.ClickBtn[i],35,255,0,0);
set_self(eqw_Const.ClickBtn[i],33,100,0,0);
}
}
if(spid_down==1081||spid_down==1082||spid_down==1083){
var y=get_self(1081,19,0,0,0);
if(eqw_Data.Balance_bg_1.length<=5){
var d=y-eqw_Const.Balance.up_y;
var t=Math.abs(d);;
play_ani(1,1081,19,get_self(1081,19,0,0,0),eqw_Const.Balance.up_y,0,t,0,0,0,1,0,0);
play_ani(1,1082,19,get_self(1082,19,0,0,0),eqw_Const.Balance.up_y,0,t,0,0,0,1,0,0);
play_ani(1,1083,19,get_self(1083,19,0,0,0),eqw_Const.Balance.up_y,0,t,0,0,0,1,0,0);
}else{
if(y>eqw_Const.Balance.up_y){
var d=eqw_Const.Balance.up_y-y;
var t=Math.abs(d);;
play_ani(1,1081,19,get_self(1081,19,0,0,0),eqw_Const.Balance.up_y,0,t,0,0,0,1,0,0);
play_ani(1,1082,19,get_self(1082,19,0,0,0),eqw_Const.Balance.up_y,0,t,0,0,0,1,0,0);
play_ani(1,1083,19,get_self(1083,19,0,0,0),eqw_Const.Balance.up_y,0,t,0,0,0,1,0,0);
}else if(y+get_self(1081,21,0,0,0)<eqw_Const.Balance.up_y+eqw_Const.Balance.Height){
var d=eqw_Const.Balance.up_y+eqw_Const.Balance.Height-get_self(1081,21,0,0,0)-y;
var t=Math.abs(d);;
play_ani(1,1081,19,get_self(1081,19,0,0,0),eqw_Const.Balance.up_y+eqw_Const.Balance.Height-get_self(1081,21,0,0,0),0,t,0,0,0,1,0,0);
play_ani(1,1082,19,get_self(1082,19,0,0,0),eqw_Const.Balance.up_y+eqw_Const.Balance.Height-get_self(1081,21,0,0,0),0,t,0,0,0,1,0,0);
play_ani(1,1083,19,get_self(1083,19,0,0,0),eqw_Const.Balance.up_y+eqw_Const.Balance.Height-get_self(1081,21,0,0,0),0,t,0,0,0,1,0,0);
}
}
}
if(spid_up==spid_down){
switch(spid_up){
//case 376://玩家一
//for(var i=0;i<Desk.PlayerList.length;i++){
//var ind=Logic.ChangeToStatus(C_Player.seat,i);
//if(ind==0){
//GameUI.OpenInfo(ind,Desk.PlayerList[i].nickname,Desk.PlayerList[i].playerid,Desk.PlayerList[i].ip,Desk.PlayerList[i].sex,Desk.PlayerList[i].seat);
//}
//}
//break;
//case 377://玩家二
//for(var i=0;i<Desk.PlayerList.length;i++){
//var ind=Logic.ChangeToStatus(C_Player.seat,i);
//if(ind==1){
//GameUI.OpenInfo(ind,Desk.PlayerList[i].nickname,Desk.PlayerList[i].playerid,Desk.PlayerList[i].ip,Desk.PlayerList[i].sex,Desk.PlayerList[i].seat);
//}
//}
//break;
//case 378://玩家三
//for(var i=0;i<Desk.PlayerList.length;i++){
//var ind=Logic.ChangeToStatus(C_Player.seat,i);
//if(ind==2){
//GameUI.OpenInfo(ind,Desk.PlayerList[i].nickname,Desk.PlayerList[i].playerid,Desk.PlayerList[i].ip,Desk.PlayerList[i].sex,Desk.PlayerList[i].seat);
//}
//}
//break;
case 744:
if(Utl.getMySeat()==eqw_Desk.Call_Run.callpos){
var data={};
data.agentid=Utl.getAgentID();
data.gameid=Utl.getGameID();
data.roomcode=Utl.getRoomcode();
data.playerid=Utl.getMyPlayerid();
data.seat=Utl.getMySeat();
data.call=0;
eqw_Net.Send_jiaofen(data);
}
//eqw_GameUI.SwitchCall();
break;
case 800://埋牌
var data={};
data.agentid=Utl.getAgentID();
data.gameid=Utl.getGameID();
data.roomcode=Utl.getRoomcode();
data.playerid=Utl.getMyPlayerid();
data.seat=Utl.getMySeat();
data.cards=eqw_Player.GetSelectCards();
eqw_Net.Send_maipai(data);
break;
case 801://出牌
if(eqw_Desk.PushInd===1){
//var re=cls_youle_erqiwang_arith.can_playcard(eqw_Desk.MainCard,eqw_Player.GetSelectCards(),Utl.GetMySeat(),eqw_Desk.GetPlayerBySeat(Utl.GetMySeat()).info);
var re=cls_youle_erqiwang_arith.can_playcard(eqw_Desk.MainCard,eqw_Player.GetSelectCards(),Utl.getMySeat(),eqw_Desk.getSeatList());
if(re.result==true){
var data={};
data.agentid=Utl.getAgentID();
data.gameid=Utl.getGameID();
data.roomcode=Utl.getRoomcode();
data.playerid=Utl.getMyPlayerid();
data.seat=Utl.getMySeat();
data.cards=eqw_Player.GetSelectCards();
eqw_Net.Send_chupai(data);
}else{
GameUI.OpenTips("牌型不符",ConstVal.Tips.time);
}
}else{
var re=cls_youle_erqiwang_arith.can_followcard(eqw_Desk.MainCard, eqw_Player.GetCardsList(), eqw_Player.GetSelectCards(), eqw_Desk.push_count, eqw_Desk.push_flower, eqw_Desk.push_cardtype);
if(re.result==true){
var data={};
data.agentid=Utl.getAgentID();
data.gameid=Utl.getGameID();
data.roomcode=Utl.getRoomcode();
data.playerid=Utl.getMyPlayerid();
data.seat=Utl.getMySeat();
data.cards=eqw_Player.GetSelectCards();
eqw_Net.Send_chupai(data);
}else{
GameUI.OpenTips("牌型不符",ConstVal.Tips.time);
}
}
break;
case 860:
eqw_GameUI.ShowBottomOrGrade();
break;
case 701:
eqw_GameUI.ShowSearch();
break;
case 918:
eqw_GameUI.UpSearch();
break;
case 919:
eqw_GameUI.DownSearch();
break;
case 861:
eqw_GameUI.HideSearch();
break;
case 856:
eqw_GameUI.HideBottomOrGrade();
break;
case 922://小局结算关闭按钮
case 920:
if(eqw_GameUI.Data.BalancePack!=null){//有大局结算数据
eqw_GameUI.CloseSingleBalance();
eqw_GameUI.OpenBalance();
}else{
var data={};
data.agentid=Utl.getAgentID();
data.gameid=Utl.getGameID();
data.roomcode=Utl.getRoomcode();
data.playerid=Utl.getMyPlayerid();
data.seat=Utl.getMySeat();
eqw_Net.Send_zhunbei(data);
}
break;
case 1040://大局结算返回
eqw_GameUI.CloseBalance();
eqw_GameUI.Init();
eqw_Desk.Init();
eqw_Player.Init();
Utl.Exit();
break;
case 1177://回放播放暂停
eqw_GameUI.Video_ClickPlay();
break;
case 1178://回放返回
eqw_GameUI.CloseVideo();
break;
case 1043:
//Func.ShotShare(1);
Func.sharefinend(1,2,"","","",[1047,1048,1049]);
break;
case 1220:
eqw_GameUI.openSurrender();
break;
case 1222:
case 1225:
eqw_GameUI.closeSurrender();
break;
case 1224:
eqw_GameUI.closeSurrender();
var data={};
data.agentid=Utl.getAgentID();
data.gameid=Utl.getGameID();
data.roomcode=Utl.getRoomcode();
data.playerid=Utl.getMyPlayerid();
data.seat=Utl.getMySeat();
eqw_Net.Send_touxiang(data);
break;
}
if(spid_up>=746&&spid_up<=765){
//eqw_GameUI.SwitchCall();
if(Utl.getMySeat()==eqw_Desk.Call_Run.callpos){
var data={};
data.agentid=Utl.getAgentID();
data.gameid=Utl.getGameID();
data.roomcode=Utl.getRoomcode();
data.playerid=Utl.getMyPlayerid();
data.seat=Utl.getMySeat();
data.call=(766-spid_up)*5;
eqw_Net.Send_jiaofen(data);
}
}
if(spid_up>=790&&spid_up<=793){
//eqw_GameUI.ChoseMainEffct(spid_up-790);
var data={};
data.agentid=Utl.getAgentID();
data.gameid=Utl.getGameID();
data.roomcode=Utl.getRoomcode();
data.playerid=Utl.getMyPlayerid();
data.seat=Utl.getMySeat();
data.flower=spid_up-789;
eqw_Net.Send_xuanzhu(data);
}
if(spid_up>=705&&spid_up<=740){
if(!eqw_Data.isSlide){
eqw_GameUI.ClickCard(spid_up);
}
}
}
}
eqw_GameUI.utlmousemove=function(gameid, spid, downx, downy, movex,movey ,timelong,offmovex, offmovey, no1){
switch(spid){
case 1081:
case 1082:
case 1083:
set_self(1081,19,offmovey,1,0);
set_self(1082,19,offmovey,1,0);
set_self(1083,19,offmovey,1,0);
break;
}
if(spid>=705&&spid<=740){
eqw_Data.isSlide = true;
for(var i=0;i<eqw_Data.CardsList.length;i++){
//console.log("i");
if(gameabc_check_click(movex,movey) == eqw_Data.CardsList[i]){
//console.log("选中"+spidList[i]);
if(eqw_Data.CardSpid != eqw_Data.CardsList[i]){
eqw_Data.CardSpid = eqw_Data.CardsList[i];
if(!eqw_Data.CardIndex){
eqw_Data.CardIndex = true;
eqw_GameUI.ClickCard(eqw_Data.CardsList[i]);
}
//console.log("更换"+spidList[i]);
}else{
}
}else{
eqw_Data.CardIndex = false;
}
}
}
}
eqw_GameUI.utlgamemydraw=function(gameid, spid, times, timelong, no2, no3, no4, no5, no6, no7){
switch(spid){
case 782:
switch(eqw_Desk.Multi){
case 1:
ifast_mydrawbmp(spid,1018,10,20,80,35,0,0,80,35);
break;
case 2:
ifast_mydrawbmp(spid,1018,83,20,80,35,0,35,80,35);
break;
case 4:
ifast_mydrawbmp(spid,1018,154,20,80,35,0,70,80,35);
break;
}
break;
case 288:
if(eqw_GameUI.Data.Bankerspid==spid){
ifast_mydrawbmp(spid,1021,63,-5,73,49,0,0,73,49);
}
break;
case 289:
if(eqw_GameUI.Data.Bankerspid==spid){
ifast_mydrawbmp(spid,1021,63,-5,73,49,0,0,73,49);
}
break;
case 290:
if(eqw_GameUI.Data.Bankerspid==spid){
ifast_mydrawbmp(spid,1021,63,-5,73,49,0,0,73,49);
}
break;
case 1217://右上角横幅
//ifast_mydrawbmp(spid,201,40,2,38,38,0,0,118,105);
if(eqw_GameUI.Data.Main>0){
ifast_mydrawbmp(spid,1024,40,2,38,38,(eqw_GameUI.Data.Main-1)*114,0,114,103);
}
break;
case 705:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 706:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 707:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 708:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 709:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 710:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 711:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 712:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 713:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 714:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 715:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 716:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 717:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 718:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 719:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 720:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 721:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 722:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 723:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 724:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 725:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 726:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 727:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 728:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 729:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 730:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 731:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 732:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 733:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 734:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 735:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 736:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 737:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 738:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 739:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
case 740:
if(typeof(eqw_Player.HandCards[spid-705])!="undefined"){
if(eqw_Player.HandCards[spid-705].diff==1){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
if(eqw_Player.HandCards[spid-705].click==0&&eqw_Player.HandCards[spid-705].mustpush==0){
ifast_mydrawbmp(spid,11,0,0,eqw_Const.Card.oriwidth,eqw_Const.Card.oriheight,0,0,4,4);
}
}
break;
//case 800:
//if(eqw_GameUI.Data.canBury==0){
//ifast_mydrawbmp(spid,11,0,0,197,82,0,0,4,4);
//}
//break;
//case 801:
//if(eqw_GameUI.Data.canPush==0){
//ifast_mydrawbmp(spid,11,0,0,197,82,0,0,4,4);
//}
//break;
}
}
eqw_GameUI.utlgamemydrawbegin=function(gameid, spid, times, timelong, no2, no3, no4, no5, no6, no7){
if(spid==1081||spid==1082||spid==1083){
set_clip(0,0,0,eqw_Const.Balance.up_y,1280,eqw_Const.Balance.Height);
}
}
eqw_GameUI.utlontimer=function(gameid, spid, /* 本次间隔多少次了 */ times, /* 本次间隔多久 */ timelong,/* 开启后运行多少次了 */ alltimes){
switch(spid){
case 50:
eqw_GameUI.CountDown();
break;
}
}
//显示等待动画
eqw_GameUI.ShowWaitting=function(){
set_self(704,37,1,0,0);
play_ani(1,704,43,1,2,0,500,0,0,0,0,0,0);
}
//关闭等待动画
eqw_GameUI.HideWaitting=function(){
set_self(704,37,0,0,0);
play_ani(0,704,43,1,2,0,500,0,0,0,0,0,0);
}
//开始倒计时动画
eqw_GameUI.OpenCountDown=function(seat){
//eqw_GameUI.Data.CountDown=25;
var ind =eqw_Logic.ChangeToStatus(seat);
eqw_GameUI.Data.CurLocation=ind;
if(eqw_GameUI.Data.CountDown<=eqw_Const.CountDown.warning){
set_self(771,1,1033,0,0);
}else{
set_self(771,1,1014,0,0);
}
set_self(769,18,eqw_Const.CountDown.Location[ind][0],0,0);
set_self(769,19,eqw_Const.CountDown.Location[ind][1],0,0);
set_self(770,18,eqw_Const.CountDown.Location[ind][0],0,0);
set_self(770,19,eqw_Const.CountDown.Location[ind][1],0,0);
set_self(771,7,eqw_GameUI.Data.CountDown,0,0);
set_self(771,20,String(eqw_GameUI.Data.CountDown).length*eqw_Const.CountDown.Width,0,0);
set_self(771,18,eqw_Const.CountDown.Location[ind][0]+(get_self(769,20,0,0,0)-get_self(771,20,0,0,0))/2,0,0);
set_self(771,19,eqw_Const.CountDown.Location[ind][1]+(get_self(769,21,0,0,0)-get_self(771,21,0,0,0))/2,0,0);
set_self(769,37,1,0,0);
set_self(770,37,1,0,0);
set_self(771,37,1,0,0);
set_self(50,57,1000,0,0);
//setInterval(eqw_GameUI.CountDown,1000);
}
eqw_GameUI.CountDown=function(){
eqw_GameUI.Data.CountDown--;
play_ani(1,771,33,100,1,0,500,0,0,0,1,0,0);
play_ani(1,771,33,80,100,500,500,0,0,0,1,0,0);
if(eqw_GameUI.Data.CountDown>=0){
if(eqw_GameUI.Data.CountDown==eqw_Const.CountDown.warning){
set_self(771,1,1033,0,0);
}
if(eqw_GameUI.Data.CountDown<eqw_Const.CountDown.warning){
eqw_Logic.play_timeup();
}
set_self(771,7,eqw_GameUI.Data.CountDown,0,0);
set_self(771,20,String(eqw_GameUI.Data.CountDown).length*eqw_Const.CountDown.Width,0,0);
set_self(771,18,eqw_Const.CountDown.Location[eqw_GameUI.Data.CurLocation][0]+(get_self(769,20,0,0,0)-get_self(771,20,0,0,0))/2,0,0);
set_self(771,19,eqw_Const.CountDown.Location[eqw_GameUI.Data.CurLocation][1]+(get_self(769,21,0,0,0)-get_self(771,21,0,0,0))/2,0,0);
}else if(eqw_GameUI.Data.CountDown<0){
eqw_GameUI.CloseCountDown();
}
}
//结束倒计时动画调用
eqw_GameUI.CloseCountDown=function(){
set_self(50,57,0,0,0);
//set_self(769,37,0,0,0);
//set_self(770,37,0,0,0);
//set_self(771,37,0,0,0);
//clearInterval(eqw_Data.Timer);
play_ani(0,771,33,80,100,0,500,0,0,0,1,0,0);
}
eqw_GameUI.HideCountDown=function(){
set_self(50,57,0,0,0);
play_ani(0,771,33,80,100,0,500,0,0,0,1,0,0);
set_self(769,37,0,0,0);
set_self(770,37,0,0,0);
set_self(771,37,0,0,0);
}
//发牌动画开始
eqw_GameUI.StartDealCardsEffct=function(){
var mid=640-get_self(781,20,0,0,0)/2;
var p=get_self(781,20,0,0,0);
set_self(781,18,mid,0,0);
set_self(781,34,0,0,0);
set_self(781,33,0,0,0);
set_self(781,37,1,0,0);
play_ani(1,781,33,0,100,0,500,0,0,0,1,0,0);
play_ani(1,781,34,0,360,0,500,0,1000,0,1,0,0);
//play_ani(1,781,33,100,0,1000,500,0,0,0,1,0,0);
setTimeout(function(){play_ani(1,781,33,100,0,0,500,0,0,0,1,0,0);},1000);
setTimeout(
function(){
for(var i=0;i<8;i++){
set_self(773+i,18,eqw_Const.Bottom.Location[0]-get_self(773+i,20,0,0,0)/2,0,0);
set_self(773+i,19,eqw_Const.Bottom.Location[1],0,0);
set_self(773+i,33,20,0,0);
set_self(773+i,37,1,0,0);
play_ani(1,773+i,33,20,eqw_Const.Card.deskscale,0,500,0,0,0,1,0,0);
}
setTimeout(
function(){
set_self(781,37,0,0,0);
play_ani(1,780,18,get_self(780,18,0,0,0),eqw_Const.Card.dealcard[0][0],0,500,0,0,0,1,0,0);
play_ani(1,780,19,get_self(780,19,0,0,0),eqw_Const.Card.dealcard[0][1],0,500,0,0,0,1,0,0);
setTimeout("eqw_GameUI.EndDealCardsEffct()",1500);
play_ani(1,779,18,get_self(779,18,0,0,0),eqw_Const.Card.dealcard[1][0],0,500,0,500,0,1,0,0);
play_ani(1,779,19,get_self(779,19,0,0,0),eqw_Const.Card.dealcard[1][1],0,500,0,500,0,1,0,0);
play_ani(1,779,35,255,130,0,500,0,500,0,1,0,0);
setTimeout("set_self(779,37,0,0,0)",1000);
play_ani(1,778,18,get_self(778,18,0,0,0),eqw_Const.Card.dealcard[2][0],0,500,0,1000,0,1,0,0);
play_ani(1,778,19,get_self(778,19,0,0,0),eqw_Const.Card.dealcard[2][1],0,500,0,1000,0,1,0,0);
play_ani(1,778,35,255,130,0,500,0,1000,0,1,0,0);
setTimeout("set_self(778,37,0,0,0)",1500);
},500);
},1500);
}
//停止发牌
eqw_GameUI.EndDealCards=function(){
//var mid=640-get_self(781,20,0,0,0)/2;
//var p=get_self(781,20,0,0,0);
//set_self(781,18,mid,0,0);
//set_self(781,34,0,0,0);
//set_self(781,33,0,0,0);
//set_self(781,37,1,0,0);
play_ani(0,781,33,0,100,0,500,0,0,0,1,0,0);
play_ani(0,781,34,0,360,0,500,0,1000,0,1,0,0);
//play_ani(1,781,33,100,0,1000,500,0,0,0,1,0,0);
//setTimeout(function(){
play_ani(0,781,33,100,0,0,500,0,0,0,1,0,0);
//},1000);
//setTimeout(
//function(){
for(var i=0;i<8;i++){
//set_self(773+i,18,eqw_Const.Bottom.Location[0]-get_self(773+i,20,0,0,0)/2,0,0);
//set_self(773+i,19,eqw_Const.Bottom.Location[1],0,0);
//set_self(773+i,33,20,0,0);
//set_self(773+i,37,1,0,0);
play_ani(0,773+i,33,20,eqw_Const.Card.deskscale,0,500,0,0,0,1,0,0);
set_self(773+i,33,20,eqw_Const.Card.deskscale,0);
set_self(773+i,37,0,0,0);
}
//setTimeout(
//function(){
set_self(781,37,0,0,0);
play_ani(0,780,18,get_self(780,18,0,0,0),eqw_Const.Card.dealcard[0][0],0,500,0,0,0,1,0,0);
play_ani(0,780,19,get_self(780,19,0,0,0),eqw_Const.Card.dealcard[0][1],0,500,0,0,0,1,0,0);
set_self(781,18,eqw_Const.Card.dealcard[0][0],0,0);
set_self(781,19,eqw_Const.Card.dealcard[0][1],0,0);
//setTimeout("eqw_GameUI.EndDealCardsEffct()",1500);
play_ani(0,779,18,get_self(779,18,0,0,0),eqw_Const.Card.dealcard[1][0],0,500,0,500,0,1,0,0);
play_ani(0,779,19,get_self(779,19,0,0,0),eqw_Const.Card.dealcard[1][1],0,500,0,500,0,1,0,0);
play_ani(0,779,35,255,130,0,500,0,500,0,1,0,0);
set_self(779,37,0,0,0);
set_self(779,18,eqw_Const.Card.dealcard[1][0],0,0);
set_self(779,19,eqw_Const.Card.dealcard[1][1],0,0);
set_self(779,35,130,0,0);
play_ani(0,778,18,get_self(778,18,0,0,0),eqw_Const.Card.dealcard[2][0],0,500,0,1000,0,1,0,0);
play_ani(0,778,19,get_self(778,19,0,0,0),eqw_Const.Card.dealcard[2][1],0,500,0,1000,0,1,0,0);
play_ani(0,778,35,255,130,0,500,0,1000,0,1,0,0);
set_self(778,35,130,0,0);
set_self(778,37,0,0,0);
set_self(778,18,eqw_Const.Card.dealcard[2][0],0,0);
set_self(778,19,eqw_Const.Card.dealcard[2][1],0,0);
//},500);
//},1500);
set_self(780,37,0,0,0);
set_group(204,37,0,0,0);
var len=eqw_Player.HandCards.length;
for(var i=0;i<len;i++){
set_self(705+i,43,(eqw_Player.HandCards[i].id)%54+1,0,0);
set_self(705+i,37,1,0,0);
set_self(705+i,18,eqw_Const.Card.dealcard[0][0],0,0);
set_self(705+i,19,eqw_Const.Card.dealcard[0][1],0,0);
set_self(705+i,33,eqw_Const.Card.deskscale,0,0);
}
for(var i=0;i<len-21;i++){
play_ani(0,705+len-22-i,18,eqw_Const.Card.dealcard[0][0],eqw_Const.Card.x2-eqw_Const.Card.Dis1*i,0,500,0,(21+i)*100,0,1,0,0);
play_ani(0,705+len-22-i,19,eqw_Const.Card.dealcard[0][1],eqw_Const.Card.y1,0,500,0,(21+i)*100,0,1,0,0);
play_ani(0,705+len-22-i,33,eqw_Const.Card.deskscale,eqw_Const.Card.scale,0,500,0,(21+i)*100,0,1,0,0);
set_self(705+len-22-i,18,eqw_Const.Card.x2-eqw_Const.Card.Dis1*i,0,0);
set_self(705+len-22-i,19,eqw_Const.Card.y1,0,0);
set_self(705+len-22-i,33,eqw_Const.Card.scale,0,0);
}
var w = 20*eqw_Const.Card.Dis1+eqw_Const.Card.w1;
var x = 640-w/2;
for(var i=0;i<21;i++){
play_ani(0,705+len-21+i,18,eqw_Const.Card.dealcard[0][0],x+eqw_Const.Card.Dis1*i,0,500,0,(21-i)*100,0,1,0,0);
play_ani(0,705+len-21+i,19,eqw_Const.Card.dealcard[0][1],eqw_Const.Card.y2,0,500,0,(21-i)*100,0,1,0,0);
play_ani(0,705+len-21+i,33,eqw_Const.Card.deskscale,eqw_Const.Card.scale,0,500,0,(21-i)*100,0,1,0,0);
set_self(705+len-21+i,18,x+eqw_Const.Card.Dis1*i,0,0);
set_self(705+len-21+i,19,eqw_Const.Card.y2,0,0);
set_self(705+len-21+i,33,eqw_Const.Card.scale,0,0);
}
eqw_GameUI.OpenScore();
}
//发牌动画结束调用
eqw_GameUI.EndDealCardsEffct=function(){
set_self(780,37,0,0,0);
eqw_Logic.play_dealcards();
//eqw_Player.SetHandCards([17,11,65,64,62,61,59,58,11,65,64,62,61,59,58,11,65,64,62,61,59,58,11,65,64,62,61,59,58]);
//eqw_GameUI.SetMyCards();
set_group(204,37,0,0,0);
var len=eqw_Player.HandCards.length;
for(var i=0;i<len;i++){
set_self(705+i,43,(eqw_Player.HandCards[i].id)%54+1,0,0);
set_self(705+i,37,1,0,0);
set_self(705+i,18,eqw_Const.Card.dealcard[0][0],0,0);
set_self(705+i,19,eqw_Const.Card.dealcard[0][1],0,0);
set_self(705+i,33,eqw_Const.Card.deskscale,0,0);
}
for(var i=0;i<len-21;i++){
play_ani(1,705+len-22-i,18,eqw_Const.Card.dealcard[0][0],eqw_Const.Card.x2-eqw_Const.Card.Dis1*i,0,500,0,(21+i)*100,0,1,0,0);
play_ani(1,705+len-22-i,19,eqw_Const.Card.dealcard[0][1],eqw_Const.Card.y1,0,500,0,(21+i)*100,0,1,0,0);
play_ani(1,705+len-22-i,33,eqw_Const.Card.deskscale,eqw_Const.Card.scale,0,500,0,(21+i)*100,0,1,0,0);
}
var w = 20*eqw_Const.Card.Dis1+eqw_Const.Card.w1;
var x = 640-w/2;
for(var i=0;i<21;i++){
play_ani(1,705+len-21+i,18,eqw_Const.Card.dealcard[0][0],x+eqw_Const.Card.Dis1*i,0,500,0,(21-i)*100,0,1,0,0);
play_ani(1,705+len-21+i,19,eqw_Const.Card.dealcard[0][1],eqw_Const.Card.y2,0,500,0,(21-i)*100,0,1,0,0);
play_ani(1,705+len-21+i,33,eqw_Const.Card.deskscale,eqw_Const.Card.scale,0,500,0,(21-i)*100,0,1,0,0);
}
setTimeout("eqw_GameUI.OpenScore()",3400);
}
//发牌
eqw_GameUI.DealCards=function(_data){
//
eqw_GameUI.StartDealCardsEffct();
for(var i=0;i<8;i++){
set_self(773+i,43,55,0,0);
}
}
//设置玩家自己手牌
eqw_GameUI.SetMyCards=function(){
set_group(204,37,0,0,0);
var len=eqw_Player.HandCards.length;
if(len>21){
for(var i=0;i<len-21;i++){
set_self(705+len-22-i,19,eqw_Const.Card.y1,0,0);
set_self(705+len-22-i,18,eqw_Const.Card.x2-eqw_Const.Card.Dis1*i,0,0);
set_self(705+len-22-i,33,eqw_Const.Card.scale,0,0);
}
var w = 20*eqw_Const.Card.Dis1+eqw_Const.Card.w1;
var x = 640-w/2;
for(var i=0;i<21;i++){
set_self(705+len-21+i,19,eqw_Const.Card.y2,0,0);
set_self(705+len-21+i,18,x+eqw_Const.Card.Dis1*i,0,0);
set_self(705+len-21+i,33,eqw_Const.Card.scale,0,0);
}
}else{
if(len>eqw_Const.Card.Limit){
var w = (len-1)*eqw_Const.Card.Dis1+eqw_Const.Card.w1;
var x = 640-w/2;
for(var i=0;i<len;i++){
set_self(705+i,18,x+eqw_Const.Card.Dis1*i,0,0);
set_self(705+i,19,eqw_Const.Card.y3,0,0);
set_self(705+i,33,eqw_Const.Card.scale,0,0);
}
}else{
var w = (len-1)*eqw_Const.Card.Dis2+eqw_Const.Card.w2;
var x = 640-w/2;
for(var i=0;i<len;i++){
set_self(705+i,18,x+eqw_Const.Card.Dis2*i,0,0);
set_self(705+i,19,eqw_Const.Card.y3,0,0);
set_self(705+i,33,100,0,0);
}
}
}
for(var i=0;i<len;i++){
set_self(705+i,43,(eqw_Player.HandCards[i].id)%54+1,0,0);
if(eqw_Player.HandCards[i].isSelect==1){
set_self(705+i,19,-eqw_Const.Card.out_y,1,0);
}
set_self(705+i,37,1,0,0);
}
}
//打开叫分面板
eqw_GameUI.OpenScore=function(bTemp){
//eqw_Desk.Call_Run.callpos=0;
//eqw_Desk.Call_Run.score=100;
//C_Player.seat=0;
var ind=eqw_Logic.ChangeToStatus(eqw_Desk.Call_Run.callpos);
set_self(743,18,640-get_self(743,20,0,0,0)/2,0,0);
set_self(772,18,640-get_self(772,20,0,0,0)/2,0,0);
set_self(766,20,eqw_Const.Call.x,0,0);
set_self(745,18,get_self(766,20,0,0,0)-get_self(745,20,0,0,0)/2,0,0);
set_self(786,18,get_self(766,20,0,0,0)-get_self(786,20,0,0,0)/2,0,0);
set_self(767,18,get_self(766,20,0,0,0)-get_self(767,20,0,0,0)/2,0,0);
switch(ind){
case 0:
set_self(743,1,1008,0,0);
set_self(772,43,1,0,0);
if(eqw_Desk.Call_Run.score){
set_self(744,43,2,0,0);
}else{
set_self(744,43,1,0,0);
}
break;
case 1:
set_self(743,1,1006,0,0);
set_self(772,43,2,0,0);
set_self(744,43,1,0,0);
break;
case 2:
set_self(743,1,1006,0,0);
set_self(772,43,2,0,0);
set_self(744,43,1,0,0);
break;
}
set_group(205,37,1,0,0);
if(eqw_Desk.Call_Run.score==null || eqw_Desk.Call_Run.score==0){
set_self(745,37,0,0,0);
set_self(766,37,0,0,0);
set_self(786,37,0,0,0);
set_self(767,37,0,0,0);
set_self(768,7,100,0,0);
set_self(768,20,String(100).length*eqw_Const.Call.Width_1,0,0);
set_self(768,18,get_self(772,18,0,0,0)+(get_self(772,20,0,0,0)-get_self(768,20,0,0,0))/2,0,0);
//set_self(768,19,get_self(743,19,0,0,0)+(get_self(743,21,0,0,0)-get_self(768,21,0,0,0))/2,0,0);
}else{
var ind=(100-eqw_Desk.Call_Run.score)/5;
set_self(767,7,eqw_Desk.Call_Run.score,0,0);
set_self(767,20,String(eqw_Desk.Call_Run.score).length*eqw_Const.Call.Width_2,0,0);
set_self(766,20,eqw_Const.Call.x+ind*eqw_Const.Call.Dis+get_self(746+ind,20,0,0,0)/2,0,0);
set_self(745,18,get_self(766,20,0,0,0)-get_self(745,20,0,0,0)/2,0,0);
set_self(767,18,get_self(766,20,0,0,0)-get_self(767,20,0,0,0)/2,0,0);
set_self(786,18,get_self(766,20,0,0,0)-get_self(786,20,0,0,0)/2,0,0);
set_self(786,19,get_self(742,19,0,0,0),0,0);
set_self(786,43,eqw_Logic.power2fs(eqw_Desk.Multi)+1,0,0);
//if(eqw_Desk.Call_Run.score<=eqw_Const.Call.grade[0]&&eqw_Desk.Call_Run.score>eqw_Const.Call.grade[1]){
//set_self(786,43,1,0,0);
//}
//if(eqw_Desk.Call_Run.score<=eqw_Const.Call.grade[1]&&eqw_Desk.Call_Run.score>eqw_Const.Call.grade[2]){
//set_self(786,43,2,0,0);
//}
//if(eqw_Desk.Call_Run.score<=eqw_Const.Call.grade[2]&&eqw_Desk.Call_Run.score>eqw_Const.Call.grade[3]){
//set_self(786,43,3,0,0);
//}
//set_self(767,18,eqw_Desk.Call_Run.score,0,0);
if(ind%2==0){
set_self(745,19,eqw_Const.Call.y1,0,0);
set_self(767,19,eqw_Const.Call.y1+(get_self(745,21,0,0,0)-get_self(767,21,0,0,0))/2,0,0);
}else{
set_self(745,19,eqw_Const.Call.y2,0,0);
set_self(767,19,eqw_Const.Call.y2+(get_self(745,21,0,0,0)-get_self(767,21,0,0,0))/2,0,0);
}
set_self(768,7,eqw_Desk.Call_Run.score,0,0);
set_self(768,20,String(eqw_Desk.Call_Run.score).length*eqw_Const.Call.Width_1,0,0);
set_self(768,18,get_self(772,18,0,0,0)+(get_self(772,20,0,0,0)-get_self(768,20,0,0,0))/2,0,0);
//set_self(768,19,get_self(743,19,0,0,0)+(get_self(743,21,0,0,0)-get_self(768,21,0,0,0))/2,0,0);
}
if(!bTemp){
eqw_GameUI.OpenCountDown(eqw_Desk.Call_Run.callpos);
}
}
//转换叫分权动画
eqw_GameUI.SwitchCall=function(){
//eqw_Desk.Call_Run.callpos=1;
//eqw_Desk.Call_Run.score=30;
var ind=eqw_Logic.ChangeToStatus(eqw_Desk.Call_Run.callpos);
//set_self(743,18,640-get_self(743,20,0,0,0)/2,0,0);
//set_self(772,18,640-get_self(772,20,0,0,0)/2,0,0);
switch(ind){
case 0:
setTimeout(function(){set_self(743,1,1008,0,0);},500);
//set_self(772,43,1,0,0);
set_self(772,43,1,0,0);
set_self(744,43,2,0,0);
play_ani(1,743,34,0,180,0,500,0,0,0,1,0,0);
play_ani(1,743,34,-180,0,500,500,0,0,0,1,0,0);
break;
case 1:
//set_self(743,1,1006,0,0);
setTimeout(function(){set_self(743,1,1006,0,0);},500);
set_self(772,43,2,0,0);
set_self(744,43,1,0,0);
//set_self(772,43,2,0,0);
play_ani(1,743,34,0,180,0,500,0,0,0,1,0,0);
play_ani(1,743,33,20,100,0,1000,0,0,0,1,0,0);
play_ani(1,743,34,-180,0,500,500,0,0,0,1,0,0);
break;
case 2:
setTimeout(function(){set_self(743,1,1006,0,0);},500);
set_self(772,43,2,0,0);
set_self(744,43,1,0,0);
//set_self(772,43,1,0,0);
play_ani(1,743,34,0,180,0,500,0,0,0,1,0,0);
play_ani(1,743,34,-180,0,500,500,0,0,0,1,0,0);
break;
}
if(eqw_Desk.Call_Run.score==null || eqw_Desk.Call_Run.score==0){
set_self(745,37,0,0,0);
set_self(766,37,0,0,0);
set_self(786,37,0,0,0);
set_self(767,37,0,0,0);
set_self(768,7,100,0,0);
set_self(768,20,String(100).length*eqw_Const.Call.Width_1,0,0);
set_self(768,18,get_self(772,18,0,0,0)+(get_self(772,20,0,0,0)-get_self(768,20,0,0,0))/2,0,0);
}else{
set_self(745,37,1,0,0);
set_self(786,37,1,0,0);
set_self(766,37,1,0,0);
set_self(767,37,1,0,0);
var ind=(100-eqw_Desk.Call_Run.score)/5;
set_self(767,7,eqw_Desk.Call_Run.score,0,0);
set_self(767,20,String(eqw_Desk.Call_Run.score).length*eqw_Const.Call.Width_2,0,0);
//set_self(766,20,30+ind*eqw_Const.Call.Dis+get_self(746+ind,20,0,0,0)/2,0,0);
//set_self(745,18,get_self(766,20,0,0,0)-get_self(745,20,0,0,0)/2,0,0);
//set_self(767,18,get_self(766,20,0,0,0)-get_self(767,20,0,0,0)/2,0,0);
play_ani(1,766,20,get_self(766,20,0,0,0),eqw_Const.Call.x+ind*eqw_Const.Call.Dis+get_self(746+ind,20,0,0,0)/2,0,500,0,0,0,1,0,0);
play_ani(1,745,18,get_self(745,18,0,0,0),eqw_Const.Call.x+ind*eqw_Const.Call.Dis+get_self(746+ind,20,0,0,0)/2-get_self(745,20,0,0,0)/2,0,500,0,0,0,1,0,0);
play_ani(1,767,18,get_self(767,18,0,0,0),eqw_Const.Call.x+ind*eqw_Const.Call.Dis+get_self(746+ind,20,0,0,0)/2-get_self(767,20,0,0,0)/2,0,500,0,0,0,1,0,0);
set_self(786,19,get_self(742,19,0,0,0),0,0);
set_self(786,43,eqw_Logic.power2fs(eqw_Desk.Multi)+1,0,0);
play_ani(1,786,18,get_self(786,18,0,0,0),eqw_Const.Call.x+ind*eqw_Const.Call.Dis+get_self(746+ind,20,0,0,0)/2-get_self(786,20,0,0,0)/2,0,500,0,0,0,1,0,0);
if(ind%2==0){
set_self(745,19,eqw_Const.Call.y1,0,0);
set_self(767,19,eqw_Const.Call.y1+(get_self(745,21,0,0,0)-get_self(767,21,0,0,0))/2,0,0);
}else{
set_self(745,19,eqw_Const.Call.y2,0,0);
set_self(767,19,eqw_Const.Call.y2+(get_self(745,21,0,0,0)-get_self(767,21,0,0,0))/2,0,0);
}
set_self(768,7,eqw_Desk.Call_Run.score,0,0);
set_self(768,20,String(eqw_Desk.Call_Run.score).length*eqw_Const.Call.Width_1,0,0);
set_self(768,18,get_self(772,18,0,0,0)+(get_self(772,20,0,0,0)-get_self(768,20,0,0,0))/2,0,0);
//play_ani(1,768,33,100,80,0,250,0,0,0,1,0,0);
//play_ani(1,768,33,80,100,0,250,0,250,0,1,0,0);
}
}
eqw_GameUI.ShowMulti=function(){
set_self(782,37,1,0,0);
}
eqw_GameUI.HideMulti=function(){
set_self(782,37,0,0,0);
}
eqw_GameUI.ShowCall=function(seat,call){
var ind=eqw_Logic.ChangeToStatus(seat);
if(call>0){
set_self(783+ind,7,call,0,0);
set_self(783+ind,20,String(call).length*30,0,0);
if(ind==0){
set_self(783+ind,18,700-String(call).length*15,0,0);
}else{
set_self(783+ind,18,get_self(346+ind,18,0,0,0) + get_self(346+ind,20,0,0,0)/2 -String(call).length*15,0,0);
}
//set_self(783+ind,18,eqw_Const.Call.Location[ind][0],0,0);
//set_self(783+ind,19,eqw_Const.Call.Location[ind][1],0,0);
set_self(783+ind,37,1,0,0);
}else if(call==0){
set_self(783+ind,37,0,0,0);
set_self(857+ind,37,1,0,0);
}
}
eqw_GameUI.HideCall=function(){
for(var i=0;i<3;i++){
set_self(783+i,37,0,0,0);
set_self(857+i,37,0,0,0);
}
}
eqw_GameUI.ShowBanker = function(bker){
var ind = eqw_Logic.ChangeToStatus(bker);
eqw_GameUI.Data.Bankerspid=346+ind;
set_self(787,18,get_self(eqw_GameUI.Data.Bankerspid,18,0,0,0)-26,0,0);
set_self(787,19,get_self(eqw_GameUI.Data.Bankerspid,19,0,0,0)-17,0,0);
set_self(787,37,1,0,0);
}
eqw_GameUI.HideBanker = function(bker){
set_self(787,37,0,0,0);
}
eqw_GameUI.shangzhuang=function(){
//eqw_Desk.BankerSeat=0;
//C_Player.seat=0;
eqw_Logic.play_banker();
eqw_GameUI.HideCall();
set_group(205,37,0,0,0);
var ind=eqw_Logic.ChangeToStatus(eqw_Desk.BankerSeat);
set_self(787,18,590,0,0);
set_self(787,19,270,0,0);
set_self(787,37,1,0,0);
eqw_GameUI.ShowRound(eqw_Desk.idx,eqw_Desk.count);
//set_group(202,37,1,0,0);
eqw_GameUI.ShowFlowerInfo();
eqw_GameUI.ShowMulti();
switch(ind){
case 0:
play_ani(1,787,18,590,get_self(346+ind,18,0,0,0)-26,0,800,0,0,0,1,0,0);
play_ani(1,787,19,270,get_self(346+ind,19,0,0,0)-17,0,800,0,0,0,1,0,0);
setTimeout("play_ani(1,787,33,100,130,0,500,0,0,0,1,0,0)",800);
//play_ani(1,787,33,130,100,0,500,0,0,0,1,0,0);
setTimeout("play_ani(1,787,33,130,100,0,500,0,0,0,1,0,0)",1200);
//var w=7*eqw_Const.Bottom.Dis+eqw_Const.Card.oriwidth*eqw_Const.Card.deskscale/100;
//var x=640-w/2;
//var mid=640-eqw_Const.Card.oriwidth*eqw_Const.Card.deskscale/200;
for(var i=0;i<8;i++){
set_self(773+i,37,0,0,0);
//set_self(773+i,19,eqw_Const.Bottom.Location[1],0,0);
//set_self(773+i,18,mid,0);
//set_self(773+i,43,eqw_Desk.bottomcards[i]%54+1,0,0);
}
//for(var i=0;i<8;i++){
//set_self(773+i,18,x+eqw_Const.Bottom.Dis*i,0);
//play_ani(1,773+i,18,mid,x+eqw_Const.Bottom.Dis*i,0,500,0,0,0,1,0,0);
//}
eqw_GameUI.Data.Bankerspid=346+ind;
setTimeout(function(){
//set_self(787,37,0,0,0);
eqw_GameUI.ShowChoseMainBoard();
eqw_GameUI.OpenCountDown(eqw_Desk.BankerSeat);
},1700);
break;
case 1:
play_ani(1,787,18,590,get_self(346+ind,18,0,0,0)-26,0,800,0,0,0,1,0,0);
play_ani(1,787,19,270,get_self(346+ind,19,0,0,0)-17,0,800,0,0,0,1,0,0);
setTimeout("play_ani(1,787,33,100,130,0,500,0,0,0,1,0,0)",800);
//play_ani(1,787,33,130,100,0,500,0,0,0,1,0,0);
setTimeout("play_ani(1,787,33,130,100,0,500,0,0,0,1,0,0)",1200);
//var w=7*eqw_Const.Bottom.Dis+eqw_Const.Card.oriwidth*eqw_Const.Card.deskscale/100;
var w=7*eqw_Const.Bottom.Dis+eqw_Const.Card.oriwidth;
var x=640-w/2;
//var mid=640-eqw_Const.Card.oriwidth*eqw_Const.Card.deskscale/200;
var mid=640-eqw_Const.Card.oriwidth/2;
for(var i=0;i<8;i++){
set_self(773+i,37,1,0,0);
set_self(773+i,33,eqw_Const.Card.deskscale,0,0);
set_self(773+i,35,255,0,0);
set_self(773+i,19,eqw_Const.Bottom.Location[1],0,0);
set_self(773+i,18,mid,0,0);
set_self(773+i,43,eqw_Desk.bottomcards[i]%54+1,0,0);
}
for(var i=0;i<8;i++){
//set_self(773+i,18,x+eqw_Const.Bottom.Dis*i,0);
play_ani(1,773+i,18,mid,x+eqw_Const.Bottom.Dis*i,0,500,0,0,0,1,0,0);
}
eqw_GameUI.Data.Bankerspid=346+ind;
setTimeout(function(){
//set_self(787,37,0,0,0);
eqw_GameUI.ShowChoseMainBoard();
eqw_GameUI.OpenCountDown(eqw_Desk.BankerSeat);
},1700);
break;
case 2:
play_ani(1,787,18,590,get_self(346+ind,18,0,0,0)-26,0,800,0,0,0,1,0,0);
play_ani(1,787,19,270,get_self(346+ind,19,0,0,0)-17,0,800,0,0,0,1,0,0);
setTimeout("play_ani(1,787,33,100,130,0,500,0,0,0,1,0,0)",800);
//play_ani(1,787,33,130,100,0,500,0,0,0,1,0,0);
setTimeout("play_ani(1,787,33,130,100,0,500,0,0,0,1,0,0)",1200);
//var w=7*eqw_Const.Bottom.Dis+eqw_Const.Card.oriwidth*eqw_Const.Card.deskscale/100;
var w=7*eqw_Const.Bottom.Dis+eqw_Const.Card.oriwidth;
var x=640-w/2;
//var mid=640-eqw_Const.Card.oriwidth*eqw_Const.Card.deskscale/200;
var mid=640-eqw_Const.Card.oriwidth/2;
for(var i=0;i<8;i++){
set_self(773+i,37,1,0,0);
set_self(773+i,33,eqw_Const.Card.deskscale,0,0);
set_self(773+i,35,255,0,0);
set_self(773+i,19,eqw_Const.Bottom.Location[1],0,0);
set_self(773+i,18,mid,0,0);
set_self(773+i,43,eqw_Desk.bottomcards[i]%54+1,0,0);
}
for(var i=0;i<8;i++){
//set_self(773+i,18,x+eqw_Const.Bottom.Dis*i,0);
play_ani(1,773+i,18,mid,x+eqw_Const.Bottom.Dis*i,0,500,0,0,0,1,0,0);
}
eqw_GameUI.Data.Bankerspid=346+ind;
setTimeout(function(){
//set_self(787,37,0,0,0);
eqw_GameUI.ShowChoseMainBoard();
eqw_GameUI.OpenCountDown(eqw_Desk.BankerSeat);
},1700);
break;
}
}
eqw_GameUI.ShowChoseMainBoard=function(){
if(Utl.getMySeat()==eqw_Desk.BankerSeat){//自己为主
if(eqw_GameUI.Data.Video_Step == -1){
eqw_GameUI.openSurrenderBtn();
}
for(var i=788;i<=793;i++){
set_self(i,33,100,0,0);
}
set_self(788,18,0,0,0);
set_self(788,19,266,0,0);
set_self(789,18,550,0,0);
set_self(789,19,85,0,0);
for(var i=0;i<4;i++){
set_self(790+i,18,eqw_Const.Main.Location_1[i][0],0,0);
set_self(790+i,19,eqw_Const.Main.Location_1[i][1],0,0);
}
set_group(206,37,1,0,0);
set_self(794,37,0,0,0);
set_self(795,37,0,0,0);
}else{
set_self(794,37,1,0,0);
var w=7*eqw_Const.Bottom.Dis+eqw_Const.Card.oriwidth;
var x=640-w/2;
for(var i=0;i<8;i++){
set_self(773+i,37,1,0,0);
set_self(773+i,35,255,0,0);
set_self(773+i,33,eqw_Const.Card.deskscale,0,0);
set_self(773+i,19,eqw_Const.Bottom.Location[1],0,0);
set_self(773+i,18,x+i*eqw_Const.Bottom.Dis,0,0);
set_self(773+i,43,eqw_Desk.bottomcards[i]%54+1,0,0);
}
}
}
eqw_GameUI.HideChoseMainBoard=function(){
set_group(206,37,0,0,0);
}
eqw_GameUI.ChoseMainEffct=function(ind){
ind=ind-1;
if(Utl.getMySeat()==eqw_Desk.BankerSeat){//自己为主
eqw_GameUI.Data.Main=ind+1;
play_ani(1,790+ind,18,get_self(790+ind,18,0,0,0),eqw_Const.Main.Location_2[0],0,500,0,0,0,1,0,0);
play_ani(1,790+ind,19,get_self(790+ind,19,0,0,0),eqw_Const.Main.Location_2[1],0,500,0,0,0,1,0,0);
setTimeout(function(){
play_ani(1,790+ind,18,eqw_Const.Main.Location_2[0],1000,0,500,0,0,0,1,0,0);
play_ani(1,790+ind,19,eqw_Const.Main.Location_2[1],-40,0,500,0,0,0,1,0,0);
play_ani(1,790+ind,33,100,45,0,500,0,0,0,1,0,0);
setTimeout(function(){
set_group(206,37,0,0,0);
eqw_GameUI.ShowMaiPai();
},500);
},800);
}else{
eqw_GameUI.Data.Main=ind+1;
set_self(790+ind,18,eqw_Const.Main.Location_2[0],0,0);
set_self(790+ind,19,eqw_Const.Main.Location_2[1],0,0);
setTimeout(function(){
play_ani(1,790+ind,18,eqw_Const.Main.Location_2[0],1000,0,500,0,0,0,1,0,0);
play_ani(1,790+ind,19,eqw_Const.Main.Location_2[1],-40,0,500,0,0,0,1,0,0);
play_ani(1,790+ind,33,100,45,0,500,0,0,0,1,0,0);
setTimeout(function(){
set_group(206,37,0,0,0);
eqw_GameUI.ShowMaiPai();
},500);
},300);
}
}
eqw_GameUI.ShowMaiPai=function(){
var ind = eqw_Logic.ChangeToStatus(eqw_Desk.BankerSeat);
//if(eqw_GameUI.Data.Video_Step == -1){
//eqw_GameUI.openSurrenderBtn();
//}
if(ind==0){
//set_self(800,36,10,0,0);
eqw_GameUI.Data.canBury=0;
set_self(800,37,1,0,0);
set_self(800,43,2,0,0);
}else{
set_self(795,37,1,0,0);
}
}
eqw_GameUI.HideMaiPai=function(){
//var ind = eqw_Logic.ChangeToStatus(eqw_Desk.BankerSeat);
//if(ind==0){
set_self(800,37,0,0,0);
//}else{
set_self(795,37,0,0,0);
//}
}
eqw_GameUI.ShowRound=function(idx,sum){
set_self(702,18,486,0,0);
set_self(703,7,"第"+idx+"/"+sum+"局");
set_self(703,20,get_self(703,7,0,0,0).gblen()*14,0,0);
set_self(703,18,640-get_self(703,7,0,0,0).gblen()*7,0,0);
set_self(702,37,1,0,0);
set_self(703,37,1,0,0);
}
eqw_GameUI.ShowFlowerInfo=function(){
set_self(798,7,eqw_Desk.Callgrade,0,0);
set_self(798,20,String(eqw_Desk.Callgrade).length*22,0,0);
set_self(799,7,eqw_Desk.Curgrade,0,0);
set_self(799,20,String(eqw_Desk.Curgrade).length*22,0,0);
set_group(202,37,1,0,0);
}
eqw_GameUI.ClickCard=function(spid){
if(spid>=705&&spid<=704+eqw_Player.HandCards.length){//选牌在手中
if(eqw_Player.HandCards[spid-705].GetClick()==1){
if(eqw_Player.HandCards[spid-705].GetSelect()==0){//未选中
if(eqw_Desk.step==3){//埋牌阶段
if(eqw_Player.GetNumSelect()<8){
set_self(spid,19,-eqw_Const.Card.out_y,1,0);
eqw_Player.SelectCards(spid-705);
}
if(eqw_Player.GetNumSelect()==8){
set_self(800,43,1,0,0);
//eqw_GameUI.Data.canBury=1;
}
}else if(eqw_Desk.step==4||eqw_Desk.step==5){
set_self(spid,19,-eqw_Const.Card.out_y,1,0);
eqw_Player.SelectCards(spid-705);
if(eqw_Desk.PushInd>1){
if(eqw_Player.GetNumSelect()==eqw_Desk.push_count){
set_self(801,43,2,0,0);
//eqw_GameUI.Data.canPush=1;
}else{
//eqw_GameUI.Data.canPush=0;
set_self(801,43,1,0,0);
}
}else{
if(eqw_Player.GetNumSelect()>0){
//eqw_GameUI.Data.canPush=1;
set_self(801,43,2,0,0);
}else{
//eqw_GameUI.Data.canPush=0;
set_self(801,43,1,0,0);
}
}
}
}else{//已选中
if(eqw_Desk.step==3){//埋牌阶段
set_self(spid,19,eqw_Const.Card.out_y,1,0);
eqw_Player.CancelSelectCards(spid-705);
if(eqw_Player.GetNumSelect()<8){
//set_self(800,36,10,0,0);
//eqw_GameUI.Data.canBury=0;
set_self(800,43,2,0,0);
}
}else if(eqw_Desk.step==4||eqw_Desk.step==5){
set_self(spid,19,eqw_Const.Card.out_y,1,0);
eqw_Player.CancelSelectCards(spid-705);
if(eqw_Desk.PushInd>1){
if(eqw_Player.GetNumSelect()==eqw_Desk.push_count){
//eqw_GameUI.Data.canPush=1;
set_self(801,43,2,0,0);
}else{
//eqw_GameUI.Data.canPush=0;
set_self(801,43,1,0,0);
}
}else{
if(eqw_Player.GetNumSelect()>0){
//eqw_GameUI.Data.canPush=1;
set_self(801,43,2,0,0);
}else{
//eqw_GameUI.Data.canPush=0;
set_self(801,43,1,0,0);
}
}
}
}
}
}
}
//显示桌面底牌
eqw_GameUI.ShowDeskCards=function(){
set_self(860,37,1,0,0);
set_self(860,18,eqw_Const.Bottom.Location[0]-get_self(860,20,0,0,0)/2,0,0);
set_self(860,19,eqw_Const.Bottom.Location[1],0,0,0);
set_self(860,33,eqw_Const.Card.deskscale,0,0);
}
//埋牌动画
eqw_GameUI.maipai=function(){
//if(Utl.getMySeat()==eqw_Desk.BankerSeat){
eqw_Logic.play_burry();
set_self(860,37,1,0,0);
set_self(860,18,eqw_Const.Bottom.Location[0]-get_self(860,20,0,0,0)/2,0,0);
set_self(860,19,eqw_Const.Bottom.Location[1],0,0,0);
set_self(860,33,eqw_Const.Card.deskscale,0,0);
var ind=eqw_Logic.ChangeToStatus(eqw_Desk.BankerSeat);
eqw_GameUI.HideMaiPai();
switch(ind){
case 0:
var w=7*eqw_Const.Card.pushdis+eqw_Const.Card.oriwidth*eqw_Const.Card.pushscale/100;
var x=eqw_Const.Card.pushlocation[0][0]-w/2;
for(var i=0;i<8;i++){
set_self(773+i,19,eqw_Const.Card.pushlocation[0][1],0,0);
set_self(773+i,18,x+i*eqw_Const.Card.pushdis,0,0);
set_self(773+i,33,eqw_Const.Card.pushscale,0,0);
set_self(773+i,43,eqw_Player.BottomCards[i]%54+1,0,0);
set_self(773+i,35,255,0,0);
}
eqw_GameUI.SetMyCards();
for(var i=0;i<8;i++){
set_self(773+i,37,1,0,0);
play_ani(1,773+i,18,get_self(773+i,18,0,0,0),eqw_Const.Bottom.Location[0]-get_self(773+i,20,0,0,0)/2,0,500,0,200,0,1,0,0);
play_ani(1,773+i,19,get_self(773+i,19,0,0,0),eqw_Const.Bottom.Location[1],0,500,0,200,0,1,0,0);
}
break;
case 1:
var w=7*eqw_Const.Card.pushdis+eqw_Const.Card.oriwidth*eqw_Const.Card.pushscale/100;
var x=eqw_Const.Card.pushlocation[ind][0]-w/2;
for(var i=0;i<8;i++){
set_self(773+i,37,0,0,0);
set_self(773+i,43,55,0,0);
set_self(773+i,35,255,0,0);
}
for(var i=0;i<8;i++){
set_self(773+i,19,eqw_Const.Card.pushlocation[ind][1],0,0);
set_self(773+i,18,x+i*eqw_Const.Card.pushdis,0,0);
set_self(773+i,33,eqw_Const.Card.pushscale,0,0);
}
//eqw_GameUI.SetMyCards();
for(var i=0;i<8;i++){
set_self(773+i,37,1,0,0);
play_ani(1,773+i,18,get_self(773+i,18,0,0,0),eqw_Const.Bottom.Location[0]-get_self(773+i,20,0,0,0)/2,0,500,0,0,0,1,0,0);
play_ani(1,773+i,19,get_self(773+i,19,0,0,0),eqw_Const.Bottom.Location[1],0,500,0,0,0,1,0,0);
}
break;
case 2:
var w=7*eqw_Const.Card.pushdis+eqw_Const.Card.oriwidth*eqw_Const.Card.pushscale/100;
var x=eqw_Const.Card.pushlocation[ind][0]-w/2;
for(var i=0;i<8;i++){
set_self(773+i,37,0,0,0);
set_self(773+i,43,55,0,0);
set_self(773+i,35,255,0,0);
}
for(var i=0;i<8;i++){
set_self(773+i,19,eqw_Const.Card.pushlocation[ind][1],0,0);
set_self(773+i,18,x+i*eqw_Const.Card.pushdis,0,0);
set_self(773+i,33,eqw_Const.Card.pushscale,0,0);
set_self(773+i,37,1,0,0);
}
//eqw_GameUI.SetMyCards();
for(var i=0;i<8;i++){
play_ani(1,773+i,18,get_self(773+i,18,0,0,0),eqw_Const.Bottom.Location[0]-get_self(773+i,20,0,0,0)/2,0,500,0,0,0,1,0,0);
play_ani(1,773+i,19,get_self(773+i,19,0,0,0),eqw_Const.Bottom.Location[1],0,500,0,0,0,1,0,0);
}
break;
}
//}else{
//}
set_self(701,37,1,0,0);
setTimeout("eqw_GameUI.PushCardsRun(eqw_Desk.PushSeat)",700);
}
//停止埋牌动画
eqw_GameUI.Endmaipai=function(){
//if(Utl.getMySeat()==eqw_Desk.BankerSeat){
eqw_Logic.play_burry();
set_self(860,37,1,0,0);
set_self(860,18,eqw_Const.Bottom.Location[0]-get_self(860,20,0,0,0)/2,0,0);
set_self(860,19,eqw_Const.Bottom.Location[1],0,0,0);
set_self(860,33,eqw_Const.Card.deskscale,0,0);
var ind=eqw_Logic.ChangeToStatus(eqw_Desk.BankerSeat);
eqw_GameUI.HideMaiPai();
switch(ind){
case 0:
var w=7*eqw_Const.Card.pushdis+eqw_Const.Card.oriwidth*eqw_Const.Card.pushscale/100;
var x=eqw_Const.Card.pushlocation[0][0]-w/2;
for(var i=0;i<8;i++){
set_self(773+i,19,eqw_Const.Card.pushlocation[0][1],0,0);
set_self(773+i,18,x+i*eqw_Const.Card.pushdis,0,0);
set_self(773+i,33,eqw_Const.Card.pushscale,0,0);
set_self(773+i,43,eqw_Player.BottomCards[i]%54+1,0,0);
set_self(773+i,35,255,0,0);
}
eqw_GameUI.SetMyCards();
for(var i=0;i<8;i++){
set_self(773+i,37,1,0,0);
play_ani(0,773+i,18,get_self(773+i,18,0,0,0),eqw_Const.Bottom.Location[0]-get_self(773+i,20,0,0,0)/2,0,500,0,200,0,1,0,0);
play_ani(0,773+i,19,get_self(773+i,19,0,0,0),eqw_Const.Bottom.Location[1],0,500,0,200,0,1,0,0);
set_self(773+i,18,eqw_Const.Bottom.Location[0]-get_self(773+i,20,0,0,0)/2,0,0);
set_self(773+i,19,eqw_Const.Bottom.Location[1],0,0);
}
break;
case 1:
var w=7*eqw_Const.Card.pushdis+eqw_Const.Card.oriwidth*eqw_Const.Card.pushscale/100;
var x=eqw_Const.Card.pushlocation[ind][0]-w/2;
for(var i=0;i<8;i++){
set_self(773+i,37,0,0,0);
set_self(773+i,43,55,0,0);
set_self(773+i,35,255,0,0);
}
for(var i=0;i<8;i++){
set_self(773+i,19,eqw_Const.Card.pushlocation[ind][1],0,0);
set_self(773+i,18,x+i*eqw_Const.Card.pushdis,0,0);
set_self(773+i,33,eqw_Const.Card.pushscale,0,0);
}
//eqw_GameUI.SetMyCards();
for(var i=0;i<8;i++){
set_self(773+i,37,1,0,0);
play_ani(0,773+i,18,get_self(773+i,18,0,0,0),eqw_Const.Bottom.Location[0]-get_self(773+i,20,0,0,0)/2,0,500,0,0,0,1,0,0);
play_ani(0,773+i,19,get_self(773+i,19,0,0,0),eqw_Const.Bottom.Location[1],0,500,0,0,0,1,0,0);
set_self(773+i,18,eqw_Const.Bottom.Location[0]-get_self(773+i,20,0,0,0)/2,0,0);
set_self(773+i,19,eqw_Const.Bottom.Location[1],0,0);
}
break;
case 2:
var w=7*eqw_Const.Card.pushdis+eqw_Const.Card.oriwidth*eqw_Const.Card.pushscale/100;
var x=eqw_Const.Card.pushlocation[ind][0]-w/2;
for(var i=0;i<8;i++){
set_self(773+i,37,0,0,0);
set_self(773+i,43,55,0,0);
set_self(773+i,35,255,0,0);
}
for(var i=0;i<8;i++){
set_self(773+i,19,eqw_Const.Card.pushlocation[ind][1],0,0);
set_self(773+i,18,x+i*eqw_Const.Card.pushdis,0,0);
set_self(773+i,33,eqw_Const.Card.pushscale,0,0);
set_self(773+i,37,1,0,0);
}
//eqw_GameUI.SetMyCards();
for(var i=0;i<8;i++){
play_ani(0,773+i,18,get_self(773+i,18,0,0,0),eqw_Const.Bottom.Location[0]-get_self(773+i,20,0,0,0)/2,0,500,0,0,0,1,0,0);
play_ani(0,773+i,19,get_self(773+i,19,0,0,0),eqw_Const.Bottom.Location[1],0,500,0,0,0,1,0,0);
set_self(773+i,18,eqw_Const.Bottom.Location[0]-get_self(773+i,20,0,0,0)/2,0,0);
set_self(773+i,19,eqw_Const.Bottom.Location[1],0,0);
}
break;
}
//}else{
//}
set_self(701,37,1,0,0);
//eqw_GameUI.PushCardsRun(eqw_Desk.PushSeat);
}
//显示哪家牌大(500)
eqw_GameUI.ShowMaxSeat=function(seat,bTemp){
//console.log(eqw_Data.isShowmaxseat);
var ind=eqw_Logic.ChangeToStatus(seat);
switch(ind){
case 0:
//var len=eqw_Desk.Call_Run.CardList[seat].length;
if(bTemp){
setTimeout(
function(){
if(eqw_Data.isShowmaxseat){
set_self(1039,18,get_self(740,18,0,0,0)-eqw_Const.Card.oriwidth*eqw_Const.Card.pushscale/200-40+eqw_Const.Card.oriwidth,0,0);
set_self(1039,19,get_self(740,19,0,0,0)+eqw_Const.Card.oriheight*eqw_Const.Card.pushscale/200,0,0);
set_self(1039,33,50,0,0);
set_self(1039,37,1,0,0);
play_ani(1,1039,33,50,100,0,500,0,0,0,1,0,0);
play_ani(1,1039,34,0,360,0,500,0,0,0,1,0,0);
}
},700);
}else{
set_self(1039,18,get_self(740,18,0,0,0)-eqw_Const.Card.oriwidth*eqw_Const.Card.pushscale/200-40+eqw_Const.Card.oriwidth,0,0);
set_self(1039,19,get_self(740,19,0,0,0)+eqw_Const.Card.oriheight*eqw_Const.Card.pushscale/200,0,0);
set_self(1039,33,50,0,0);
set_self(1039,37,1,0,0);
play_ani(1,1039,33,50,100,0,500,0,0,0,1,0,0);
play_ani(1,1039,34,0,360,0,500,0,0,0,1,0,0);
}
break;
case 1:
var len=eqw_Desk.Call_Run.CardList[seat].length;
if(bTemp){
setTimeout(
function(){
if(eqw_Data.isShowmaxseat){
set_self(1039,18,get_self(827+len-1,18,0,0,0)-eqw_Const.Card.oriwidth*eqw_Const.Card.pushscale/200-40+eqw_Const.Card.oriwidth,0,0);
set_self(1039,19,get_self(827+len-1,19,0,0,0)+eqw_Const.Card.oriheight*eqw_Const.Card.pushscale/200,0,0);
set_self(1039,33,50,0,0);
set_self(1039,37,1,0,0);
play_ani(1,1039,33,50,100,0,500,0,0,0,1,0,0);
play_ani(1,1039,34,0,360,0,500,0,0,0,1,0,0);
}
},700);
}else{
set_self(1039,18,get_self(827+len-1,18,0,0,0)-eqw_Const.Card.oriwidth*eqw_Const.Card.pushscale/200-40+eqw_Const.Card.oriwidth,0,0);
set_self(1039,19,get_self(827+len-1,19,0,0,0)+eqw_Const.Card.oriheight*eqw_Const.Card.pushscale/200,0,0);
set_self(1039,33,50,0,0);
set_self(1039,37,1,0,0);
play_ani(1,1039,33,50,100,0,500,0,0,0,1,0,0);
play_ani(1,1039,34,0,360,0,500,0,0,0,1,0,0);
}
break;
case 2:
var len=eqw_Desk.Call_Run.CardList[seat].length;
if(bTemp){
setTimeout(
function(){
if(eqw_Data.isShowmaxseat){
set_self(1039,18,get_self(841+len-1,18,0,0,0)-eqw_Const.Card.oriwidth*eqw_Const.Card.pushscale/200-40+eqw_Const.Card.oriwidth,0,0);
set_self(1039,19,get_self(841+len-1,19,0,0,0)+eqw_Const.Card.oriheight*eqw_Const.Card.pushscale/200,0,0);
set_self(1039,33,50,0,0);
set_self(1039,37,1,0,0);
play_ani(1,1039,33,50,100,0,500,0,0,0,1,0,0);
play_ani(1,1039,34,0,360,0,500,0,0,0,1,0,0);
}
},700);
}else{
set_self(1039,18,get_self(841+len-1,18,0,0,0)-eqw_Const.Card.oriwidth*eqw_Const.Card.pushscale/200-40+eqw_Const.Card.oriwidth,0,0);
set_self(1039,19,get_self(841+len-1,19,0,0,0)+eqw_Const.Card.oriheight*eqw_Const.Card.pushscale/200,0,0);
set_self(1039,33,50,0,0);
set_self(1039,37,1,0,0);
play_ani(1,1039,33,50,100,0,500,0,0,0,1,0,0);
play_ani(1,1039,34,0,360,0,500,0,0,0,1,0,0);
}
break;
}
}
//出牌(0)
eqw_GameUI.PushCards=function(seat,CardList){
var ind = eqw_Logic.ChangeToStatus(seat);
eqw_Logic.play_outpoker();
switch(ind){
case 0:
eqw_GameUI.MyPush(CardList);
break;
case 1:
eqw_GameUI.DownPush(CardList);
break;
case 2:
eqw_GameUI.UpPush(CardList);
break;
}
}
//自己出牌(700)
eqw_GameUI.MyPush=function(CardList){
var len=CardList.length;
var w=(len-1)*eqw_Const.Card.pushdis+eqw_Const.Card.oriwidth;
var x=eqw_Const.Card.pushlocation[0][0]-w/2;
for(var i=0;i<len;i++){
set_self(740-len+1+i,43,CardList[i]%54+1,0,0);
set_self(740-len+1+i,33,eqw_Const.Card.pushscale,0,0);
set_self(740-len+1+i,18,x+eqw_Const.Card.pushdis*i,0,0);
set_self(740-len+1+i,19,eqw_Const.Card.pushlocation[0][1],0,0);
set_self(740-len+1+i,37,1,0,0);
play_ani(1,740-len+1+i,19,eqw_Const.Card.pushlocation[0][1],eqw_Const.Card.pushlocation_f[0][1],0,300,0,200,0,1,0,0);
}
}
//下家出牌
eqw_GameUI.DownPush=function(CardList){
var len=CardList.length;
var w=(len-1)*eqw_Const.Card.pushdis+eqw_Const.Card.oriwidth;
var x=eqw_Const.Card.pushlocation[1][0]-w/2;
var xf=eqw_Const.Card.pushlocation_f[1][0]-w/2;
for(var i=0;i<len;i++){
set_self(827+i,43,CardList[i]%54+1,0,0);
set_self(827+i,33,eqw_Const.Card.pushscale,0,0);
set_self(827+i,18,x+eqw_Const.Card.pushdis*i,0,0);
set_self(827+i,19,eqw_Const.Card.pushlocation[1][1],0,0);
set_self(827+i,37,1,0,0);
play_ani(1,827+i,18,get_self(827+i,18,0,0,0),xf+i*eqw_Const.Card.pushdis,0,300,0,200,0,1,0,0);
}
}
//上家出牌
eqw_GameUI.UpPush=function(CardList){
var len=CardList.length;
var w=(len-1)*eqw_Const.Card.pushdis+eqw_Const.Card.oriwidth;
var x=eqw_Const.Card.pushlocation[2][0]-w/2;
var xf=eqw_Const.Card.pushlocation_f[2][0]-w/2;
for(var i=0;i<len;i++){
set_self(841+i,43,CardList[i]%54+1,0,0);
set_self(841+i,33,eqw_Const.Card.pushscale,0,0);
set_self(841+i,18,x+eqw_Const.Card.pushdis*i,0,0);
set_self(841+i,19,eqw_Const.Card.pushlocation[2][1],0,0);
set_self(841+i,37,1,0,0);
play_ani(1,841+i,18,get_self(841+i,18,0,0,0),xf+i*eqw_Const.Card.pushdis,0,300,0,200,0,1,0,0);
}
}
//显示自己出牌
eqw_GameUI.ShowMyPush=function(CardList){
var len=CardList.length;
var w=(len-1)*eqw_Const.Card.pushdis+eqw_Const.Card.oriwidth;
var x=eqw_Const.Card.pushlocation[0][0]-w/2;
for(var i=0;i<len;i++){
set_self(740-len+1+i,43,CardList[i]%54+1,0,0);
set_self(740-len+1+i,33,eqw_Const.Card.pushscale,0,0);
set_self(740-len+1+i,18,x+eqw_Const.Card.pushdis*i,0,0);
set_self(740-len+1+i,19,eqw_Const.Card.pushlocation_f[0][1],0,0);
set_self(740-len+1+i,37,1,0,0);
//play_ani(1,740-len+1+i,19,eqw_Const.Card.pushlocation[0][1],eqw_Const.Card.pushlocation_f[0][1],0,300,0,200,0,1,0,0);
}
}
//显示下家出牌
eqw_GameUI.ShowDownPush=function(CardList){
var len=CardList.length;
var w=(len-1)*eqw_Const.Card.pushdis+eqw_Const.Card.oriwidth;
//var x=eqw_Const.Card.pushlocation[1][0]-w/2;
var xf=eqw_Const.Card.pushlocation_f[1][0]-w/2;
for(var i=0;i<len;i++){
set_self(827+i,43,CardList[i]%54+1,0,0);
set_self(827+i,33,eqw_Const.Card.pushscale,0,0);
set_self(827+i,18,xf+i*eqw_Const.Card.pushdis,0,0);
set_self(827+i,19,eqw_Const.Card.pushlocation[1][1],0,0);
set_self(827+i,37,1,0,0);
//play_ani(1,827+i,18,get_self(827+i,18,0,0,0),xf+i*eqw_Const.Card.pushdis,0,300,0,200,0,1,0,0);
}
}
//显示上家出牌
eqw_GameUI.ShowUpPush=function(CardList){
var len=CardList.length;
var w=(len-1)*eqw_Const.Card.pushdis+eqw_Const.Card.oriwidth;
//var x=eqw_Const.Card.pushlocation[2][0]-w/2;
var xf=eqw_Const.Card.pushlocation_f[2][0]-w/2;
for(var i=0;i<len;i++){
set_self(841+i,43,CardList[i]%54+1,0,0);
set_self(841+i,33,eqw_Const.Card.pushscale,0,0);
set_self(841+i,18,xf+i*eqw_Const.Card.pushdis,0,0);
set_self(841+i,19,eqw_Const.Card.pushlocation[2][1],0,0);
set_self(841+i,37,1,0,0);
//play_ani(1,841+i,18,get_self(841+i,18,0,0,0),xf+i*eqw_Const.Card.pushdis,0,300,0,200,0,1,0,0);
}
}
//出牌轮换
eqw_GameUI.PushCardsRun=function(seat,bTemp){
if(!bTemp){
eqw_GameUI.OpenCountDown(seat);
}
if(Utl.getMySeat()==eqw_Desk.BankerSeat){//自己为主
if(eqw_GameUI.Data.Video_Step == -1){
if(eqw_Desk.surrender != 1){
eqw_GameUI.closeSurrenderBtn();
}else{
eqw_GameUI.openSurrenderBtn();
}
}
}
var ind = eqw_Logic.ChangeToStatus(seat);
switch(ind){
case 0:
set_self(801,37,1,0,0);
if(eqw_Desk.PushInd>1){
if(eqw_Player.GetNumSelect()==eqw_Desk.push_count){
//eqw_GameUI.Data.canPush=1;
set_self(801,43,2,0,0);
}else{
//eqw_GameUI.Data.canPush=0;
set_self(801,43,1,0,0);
}
}else{
if(eqw_Player.GetNumSelect()>0){
set_self(801,43,2,0,0);
//eqw_GameUI.Data.canPush=1;
}else{
//eqw_GameUI.Data.canPush=0;
set_self(801,43,1,0,0);
}
}
break;
case 1:
set_self(801,37,0,0,0);
break;
case 2:
set_self(801,37,0,0,0);
break;
}
}
//显示自己可出必出的牌
eqw_GameUI.ShowFollow=function(input_obj){
console.log("可出必出:"+JSON.stringify(input_obj));
eqw_Player.NoSelect();
eqw_Player.SetMustCards(input_obj.mustcard);
eqw_Player.SetClickCards(input_obj.cancard);
}
//得分特效(1300)
eqw_GameUI.ShowGrade=function(grade){
//console.log("Grade1:"+eqw_GameUI.Data.Grade1);
//console.log("Grade2:"+eqw_GameUI.Data.Grade2);
//console.log("Grade3:"+eqw_GameUI.Data.Grade3);
if(eqw_Data.isShowgrade){
set_self(1039,37,0,0,0);
var len=eqw_GameUI.Data.Grade1.length;
for(var i=0;i<eqw_GameUI.Data.Grade1.length;i++){
if(eqw_GameUI.Data.Grade1[i]==0){
set_self(740-len+1+i,37,0,0,0);
}else{
play_ani(1,740-len+1+i,19,get_self(740-len+1+i,19,0,0,0),eqw_Const.Bottom.Location[1],0,500,0,0,0,1,0,0);
play_ani(1,740-len+1+i,18,get_self(740-len+1+i,18,0,0,0),eqw_Const.Bottom.Location[0]-get_self(740-len+1+i,20,0,0,0)/2,0,500,0,0,0,1,0,0);
}
}
for(var i=0;i<eqw_GameUI.Data.Grade2.length;i++){
if(eqw_GameUI.Data.Grade2[i]==0){
set_self(827+i,37,0,0,0);
}else{
play_ani(1,827+i,19,get_self(827+i,19,0,0,0),eqw_Const.Bottom.Location[1],0,500,0,0,0,1,0,0);
play_ani(1,827+i,18,get_self(827+i,18,0,0,0),eqw_Const.Bottom.Location[0]-get_self(827+i,20,0,0,0)/2,0,500,0,0,0,1,0,0);
}
}
for(var i=0;i<eqw_GameUI.Data.Grade3.length;i++){
if(eqw_GameUI.Data.Grade3[i]==0){
set_self(841+i,37,0,0,0);
}else{
play_ani(1,841+i,19,get_self(841+i,19,0,0,0),eqw_Const.Bottom.Location[1],0,500,0,0,0,1,0,0);
play_ani(1,841+i,18,get_self(841+i,18,0,0,0),eqw_Const.Bottom.Location[0]-get_self(841+i,20,0,0,0)/2,0,500,0,0,0,1,0,0);
}
}
setTimeout(function(){
set_self(855,7,grade,0,0);
set_self(855,20,String(grade).length*21,0,0);
set_self(855,18,617,0,0);
set_self(855,19,190,0,0);
set_self(855,37,1,0,0);
eqw_Logic.play_score();
play_ani(1,855,18,617,1205,0,500,0,0,0,1,0,0);
play_ani(1,855,19,190,11,0,500,0,0,0,1,0,0);
setTimeout(function(){
set_self(855,37,0,0,0);
set_self(799,7,eqw_Desk.Curgrade,0,0);
set_self(799,20,String(eqw_Desk.Curgrade).length*22,0,0);
},500);
},800);
}
}
eqw_GameUI.HideAllCards=function(){
set_group(208,37,0,0,0);
set_group(209,37,0,0,0);
set_group(204,37,0,0,0);
for(var i=0;i<8;i++){
set_self(773+i,37,0,0,0);
}
set_self(860,37,0,0,0);
}
//eqw_GameUI.HideCards=function(){
//if(eqw_Data.isHideCards){
//set_self(1039,37,0,0,0);
//for(var i=0;i<3;i++){
//var ind=eqw_Logic.ChangeToStatus(i);
//switch(ind){
//case 0:
//var len=eqw_Desk.Call_Run.CardList[i].length;
//for(var j=0;j<len;j++){
//set_self(740-len+1+j,37,0,0,0);
//}
//break;
//case 1:
//for(var j=0;j<eqw_Desk.Call_Run.CardList[i].length;j++){
//set_self(827+j,37,0,0,0);
//}
//break;
//case 2:
//for(var j=0;j<eqw_Desk.Call_Run.CardList[i].length;j++){
//set_self(841+j,37,0,0,0);
//}
//break;
//}
//}
//}
//}
eqw_GameUI.HideCards=function(CardList){
//if(!CardList){
//CardList = [].concat(eqw_Data.pushcards);
//}
if(eqw_Data.isHideCards){
set_self(1039,37,0,0,0);
for(var i=0;i<3;i++){
//if(CardList[i]!=null){
var ind=eqw_Logic.ChangeToStatus(i);
switch(ind){
case 0:
//var len=CardList[i].length;
//for(var j=0;j<len;j++){
//set_self(740-len+1+j,37,0,0,0);
//}
var len = eqw_Player.HandCards.length;
for(var j=0;j<36-len;j++){
set_self(705+len+j,37,0,0,0);
}
break;
case 1:
for(var j=0;j<14;j++){
set_self(827+j,37,0,0,0);
}
break;
case 2:
for(var j=0;j<14;j++){
set_self(841+j,37,0,0,0);
}
break;
}
//}
}
}
}
//查牌
eqw_GameUI.HideSearch=function(){
set_group(210,37,0,0,0);
}
//查牌
eqw_GameUI.ShowSearch=function(){
eqw_GameUI.Data.SearchPage=eqw_Desk.Page_Search-1;
if(eqw_GameUI.Data.SearchPage>=0){
set_self(861,37,1,0,0);
//if(Utl.getMySeat()==eqw_Desk.BankerSeat){//庄家
//var w=(eqw_Desk.PushCardList_1[eqw_GameUI.Data.SearchPage].length-1)*eqw_Const.Search.Dis+eqw_Const.Card.oriwidth*eqw_Const.Search.scale/100;
//var x=eqw_Const.Search.Location[0][0]-w/2;
//for(var i=0;i<eqw_Desk.PushCardList_1[eqw_GameUI.Data.SearchPage].length;i++){
//set_self(862+i,33,eqw_Const.Search.scale,0,0);
//set_self(862+i,43,eqw_Desk.PushCardList_1[eqw_GameUI.Data.SearchPage][i]%54+1,0,0);
//set_self(862+i,18,x+i*eqw_Const.Search.Dis,0,0);
//set_self(862+i,19,eqw_Const.Search.Location[0][1],0,0);
//set_self(862+i,37,1,0,0);
//}
//}else{
for(var j=0;j<3;j++){
//if(j!=eqw_Desk.BankerSeat){
var ind = eqw_Logic.ChangeToStatus(j);//得到方位
var CardsList=[];
switch(j){
case 0:
CardsList=eqw_Desk.PushCardList_1[eqw_GameUI.Data.SearchPage];
break;
case 1:
CardsList=eqw_Desk.PushCardList_2[eqw_GameUI.Data.SearchPage];
break;
case 2:
CardsList=eqw_Desk.PushCardList_3[eqw_GameUI.Data.SearchPage];
break;
}
switch(ind){
case 0:
var w=(CardsList.length-1)*eqw_Const.Search.Dis+eqw_Const.Card.oriwidth*eqw_Const.Search.scale/100;
var x=eqw_Const.Search.Location[0][0]-w/2;
for(var i=0;i<CardsList.length;i++){
set_self(862+i,33,eqw_Const.Search.scale,0,0);
set_self(862+i,43,CardsList[i]%54+1,0,0);
set_self(862+i,18,x+i*eqw_Const.Search.Dis,0,0);
set_self(862+i,19,eqw_Const.Search.Location[0][1],0,0);
set_self(862+i,37,1,0,0);
}
break;
case 1:
var w=(CardsList.length-1)*eqw_Const.Search.Dis+eqw_Const.Card.oriwidth*eqw_Const.Search.scale/100;
var x=eqw_Const.Search.Location[1][0]-w/2;
for(var i=0;i<CardsList.length;i++){
set_self(876+i,33,eqw_Const.Search.scale,0,0);
set_self(876+i,43,CardsList[i]%54+1,0,0);
set_self(876+i,18,x+i*eqw_Const.Search.Dis,0,0);
set_self(876+i,19,eqw_Const.Search.Location[1][1],0,0);
set_self(876+i,37,1,0,0);
}
break;
case 2:
var w=(CardsList.length-1)*eqw_Const.Search.Dis+eqw_Const.Card.oriwidth*eqw_Const.Search.scale/100;
var x=eqw_Const.Search.Location[2][0]-w/2;
for(var i=0;i<CardsList.length;i++){
set_self(904+i,33,eqw_Const.Search.scale,0,0);
set_self(904+i,43,CardsList[i]%54+1,0,0);
set_self(904+i,18,x+i*eqw_Const.Search.Dis,0,0);
set_self(904+i,19,eqw_Const.Search.Location[2][1],0,0);
set_self(904+i,37,1,0,0);
}
break;
}
//}
}
//}
//set_group(210,37,1,0,0);
if(eqw_Desk.Page_Search>1){
set_self(918,37,1,0,0);
}
}
}
//往后查牌
eqw_GameUI.UpSearch=function(){
eqw_GameUI.Data.SearchPage--;
if(eqw_GameUI.Data.SearchPage>=0){
set_self(919,37,1,0,0);
if(eqw_GameUI.Data.SearchPage==0){
set_self(918,37,0,0,0);
}
if(Utl.getMySeat()==eqw_Desk.BankerSeat){//庄家
var CardsList=[];
switch(Utl.getMySeat()){
case 0:
CardsList=eqw_Desk.PushCardList_1;
break;
case 1:
CardsList=eqw_Desk.PushCardList_2;
break;
case 2:
CardsList=eqw_Desk.PushCardList_3;
break;
}
var w=(CardsList[eqw_GameUI.Data.SearchPage].length-1)*eqw_Const.Search.Dis+eqw_Const.Card.oriwidth*eqw_Const.Search.scale/100;
var x=eqw_Const.Search.Location[0][0]-w/2;
for(var i=0;i<CardsList[eqw_GameUI.Data.SearchPage].length;i++){
set_self(862+i,33,eqw_Const.Search.scale,0,0);
set_self(862+i,43,CardsList[eqw_GameUI.Data.SearchPage][i]%54+1,0,0);
set_self(862+i,18,x+i*eqw_Const.Search.Dis,0,0);
set_self(862+i,19,eqw_Const.Search.Location[0][1],0,0);
set_self(862+i,37,1,0,0);
}
for(var i=CardsList[eqw_GameUI.Data.SearchPage].length;i<14;i++){
set_self(862+i,37,0,0,0);
}
for(var i=0;i<14;i++){
set_self(876+i,37,0,0,0);
set_self(904+i,37,0,0,0);
}
}else{
for(var j=0;j<3;j++){
if(j!=eqw_Desk.BankerSeat){
var ind = eqw_Logic.ChangeToStatus(j);//得到方位
var CardsList=[];
switch(j){
case 0:
CardsList=eqw_Desk.PushCardList_1[eqw_GameUI.Data.SearchPage];
break;
case 1:
CardsList=eqw_Desk.PushCardList_2[eqw_GameUI.Data.SearchPage];
break;
case 2:
CardsList=eqw_Desk.PushCardList_3[eqw_GameUI.Data.SearchPage];
break;
}
switch(ind){
case 0:
//if(eqw_Desk.PushCardList_1.length>=eqw_GameUI.Data.SearchPage+1){
console.log(CardsList);
//}
var w=(CardsList.length-1)*eqw_Const.Search.Dis+eqw_Const.Card.oriwidth*eqw_Const.Search.scale/100;
var x=eqw_Const.Search.Location[0][0]-w/2;
for(var i=0;i<CardsList.length;i++){
set_self(862+i,33,eqw_Const.Search.scale,0,0);
set_self(862+i,43,CardsList[i]%54+1,0,0);
set_self(862+i,18,x+i*eqw_Const.Search.Dis,0,0);
set_self(862+i,19,eqw_Const.Search.Location[0][1],0,0);
set_self(862+i,37,1,0,0);
}
for(var i=CardsList.length;i<14;i++){
set_self(862+i,37,0,0,0);
}
break;
case 1:
var w=(CardsList.length-1)*eqw_Const.Search.Dis+eqw_Const.Card.oriwidth*eqw_Const.Search.scale/100;
var x=eqw_Const.Search.Location[1][0]-w/2;
for(var i=0;i<CardsList.length;i++){
set_self(876+i,33,eqw_Const.Search.scale,0,0);
set_self(876+i,43,CardsList[i]%54+1,0,0);
set_self(876+i,18,x+i*eqw_Const.Search.Dis,0,0);
set_self(876+i,19,eqw_Const.Search.Location[1][1],0,0);
set_self(876+i,37,1,0,0);
}
for(var i=CardsList.length;i<14;i++){
set_self(876+i,37,0,0,0);
}
break;
case 2:
var w=(CardsList.length-1)*eqw_Const.Search.Dis+eqw_Const.Card.oriwidth*eqw_Const.Search.scale/100;
var x=eqw_Const.Search.Location[2][0]-w/2;
for(var i=0;i<CardsList.length;i++){
set_self(904+i,33,eqw_Const.Search.scale,0,0);
set_self(904+i,43,CardsList[i]%54+1,0,0);
set_self(904+i,18,x+i*eqw_Const.Search.Dis,0,0);
set_self(904+i,19,eqw_Const.Search.Location[2][1],0,0);
set_self(904+i,37,1,0,0);
}
for(var i=CardsList.length;i<14;i++){
set_self(904+i,37,0,0,0);
}
break;
}
}else{
var ind = eqw_Logic.ChangeToStatus(j);//得到方位
switch(ind){
case 0:
for(var i=0;i<14;i++){
set_self(862+i,37,0,0,0);
}
break;
case 1:
for(var i=0;i<14;i++){
set_self(876+i,37,0,0,0);
}
break;
case 2:
for(var i=0;i<14;i++){
set_self(904+i,37,0,0,0);
}
break;
}
}
}
}
}else{
set_self(918,37,0,0,0);
}
}
//往前查牌
eqw_GameUI.DownSearch=function(){
eqw_GameUI.Data.SearchPage++;
if(eqw_GameUI.Data.SearchPage<=eqw_Desk.Page_Search-1){
set_self(918,37,1,0,0);
var bTemp=false;
if(eqw_GameUI.Data.SearchPage==eqw_Desk.Page_Search-1){
set_self(919,37,0,0,0);
bTemp=true;
}
if(bTemp){
for(var j=0;j<3;j++){
var ind = eqw_Logic.ChangeToStatus(j);//得到方位
var CardsList=[];
switch(j){
case 0:
CardsList=eqw_Desk.PushCardList_1[eqw_GameUI.Data.SearchPage];
break;
case 1:
CardsList=eqw_Desk.PushCardList_2[eqw_GameUI.Data.SearchPage];
break;
case 2:
CardsList=eqw_Desk.PushCardList_3[eqw_GameUI.Data.SearchPage];
break;
}
switch(ind){
case 0:
var w=(CardsList.length-1)*eqw_Const.Search.Dis+eqw_Const.Card.oriwidth*eqw_Const.Search.scale/100;
var x=eqw_Const.Search.Location[0][0]-w/2;
for(var i=0;i<CardsList.length;i++){
set_self(862+i,33,eqw_Const.Search.scale,0,0);
set_self(862+i,43,CardsList[i]%54+1,0,0);
set_self(862+i,18,x+i*eqw_Const.Search.Dis,0,0);
set_self(862+i,19,eqw_Const.Search.Location[0][1],0,0);
set_self(862+i,37,1,0,0);
}
for(var i=CardsList.length;i<14;i++){
set_self(862+i,37,0,0,0);
}
break;
case 1:
var w=(CardsList.length-1)*eqw_Const.Search.Dis+eqw_Const.Card.oriwidth*eqw_Const.Search.scale/100;
var x=eqw_Const.Search.Location[1][0]-w/2;
for(var i=0;i<CardsList.length;i++){
set_self(876+i,33,eqw_Const.Search.scale,0,0);
set_self(876+i,43,CardsList[i]%54+1,0,0);
set_self(876+i,18,x+i*eqw_Const.Search.Dis,0,0);
set_self(876+i,19,eqw_Const.Search.Location[1][1],0,0);
set_self(876+i,37,1,0,0);
}
for(var i=CardsList.length;i<14;i++){
set_self(876+i,37,0,0,0);
}
break;
case 2:
var w=(CardsList.length-1)*eqw_Const.Search.Dis+eqw_Const.Card.oriwidth*eqw_Const.Search.scale/100;
var x=eqw_Const.Search.Location[2][0]-w/2;
for(var i=0;i<CardsList.length;i++){
set_self(904+i,33,eqw_Const.Search.scale,0,0);
set_self(904+i,43,CardsList[i]%54+1,0,0);
set_self(904+i,18,x+i*eqw_Const.Search.Dis,0,0);
set_self(904+i,19,eqw_Const.Search.Location[2][1],0,0);
set_self(904+i,37,1,0,0);
}
for(var i=CardsList.length;i<14;i++){
set_self(904+i,37,0,0,0);
}
break;
}
}
}else{
if(Utl.getMySeat()==eqw_Desk.BankerSeat){//庄家
var CardsList=[];
switch(Utl.getMySeat()){
case 0:
CardsList=eqw_Desk.PushCardList_1;
break;
case 1:
CardsList=eqw_Desk.PushCardList_2;
break;
case 2:
CardsList=eqw_Desk.PushCardList_3;
break;
}
var w=(CardsList[eqw_GameUI.Data.SearchPage].length-1)*eqw_Const.Search.Dis+eqw_Const.Card.oriwidth*eqw_Const.Search.scale/100;
var x=eqw_Const.Search.Location[0][0]-w/2;
for(var i=0;i<CardsList[eqw_GameUI.Data.SearchPage].length;i++){
set_self(862+i,33,eqw_Const.Search.scale,0,0);
set_self(862+i,43,CardsList[eqw_GameUI.Data.SearchPage][i]%54+1,0,0);
set_self(862+i,18,x+i*eqw_Const.Search.Dis,0,0);
set_self(862+i,19,eqw_Const.Search.Location[0][1],0,0);
set_self(862+i,37,1,0,0);
}
for(var i=CardsList[eqw_GameUI.Data.SearchPage].length;i<14;i++){
set_self(862+i,37,0,0,0);
}
for(var i=0;i<14;i++){
set_self(876+i,37,0,0,0);
set_self(904+i,37,0,0,0);
}
}else{
for(var j=0;j<3;j++){
if(j!=eqw_Desk.BankerSeat){
var ind = eqw_Logic.ChangeToStatus(j);//得到方位
var CardsList=[];
switch(j){
case 0:
CardsList=eqw_Desk.PushCardList_1[eqw_GameUI.Data.SearchPage];
break;
case 1:
CardsList=eqw_Desk.PushCardList_2[eqw_GameUI.Data.SearchPage];
break;
case 2:
CardsList=eqw_Desk.PushCardList_3[eqw_GameUI.Data.SearchPage];
break;
}
switch(ind){
case 0:
var w=(CardsList.length-1)*eqw_Const.Search.Dis+eqw_Const.Card.oriwidth*eqw_Const.Search.scale/100;
var x=eqw_Const.Search.Location[0][0]-w/2;
for(var i=0;i<CardsList.length;i++){
set_self(862+i,33,eqw_Const.Search.scale,0,0);
set_self(862+i,43,CardsList[i]%54+1,0,0);
set_self(862+i,18,x+i*eqw_Const.Search.Dis,0,0);
set_self(862+i,19,eqw_Const.Search.Location[0][1],0,0);
set_self(862+i,37,1,0,0);
}
for(var i=CardsList.length;i<14;i++){
set_self(862+i,37,0,0,0);
}
break;
case 1:
var w=(CardsList.length-1)*eqw_Const.Search.Dis+eqw_Const.Card.oriwidth*eqw_Const.Search.scale/100;
var x=eqw_Const.Search.Location[1][0]-w/2;
for(var i=0;i<CardsList.length;i++){
set_self(876+i,33,eqw_Const.Search.scale,0,0);
set_self(876+i,43,CardsList[i]%54+1,0,0);
set_self(876+i,18,x+i*eqw_Const.Search.Dis,0,0);
set_self(876+i,19,eqw_Const.Search.Location[1][1],0,0);
set_self(876+i,37,1,0,0);
}
for(var i=CardsList.length;i<14;i++){
set_self(876+i,37,0,0,0);
}
break;
case 2:
var w=(CardsList.length-1)*eqw_Const.Search.Dis+eqw_Const.Card.oriwidth*eqw_Const.Search.scale/100;
var x=eqw_Const.Search.Location[2][0]-w/2;
for(var i=0;i<CardsList.length;i++){
set_self(904+i,33,eqw_Const.Search.scale,0,0);
set_self(904+i,43,CardsList[i]%54+1,0,0);
set_self(904+i,18,x+i*eqw_Const.Search.Dis,0,0);
set_self(904+i,19,eqw_Const.Search.Location[2][1],0,0);
set_self(904+i,37,1,0,0);
}
for(var i=CardsList.length;i<14;i++){
set_self(904+i,37,0,0,0);
}
break;
}
}else{
var ind = eqw_Logic.ChangeToStatus(j);//得到方位
switch(ind){
case 0:
for(var i=0;i<14;i++){
set_self(862+i,37,0,0,0);
}
break;
case 1:
for(var i=0;i<14;i++){
set_self(876+i,37,0,0,0);
}
break;
case 2:
for(var i=0;i<14;i++){
set_self(904+i,37,0,0,0);
}
break;
}
}
}
}
}
}else{
set_self(919,37,0,0,0);
}
}
//查底牌或者得分
eqw_GameUI.ShowBottomOrGrade=function(){
if(Utl.getMySeat()==eqw_Desk.BankerSeat){//庄家
//var w=7*eqw_Const.BottomOrGrade.Dis+eqw_Const.Card.oriwidth*eqw_Const.BottomOrGrade.scale/100;
var w=7*eqw_Const.BottomOrGrade.Dis+eqw_Const.Card.oriwidth;
var x=eqw_Const.BottomOrGrade.Location[0]-w/2;
set_self(856,37,1,0,0);
for(var i=0;i<8;i++){
set_self(802+i,33,eqw_Const.BottomOrGrade.scale,0,0);
set_self(802+i,18,x+i*eqw_Const.BottomOrGrade.Dis,0,0);
set_self(802+i,19,eqw_Const.BottomOrGrade.Location[1],0,0);
set_self(802+i,43,eqw_Player.BottomCards[i]%54+1,0,0);
set_self(802+i,37,1,0,0);
}
}else{
if(eqw_Desk.GradeList.length>0){
//var w=(eqw_Desk.GradeList.length-1)*eqw_Const.BottomOrGrade.Dis+eqw_Const.Card.oriwidth*eqw_Const.BottomOrGrade.scale/100;
var w=(eqw_Desk.GradeList.length-1)*eqw_Const.BottomOrGrade.Dis+eqw_Const.Card.oriwidth;
var x=eqw_Const.BottomOrGrade.Location[0]-w/2;
set_self(856,37,1,0,0);
for(var i=0;i<eqw_Desk.GradeList.length;i++){
set_self(802+i,33,eqw_Const.BottomOrGrade.scale,0,0);
set_self(802+i,18,x+i*eqw_Const.BottomOrGrade.Dis,0,0);
set_self(802+i,19,eqw_Const.BottomOrGrade.Location[1],0,0);
set_self(802+i,43,eqw_Desk.GradeList[i]%54+1,0,0);
set_self(802+i,37,1,0,0);
}
}
}
}
eqw_GameUI.HideBottomOrGrade=function(){
set_group(207,37,0,0,0);
}
//打开小局结算界面
eqw_GameUI.OpenSingleBalance=function(){
set_group(211,37,1,0,0);
Utl.closeWindow();
eqw_GameUI.CloseCountDown();
if(eqw_GameUI.Data.SingleBalancePack.upgrade==0){//中途解散
//set_self(1037,37,0,0,0);
set_self(1038,37,0,0,0);
set_self(928,43,2,0,0);
}else if(eqw_GameUI.Data.SingleBalancePack.upgrade==-99){//投降
//set_self(1037,37,0,0,0);
set_self(1038,37,0,0,0);
set_self(928,43,3,0,0);
}else if(eqw_GameUI.Data.SingleBalancePack.upgrade<0){//闲家赢
if(eqw_GameUI.Data.SingleBalancePack.upgrade==-1){//倒桩
//set_self(1037,37,0,0,0);
set_self(1038,37,0,0,0);
set_self(928,43,4,0,0);
}else{//升级
set_self(928,43,6,0,0);
set_self(1038,7,Math.abs(eqw_GameUI.Data.SingleBalancePack.upgrade),0,0);
//set_self(1038,34,45,0,0);
set_self(1038,20,String(Math.abs(eqw_GameUI.Data.SingleBalancePack.upgrade)).length*18,0,0);
set_self(1038,18,get_self(928,18,0,0,0)+get_self(928,20,0,0,0)/2-String(Math.abs(eqw_GameUI.Data.SingleBalancePack.upgrade)).length*9-6,0,0);
}
}else{//庄家赢
//set_self(1037,37,0,0,0);
set_self(1038,37,0,0,0);
switch(eqw_GameUI.Data.SingleBalancePack.upgrade){
case 1://过庄
set_self(928,43,5,0,0);
break;
case 2://小光
set_self(928,43,7,0,0);
break;
case 4://大光
set_self(928,43,1,0,0);
break;
}
}
if(eqw_GameUI.Data.SingleBalancePack.flower!=-1){
set_self(923,43,eqw_GameUI.Data.SingleBalancePack.flower,0,0);//花色
}else{
set_self(923,37,0,0,0);
}
if(eqw_GameUI.Data.SingleBalancePack.banker!=-1){
set_self(1036,18,get_self(934+eqw_GameUI.Data.SingleBalancePack.banker,18,0,0,0)+50,0,0);
}else{//无庄
set_self(1036,37,0,0,0);
}
if(eqw_GameUI.Data.SingleBalancePack.call!=-1){
set_self(949,7,eqw_GameUI.Data.SingleBalancePack.call,0,0);
set_self(949,20,String(eqw_GameUI.Data.SingleBalancePack.call).length*16,0,0);
}else{//无叫分
set_self(949,37,0,0,0);
}
set_self(950,7,eqw_GameUI.Data.SingleBalancePack.grade,0,0);
set_self(950,20,String(eqw_GameUI.Data.SingleBalancePack.grade).length*16,0,0);
if(eqw_GameUI.Data.SingleBalancePack.multiple!=-1){
set_self(951,7,'b'+eqw_GameUI.Data.SingleBalancePack.multiple,0,0);
set_self(951,20,('b'+eqw_GameUI.Data.SingleBalancePack.multiple).length*16,0,0);
}else{//无叫分
set_self(951,37,0,0,0);
}
for(var i=0;i<eqw_GameUI.Data.SingleBalancePack.seatlist.length;i++){
var ind=eqw_Logic.ChangeToStatus(i);
set_self(929+i,1,116+ind,0,0);
set_self(952+i,7,Func.subString(Utl.getNicknameBySeat(i),10,true),0,0);
for(var j=0;j<eqw_GameUI.Data.SingleBalancePack.seatlist[i].cards.length;j++){
set_self(967+i*20+j,43,eqw_GameUI.Data.SingleBalancePack.seatlist[i].cards[j]%54+1,0,0);
set_self(967+i*20+j,37,1,0,0);
}
if(eqw_GameUI.Data.SingleBalancePack.seatlist[i].grade_cg>=0){//
set_self(955+i*4,7,'b'+eqw_GameUI.Data.SingleBalancePack.seatlist[i].grade_cg,0,0);
set_self(955+i*4,20,('b'+eqw_GameUI.Data.SingleBalancePack.seatlist[i].grade_cg).length*18,0,0);
}else{
set_self(955+i*4,7,'c'+Math.abs(eqw_GameUI.Data.SingleBalancePack.seatlist[i].grade_cg),0,0);
set_self(955+i*4,20,('c'+Math.abs(eqw_GameUI.Data.SingleBalancePack.seatlist[i].grade_cg)).length*18,0,0);
}
if(eqw_GameUI.Data.SingleBalancePack.seatlist[i].grade_w>=0){//
set_self(956+i*4,7,'b'+eqw_GameUI.Data.SingleBalancePack.seatlist[i].grade_w,0,0);
set_self(956+i*4,20,('b'+eqw_GameUI.Data.SingleBalancePack.seatlist[i].grade_w).length*18,0,0);
}else{
set_self(956+i*4,7,'c'+Math.abs(eqw_GameUI.Data.SingleBalancePack.seatlist[i].grade_w),0,0);
set_self(956+i*4,20,('c'+Math.abs(eqw_GameUI.Data.SingleBalancePack.seatlist[i].grade_w)).length*18,0,0);
}
if(eqw_GameUI.Data.SingleBalancePack.seatlist[i].grade_jf>=0){//
set_self(957+i*4,7,'b'+eqw_GameUI.Data.SingleBalancePack.seatlist[i].grade_jf,0,0);
set_self(957+i*4,20,('b'+eqw_GameUI.Data.SingleBalancePack.seatlist[i].grade_jf).length*18,0,0);
}else{
set_self(957+i*4,7,'c'+Math.abs(eqw_GameUI.Data.SingleBalancePack.seatlist[i].grade_jf),0,0);
set_self(957+i*4,20,('c'+Math.abs(eqw_GameUI.Data.SingleBalancePack.seatlist[i].grade_jf)).length*18,0,0);
}
if(eqw_GameUI.Data.SingleBalancePack.seatlist[i].grade>=0){//
set_self(958+i*4,7,'b'+eqw_GameUI.Data.SingleBalancePack.seatlist[i].grade,0,0);
set_self(958+i*4,20,('b'+eqw_GameUI.Data.SingleBalancePack.seatlist[i].grade).length*18,0,0);
}else{
set_self(958+i*4,7,'c'+Math.abs(eqw_GameUI.Data.SingleBalancePack.seatlist[i].grade),0,0);
set_self(958+i*4,20,('c'+Math.abs(eqw_GameUI.Data.SingleBalancePack.seatlist[i].grade)).length*18,0,0);
}
if(eqw_GameUI.Data.SingleBalancePack.seatlist[i].obsolete==0){
set_self(1027+i,37,0,0,0);
}
if(eqw_GameUI.Data.SingleBalancePack.seatlist[i].chongguan==0){
set_self(1030+i,37,0,0,0);
set_self(1033+i,37,0,0,0);
}else{
set_self(1033+i,7,eqw_GameUI.Data.SingleBalancePack.seatlist[i].chongguan,0,0);
set_self(1033+i,20,String(eqw_GameUI.Data.SingleBalancePack.seatlist[i].chongguan).length*18,0,0);
set_self(1033+i,18,get_self(1030+i,18,0,0,0)+(get_self(1030+i,20,0,0,0)-get_self(1033+i,20,0,0,0))/2,0,0);
}
}
}
//关闭小局结算界面
eqw_GameUI.CloseSingleBalance=function(){
set_group(211,37,0,0,0);
set_group(212,37,0,0,0);
eqw_GameUI.Data.SingleBalancePack=null;
eqw_GameUI.Data.BottomPack=null;
eqw_GameUI.jiesuanInit();
}
eqw_GameUI.GetBottom=function(){
if(eqw_Data.isGetBottom){
set_self(860,37,0,0,0);
eqw_GameUI.HideAllCards();
for(var i=0;i<eqw_GameUI.Data.BottomPack.cards.length;i++){
set_self(773+i,43,eqw_GameUI.Data.BottomPack.cards[i]%54+1,0,0);
set_self(773+i,18,eqw_Const.Bottom.Location[0]-get_self(773+i,20,0,0,0)/2,0,0);
set_self(773+i,19,eqw_Const.Bottom.Location[1],0,0);
set_self(773+i,33,eqw_Const.Card.deskscale,0,0);
set_self(773+i,37,1,0,0);
}
var w=7*eqw_Const.Bottom.Dis+eqw_Const.Card.oriwidth*eqw_Const.Card.deskscale/100;
//var w=7*eqw_Const.Bottom.Dis+eqw_Const.Card.oriwidth;
var x=eqw_Const.Bottom.Location[0]-w/2;
for(var i=0;i<eqw_GameUI.Data.BottomPack.cards.length;i++){
play_ani(1,773+i,18,get_self(773+i,18,0,0,0),x+i*eqw_Const.Bottom.Dis,0,500,0,0,0,1,0,0);
}
setTimeout(function(){
for(var i=0;i<eqw_GameUI.Data.BottomPack.cards.length;i++){
var gd = cls_youle_erqiwang_arith.id_to_number(eqw_GameUI.Data.BottomPack.cards[i]);
if(gd==5||gd==10||gd==13){
set_self(773+i,19,-20,1,0);
}
}
if(typeof(eqw_GameUI.Data.BottomPack.multiple)!="undefined"){//闲家有扣底
if(eqw_GameUI.Data.BottomPack.multiple==0){//没有翻倍
//
}else{
//倍数特效
}
if(eqw_GameUI.Data.BottomPack.grade2>0){
eqw_GameUI.ShowGrade(eqw_GameUI.Data.BottomPack.grade2);
//setTimeout(function(){
//eqw_GameUI.OpenSingleBalance();
//},1800);
setTimeout(function(){
eqw_GameUI.OpenSingleBalance();
},2800);
}else{
//eqw_GameUI.OpenSingleBalance();
//setTimeout(function(){
//eqw_GameUI.OpenSingleBalance();
//},1000);
setTimeout(function(){
//eqw_GameUI.jiesuanInit();
eqw_GameUI.OpenSingleBalance();
},2000);
}
}else{
//eqw_GameUI.OpenSingleBalance();
//setTimeout(function(){
//eqw_GameUI.OpenSingleBalance();
//},1000);
setTimeout(function(){
//eqw_GameUI.jiesuanInit();
eqw_GameUI.OpenSingleBalance();
},2000);
}
},500);
}
}
eqw_GameUI.OpenBalance=function(){
var inputArray=[];
//for(var i=0;i<3;i++){
//var arrTemp = [Utl.getNicknameBySeat(i),];
//inputArray.push(arrTemp);
//}
//Utl.onGameFinished(inputArray);
var input=[];
for(var i=0;i<eqw_GameUI.Data.BalancePack.length;i++){
input.push(eqw_GameUI.Data.BalancePack[i][0]);
}
var calrt = Utl.getMultipleResult(input);
GameUI.showCalBtn(input);
eqw_Logic.play_balance();
set_group(213,37,1,0,0);
for(var i=0;i<3;i++){
set_self(1087+i,37,0,0,0);
}
for(var i=0;i<eqw_GameUI.Data.WinPlayer.length;i++){
set_self(1087+eqw_GameUI.Data.WinPlayer[i],37,1,0,0);
}
for(var i=0;i<eqw_GameUI.Data.BalancePack.length;i++){
set_self(1047+i,1,116+eqw_Logic.ChangeToStatus(i),0,0);
set_self(1053+i,7,Func.subString(Utl.getNicknameBySeat(i),6,true),0,0);
set_self(1056+i,7,"ID:"+Utl.getPlayeridBySeat(i),0,0);
if(eqw_GameUI.Data.BalancePack[i][0]>=0){
set_self(1066+i,7,'b'+eqw_GameUI.Data.BalancePack[i][0],0,0);
set_self(1066+i,20,('b'+eqw_GameUI.Data.BalancePack[i][0]).length*18,0,0);
}else{
set_self(1066+i,7,'c'+Math.abs(eqw_GameUI.Data.BalancePack[i][0]),0,0);
set_self(1066+i,20,('c'+Math.abs(eqw_GameUI.Data.BalancePack[i][0])).length*18,0,0);
}
var aryTemp = [Utl.getNicknameBySeat(i),eqw_GameUI.Data.BalancePack[i][0]];
inputArray.push(aryTemp);
if(calrt[i]>=0){
calrt[i] = min_replaceAll(String(calrt[i]), "\\.", "d", false);
set_self(1214+i,7,'b'+calrt[i],0,0);
set_self(1214+i,20,('b'+calrt[i]).length*18,0,0);
}else{
calrt[i] = min_replaceAll(String(Math.abs(calrt[i])), "\\.", "d", false);
set_self(1214+i,7,'c'+calrt[i],0,0);
set_self(1214+i,20,('c'+calrt[i]).length*18,0,0);
}
set_self(1081+i,21,(eqw_GameUI.Data.BalancePack[i][1].length-1)*eqw_Const.Balance.Dis+get_self(1069,21,0,0,0),0,0);
for(var j=0;j<eqw_GameUI.Data.BalancePack[i][1].length;j++){
//背景框
var fspid=1081+i;
var copyspid=1069+i;
var tag=eqw_Const.Balance.BG_Tag+j;
ifast_addtospritefromspritecopy(fspid,copyspid,eqw_Const.Balance.Location_bg[i][0],eqw_Const.Balance.Location_bg[i][1]+j*eqw_Const.Balance.Dis,tag);
switch(i){
case 0:
eqw_Data.Balance_bg_1.push(fspid+"add"+tag);
break;
case 1:
eqw_Data.Balance_bg_2.push(fspid+"add"+tag);
break;
case 2:
eqw_Data.Balance_bg_3.push(fspid+"add"+tag);
break;
}
//局数背景
var fspid=1081+i;
var copyspid=1072+i;
var tag=eqw_Const.Balance.SET_Tag+j;
ifast_addtospritefromspritecopy(fspid,copyspid,eqw_Const.Balance.Location_set[i][0],eqw_Const.Balance.Location_set[i][1]+j*eqw_Const.Balance.Dis,tag);
if(j>=10){
set_self(fspid+"add"+tag,1,1065,0,0);
set_self(fspid+"add"+tag,20,86,0,0);
}
switch(i){
case 0:
eqw_Data.Balance_set_1.push(fspid+"add"+tag);
break;
case 1:
eqw_Data.Balance_set_2.push(fspid+"add"+tag);
break;
case 2:
eqw_Data.Balance_set_3.push(fspid+"add"+tag);
break;
}
//局数数字
var fspid=1081+i;
var copyspid=1075+i;
var tag=eqw_Const.Balance.SETNUM_Tag+j;
ifast_addtospritefromspritecopy(fspid,copyspid,eqw_Const.Balance.Location_setnum[i][0],eqw_Const.Balance.Location_setnum[i][1]+j*eqw_Const.Balance.Dis,tag);
set_self(fspid+"add"+tag,7,j+1,0,0);
set_self(fspid+"add"+tag,20,String(j+1).length*17,0,0);
switch(i){
case 0:
eqw_Data.Balance_setnum_1.push(fspid+"add"+tag);
break;
case 1:
eqw_Data.Balance_setnum_2.push(fspid+"add"+tag);
break;
case 2:
eqw_Data.Balance_setnum_3.push(fspid+"add"+tag);
break;
}
//积分
var fspid=1081+i;
var copyspid=1078+i;
var tag=eqw_Const.Balance.GRADE_Tag+j;
ifast_addtospritefromspritecopy(fspid,copyspid,eqw_Const.Balance.Location_grade[i][0],eqw_Const.Balance.Location_grade[i][1]+j*eqw_Const.Balance.Dis,tag);
if(eqw_GameUI.Data.BalancePack[i][1][j]>=0){
set_self(fspid+"add"+tag,7,'b'+eqw_GameUI.Data.BalancePack[i][1][j],0,0);
set_self(fspid+"add"+tag,20,('b'+eqw_GameUI.Data.BalancePack[i][1][j]).length*17,0,0);
}else{
set_self(fspid+"add"+tag,7,'c'+Math.abs(eqw_GameUI.Data.BalancePack[i][1][j]),0,0);
set_self(fspid+"add"+tag,20,('c'+Math.abs(eqw_GameUI.Data.BalancePack[i][1][j])).length*17,0,0);
}
switch(i){
case 0:
eqw_Data.Balance_grade_1.push(fspid+"add"+tag);
break;
case 1:
eqw_Data.Balance_grade_2.push(fspid+"add"+tag);
break;
case 2:
eqw_Data.Balance_grade_3.push(fspid+"add"+tag);
break;
}
}
}
Utl.onGameFinished(inputArray);
}
eqw_GameUI.CloseBalance=function(){
set_group(213,37,0,0,0);
for(var i=0;i<eqw_GameUI.Data.BalancePack.length;i++){
for(var j=0;j<eqw_GameUI.Data.BalancePack[i][1].length;j++){
//背景框
var fspid=1081+i;
var tag=eqw_Const.Balance.BG_Tag+j;
ifast_dllpritefromspritecopy(fspid,tag);
//局数背景
var fspid=1081+i;
var tag=eqw_Const.Balance.SET_Tag+j;
ifast_dllpritefromspritecopy(fspid,tag);
//局数数字
var fspid=1081+i;
var tag=eqw_Const.Balance.SETNUM_Tag+j;
ifast_dllpritefromspritecopy(fspid,tag);
//积分
var fspid=1081+i;
var tag=eqw_Const.Balance.GRADE_Tag+j;
ifast_dllpritefromspritecopy(fspid,tag);
}
}
}
eqw_GameUI.ShowReady=function(seat){
set_self(1084+eqw_Logic.ChangeToStatus(seat),37,1,0,0);
}
eqw_GameUI.HideReady=function(seat){
set_self(1084+eqw_Logic.ChangeToStatus(seat),37,0,0,0);
}
eqw_GameUI.baozhu=function(seat,info){
var ind=eqw_Logic.ChangeToStatus(seat);
console.log("方位:"+ind+"\ninfo = "+info);
//set_self(1090+ind,37,1,0,0);
if(info[4][0]==0){
set_self(1093+ind,7,"无主",0,0);
if(ind==0){
set_self(1093,18,720-get_self(1093,7,0,0,0).gblen()*6,0,0);
}else{
set_self(1093+ind,18,get_self(346+ind,18,0,0,0)+get_self(346+ind,20,0,0,0)/2-get_self(1093+ind,7,0,0,0).gblen()*6,0,0);
}
}else{
set_self(1093+ind,7,info[4][0]+" 主 "+info[4][1]+" 对",0,0);
if(ind==0){
set_self(1093,18,720-get_self(1093,7,0,0,0).gblen()*5,0,0);
}else{
set_self(1093+ind,18,get_self(346+ind,18,0,0,0)+get_self(346+ind,20,0,0,0)/2-get_self(1093+ind,7,0,0,0).gblen()*5,0,0);
}
}
set_self(1093+ind,37,1,0,0);
}
eqw_GameUI.Hidebaozhu=function(){
for(var i=0;i<3;i++){
set_self(1093+i,37,0,0,0);
//set_self(1090+i,37,0,0,0);
}
}
eqw_GameUI.SetVideoData=function(){
var iind=0;
for(var i=0;i<CombatInfo.length;i++){
if(CombatInfo[i].idx==GameData.GradeIdx){
iind=i;
break;
}
}
for(var i=0;i<CombatInfo[iind].gameinfo1.players.length;i++){
if(CombatInfo[iind].gameinfo1.players[i].playerid==Utl.getMyPlayerid()){
C_Player.seat=CombatInfo[iind].gameinfo1.players[i].seat;
}
}
eqw_Desk.MainCard=CombatInfo_2[eqw_GameUI.Data.Video_Index].flower;
eqw_GameUI.Data.Video_Bottom=eqw_Logic.get_bottom_cards(CombatInfo_2[eqw_GameUI.Data.Video_Index].cards);
eqw_GameUI.Data.Video_Burry=eqw_Logic.get_bury_cards(CombatInfo_2[eqw_GameUI.Data.Video_Index].cards);
eqw_Desk.idx=eqw_GameUI.Data.Video_Index+1;
eqw_Desk.count=CombatInfo[iind].gameinfo1.asetcount;
eqw_Desk.BankerSeat=CombatInfo_2[eqw_GameUI.Data.Video_Index].banker;
eqw_Desk.Curgrade=0;
var push1=[];
var push2=[];
var push3=[];
var pindex1=-1;
var pindex2=-1;
var pindex3=-1;
var roundtemp=-1;
for(var i=0;i<CombatInfo_2[eqw_GameUI.Data.Video_Index].cards.length;i++){
if(CombatInfo_2[eqw_GameUI.Data.Video_Index].cards[i][5]>roundtemp){
roundtemp=CombatInfo_2[eqw_GameUI.Data.Video_Index].cards[i][5];
}
//if(CombatInfo_2[eqw_GameUI.Data.Video_Index].cards[i][6]>-1){
//roundtemp=CombatInfo_2[eqw_GameUI.Data.Video_Index].cards[i][5];
//eqw_GameUI.Data.Video_PushRound++;
//}
}
//if(roundtemp>0){//有出牌
//}
//eqw_GameUI.Data.Video_PushRound=roundtemp*3;
eqw_GameUI.Data.Video_PushList=[];
//if(eqw_GameUI.Data.Video_PushRound>0){//有出牌
if(roundtemp>0){//有出牌
var roundnum=1;
//while(roundnum<=eqw_GameUI.Data.Video_PushRound){
while(roundnum<=roundtemp){
for(var i=0;i<CombatInfo_2[eqw_GameUI.Data.Video_Index].cards.length;i++){
if(CombatInfo_2[eqw_GameUI.Data.Video_Index].cards[i][5]==roundnum){//当前轮出的牌
switch(CombatInfo_2[eqw_GameUI.Data.Video_Index].cards[i][6]){
case 1:
push1.push(CombatInfo_2[eqw_GameUI.Data.Video_Index].cards[i][0]);
pindex1=i;
break;
case 2:
push2.push(CombatInfo_2[eqw_GameUI.Data.Video_Index].cards[i][0]);
pindex2=i;
break;
case 3:
push3.push(CombatInfo_2[eqw_GameUI.Data.Video_Index].cards[i][0]);
pindex3=i;
break;
}
}
}
var a1=cls_youle_erqiwang_arith.order_cards(CombatInfo_2[eqw_GameUI.Data.Video_Index].flower, push1);
var a2=cls_youle_erqiwang_arith.order_cards(CombatInfo_2[eqw_GameUI.Data.Video_Index].flower, push2);
var a3=cls_youle_erqiwang_arith.order_cards(CombatInfo_2[eqw_GameUI.Data.Video_Index].flower, push3);
push1=[];
push2=[];
push3=[];
if(a1.length>0){
eqw_GameUI.Data.Video_PushRound++;
var data={};
if(CombatInfo_2[eqw_GameUI.Data.Video_Index].cards[pindex1][4]==0){
data.seat=eqw_Desk.BankerSeat;
}else{
data.seat=CombatInfo_2[eqw_GameUI.Data.Video_Index].cards[pindex1][4]-1;
}
//data.pushindex=1;
data.cards=a1;
eqw_GameUI.Data.Video_PushList.push(data);
}
if(a2.length>0){
eqw_GameUI.Data.Video_PushRound++;
var data={};
if(CombatInfo_2[eqw_GameUI.Data.Video_Index].cards[pindex2][4]==0){
data.seat=eqw_Desk.BankerSeat;
}else{
data.seat=CombatInfo_2[eqw_GameUI.Data.Video_Index].cards[pindex2][4]-1;
}
//data.pushindex=2;
data.cards=a2;
eqw_GameUI.Data.Video_PushList.push(data);
}
if(a3.length>0){
eqw_GameUI.Data.Video_PushRound++;
var data={};
if(CombatInfo_2[eqw_GameUI.Data.Video_Index].cards[pindex3][4]==0){
data.seat=eqw_Desk.BankerSeat;
}else{
data.seat=CombatInfo_2[eqw_GameUI.Data.Video_Index].cards[pindex3][4]-1;
}
//data.pushindex=3;
data.cards=a3;
data.maxseat=CombatInfo_2[eqw_GameUI.Data.Video_Index].cards[pindex3][7];
eqw_GameUI.Data.Video_PushList.push(data);
if(CombatInfo_2[eqw_GameUI.Data.Video_Index].cards[pindex3][7] != CombatInfo_2[eqw_GameUI.Data.Video_Index].banker){//闲家得分
var get_grade=0;
for(var i=eqw_GameUI.Data.Video_PushList.length-3;i<eqw_GameUI.Data.Video_PushList.length;i++){
var ind=eqw_Logic.ChangeToStatus(eqw_GameUI.Data.Video_PushList[i].seat);
switch(ind){
case 0:
//eqw_GameUI.Data.Grade1.length=eqw_GameUI.Data.Video_PushList[i].cards.length;
for(var j=0;j<eqw_GameUI.Data.Video_PushList[i].cards.length;j++){
var gd = cls_youle_erqiwang_arith.id_to_number(eqw_GameUI.Data.Video_PushList[i].cards[j]);
if(gd==5){
get_grade+=5;
//eqw_GameUI.Data.Grade1[j]=1;
//eqw_Desk.GradeList.push(eqw_GameUI.Data.Video_PushList[i].cards[j]);
}else if(gd==10||gd==13){
get_grade+=10;
//eqw_GameUI.Data.Grade1[j]=1;
//eqw_Desk.GradeList.push(eqw_GameUI.Data.Video_PushList[i].cards[j]);
}else{
//eqw_GameUI.Data.Grade1[j]=0;
}
}
break;
case 1:
//eqw_GameUI.Data.Grade2.length=eqw_GameUI.Data.Video_PushList[i].cards.length;
for(var j=0;j<eqw_GameUI.Data.Video_PushList[i].cards.length;j++){
var gd = cls_youle_erqiwang_arith.id_to_number(eqw_GameUI.Data.Video_PushList[i].cards[j]);
if(gd==5){
get_grade+=5;
//eqw_GameUI.Data.Grade2[j]=1;
//eqw_Desk.GradeList.push(eqw_GameUI.Data.Video_PushList[i].cards[j]);
}else if(gd==10||gd==13){
get_grade+=10;
//eqw_GameUI.Data.Grade2[j]=1;
//eqw_Desk.GradeList.push(eqw_GameUI.Data.Video_PushList[i].cards[j]);
}else{
//eqw_GameUI.Data.Grade2[j]=0;
}
}
break;
case 2:
//eqw_GameUI.Data.Grade3.length=eqw_GameUI.Data.Video_PushList[i].cards.length;
for(var j=0;j<eqw_GameUI.Data.Video_PushList[i].cards.length;j++){
var gd = cls_youle_erqiwang_arith.id_to_number(eqw_GameUI.Data.Video_PushList[i].cards[j]);
if(gd==5){
get_grade+=5;
//eqw_GameUI.Data.Grade3[j]=1;
//eqw_Desk.GradeList.push(eqw_GameUI.Data.Video_PushList[i].cards[j]);
}else if(gd==10||gd==13){
get_grade+=10;
//eqw_GameUI.Data.Grade3[j]=1;
//eqw_Desk.GradeList.push(eqw_GameUI.Data.Video_PushList[i].cards[j]);
}else{
//eqw_GameUI.Data.Grade3[j]=0;
}
}
break;
}
}
if(get_grade>0){
eqw_GameUI.Data.Video_PushList[eqw_GameUI.Data.Video_PushList.length-1].grade=get_grade;
}
}
}
roundnum++;
}
}
//eqw_GameUI.Data.Video_PushRound=eqw_GameUI.Data.Video_PushList.length;
}
eqw_GameUI.CloseVideo=function(){
if(eqw_GameUI.Data.Video_PlayState){
clearInterval(eqw_GameUI.Data.Video_TimerID);
}
eqw_GameUI.VideoInit();
Game_Modify.GoCombatPageTwo(eqw_GameUI.Data.Video_Index);
eqw_GameUI.VideoInit();
set_group(21,37,0,0,0);
set_group(43,37,0,0,0);
set_group(44,37,0,0,0);
set_group(45,37,0,0,0);
set_group(28,37,0,0,0);
set_group(21,37,0,0,0);
for(var i=201;i<=217;i++){
set_group(i,37,0,0,0);
}
}
eqw_GameUI.OpenVideo=function(){
//GameUI.invisible();
eqw_GameUI.Data.Video_PlayState=true;
eqw_GameUI.Data.Video_Step=0;
eqw_GameUI.Data.Video_CallStep=CombatInfo_2[eqw_GameUI.Data.Video_Index].callproc.length;
eqw_GameUI.Data.Video_TimerID = setInterval(eqw_GameUI.Video_Next,eqw_Const.Video.timer);
set_group(21,37,1,0,0);
//GameData.Battery=Func.getbattery();
//if(GameData.Battery<=0.2){
//set_self(371,43,3,0,0);
//}else{
//set_self(371,43,2,0,0);
//}
//GameData.NetWork=Func.getnetwork();
//if(GameData.NetWork==2){
//set_self(369,43,3,0,0);
//Func.getwifisignalLevel();
//}else{
//set_self(369,43,4,0,0);
//}
//if(GameData.OS==1){
//set_self(154,1,191,0,0);
//set_self(155,1,191,0,0);
//set_self(156,1,192,0,0);
//}else{
//set_self(154,1,69,0,0);
//set_self(155,1,69,0,0);
//set_self(156,1,70,0,0);
//}
GameData.Battery=Func.getbattery();
if(GameData.Battery<=0.2){
set_self(338,43,3,0,0);
}else{
set_self(338,43,2,0,0);
}
GameData.NetWork=Func.getnetwork();
if(GameData.NetWork==2){
set_self(336,43,3,0,0);
Func.getwifisignalLevel();
}else{
set_self(336,43,4,0,0);
}
if(GameData.OS == ConstVal.OS.apple){//苹果
set_self(154,1,174,0,0);
set_self(155,1,174,0,0);
set_self(156,1,173,0,0);
}else if(GameData.OS == ConstVal.OS.android){//安卓
set_self(154,1,69,0,0);
set_self(155,1,69,0,0);
set_self(156,1,70,0,0);
}
eqw_GameUI.ShowRound(eqw_Desk.idx,eqw_Desk.count);
set_self(151,37,0,0,0);
set_self(150,37,0,0,0);
set_self(152,37,0,0,0);
set_self(153,37,0,0,0);
set_self(1177,43,2,0,0);
var iind=0;
for(var i=0;i<CombatInfo.length;i++){
if(CombatInfo[i].idx==GameData.GradeIdx){
set_self(285,7,"房间号:"+CombatInfo[i].roomcode);
iind=i;
break;
}
}
for(var i=0;i<CombatInfo[iind].gameinfo1.players.length;i++){
var ind=Logic.ChangeToStatus(C_Player.seat,i);
var text=Func.subString(CombatInfo[iind].gameinfo1.players[i].name,Game_Config.Max.Mainnickname,true);
set_self(406+ind,7,text,0,0);
//var namepos = Func.subString(CombatInfo[iind].gameinfo1.players[i].name,Game_Config.Max.Mainnickname,true).gblen()*5;
//if(ind>0){
//set_self(406+ind,18,get_self(346+ind,18,0,0,0)+get_self(346+ind,20,0,0,0)/2-namepos,0,0);
//}else{
//set_self(406,18,700-namepos,0,0);
//}
if(ind==0){
if(Game_Config.Info.myPositionDefault){
set_self(406+ind,18,get_self(376+ind,18,0,0,0) + get_self(376+ind,20,0,0,0)/2 - text.gblen()*Game_Config.Info.textwidth_1/2,0,0);
}else{
set_self(406+ind,18,Game_Config.Info.myPosition - text.gblen()*Game_Config.Info.textwidth_1/2,0,0);
}
}else{
if(Game_Config.Info.otherPositionDefault){
set_self(406+ind,18,get_self(376+ind,18,0,0,0) + get_self(376+ind,20,0,0,0)/2 - text.gblen()*Game_Config.Info.textwidth_1/2,0,0);
}else{
set_self(406+ind,18,Game_Config.Info.position[ind-1] - text.gblen()*Game_Config.Info.textwidth_1/2,0,0);
}
}
//if(ind==0){
//set_self(176,18,get_self(288,18,0,0,0)-30,0,0);
//}else{
//set_self(176+ind,18,get_self(288+ind,18,0,0,0)+get_self(288+ind,20,0,0,0)/2-5,0,0);
//}
Func.up_imgurl(116+ind,CombatInfo[iind].gameinfo1.players[i].avatar);
set_group(43+ind,37,1,0,0);
set_self(436+ind,37,0,0,0);
set_self(176,37,0,0,0);
set_self(177,37,0,0,0);
set_self(178,37,0,0,0);
set_self(291,37,0,0,0);
set_self(294,37,0,0,0);
}
for(var i=0;i<3;i++){
var pobj=eqw_Desk.GetPlayerBySeat(i);
pobj.SetHandCards(eqw_Logic.get_seat_cards_deal(CombatInfo_2[eqw_GameUI.Data.Video_Index].cards,i));
eqw_GameUI.Video_SetCards(i,pobj.HandCards);
}
set_group(216,37,1,0,0);
eqw_GameUI.Video_ShowBottom(eqw_GameUI.Data.Video_Bottom);
}
//显示玩家头像栏
//eqw_GameUI.Video_ShowPlayer=function(){
//for(var i=0;i<CombatInfo.players.length;i++){
//var ind=eqw_Logic.ChangeToStatus(i);
//Func.up_imgurl(116+ind,CombatInfo.players[i].avatar);//玩家头像
//}
//}
//设置玩家自己手牌
eqw_GameUI.Video_SetMyCards=function(CardList){
set_group(204,37,0,0,0);
var len=CardList.length;
var w = (len-1)*eqw_Const.Video.MyCardsDis+eqw_Const.Card.oriwidth;
var x = 640-w/2;
for(var i=0;i<len;i++){
set_self(705+i,18,x+eqw_Const.Video.MyCardsDis*i,0,0);
set_self(705+i,19,eqw_Const.Video.MyCards_y,0,0);
set_self(705+i,33,eqw_Const.Video.MyCardsScale,0,0);
}
for(var i=0;i<len;i++){
set_self(705+i,43,CardList[i]%54+1,0,0);
set_self(705+i,37,1,0,0);
}
}
//设置下家牌
eqw_GameUI.Video_SetDownCards=function(CardList){
set_group(214,37,0,0,0);
for(var i=0;i<CardList.length;i++){
set_self(1096+i,43,CardList[i]%54+1,0,0);
set_self(1096+i,37,1,0,0);
}
}
//设置上家牌
eqw_GameUI.Video_SetUpCards=function(CardList){
set_group(215,37,0,0,0);
for(var i=0;i<CardList.length;i++){
set_self(1136+i,43,CardList[i]%54+1,0,0);
set_self(1136+i,37,1,0,0);
}
}
//设置玩家手牌
eqw_GameUI.Video_SetCards=function(seat,CardList){
var ind=eqw_Logic.ChangeToStatus(seat);
switch(ind){
case 0:
eqw_GameUI.Video_SetMyCards(CardList);
break;
case 1:
eqw_GameUI.Video_SetDownCards(CardList);
break;
case 2:
eqw_GameUI.Video_SetUpCards(CardList);
break;
}
}
//自己出牌(500)
eqw_GameUI.Video_MyPush=function(CardList){
var len=CardList.length;
var w=(len-1)*eqw_Const.Video.pushdis+eqw_Const.Video.oriwidth;
var x=eqw_Const.Video.pushlocation[0][0]-w/2;
for(var i=0;i<len;i++){
set_self(740-len+1+i,43,CardList[i]%54+1,0,0);
set_self(740-len+1+i,33,eqw_Const.Video.pushscale,0,0);
set_self(740-len+1+i,18,x+eqw_Const.Video.pushdis*i,0,0);
set_self(740-len+1+i,19,eqw_Const.Video.pushlocation[0][1],0,0);
set_self(740-len+1+i,37,1,0,0);
play_ani(1,740-len+1+i,19,eqw_Const.Video.pushlocation[0][1],eqw_Const.Video.pushlocation_f[0][1],0,300,0,200,0,1,0,0);
}
}
//下家出牌
eqw_GameUI.Video_DownPush=function(CardList){
var len=CardList.length;
var w=(len-1)*eqw_Const.Video.pushdis+eqw_Const.Video.oriwidth;
var x=eqw_Const.Video.pushlocation[1][0]-w/2;
var xf=eqw_Const.Video.pushlocation_f[1][0]-w/2;
for(var i=0;i<len;i++){
set_self(827+i,43,CardList[i]%54+1,0,0);
set_self(827+i,33,eqw_Const.Video.pushscale,0,0);
set_self(827+i,18,x+eqw_Const.Video.pushdis*i,0,0);
set_self(827+i,19,eqw_Const.Video.pushlocation[1][1],0,0);
set_self(827+i,37,1,0,0);
play_ani(1,827+i,18,get_self(827+i,18,0,0,0),xf+i*eqw_Const.Video.pushdis,0,300,0,200,0,1,0,0);
play_ani(1,827+i,19,get_self(827+i,19,0,0,0),eqw_Const.Video.pushlocation_f[1][1],0,300,0,200,0,1,0,0);
}
}
//上家出牌
eqw_GameUI.Video_UpPush=function(CardList){
var len=CardList.length;
var w=(len-1)*eqw_Const.Video.pushdis+eqw_Const.Video.oriwidth;
var x=eqw_Const.Video.pushlocation[2][0]-w/2;
var xf=eqw_Const.Video.pushlocation_f[2][0]-w/2;
for(var i=0;i<len;i++){
set_self(841+i,43,CardList[i]%54+1,0,0);
set_self(841+i,33,eqw_Const.Video.pushscale,0,0);
set_self(841+i,18,x+eqw_Const.Video.pushdis*i,0,0);
set_self(841+i,19,eqw_Const.Video.pushlocation[2][1],0,0);
set_self(841+i,37,1,0,0);
play_ani(1,841+i,18,get_self(841+i,18,0,0,0),xf+i*eqw_Const.Video.pushdis,0,300,0,200,0,1,0,0);
play_ani(1,841+i,19,get_self(841+i,19,0,0,0),eqw_Const.Video.pushlocation_f[2][1],0,300,0,200,0,1,0,0);
}
}
eqw_GameUI.video_PushCards=function(seat,CardList){
var ind=eqw_Logic.ChangeToStatus(seat);
switch(ind){
case 0:
eqw_GameUI.Video_MyPush(CardList);
break;
case 1:
eqw_GameUI.Video_DownPush(CardList);
break;
case 2:
eqw_GameUI.Video_UpPush(CardList);
break;
}
}
eqw_GameUI.Video_shangzhuang=function(){
set_group(205,37,0,0,0);
var ind=eqw_Logic.ChangeToStatus(eqw_Desk.BankerSeat);
set_self(787,18,590,0,0);
set_self(787,19,270,0,0);
set_self(787,37,1,0,0);
switch(ind){
case 0:
play_ani(1,787,18,590,get_self(346+ind,18,0,0,0)-26,0,800,0,0,0,1,0,0);
play_ani(1,787,19,270,get_self(346+ind,19,0,0,0)-17,0,800,0,0,0,1,0,0);
setTimeout("play_ani(1,787,33,100,130,0,500,0,0,0,1,0,0)",800);
//play_ani(1,787,33,130,100,0,500,0,0,0,1,0,0);
setTimeout("play_ani(1,787,33,130,100,0,500,0,0,0,1,0,0)",1200);
for(var i=0;i<8;i++){
set_self(773+i,37,0,0,0);
}
setTimeout(function(){
//set_self(787,37,0,0,0);
eqw_GameUI.Data.Bankerspid=166+ind;
set_self(794,37,1,0,0);
var pobj=eqw_Desk.GetPlayerBySeat(eqw_Desk.BankerSeat);
pobj.SetHandCards(eqw_Logic.get_seat_cards_owner(CombatInfo_2[eqw_GameUI.Data.Video_Index].cards,eqw_Desk.BankerSeat));
eqw_GameUI.Video_SetMyCards(pobj.HandCards);
//eqw_GameUI.ShowChoseMainBoard();
//eqw_GameUI.OpenCountDown(eqw_Desk.BankerSeat);
},1700);
break;
case 1:
play_ani(1,787,18,590,get_self(346+ind,18,0,0,0)-26,0,800,0,0,0,1,0,0);
play_ani(1,787,19,270,get_self(346+ind,19,0,0,0)-17,0,800,0,0,0,1,0,0);
setTimeout("play_ani(1,787,33,100,130,0,500,0,0,0,1,0,0)",800);
//play_ani(1,787,33,130,100,0,500,0,0,0,1,0,0);
setTimeout("play_ani(1,787,33,130,100,0,500,0,0,0,1,0,0)",1200);
//var w=7*eqw_Const.Bottom.Dis+eqw_Const.Card.oriwidth*eqw_Const.Card.deskscale/100;
var w=7*eqw_Const.Bottom.Dis+eqw_Const.Card.oriwidth;
var x=640-w/2;
//var mid=640-eqw_Const.Card.oriwidth*eqw_Const.Card.deskscale/200;
var mid=640-eqw_Const.Card.oriwidth/2;
for(var i=0;i<8;i++){
set_self(773+i,37,1,0,0);
set_self(773+i,33,eqw_Const.Card.deskscale,0,0);
set_self(773+i,35,255,0,0);
set_self(773+i,19,eqw_Const.Bottom.Location[1],0,0);
set_self(773+i,18,mid,0,0);
set_self(773+i,43,eqw_Desk.bottomcards[i]%54+1,0,0);
}
for(var i=0;i<8;i++){
//set_self(773+i,18,x+eqw_Const.Bottom.Dis*i,0);
play_ani(1,773+i,18,mid,x+eqw_Const.Bottom.Dis*i,0,500,0,0,0,1,0,0);
}
setTimeout(function(){
//set_self(787,37,0,0,0);
eqw_GameUI.Data.Bankerspid=166+ind;
set_self(794,37,1,0,0);
var pobj=eqw_Desk.GetPlayerBySeat(eqw_Desk.BankerSeat);
pobj.SetHandCards(eqw_Logic.get_seat_cards_owner(CombatInfo_2[eqw_GameUI.Data.Video_Index].cards,eqw_Desk.BankerSeat));
eqw_GameUI.Video_SetDownCards(pobj.HandCards);
//eqw_GameUI.ShowChoseMainBoard();
//eqw_GameUI.OpenCountDown(eqw_Desk.BankerSeat);
},1700);
break;
case 2:
play_ani(1,787,18,590,get_self(346+ind,18,0,0,0)-26,0,800,0,0,0,1,0,0);
play_ani(1,787,19,270,get_self(346+ind,19,0,0,0)-17,0,800,0,0,0,1,0,0);
setTimeout("play_ani(1,787,33,100,130,0,500,0,0,0,1,0,0)",800);
//play_ani(1,787,33,130,100,0,500,0,0,0,1,0,0);
setTimeout("play_ani(1,787,33,130,100,0,500,0,0,0,1,0,0)",1200);
//var w=7*eqw_Const.Bottom.Dis+eqw_Const.Card.oriwidth*eqw_Const.Card.deskscale/100;
var w=7*eqw_Const.Bottom.Dis+eqw_Const.Card.oriwidth;
var x=640-w/2;
//var mid=640-eqw_Const.Card.oriwidth*eqw_Const.Card.deskscale/200;
var mid=640-eqw_Const.Card.oriwidth/2;
for(var i=0;i<8;i++){
set_self(773+i,37,1,0,0);
set_self(773+i,33,eqw_Const.Card.deskscale,0,0);
set_self(773+i,35,255,0,0);
set_self(773+i,19,eqw_Const.Bottom.Location[1],0,0);
set_self(773+i,18,mid,0,0);
set_self(773+i,43,eqw_Desk.bottomcards[i]%54+1,0,0);
}
for(var i=0;i<8;i++){
//set_self(773+i,18,x+eqw_Const.Bottom.Dis*i,0);
play_ani(1,773+i,18,mid,x+eqw_Const.Bottom.Dis*i,0,500,0,0,0,1,0,0);
}
setTimeout(function(){
//set_self(787,37,0,0,0);
eqw_GameUI.Data.Bankerspid=166+ind;
//eqw_GameUI.ShowChoseMainBoard();
set_self(794,37,1,0,0);
var pobj=eqw_Desk.GetPlayerBySeat(eqw_Desk.BankerSeat);
pobj.SetHandCards(eqw_Logic.get_seat_cards_owner(CombatInfo_2[eqw_GameUI.Data.Video_Index].cards,eqw_Desk.BankerSeat));
eqw_GameUI.Video_SetUpCards(pobj.HandCards);
//eqw_GameUI.OpenCountDown(eqw_Desk.BankerSeat);
},1700);
break;
}
}
//(1000)
eqw_GameUI.Video_ChoseMainEffct=function(ind){
ind=ind-1;
set_self(790+ind,18,eqw_Const.Main.Location_2[0],0,0);
set_self(790+ind,19,eqw_Const.Main.Location_2[1],0,0);
set_self(790+ind,37,1,0,0);
setTimeout(function(){
play_ani(1,790+ind,18,eqw_Const.Main.Location_2[0],1000,0,300,0,0,0,1,0,0);
play_ani(1,790+ind,19,eqw_Const.Main.Location_2[1],-30,0,300,0,0,0,1,0,0);
play_ani(1,790+ind,33,100,45,0,500,0,0,0,1,0,0);
setTimeout(function(){
eqw_GameUI.Data.Main=ind+1;
set_self(790+ind,37,0,0,0);
set_self(794,37,0,0,0);
set_self(795,37,1,0,0);
},500);
},200);
}
eqw_GameUI.Video_Next=function(){
//console.log("Video_Next:"+eqw_GameUI.Data.Video_Step);
if(eqw_GameUI.Data.Video_Step<eqw_GameUI.Data.Video_CallStep){//处于叫分阶段
eqw_GameUI.ShowCall(CombatInfo_2[eqw_GameUI.Data.Video_Index].callproc[eqw_GameUI.Data.Video_Step].seat,CombatInfo_2[eqw_GameUI.Data.Video_Index].callproc[eqw_GameUI.Data.Video_Step].call);
if(eqw_GameUI.Data.Video_Step==eqw_GameUI.Data.Video_CallStep-1){//上庄动画
if(eqw_Desk.BankerSeat>-1){
eqw_GameUI.HideCall();
eqw_Desk.Callgrade=CombatInfo_2[eqw_GameUI.Data.Video_Index].call;
eqw_Desk.Multi = cls_youle_erqiwang_arith.get_multiple_bycall(eqw_Desk.Callgrade);
eqw_GameUI.Video_shangzhuang();
eqw_GameUI.ShowMulti();
eqw_GameUI.ShowFlowerInfo();
}else{
eqw_GameUI.Video_End();
}
}
}else if(eqw_GameUI.Data.Video_Step==eqw_GameUI.Data.Video_CallStep){//选主
if(eqw_Desk.MainCard>0){
eqw_GameUI.Video_ChoseMainEffct(eqw_Desk.MainCard);
}else{
eqw_GameUI.Video_End();
}
}else if(eqw_GameUI.Data.Video_Step==eqw_GameUI.Data.Video_CallStep+1){
eqw_GameUI.Video_maipai(eqw_GameUI.Data.Video_Burry);
}else if(eqw_GameUI.Data.Video_Step>eqw_GameUI.Data.Video_CallStep+1&&eqw_GameUI.Data.Video_Step<=eqw_GameUI.Data.Video_PushRound+eqw_GameUI.Data.Video_CallStep+1){//出牌阶段
//if(eqw_GameUI.Data.Video_PushList[eqw_GameUI.Data.Video_Step-eqw_GameUI.Data.Video_CallStep-1].pushindex==1){//第一轮出牌
//}
var pobj=eqw_Desk.GetPlayerBySeat(eqw_GameUI.Data.Video_PushList[eqw_GameUI.Data.Video_Step-eqw_GameUI.Data.Video_CallStep-2].seat);
pobj.PushCards(eqw_GameUI.Data.Video_PushList[eqw_GameUI.Data.Video_Step-eqw_GameUI.Data.Video_CallStep-2].cards);
eqw_GameUI.Video_SetCards(pobj.seat,pobj.HandCards);
eqw_GameUI.video_PushCards(pobj.seat,eqw_GameUI.Data.Video_PushList[eqw_GameUI.Data.Video_Step-eqw_GameUI.Data.Video_CallStep-2].cards);
eqw_Desk.Call_Run.CardList[pobj.seat]=eqw_GameUI.Data.Video_PushList[eqw_GameUI.Data.Video_Step-eqw_GameUI.Data.Video_CallStep-2].cards;
if(typeof(eqw_GameUI.Data.Video_PushList[eqw_GameUI.Data.Video_Step-eqw_GameUI.Data.Video_CallStep-2].maxseat)!="undefined"){//最后一家出牌
eqw_GameUI.Data.Video_MaxSeatbTemp=false;
if(eqw_GameUI.Data.Video_PushList[eqw_GameUI.Data.Video_Step-eqw_GameUI.Data.Video_CallStep-2].maxseat==eqw_GameUI.Data.Video_PushList[eqw_GameUI.Data.Video_Step-eqw_GameUI.Data.Video_CallStep-2].seat){
eqw_GameUI.Data.Video_MaxSeatbTemp=true;
}
eqw_GameUI.Data.Video_MaxSeat=eqw_GameUI.Data.Video_PushList[eqw_GameUI.Data.Video_Step-eqw_GameUI.Data.Video_CallStep-2].maxseat;
eqw_GameUI.Data.Video_MaxSeatLen=eqw_GameUI.Data.Video_PushList[eqw_GameUI.Data.Video_Step-eqw_GameUI.Data.Video_CallStep-2].cards.length;
//setTimeout("eqw_GameUI.Video_ShowMaxSeat(eqw_GameUI.Data.Video_MaxSeat,eqw_GameUI.Data.Video_MaxSeatbTemp,eqw_GameUI.Data.Video_MaxSeatLen)",500);
//setTimeout(function(){
eqw_GameUI.Video_ShowMaxSeat(eqw_GameUI.Data.Video_MaxSeat,eqw_GameUI.Data.Video_MaxSeatbTemp,eqw_GameUI.Data.Video_MaxSeatLen);
//if(typeof(eqw_GameUI.Data.Video_PushList[eqw_GameUI.Data.Video_Step-eqw_GameUI.Data.Video_CallStep-2].grade)!="undefined"){
//setTimeout("eqw_GameUI.Video_ShowGrade(eqw_GameUI.Data.GetGrade)",400);
//}
//},500);
if(typeof(eqw_GameUI.Data.Video_PushList[eqw_GameUI.Data.Video_Step-eqw_GameUI.Data.Video_CallStep-2].grade)!="undefined"){//闲家有得分
eqw_GameUI.Data.GetGrade=eqw_GameUI.Data.Video_PushList[eqw_GameUI.Data.Video_Step-eqw_GameUI.Data.Video_CallStep-2].grade;
eqw_Desk.Curgrade+=eqw_GameUI.Data.GetGrade;
for(var i=eqw_GameUI.Data.Video_Step-eqw_GameUI.Data.Video_CallStep-4;i<=eqw_GameUI.Data.Video_Step-eqw_GameUI.Data.Video_CallStep-2;i++){
//eqw_Desk.Call_Run.CardList[eqw_GameUI.Data.Video_PushList[i].seat] = eqw_GameUI.Data.Video_PushList[i].cards;
var ind=eqw_Logic.ChangeToStatus(eqw_GameUI.Data.Video_PushList[i].seat);
switch(ind){
case 0:
eqw_GameUI.Data.Grade1.length=eqw_GameUI.Data.Video_PushList[i].cards.length;
for(var j=0;j<eqw_GameUI.Data.Video_PushList[i].cards.length;j++){
var gd = cls_youle_erqiwang_arith.id_to_number(eqw_GameUI.Data.Video_PushList[i].cards[j]);
if(gd==5){
eqw_GameUI.Data.Grade1[j]=1;
eqw_Desk.GradeList.push(eqw_GameUI.Data.Video_PushList[i].cards[j]);
}else if(gd==10||gd==13){
eqw_GameUI.Data.Grade1[j]=1;
eqw_Desk.GradeList.push(eqw_GameUI.Data.Video_PushList[i].cards[j]);
}else{
eqw_GameUI.Data.Grade1[j]=0;
}
}
break;
case 1:
eqw_GameUI.Data.Grade2.length=eqw_GameUI.Data.Video_PushList[i].cards.length;
for(var j=0;j<eqw_GameUI.Data.Video_PushList[i].cards.length;j++){
var gd = cls_youle_erqiwang_arith.id_to_number(eqw_GameUI.Data.Video_PushList[i].cards[j]);
if(gd==5){
eqw_GameUI.Data.Grade2[j]=1;
eqw_Desk.GradeList.push(eqw_GameUI.Data.Video_PushList[i].cards[j]);
}else if(gd==10||gd==13){
eqw_GameUI.Data.Grade2[j]=1;
eqw_Desk.GradeList.push(eqw_GameUI.Data.Video_PushList[i].cards[j]);
}else{
eqw_GameUI.Data.Grade2[j]=0;
}
}
break;
case 2:
eqw_GameUI.Data.Grade3.length=eqw_GameUI.Data.Video_PushList[i].cards.length;
for(var j=0;j<eqw_GameUI.Data.Video_PushList[i].cards.length;j++){
var gd = cls_youle_erqiwang_arith.id_to_number(eqw_GameUI.Data.Video_PushList[i].cards[j]);
if(gd==5){
eqw_GameUI.Data.Grade3[j]=1;
eqw_Desk.GradeList.push(eqw_GameUI.Data.Video_PushList[i].cards[j]);
}else if(gd==10||gd==13){
eqw_GameUI.Data.Grade3[j]=1;
eqw_Desk.GradeList.push(eqw_GameUI.Data.Video_PushList[i].cards[j]);
}else{
eqw_GameUI.Data.Grade3[j]=0;
}
}
break;
}
}
setTimeout(function(){eqw_GameUI.Video_ShowGrade(eqw_GameUI.Data.GetGrade);},900);
//setTimeout("eqw_GameUI.HideCards()",800);
}else{
setTimeout(function(){eqw_GameUI.Video_HideCards(eqw_Desk.Call_Run.CardList)},1000);
}
//
}
}else{
eqw_GameUI.Video_End();
}
eqw_GameUI.Data.Video_Step++;
}
eqw_GameUI.Video_End=function(){//录像播放完毕
//eqw_GameUI.Data.Video_Timer=true;
//alert("播放完毕");
eqw_GameUI.CloseVideo();
}
//function Video_Timer(time)
//{
//if(eqw_GameUI.Data.Video_Timer) return;
//eqw_GameUI.Video_Next();
//var timeid=setTimeout(Video_Timer,time); //
//console.log("timeid="+timeid);
//}
//得分特效(1300)
eqw_GameUI.Video_ShowGrade=function(grade){
//console.log("Grade1:"+eqw_GameUI.Data.Grade1);
//console.log("Grade2:"+eqw_GameUI.Data.Grade2);
//console.log("Grade3:"+eqw_GameUI.Data.Grade3);
set_self(1039,37,0,0,0);
eqw_GameUI.Video_HideCards(eqw_Desk.Call_Run.CardList);
var len=eqw_GameUI.Data.Grade1.length;
for(var i=0;i<eqw_GameUI.Data.Grade1.length;i++){
if(eqw_GameUI.Data.Grade1[i]==0){
set_self(740-len+1+i,37,0,0,0);
}else{
play_ani(1,740-len+1+i,19,get_self(740-len+1+i,19,0,0,0),get_self(1179,19,0,0,0)-51,0,300,0,0,0,1,0,0);
play_ani(1,740-len+1+i,18,get_self(740-len+1+i,18,0,0,0),eqw_Const.Bottom.Location[0]-get_self(740-len+1+i,20,0,0,0)/2,0,300,0,0,0,1,0,0);
}
}
for(var i=0;i<eqw_GameUI.Data.Grade2.length;i++){
if(eqw_GameUI.Data.Grade2[i]==0){
set_self(827+i,37,0,0,0);
}else{
play_ani(1,827+i,19,get_self(827+i,19,0,0,0),get_self(1179,19,0,0,0)-51,0,300,0,0,0,1,0,0);
play_ani(1,827+i,18,get_self(827+i,18,0,0,0),eqw_Const.Bottom.Location[0]-get_self(827+i,20,0,0,0)/2,0,300,0,0,0,1,0,0);
}
}
for(var i=0;i<eqw_GameUI.Data.Grade3.length;i++){
if(eqw_GameUI.Data.Grade3[i]==0){
set_self(841+i,37,0,0,0);
}else{
play_ani(1,841+i,19,get_self(841+i,19,0,0,0),get_self(1179,19,0,0,0)-51,0,300,0,0,0,1,0,0);
play_ani(1,841+i,18,get_self(841+i,18,0,0,0),eqw_Const.Bottom.Location[0]-get_self(841+i,20,0,0,0)/2,0,300,0,0,0,1,0,0);
}
}
setTimeout(function(){
set_self(1219,7,grade,0,0);
set_self(1219,20,String(grade).length*21,0,0);
set_self(1219,18,617,0,0);
set_self(1219,19,190,0,0);
set_self(1219,37,1,0,0);
play_ani(1,1219,18,617,1205,0,500,0,0,0,1,0,0);
play_ani(1,1219,19,190,11,0,500,0,0,0,1,0,0);
setTimeout(function(){
set_self(1219,37,0,0,0);
set_self(799,7,eqw_Desk.Curgrade,0,0);
set_self(799,20,String(eqw_Desk.Curgrade).length*22,0,0);
eqw_GameUI.Video_ShowGradeCards();
},500);
//eqw_GameUI.HideCards();
},300);
}
//显示哪家牌大(300)
eqw_GameUI.Video_ShowMaxSeat=function(seat,bTemp,len){
var ind=eqw_Logic.ChangeToStatus(seat);
switch(ind){
case 0:
//var len=eqw_Desk.Call_Run.CardList[seat].length;
if(bTemp){
setTimeout(
function(){
set_self(1039,18,get_self(740,18,0,0,0)-eqw_Const.Card.oriwidth*eqw_Const.Card.pushscale/200-40+eqw_Const.Card.oriwidth,0,0);
set_self(1039,19,get_self(740,19,0,0,0)+eqw_Const.Card.oriheight*eqw_Const.Card.pushscale/200,0,0);
set_self(1039,33,50,0,0);
set_self(1039,37,1,0,0);
play_ani(1,1039,33,50,100,0,300,0,0,0,1,0,0);
play_ani(1,1039,34,0,360,0,300,0,0,0,1,0,0);
},700);
}else{
setTimeout(
function(){
set_self(1039,18,get_self(740,18,0,0,0)-eqw_Const.Card.oriwidth*eqw_Const.Card.pushscale/200-40+eqw_Const.Card.oriwidth,0,0);
set_self(1039,19,get_self(740,19,0,0,0)+eqw_Const.Card.oriheight*eqw_Const.Card.pushscale/200,0,0);
set_self(1039,33,50,0,0);
set_self(1039,37,1,0,0);
play_ani(1,1039,33,50,100,0,300,0,0,0,1,0,0);
play_ani(1,1039,34,0,360,0,300,0,0,0,1,0,0);
},200);
}
break;
case 1:
//var len=eqw_Desk.Call_Run.CardList[seat].length;
if(bTemp){
setTimeout(
function(){
set_self(1039,18,get_self(827+len-1,18,0,0,0)-eqw_Const.Card.oriwidth*eqw_Const.Card.pushscale/200-40+eqw_Const.Card.oriwidth,0,0);
set_self(1039,19,get_self(827+len-1,19,0,0,0)+eqw_Const.Card.oriheight*eqw_Const.Card.pushscale/200,0,0);
set_self(1039,33,50,0,0);
set_self(1039,37,1,0,0);
play_ani(1,1039,33,50,100,0,300,0,0,0,1,0,0);
play_ani(1,1039,34,0,360,0,300,0,0,0,1,0,0);
},700);
}else{
setTimeout(
function(){
set_self(1039,18,get_self(827+len-1,18,0,0,0)-eqw_Const.Card.oriwidth*eqw_Const.Card.pushscale/200-40+eqw_Const.Card.oriwidth,0,0);
set_self(1039,19,get_self(827+len-1,19,0,0,0)+eqw_Const.Card.oriheight*eqw_Const.Card.pushscale/200,0,0);
set_self(1039,33,50,0,0);
set_self(1039,37,1,0,0);
play_ani(1,1039,33,50,100,0,300,0,0,0,1,0,0);
play_ani(1,1039,34,0,360,0,300,0,0,0,1,0,0);
},200);
}
break;
case 2:
//var len=eqw_Desk.Call_Run.CardList[seat].length;
if(bTemp){
setTimeout(
function(){
set_self(1039,18,get_self(841+len-1,18,0,0,0)-eqw_Const.Card.oriwidth*eqw_Const.Card.pushscale/200-40+eqw_Const.Card.oriwidth,0,0);
set_self(1039,19,get_self(841+len-1,19,0,0,0)+eqw_Const.Card.oriheight*eqw_Const.Card.pushscale/200,0,0);
set_self(1039,33,50,0,0);
set_self(1039,37,1,0,0);
play_ani(1,1039,33,50,100,0,500,0,0,0,1,0,0);
play_ani(1,1039,34,0,360,0,500,0,0,0,1,0,0);
},700);
}else{
setTimeout(
function(){
set_self(1039,18,get_self(841+len-1,18,0,0,0)-eqw_Const.Card.oriwidth*eqw_Const.Card.pushscale/200-40+eqw_Const.Card.oriwidth,0,0);
set_self(1039,19,get_self(841+len-1,19,0,0,0)+eqw_Const.Card.oriheight*eqw_Const.Card.pushscale/200,0,0);
set_self(1039,33,50,0,0);
set_self(1039,37,1,0,0);
play_ani(1,1039,33,50,100,0,500,0,0,0,1,0,0);
play_ani(1,1039,34,0,360,0,500,0,0,0,1,0,0);
},200);
}
break;
}
}
eqw_GameUI.Video_ShowBottom=function(CardList){
for(var i=0;i<CardList.length;i++){
set_self(1203+i,43,CardList[i]%54+1,0,0);
set_self(1203+i,37,1,0,0);
}
}
eqw_GameUI.Video_ShowGradeCards=function(){
set_group(217,37,1,0,0);
for(var i=0;i<eqw_Desk.GradeList.length;i++){
set_self(1179+i,43,eqw_Desk.GradeList[i]%54+1,0,0);
}
for(i=eqw_Desk.GradeList.length;i<24;i++){
set_self(1179+i,37,0,0,0);
}
}
//埋牌动画
eqw_GameUI.Video_maipai=function(CardList){
//C_Player.seat=2;
//eqw_Desk.BankerSeat=0;
//set_self(860,37,1,0,0);
//set_self(860,18,eqw_Const.Bottom.Location[0]-get_self(860,20,0,0,0)/2,0,0);
//set_self(860,19,eqw_Const.Bottom.Location[1],0,0,0);
//set_self(860,33,eqw_Const.Card.deskscale,0,0);
var ind=eqw_Logic.ChangeToStatus(eqw_Desk.BankerSeat);
//eqw_GameUI.HideMaiPai();
switch(ind){
case 0:
var pobj=eqw_Desk.GetPlayerBySeat(eqw_Desk.BankerSeat);
pobj.PushCards(eqw_GameUI.Data.Video_Burry);
eqw_GameUI.Video_SetMyCards(pobj.HandCards);
var w=7*eqw_Const.Card.pushdis+eqw_Const.Card.oriwidth*eqw_Const.Card.pushscale/100;
var x=eqw_Const.Card.pushlocation[0][0]-w/2;
for(var i=0;i<8;i++){
set_self(773+i,19,eqw_Const.Card.pushlocation[0][1],0,0);
set_self(773+i,18,x+i*eqw_Const.Card.pushdis,0,0);
set_self(773+i,18,x+i*eqw_Const.Card.pushdis,0,0);
set_self(773+i,33,eqw_Const.Card.pushscale,0,0);
set_self(773+i,43,CardList[i]%54+1,0,0);
set_self(773+i,35,255,0,0);
}
//eqw_GameUI.SetMyCards();
for(var i=0;i<8;i++){
set_self(773+i,37,1,0,0);
play_ani(1,773+i,18,get_self(773+i,18,0,0,0),eqw_Const.Bottom.Location[0]-get_self(773+i,20,0,0,0)/2,0,500,0,200,0,1,0,0);
play_ani(1,773+i,19,get_self(773+i,19,0,0,0),get_self(1203,19,0,0,0),0,500,0,200,0,1,0,0);
}
setTimeout(function(){
for(var i=0;i<8;i++){
set_self(773+i,37,0,0,0);
}
eqw_GameUI.Video_ShowBottom(eqw_GameUI.Data.Video_Burry);
set_self(795,37,0,0,0);
},500);
break;
case 1:
var pobj=eqw_Desk.GetPlayerBySeat(eqw_Desk.BankerSeat);
pobj.PushCards(eqw_GameUI.Data.Video_Burry);
eqw_GameUI.Video_SetDownCards(pobj.HandCards);
var w=7*eqw_Const.Card.pushdis+eqw_Const.Card.oriwidth*eqw_Const.Card.pushscale/100;
var x=eqw_Const.Card.pushlocation[ind][0]-w/2;
for(var i=0;i<8;i++){
set_self(773+i,37,0,0,0);
set_self(773+i,43,55,0,0);
set_self(773+i,35,255,0,0);
set_self(773+i,43,CardList[i]%54+1,0,0);
}
for(var i=0;i<8;i++){
set_self(773+i,19,eqw_Const.Card.pushlocation[ind][1],0,0);
set_self(773+i,18,x+i*eqw_Const.Card.pushdis,0,0);
set_self(773+i,33,eqw_Const.Card.pushscale,0,0);
}
//eqw_GameUI.SetMyCards();
for(var i=0;i<8;i++){
set_self(773+i,37,1,0,0);
play_ani(1,773+i,18,get_self(773+i,18,0,0,0),eqw_Const.Bottom.Location[0]-get_self(773+i,20,0,0,0)/2,0,500,0,0,0,1,0,0);
play_ani(1,773+i,19,get_self(773+i,19,0,0,0),get_self(1203,19,0,0,0),0,500,0,0,0,1,0,0);
}
setTimeout(function(){
for(var i=0;i<8;i++){
set_self(773+i,37,0,0,0);
}
eqw_GameUI.Video_ShowBottom(eqw_GameUI.Data.Video_Burry);
set_self(795,37,0,0,0);
},500);
break;
case 2:
var pobj=eqw_Desk.GetPlayerBySeat(eqw_Desk.BankerSeat);
pobj.PushCards(eqw_GameUI.Data.Video_Burry);
eqw_GameUI.Video_SetUpCards(pobj.HandCards);
var w=7*eqw_Const.Card.pushdis+eqw_Const.Card.oriwidth*eqw_Const.Card.pushscale/100;
var x=eqw_Const.Card.pushlocation[ind][0]-w/2;
for(var i=0;i<8;i++){
set_self(773+i,37,0,0,0);
set_self(773+i,43,55,0,0);
set_self(773+i,35,255,0,0);
set_self(773+i,43,CardList[i]%54+1,0,0);
}
for(var i=0;i<8;i++){
set_self(773+i,19,eqw_Const.Card.pushlocation[ind][1],0,0);
set_self(773+i,18,x+i*eqw_Const.Card.pushdis,0,0);
set_self(773+i,33,eqw_Const.Card.pushscale,0,0);
set_self(773+i,37,1,0,0);
}
//eqw_GameUI.SetMyCards();
for(var i=0;i<8;i++){
play_ani(1,773+i,18,get_self(773+i,18,0,0,0),eqw_Const.Bottom.Location[0]-get_self(773+i,20,0,0,0)/2,0,500,0,0,0,1,0,0);
play_ani(1,773+i,19,get_self(773+i,19,0,0,0),get_self(1203,19,0,0,0),0,500,0,0,0,1,0,0);
}
setTimeout(function(){
for(var i=0;i<8;i++){
set_self(773+i,37,0,0,0);
}
eqw_GameUI.Video_ShowBottom(eqw_GameUI.Data.Video_Burry);
set_self(795,37,0,0,0);
},500);
break;
}
}
eqw_GameUI.Video_ClickPlay=function(){
if(eqw_GameUI.Data.Video_PlayState){//播放阶段
clearInterval(eqw_GameUI.Data.Video_TimerID);
set_self(1177,43,1,0,0);
}else{//暂停阶段
eqw_GameUI.Data.Video_TimerID = setInterval(eqw_GameUI.Video_Next,eqw_Const.Video.timer);
set_self(1177,43,2,0,0);
}
eqw_GameUI.Data.Video_PlayState=!eqw_GameUI.Data.Video_PlayState;
}
//
eqw_GameUI.ShowRoundAction=function(){
}
eqw_GameUI.Video_HideCards=function(CardList){
//if(!CardList){
//CardList = [].concat(eqw_Data.pushcards);
//}
//if(eqw_Data.isHideCards){
set_self(1039,37,0,0,0);
for(var i=0;i<3;i++){
if(CardList[i]!=null){
var ind=eqw_Logic.ChangeToStatus(i);
switch(ind){
case 0:
var len=CardList[i].length;
for(var j=0;j<len;j++){
set_self(740-len+1+j,37,0,0,0);
}
//var len = eqw_Player.HandCards.length;
//for(var j=0;j<36-len;j++){
//set_self(705+len+j,37,0,0,0);
//}
break;
case 1:
for(var j=0;j<CardList[i].length;j++){
set_self(827+j,37,0,0,0);
}
break;
case 2:
for(var j=0;j<CardList[i].length;j++){
set_self(841+j,37,0,0,0);
}
break;
}
}
}
//}
}
//打开投降按钮
eqw_GameUI.openSurrenderBtn = function(){
if(eqw_Desk.surrender == 1){
set_self(1220,37,1,0,0);
}
}
//关闭投降按钮
eqw_GameUI.closeSurrenderBtn = function(){
set_self(1220,37,0,0,0);
}
//打开投降确认界面
eqw_GameUI.openSurrender = function(){
set_self(1223,7,"是否确认投降?",0,0);
set_group(220,37,1,0,0);
}
//关闭投降确认界面
eqw_GameUI.closeSurrender = function(){
set_group(220,37,0,0,0);
}