//1222609 var myObj var matchInit, tablehInit, statsInit; var timeComp; getFormation(); getTable(); //bMenu-n and bMenuPnt are being initialized ; and also come with full information var bMenu = ["match-info"], bMenuPnt="match-info"; makeMenu(); //sec depending var timeStr="", statusStr=""; var tmCl=document.getElementsByClassName("data__time")[0]; var vlCl=document.getElementsByClassName("vertical__live")[0]; var vrCl=document.getElementsByClassName("vertical__round")[0]; var statusList={"Kick Off":1,"Half Time":2,"Second Half":3,"Full Time":6}; var statusG=res1G=res2G=tsG=0; var timerInterval,menuInterval; var evWithCoord=["Throw In","Corner","Goal Kick","Penalty","Shot Off Target","Shot On Target","Free Kick","Dangerous Free Kick"]; var evWithBackGround={"In Possession":{"1":{"left":"2","deg":"0"},"2":{"left":"172","deg":"180"}}, "Dangerous Attack":{"1":{"left":"2","deg":"0"},"2":{"left":"100","deg":"180"}}, "Attack":{"1":{"left":"2","deg":"0"},"2":{"left":"139","deg":"180"}} }; var thCl=document.getElementsByClassName("throw-in")[0]; var frameCl=document.getElementsByClassName("pitch__frame")[0]; var descCl=document.getElementsByClassName("pitch__frame-1")[0]; var lineCl=descCl.getElementsByClassName("frame__left-horizontal-line")[0]; evWithBackGround["Attack"]["cl1"]=document.getElementsByClassName("attack_1")[0]; evWithBackGround["Dangerous Attack"]["cl1"]=document.getElementsByClassName("dangerous-attack_1")[0]; evWithBackGround["In Possession"]["cl1"]=document.getElementsByClassName("in-possession_1")[0]; evWithBackGround["Attack"]["cl2"]=document.getElementsByClassName("attack_2")[0]; evWithBackGround["Dangerous Attack"]["cl2"]=document.getElementsByClassName("dangerous-attack_2")[0]; evWithBackGround["In Possession"]["cl2"]=document.getElementsByClassName("in-possession_2")[0]; var clBack=descCl.getElementsByClassName('frame__background')[0]; var clT=descCl.getElementsByClassName('frame__title'); var clP=descCl.getElementsByClassName('frame__player'); var textWidthPrev=109, clubPrev=0, rotateDeg=0; var pointer=0; //var id=setInterval(makeEvent,1000); /* myObj.ev[0].a=""; myObj.ev[0].c="2"; myObj.ev[0].e="Free Kick"; myObj.ev[0].p="1661334957706"; myObj.ev[0].s="24:57"; myObj.ev[0].x="220"; myObj.ev[0].y="150"; makeEvent(); */ let uWidth=340; //ball size increase with every angle let bWidth = 340; //ball size let bHeight = 210; let vWidth = 340; //window size let vHeight = 210; let maxWidth = 340; //ball diagonal let width = 340; //pitch size let height = 216; let width17P = 54; //pitch size 17% let width10P = 34; //pitch size 10% let multiplierWidth=1; // let multiplierHeight=1; var tKoef=2; //used in ChartEv var koefC=100/5400; //used in koefC window.addEventListener("resize", initSize); function initSize(){ tKoef=2-vWidth/1000; tKoef=tKoef.toFixed(2); vHeight=window.innerHeight; vWidth=window.innerWidth; bWidth=document.querySelector('.throw-in').offsetWidth; bHeight=document.querySelector('.throw-in').offsetHeight; maxWidth=Math.sqrt(bWidth*bWidth+bWidth*bWidth) uWidth=(maxWidth-bWidth)/45; console.log("mW="+maxWidth+";"+uWidth); console.log("mW="+uWidth); let box = document.querySelector('.base-widget'); width = box.offsetWidth; height = box.offsetHeight-box.offsetHeight/100; multiplierWidth=(width/340).toFixed(2); multiplierHeight=(height/216).toFixed(2); if(Math.trunc(width*17/100)>54) width17P=Math.trunc(width*17/100); else width17P=54; width10P = Math.trunc(width/15); console.log({ width, height }); console.log("background"); evWithBackGround["Attack"]["cl1"].style.height=height+"px"; evWithBackGround["Dangerous Attack"]["cl1"].style.height=height+"px"; evWithBackGround["In Possession"]["cl1"].style.height=height+"px"; evWithBackGround["Attack"]["cl2"].style.height=height+"px"; evWithBackGround["Dangerous Attack"]["cl2"].style.height=height+"px"; evWithBackGround["In Possession"]["cl2"].style.height=height+"px"; getInitial(); } initSize(); var getFlag=0; var getTimer=setInterval(get,1000); function makeMenu(){ //
"+obj[i].e+"
"; descCl.innerHTML+=""+"Modrich"+"
"; descCl.innerHTML+=""+obj[i].e+"
"; html+=""+obj[i].e+"
"; html+="In possession
L. Modrić
";
strHtm+=" ";
strHtm+=" "+pl+"\n";
strHtm+="\n";
strHtm+=" ![]() | \n";
strHtm+=" \n"; strHtm+=" "+tblObject[i].t[j]["p"]+"\n"; strHtm+=" "+tblObject[i].t[j]["fa"]+"\n"; strHtm+=" "+tblObject[i].t[j]["pnt"]+"\n"; strHtm+=" | \n"; strHtm+="
"+matchInit.lineup["1"][0].no+"
"+matchInit.lineup["2"][0].no+"
"+cl1+" | \n"; str+="Starting Lineup | \n"; str+=""+cl2+" | \n"; str+="\n"; } for(var i=0; i"+matchInit.lineup["1"][i].no+" | \n"; //str+="\n"; str+=" | "+matchInit.lineup["1"][i].pl+" | \n"; str+="\n"; str+=" | "+matchInit.lineup["2"][i].pl+" | \n"; //str+="\n"; str+=" | "+matchInit.lineup["2"][i].no+" | \n"; str+="\n"; } if(matchInit.bench){ var maxBn=matchInit.bench["1"].length; if(maxBn"+cl1+" | \n"; str+="Substitute Players | \n"; str+=""+cl2+" | \n"; str+="\n"; //console.log(maxBn); for(var i=0; i"+no1+" | \n"; //str+="\n"; str+=" | "+pl1+" | \n"; str+="\n"; str+=" | "+pl2+" | \n"; // str+="\n"; str+=" | "+no2+" | \n"; str+="\n"; } } str+="
---|