<!doctype html>
<html>
<title>Emoji in Sector Game - RJM Programming - August, 2021 Thanks to https://www.iemoji.com</title>
<meta charset="utf-8"/>
<meta id="myviewport" name="viewport" content="width=device-width, initial-scale=1, minimum-scale=0.1, maximum-scale=8, user-scalable=yes">
<style>
p {
font-size: 94px;
text-align: center;
}
.kb {
background-color: yellow;
}
.peach::after {
content: '\01f351';
}
.eggplant::after {
content: '\01f346';
}
.tangerine::after {
content: '\01f34a';
}
.strawberry::after {
content: '\01f353';
}
.pineapple::after {
content: '\01f34d';
}
.watermelon::after {
content: '\01f349';
}
.grapes::after {
content: '\01f347';
}
.banana::after {
content: '\01f34c';
}
.cherries::after {
content: '\01f352';
}
.red_apple::after {
content: '\01f34e';
}
.lemon::after {
content: '\01f34b';
}
.green_apple::after {
content: '\01f34f';
}
.pear::after {
content: '\01f350';
}
.hot_pepper::after {
content: '\01f336';
}
.tomato::after {
content: '\01f345';
}
.melon::after {
content: '\01f348';
}
.one::after {
content: '';
}
.two::after {
content: '';
}
.three::after {
content: '';
}
.four::after {
content: '';
}
.five::after {
content: '';
}
</style>
<script type='text/javascript'>
var which=0;
var via='';
var gjtd=0;
var tdi=0;
var ire=0;
var wwt=0; //window.innerHeight
var obr=false;
var lastxx='', lastzz='' ;
var curkb=1;
var myt=null, myz=null; //table, first th
var thetds=[], thetdareas=[], thetdids=[];
var theclasses=[], thels=[], thets=[];
var thegridtdareas=[], thegridtdihs=[];
var numplayers=location.search.split('numplayers=')[1] ? eval(location.search.split('numplayers=')[1].split('&')[0]) : 1;
var scores=['0'];
var goes=['0'];
var players=['Player 1'];
var answers=[''];
var classes=['peach', 'eggplant', 'tangerine', 'strawberry', 'pineapple', 'watermelon', 'grapes', 'banana', 'cherries', 'red_apple', 'lemon', 'green_apple', 'pear', 'hot_pepper', 'tomato', 'melon'];
var contents=['127825', '127814', '127818', '127827', '127821', '127817', '127815', '127820', '127826', '127822', '127819', '127823', '127824', '127798', '127813', '127816'];
var analnono=false;
var br='';
var dv=20;
var ddd='... ';
var ocb="", octb="";
var fis='absolute';
if (eval('' + numplayers) > 2 || navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i)) {
ocb=" onclick=append(this); ";
octb=" onclick=append(this); ";
via=' grid cell clicks below';
fis='fixed';
}
if (!String.fromCodePoint) { // thanks to http://xahlee.info/js/js_unicode_code_point.html
// ES6 Unicode Shims 0.1 , © 2012 Steven Levithan , MIT License
String.fromCodePoint = function fromCodePoint () {
var chars = [], point, offset, units, i;
for (i = 0; i < arguments.length; ++i) {
point = arguments[i];
offset = point - 0x10000;
units = point > 0xFFFF ? [0xD800 + (offset >> 10), 0xDC00 + (offset & 0x3FF)] : [point];
chars.push(String.fromCharCode.apply(null, units));
}
return chars.join("");
}
}
function junk(eio) {
}
function nanalyze(iois) {
var done=false;
var ij=eval(iois.id.replace('c',''));
which=eval('' + ij);
var wordsare=iois.innerHTML.replace(/\ \;/g,' ').split(' ');
for (var iw=0; iw<wordsare.length; iw++) {
if (wordsare[iw].replace('(','_').replace(')','_').replace(/^\:/g,'_').replace(/\:$/g,'_').indexOf('_') != -1 || (!done && (iw != 0 && eval(1 + iw) == wordsare.length))) { done=true; document.getElementById('isc').src=document.getElementById('isc').src.split('?')[0].split('#')[0] + '?nickname=' + encodeURIComponent(wordsare[iw].replace(/^flag_/g, 'flag:_').replace('(','').replace(')','').replace(/^\:/g,'').replace(/\:$/g,'')) + '&which=' + ('' + eval(1 + eval('' + which))).replace('1','one').replace('2','two').replace('3','three').replace('4','four').replace('5','five').replace('0',''); }
}
players[ij]='' + iois.innerHTML;
}
function izeroanalyze() {
analyze(document.getElementById('i0'));
}
function analyze(iois) {
if (!analnono && iois.value != '') {
document.title+=' x';
var ij=eval(iois.id.replace('i',''));
goes[ij]='' + eval(eval('' + goes[ij]) + 1);
if (iois.value.toLowerCase().replace(/_/g,' ').replace('aubergine', 'eggplant').replace('grapes', 'grapX').replace('grape', 'grapes').replace('grapX', 'grapes').replace('cherry', 'cherries') == answers[ij]) {
scores[ij]='' + eval(eval('' + scores[ij]) + 2);
} else if ((answers[ij] + '~').indexOf(' ' + iois.value.toLowerCase().replace(/_/g,' ') + '~') != -1) {
scores[ij]='' + eval(eval('' + scores[ij]) + 1);
} else {
scores[ij]='' + Math.max(0, eval(-1 + eval('' + scores[ij])));
}
document.getElementById('sp' + ij).innerHTML='' + scores[ij] + '/' + goes[ij];
iois.value='';
another();
}
analnono=false;
}
function precontinuallook() {
if (top.document) {
if (top.document.getElementById('divac')) {
br='<br>';
ddd=' ';
document.getElementById('mytable').border='1';
document.getElementById('estyle').innerHTML="<style> p { font-size: 24px; text-align: center; } </style>";
continuallylook();
}
}
}
function continuallylook() {
var xx='';
if (top.document) {
if (top.document.getElementById('divac')) {
if (top.document.title.split(' ... ').length == 3) {
xx=top.document.title.split(' ... ')[1];
top.document.title=top.document.title.replace(' ... ' + xx, '');
}
if (xx.toLowerCase().indexOf('one ') != -1) {
document.getElementById('i0').value=xx.toLowerCase().split('one ')[1];
analyze(document.getElementById('i0'));
} else if (xx.toLowerCase().indexOf('two ') != -1) {
document.getElementById('i1').value=xx.toLowerCase().split('two ')[1];
analyze(document.getElementById('i1'));
} else if (xx.toLowerCase().indexOf('to ') != -1) {
document.getElementById('i1').value=xx.toLowerCase().split('to ')[1];
analyze(document.getElementById('i1'));
} else if (xx.toLowerCase().indexOf('three ') != -1) {
document.getElementById('i2').value=xx.toLowerCase().split('three ')[1];
analyze(document.getElementById('i2'));
} else if (xx.toLowerCase().indexOf('four ') != -1) {
document.getElementById('i3').value=xx.toLowerCase().split('four ')[1];
analyze(document.getElementById('i3'));
} else if (xx.toLowerCase().indexOf('five ') != -1) {
document.getElementById('i4').value=xx.toLowerCase().split('five ')[1];
analyze(document.getElementById('i4'));
} else if (xx.toLowerCase().indexOf('1 ') != -1) {
document.getElementById('i0').value=xx.toLowerCase().split('1 ')[1];
analyze(document.getElementById('i0'));
} else if (xx.toLowerCase().indexOf('2 ') != -1) {
document.getElementById('i1').value=xx.toLowerCase().split('2 ')[1];
analyze(document.getElementById('i1'));
} else if (xx.toLowerCase().indexOf('3 ') != -1) {
document.getElementById('i2').value=xx.toLowerCase().split('3 ')[1];
analyze(document.getElementById('i2'));
} else if (xx.toLowerCase().indexOf('4 ') != -1) {
document.getElementById('i3').value=xx.toLowerCase().split('4 ')[1];
analyze(document.getElementById('i3'));
} else if (xx.toLowerCase().indexOf('5 ') != -1) {
document.getElementById('i4').value=xx.toLowerCase().split('5 ')[1];
analyze(document.getElementById('i4'));
} else if (xx != '') {
another();
}
}
setTimeout(continuallylook, 500);
}
}
function onl() {
var i, j, k, crowh='<tr></tr>', crowd='<tr id=trd></tr>', vb='';
numplayers=location.search.split('numplayers=')[1] ? eval(location.search.split('numplayers=')[1].split('&')[0]) : numplayers;
document.getElementById('myselect').value='' + numplayers;
var cscores=location.search.split('scores=')[1] ? decodeURIComponent(location.search.split('scores=')[1].split('&')[0]) : '';
if (cscores != '') { scores=cscores.split(','); }
var cgoes=location.search.split('goes=')[1] ? decodeURIComponent(location.search.split('goes=')[1].split('&')[0]) : '';
if (cgoes != '') { goes=cgoes.split(','); }
var cplayers=location.search.split('players=')[1] ? decodeURIComponent(location.search.split('players=')[1].split('&')[0]) : '';
if (cplayers != '' && cplayers.length > 1) { players=cplayers.split(','); answers=cplayers.split(','); }
for (k=1; k<numplayers; k++) {
if (scores.length <= k) {
scores.push('0');
goes.push('0');
players.push('Player ' + eval(1 + k));
answers.push('');
}
}
precontinuallook();
for (i=0; i<numplayers; i++) {
if (numplayers == 2 && i == 0) {
vb=' and tab out';
vb=' ';
crowh=crowh.replace('</tr>', '<th id=th' + i + ' style="inline-block;width:' + eval(100 / numplayers) + '%;"><div id=c' + i + ' style=inline-block title="Give me a specific name and any underscored phrases (and/or last word) will get looked up as far as emoji short codes are concerned to try to find a match" onkeypress="junk(event);" onblur=nanalyze(this); contenteditable=true>' + players[i] + ' </div> ' + ddd + 'score <span id=sp' + i + '>' + scores[i] + '/' + goes[i] + '</span> ' + ddd + br + ' guess the one letter sector' + via + vb + ' <input onkeypress="vslast(event);" onkeydown="analnono=false;" data-onblur=setTimeout(izeroanalyze,1000); id=i' + i + ' type=text value=""></input></th></tr>');
vb=' via buttons below';
} else {
crowh=crowh.replace('</tr>', '<th id=th' + i + ' style="inline-block;width:' + eval(100 / numplayers) + '%;"><div id=c' + i + ' style=inline-block title="Give me a specific name and any underscored phrases (and/or last word) will get looked up as far as emoji short codes are concerned to try to find a match" onkeypress="junk(event);" onblur=nanalyze(this); contenteditable=true>' + players[i] + ' </div> ' + ddd + 'score <span id=sp' + i + '>' + scores[i] + '/' + goes[i] + '</span> ' + ddd + br + ' guess the one letter sector' + via + vb + ' <input onkeypress="vslast(event);" data-onblur=analyze(this); id=i' + i + ' type=text value=""></input></th></tr>');
vb='';
}
j=Math.floor(Math.random() * classes.length);
answers[i]=classes[j].replace(/_/g, ' ');
crowd=crowd.replace('</tr>', '<td style="vertical-align:top;border:1px solid red;" id=tb' + i + '>' + twentyfive('<p id=d' + i + ' class=' + classes[j] + '></p>') + '</td></tr>');
}
document.getElementById('mytbody').innerHTML=crowh + crowd;
//alert(crowd);
if (br == '<br>') {
document.getElementById('i0').style.width='60px';
document.getElementById('i1').style.width='60px';
document.getElementById('i2').style.width='60px';
document.getElementById('i3').style.width='60px';
document.getElementById('i4').style.width='60px';
}
if (numplayers == 2) {
setTimeout(andlat, 1000); //alert(1);
waw(document.getElementById('i0')).focus();
document.getElementById('th1').innerHTML+='<br>' + '<input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="a" id=ba1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="b" id=bb1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="c" id=bc1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="d" id=bd1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="e" id=be1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="f" id=bf1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="g" id=bg1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="h" id=bh1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="i" id=bi1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="j" id=bj1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="k" id=bk1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="l" id=bl1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="m" id=bm1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="n" id=bn1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="o" id=bo1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="p" id=bp1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="q" id=bq1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="r" id=br1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="s" id=bs1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="t" id=bt1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="u" id=bu1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="v" id=bv1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="w" id=bw1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="x" id=bx1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="y" id=by1></input> <input class=kb type=button style=inline-block; onmouseover=append(this); onclick=append(this); value="z" id=bz1></input> ';
} else {
setTimeout(andlat, 1000); //alert(1);
}
}
function andlat() {
if (document.getElementById('i' + eval(-1 + curkb))) {
waw(document.getElementById('i' + eval(-1 + curkb))).focus();
}
}
function waw(inip) {
if (navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i)) {
return document.getElementById('iwayaway');
}
return inip;
}
function another() {
var i, j, xcrowd='';
for (i=0; i<numplayers; i++) {
j=Math.floor(Math.random() * classes.length);
answers[i]=classes[j].replace(/_/g, ' ');
xcrowd+='<td style=vertical-align:top; id=td' + i + '><p id=d' + i + ' class=' + classes[j] + '></p></td>';
document.getElementById('i' + i).value='';
}
document.getElementById('trd').innerHTML=xcrowd;
if (numplayers == 2) {
waw(document.getElementById('i0')).focus();
}
// if (br == '<br>') { top.document.getElementById('start_button').click(); }
}
function append(ibo) {
//alert('5:' + ibo.id);
if (('' + ibo.id).indexOf('b') == 0) {
//curkb=2;
//alert('0:' + ibo.value.toUpperCase());
amiright(ibo.value.toUpperCase());
} else if (('' + ibo.id).indexOf('td') == 0) {
//curkb=2;
//alert('1:' + ibo.innerHTML);
if (lastzz != ('' + eval(1 + eval(('0' + ibo.className).slice(-1))) + ibo.innerHTML)) {
lastzz=('' + eval(1 + eval(('0' + ibo.className).slice(-1))) + ibo.innerHTML);
curkb=eval(1 + eval(('0' + ibo.className).slice(-1)));
amiright(ibo.innerHTML);
//document.getElementById('myh3').innerHTML+=' ' + lastzz;
event.stopPropagation();
return false;
}
} else if (('' + ibo.id).indexOf('t') == 0) {
//curkb=2;
//alert('2:z');
amiright('z');
} else {
//document.title+=' z';
analnono=true;
document.getElementById('i' + ibo.id.substring(2)).value+=ibo.id.substring(1,2);
if (document.getElementById('i' + ibo.id.substring(2)).value.toLowerCase().replace(/_/g,' ').replace('aubergine', 'eggplant').replace('grapes', 'grapX').replace('grape', 'grapes').replace('grapX', 'grapes').replace('cherry', 'cherries') == answers[1]) {
analnono=false;
analyze(document.getElementById('i' + ibo.id.substring(2)));
document.getElementById('i' + ibo.id.substring(2)).value='';
another();
} else if ((answers[1] + '~').indexOf(' ' + document.getElementById('i' + ibo.id.substring(2)).value.toLowerCase().replace(/_/g,' ') + '~') != -1) {
analnono=false;
analyze(document.getElementById('i' + ibo.id.substring(2)));
document.getElementById('i' + ibo.id.substring(2)).value='';
another();
}
all();
}
return true;
}
function all() {
waw(document.getElementById('i0').focus());
}
function lhit(sv) {
var k;
var xscores='' + scores[0], xgoes='' + goes[0], xplayers='' + players[0];
numplayers=eval(sv);
for (k=1; k<numplayers; k++) {
if (scores.length <= k) {
scores.push('0');
goes.push('0');
players.push('Player ' + eval(1 + k));
answers.push('');
}
xscores+=',' + scores[k];
xgoes+=',' + goes[k];
xplayers+=',' + players[k];
}
if (1 == 2 && (navigator.userAgent.toLowerCase().indexOf('chrome') > -1 && eval('' + numplayers) > 2)) {
location.href='//www.rjmprogramming.com.au/PHP/speech_supervisor.php?mode=03';
} else {
location.href=document.URL.split('#')[0].split('?')[0] + '?scores=' + encodeURIComponent(xscores) + '&goes=' + encodeURIComponent(xgoes) + '&players=' + encodeURIComponent(xplayers) + '&numplayers=' + numplayers;
}
}
function twf() {
if (thetds.length == 0) {
myt=window.getComputedStyle(document.getElementById('mytable'));
//document.getElementById('myh3').innerHTML+=' left:' + myt.left + ' top:' + myt.top + ' width:' + myt.width + ' height:' + myt.height;
myz=window.getComputedStyle(document.getElementById('th0'));
//document.getElementById('myh3').innerHTML+=' left:' + myz.left + ' top:' + myz.top + ' width:' + myz.width + ' height:' + myz.height;
//alert(thetdids);
for (var ii=0; ii<thetdids.length; ii++) {
thetds.push(document.getElementById(thetdids[ii]));
thetdareas.push(document.getElementById(thetdids[ii]).getBoundingClientRect());
//document.getElementById('myh3').innerHTML+=' left:' + thetdareas[eval(-1 + thetdareas.length)].left + ' top:' + thetdareas[eval(-1 + thetdareas.length)].top + ' width:' + thetdareas[eval(-1 + thetdareas.length)].width + ' height:' + thetdareas[eval(-1 + thetdareas.length)].height;
}
var tdlot=document.getElementsByTagName('td');
for (var itd=0; itd<tdlot.length; itd++) {
if (tdlot[itd].innerHTML.length == 1) {
//alert(tdlot[itd].innerHTML + ': ' + tdlot[itd].getBoundingClientRect().top);
thegridtdihs.push(tdlot[itd].innerHTML);
thegridtdareas.push(tdlot[itd].getBoundingClientRect());
}
}
var twenty=eval(50 + eval(100 * numplayers));
var thisd=100;
if (eval('' + thetdareas.length) == 0) {
thetds=[];
for (var jjj=0; jjj<numplayers; jjj++) {
thetds.push(document.getElementById(thetdids[jjj]));
thetdareas.push(document.getElementById(thetdids[jjj]).getBoundingClientRect());
}
}
for (var jtd=0; jtd<numplayers; jtd++) {
if (1 == 1) {
setTimeout(ggit, thisd);
thisd+=100;
} else {
document.getElementById('emj').innerHTML+='<div id=emj' + jtd + '></div>';
document.getElementById('emj' + jtd).innerHTML='<span id=s' + jtd + ' style="position:fixed;' + getmetop(jtd) + getmeleft(jtd) + 'opacity:1.0;z-index:90;" class=' + theclasses[jtd] + '></span>';
//document.getElementById('myh3').innerHTML+=' ' + jtd + ' ';
}
}
//alert(thetdareas);
//alert(thels);
//alert(thets);
obr=false;
setTimeout(poschange, twenty);
}
}
function ggit() {
document.getElementById('emj').innerHTML+='<div id=emj' + gjtd + '></div>';
document.getElementById('emj' + gjtd).innerHTML='<span id=s' + gjtd + ' style="position:fixed;' + getmetop(gjtd) + getmeleft(gjtd) + 'opacity:1.0;z-index:90;" class=' + theclasses[gjtd] + '></span>';
gjtd++;
}
function poschange() {
var wast=-1, wasl=-1, newt=-1, newl=-1;
//console.log('0');
for (var inn=0; inn<numplayers; inn++) {
//console.log('2');
if (eval('' + thetdareas.length) > eval('' + inn)) {
wast=thets[inn];
wasl=thels[inn];
//console.log('3');
newt=eval(('' + eval(wast - Math.floor(Math.random() * 30) + Math.floor(Math.random() * 30))).split('.')[0]);
newl=eval(('' + eval(wasl - Math.floor(Math.random() * 30) + Math.floor(Math.random() * 30))).split('.')[0]);
//alert('' + inn + ': ' + newt + ' ' + newl + ' ' + wast + ' ' + wasl + ' ... top=' + thetdareas[inn].top + ' ... bottom=' + thetdareas[inn].bottom + ' ... left=' + thetdareas[inn].left + ' ... right=' + thetdareas[inn].right);
//console.log(eval(Math.abs(eval(newt - wast)) + Math.abs(eval(newl - wasl))));
//setTimeout(poschange, 50);
//return '';
while (eval('' + newt) < eval(thetdareas[inn].top) || eval('' + newt) > eval(thetdareas[inn].bottom) || eval('' + newl) < eval(thetdareas[inn].left) || eval('' + newl) > eval(thetdareas[inn].right)) {
//if (eval('' + newt) < eval(thetdareas[inn].top)) alert('top');
//if (eval('' + newl) < eval(thetdareas[inn].left)) alert('' + inn + ' left:' + newl + ' vs ' + thetdareas[inn].left);
//if (eval('' + newt) > eval(thetdareas[inn].bottom)) alert('bottom');
//if (eval('' + newt) > eval(thetdareas[inn].right)) alert('right');
newt=eval(('' + eval(wast - Math.floor(Math.random() * 30) + Math.floor(Math.random() * 30))).split('.')[0]);
newl=eval(('' + eval(wasl - Math.floor(Math.random() * 30) + Math.floor(Math.random() * 30))).split('.')[0]);
//console.log(eval(Math.abs(eval(newt - wast)) + Math.abs(eval(newl - wasl))));
}
thets[inn]=newt; //eval(('' + eval(thetdareas[inn].top + Math.floor(Math.random() * thetdareas[inn].height))).split('.')[0]);
thels[inn]=newl; //eval(('' + eval(thetdareas[inn].left + Math.floor(Math.random() * thetdareas[inn].width))).split('.')[0]);
//document.title=' ' + '' + thels[inn] + 'px ' + '' + thets[inn] + 'px';
//document.getElementById('spn' + inn).style.left='' + thels[inn] + 'px';
//document.getElementById('spn' + inn).style.top='' + thets[inn] + 'px';
document.getElementById('emj' + inn).innerHTML='<span id=spn' + inn + ' style="position:fixed;left:' + thels[inn] + 'px;top:' + thets[inn] + 'px;' + 'opacity:1.0;z-index:90;" class=' + theclasses[inn] + '></span>';
}
}
if (!obr) { setTimeout(poschange, dv); } else { obr=false; }
}
function getmetop(inni) {
if (eval('' + thetdareas.length) > eval('' + inni)) {
thetdareas[inni]=document.getElementById(thetdids[inni]).getBoundingClientRect();
thets.push(eval(('' + eval(thetdareas[inni].top + Math.floor(Math.random() * thetdareas[inni].height))).split('.')[0]));
//return 'top:' + ('' + eval(thetdareas[inni].top + Math.floor(Math.random() * thetdareas[inni].height))).split('.')[0] + 'px;';
console.log(thetdareas[inni].left + ' ' + thetds[inni].id + ' inni=' + inni + ' ' + myt.left + ' ' + myt.right);
return 'top:' + thets[eval(-1 + thets.length)] + 'px;';
} else {
//alert('wht');
return '';
}
}
function getmeleft(innj) {
if (eval('' + thetdareas.length) > eval('' + innj)) {
thetdareas[innj]=document.getElementById(thetdids[innj]).getBoundingClientRect();
thels.push(eval(('' + eval(thetdareas[innj].left + Math.floor(Math.random() * thetdareas[innj].width))).split('.')[0]));
//return 'left:' + ('' + eval(thetdareas[innj].left + Math.floor(Math.random() * thetdareas[innj].width))).split('.')[0] + 'px;';
console.log(thetdareas[innj].left + ' ' + thetds[innj].id + ' innj=' + innj + ' ' + myt.left + ' ' + myt.right);
return 'left:' + thels[eval(-1 + thels.length)] + 'px;';
} else {
//alert('why');
return '';
}
}
function re(ob) {
if (ob == '') { return ob; }
ire++;
return ob + ' id=td' + ire + ' ';
}
function twentyfive(pdhtml) {
var thei=pdhtml.split('=d')[1].split(' ')[0];
theclasses.push(pdhtml.split('class=')[1].split(' ')[0].split('>')[0]);
var arowis='<tr><td ' + re(ocb) + ' class=tds' + thei + ' style="border:1px solid red;width:20%;height:18%;">a</td><td ' + re(ocb) + ' class=tds' + thei + ' style="border:1px solid red;width:20%;height:18%;">b</td><td ' + re(ocb) + ' class=tds' + thei + ' style="border:1px solid red;width:20%;height:18%;">c</td><td ' + re(ocb) + ' class=tds' + thei + ' style="border:1px solid red;width:20%;height:18%;">d</td><td ' + re(ocb) + ' class=tds' + thei + ' style="border:1px solid red;width:20%;height:18%;">e</td><tr>';
if (thetdids.length == 0) {
for (var iop=0; iop<numplayers; iop++) {
thetdids.push('tb' + iop);
}
// for (var ii=0; ii<thetdids.length; ii++) {
// thetds.push(document.getElementById(thetdids[ii]));
// thetdareas.push(document.getElementById(thetdids[ii]).getBoundingClientRect());
//document.getElementById('myh3').innerHTML+=' left:' + thetdareas[eval(-1 + thetdareas.length)].left + ' top:' + thetdareas[eval(-1 + thetdareas.length)].top + ' width:' + thetdareas[eval(-1 + thetdareas.length)].width + ' height:' + thetdareas[eval(-1 + thetdareas.length)].height;
// }
} else if (1 == 2) {
thetdids.push('td' + thei);
}
setTimeout(twf, eval(1000 + eval(thei * 12000)));
//return '<table id=t' + thei + ' style=width:100%;height:60vh;>' + arowis + arowis.replace('>a<','>f<').replace('>b<','>g<').replace('>c<','>h<').replace('>d<','>i<').replace('>e<','>j<') + arowis.replace('>a<','>k<').replace('>b<','>l<').replace('>c<','>m<').replace('>d<','>n<').replace('>e<','>o<') + arowis.replace('>a<','>p<').replace('>b<','>q<').replace('>c<','>r<').replace('>d<','>s<').replace('>e<','>t<') + arowis.replace('>a<','>u<').replace('>b<','>v<').replace('>c<','>w<').replace('>d<','>x<').replace('>e<','>y<') + '</table>';
return '<table ' + octb + ' id=t' + thei + ' style=width:100%;height:calc(60vh - 0px);>' + arowis + arowis.replace('>a<','>f<').replace('>b<','>g<').replace('>c<','>h<').replace('>d<','>i<').replace('>e<','>j<') + arowis.replace('>a<','>k<').replace('>b<','>l<').replace('>c<','>m<').replace('>d<','>n<').replace('>e<','>o<') + arowis.replace('>a<','>p<').replace('>b<','>q<').replace('>c<','>r<').replace('>d<','>s<').replace('>e<','>t<') + arowis.replace('>a<','>u<').replace('>b<','>v<').replace('>c<','>w<').replace('>d<','>x<').replace('>e<','>y<') + '</table>';
}
function vslast(eiois) {
curkb=eval(1 + eval('' + eiois.target.id.replace('i','')));
if ((eiois.which || eiois.keyCode) == 8) {
eiois=eiois;
} else if ((eiois.which || eiois.keyCode) == 186 || (eiois.which || eiois.keyCode) == 900000016) {
eiois=eiois;
} else if ((eiois.which || eiois.keyCode) < 32) { // && (eiois.which || eiois.keyCode) != 32) { // || (eiois.which || eiois.keyCode) > 58) {
eiois=eiois;
} else if (eiois.keyCode >= 48 && eiois.keyCode <= 57) {
//alert(eiois.keyCode + ' ' + 'i' + eval(-1 + eval(('0123456789').charAt(eval(eiois.keyCode - 48)))));
if (document.getElementById('i' + eval(-1 + eval(('0123456789').charAt(eval(eiois.keyCode - 48)))))) {
eiois.target.value='';
curkb=eval('' + ('0123456789').charAt(eval(eiois.keyCode - 48)));
//alert(curkb);
document.getElementById('i' + eval(-1 + curkb)).value='';
setTimeout(akb, 200);
//document.getElementById('i' + eval(-1 + ('0123456789').charAt(eval(eiois.keyCode - 48)))).focus();
}
} else if (eiois.keyCode >= 65 && eiois.keyCode <= 90) {
//alert('guess is ' + curkb + ':' + ('abcdefghijklmnopqrstuvwxyz').charAt(eval(eiois.keyCode - 65)));
amiright(('abcdefghijklmnopqrstuvwxyz').charAt(eval(eiois.keyCode - 65)));
setTimeout(nakb, 200);
} else if (eiois.keyCode >= 97 && eiois.keyCode <= 122) {
//alert('guess is ' + curkb + ':' + ('abcdefghijklmnopqrstuvwxyz').charAt(eval(eiois.keyCode - 97)));
amiright(('abcdefghijklmnopqrstuvwxyz').charAt(eval(eiois.keyCode - 97)));
setTimeout(nakb, 200);
} else {
if (1 == 2) { alert(eiois.keyCode); }
}
//eiois.target.value='';
return true; //true;
}
function nakb() {
//alert('i' + eval(-1 + curkb));
document.getElementById('i' + eval(-1 + curkb)).value='';
}
function akb() {
//alert('i' + eval(-1 + curkb));
waw(document.getElementById('i' + eval(-1 + curkb))).focus();
}
function amiright(thelet) {
var tofocus=null;
var win=false;
var acurkb=curkb;
if (thelet == thelet.toUpperCase()) { acurkb=2; thelet=thelet.toLowerCase(); tofocus=document.getElementById('i0'); }
var inn=eval(-1 + acurkb);
var wass='' + scores[inn] + '/' + goes[inn];
//alert(wass);
var ioffset=eval(eval(-1 + acurkb) * 25 + eval('' + ('abcdefghijklmnopqrstuvwxyz').indexOf(thelet.toLowerCase())));
if (document.getElementById('spn' + inn) && (thelet.toLowerCase() == 'z' || lastxx != ('' + acurkb + thelet.toLowerCase()))) {
if (thelet.toLowerCase() != 'z' || 1 == 1) { lastxx=('' + acurkb + thelet.toLowerCase()); }
goes[inn]='' + eval(1 + eval('' + goes[inn]));
//alert('guess is ' + curkb + ':' + thelet + ' ... ' + ioffset + ' inn=' + inn + ' goes[inn]=' + goes[inn]);
var thist=eval(('' + document.getElementById('spn' + inn).style.top).replace('px',''));
var thisl=eval(('' + document.getElementById('spn' + inn).style.left).replace('px',''));
if (thelet.toLowerCase() == 'z') {
ioffset--;
while (ioffset >= 0) {
if (thist >= eval('' + thegridtdareas[ioffset].top) && thist <= eval('' + thegridtdareas[ioffset].bottom)) {
//document.getElementById('myh3').innerHTML+=' ' + ('' + curkb + thelet) + ' Vs ' + thegridtdihs[ioffset] + ' ... ';
if (thisl >= eval('' + thegridtdareas[ioffset].left) && thisl <= eval('' + thegridtdareas[ioffset].right)) {
//document.getElementById('myh3').innerHTML+=' ' + ('' + curkb + thelet) + ' VS ' + thegridtdihs[ioffset] + ' ... ';
win=true;
}
}
if (thegridtdihs[ioffset] == 'a' || win) { ioffset=-1; } else { ioffset--; }
}
if (!win) {
scores[inn]='' + eval(1 + eval('' + scores[inn]));
}
} else {
//document.getElementById('myh3').innerHTML+=' ' + ('' + curkb + thelet) + ' vs ' + thegridtdihs[ioffset] + ' ... ';
if (thist >= eval('' + thegridtdareas[ioffset].top) && thist <= eval('' + thegridtdareas[ioffset].bottom)) {
//document.getElementById('myh3').innerHTML+=' ' + ('' + curkb + thelet) + ' Vs ' + thegridtdihs[ioffset] + ' ... ';
if (thisl >= eval('' + thegridtdareas[ioffset].left) && thisl <= eval('' + thegridtdareas[ioffset].right)) {
//document.getElementById('myh3').innerHTML+=' ' + ('' + curkb + thelet) + ' VS ' + thegridtdihs[ioffset] + ' ... ';
scores[inn]='' + eval(1 + eval('' + scores[inn]));
}
}
//alert(wass + ' vs ' + '' + scores[inn] + '/' + goes[inn]);
}
document.getElementById('sp' + inn).innerHTML=document.getElementById('sp' + inn).innerHTML.replace(wass, '' + scores[inn] + '/' + goes[inn]);
if (tofocus) { waw(tofocus).focus(); }
}
}
function pretwf() {
myt=null;
myz=null;
thetds=[];
thetdareas=[];
//thetdids=[];
//theclasses=[];
thels=[];
thets=[];
thegridtdareas=[];
thegridtdihs=[];
obr=true;
document.getElementById('emj').innerHTML='';
for (var iij=0; iij<numplayers; iij++) {
document.getElementById('t' + iij).style.height='calc(60vh ' + ('- ' + eval(wwt - window.innerHeight)).replace('- -','+ ') + 'px)';
}
tdi=0;
gjtd=0;
setTimeout(twf, 700);
}
function nuam(inw) {
if (navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i) && 1 == 2) {
document.getElementById('mytable').style.position='fixed';
}
var hts=document.getElementsByTagName('h3');
for (var ijk=0; ijk<hts.length; ijk++) {
hts[ijk].style.display='inline-block';
}
return inw;
}
function checksc(iois) {
if (iois != null) {
var aconto = (iois.contentWindow || iois.contentDocument);
if (aconto != null) {
if (iois.src.indexOf('?') != -1) {
if (aconto.document) { aconto = aconto.document; }
if (aconto.body != null) {
//alert(aconto.body.innerHTML);
if (aconto.body.innerHTML.indexOf('<style>') != -1) {
//alert(which);
var huhh=aconto.body.innerHTML.split("content:")[1].split(';')[0].trim().replace(/\'/g,'');
theclasses[which]=('' + eval(1 + eval('' + which))).replace('1','one').replace('2','two').replace('3','three').replace('4','four').replace('5','five').replace('0','');
document.getElementById('estyle').innerHTML+='<style> .' + ('' + eval(1 + eval('' + which))).replace('1','one').replace('2','two').replace('3','three').replace('4','four').replace('5','five').replace('0','') + "::after { content: " + aconto.body.innerHTML.split("content:")[1].split(';')[0] + " !important; } </style>";
document.getElementById('spn' + which).className=('' + eval(1 + eval('' + which))).replace('1','one').replace('2','two').replace('3','three').replace('4','four').replace('5','five').replace('0','');
//alert(aconto.body.innerHTML.split('</span>')[0].split('>')[eval(-1 + aconto.body.innerHTML.split('</span>')[0].split('>').length)]);
if (huhh.substring(1).indexOf(("\\").substring(0,1)) != -1) {
//alert('String.fromCodePoint(0x' + huhh.substring(1).replace(/\\/g, ',0x') + ')');
document.getElementById('c' + eval(0 + eval('' + which))).innerHTML=document.getElementById('c' + eval(0 + eval('' + which))).innerHTML.replace(decodeURIComponent(iois.src.split('=')[1].split('&')[0].split('#')[0]), '<span title="' + decodeURIComponent(iois.src.split('=')[1].split('&')[0].split('#')[0]) + '">' + eval('String.fromCodePoint(0x' + huhh.substring(1).replace(/\\/g, ',0x') + ')') + '</span>');
if (decodeURIComponent(iois.src.split('=')[1].split('&')[0].split('#')[0]).indexOf('flag:_') == 0) {
document.getElementById('c' + eval(0 + eval('' + which))).innerHTML=document.getElementById('c' + eval(0 + eval('' + which))).innerHTML.replace(decodeURIComponent(iois.src.split('=')[1].split('&')[0].split('#')[0]).replace('flag:_','flag_'), '<span title="' + decodeURIComponent(iois.src.split('=')[1].split('&')[0].split('#')[0]).replace('flag:_','flag_') + '">' + eval('String.fromCodePoint(0x' + huhh.substring(1).replace(/\\/g, ',0x') + ')') + '</span>');
}
} else {
document.getElementById('c' + eval(0 + eval('' + which))).innerHTML=document.getElementById('c' + eval(0 + eval('' + which))).innerHTML.replace(decodeURIComponent(iois.src.split('=')[1].split('&')[0].split('#')[0]), '<span title="' + decodeURIComponent(iois.src.split('=')[1].split('&')[0].split('#')[0]) + '">' + aconto.body.innerHTML.split('</span>')[0].split('>')[eval(-1 + aconto.body.innerHTML.split('</span>')[0].split('>').length)] + '</span>');
if (decodeURIComponent(iois.src.split('=')[1].split('&')[0].split('#')[0]).indexOf('flag:_') == 0) {
document.getElementById('c' + eval(0 + eval('' + which))).innerHTML=document.getElementById('c' + eval(0 + eval('' + which))).innerHTML.replace(decodeURIComponent(iois.src.split('=')[1].split('&')[0].split('#')[0]).replace('flag:_','flag_'), '<span title="' + decodeURIComponent(iois.src.split('=')[1].split('&')[0].split('#')[0]).replace('flag:_','flag_') + '">' + aconto.body.innerHTML.split('</span>')[0].split('>')[eval(-1 + aconto.body.innerHTML.split('</span>')[0].split('>').length)] + '</span>');
}
}
}
}
}
}
}
}
</script>
</head>
<body onload="wwt=nuam(window.innerHeight); onl();" onkeypress="vslast(event);" onresize="pretwf();">
<h2>Emoji in Sector Game for <select onchange="dv=eval('' + this.value);" id=myseldiff><option value=20>Difficult</option><option value=80>Easier</option><option value=200>Easy</option></select> <select id=myselect onchange='lhit(this.value);'><option value='1'>1</option><option value='2'>2</option><option value='3'>3</option><option value='4'>4</option><option value='5'>5</option></select></h2>
<h3 id=myh3>RJM Programming </h3><h3>August, 2021 ... Thanks <a target=_blank title='Iemoji' href='https://www.iemoji.com'>Iemoji</a></h3>
<table id=mytable style='width:100%;text-align:center;position:absolute;top:155px;left:0px;' border=10>
<tbody id=mytbody>
</tbody>
</table>
<div id=econtent></div>
<input id=iwayaway type=text style='position:absolute;top:-200px;left:-200px;' value=''></input>
<div id=emj></div><div id=estyle></div>
<iframe style=display:none; id=isc onload='checksc(this);' src='../PHP/short_codes.php'></iframe>
</body>
</html>