function Hit(d,e) { P1=",,"+PP+Po; if(P1!=",,") { if(stp){ clearTimeout(OO);OPP();stp=0;dd=d;ee=e; dede=document.images[dil+(d*16)+e].src; WW=setTimeout('Hit1(dd,ee)',300); } else { if(P1.indexOf(","+(dil+(d*16)+e)+",")>0){ stp=1;clearTimeout(WW);h=1;Po=""; for(a=0;a<QQ.length-1;a++){ document.images[QQ[a]].src=sra+"W65.jpg"; QQ[a]=dil+(dd*16)+ee; } PP="";Po=""; document.images[dil+(d*16)+e].src=dede; document.images[dil+(dd*16)+ee].src=PA[6]; } else { if(d==dd && e==ee){ stp=1;clearTimeout(WW); OO=setTimeout('OP(PP)',300); document.images[dil+(d*16)+e].src=dede; } } } } } function Hit1(d1,e1) { if(h){ document.images[dil+(d1*16)+e1].src=PA[6];h=0; } else { document.images[dil+(d1*16)+e1].src=dede;h=1; } WW=setTimeout('Hit1(dd,ee)',300); } function Wr(d,e) { if(stp){ Po="";PP=""; var de=document.images[dil+(d*16)+e].src; var zz=de.charAt(de.length-7); var zz1=de.charAt(de.length-8); if(zz == "D" || zz == "C"){ for(var a=1;a<16-e;a++){ YYY=document.images[dil+(d*16)+e+(a*17)].src; if(YYY == (sra+"W65.jpg") && d+a<16 && e+a<16){ Po=Po+(dil+(d*16)+e+(a*17))+","; } else { var zz2=YYY.charAt(YYY.length-8); if(zz1 != zz2 && d+a<16 && e+a<16 && zz2!="/"){ PP=PP+(dil+(d*16)+e+(a*17))+","+YYY+","; } break;} } for(var a=1;a<e+1;a++){ YYY=document.images[dil+(d*16)+e-(a*17)].src; if(YYY == (sra+"W65.jpg") && e-a>=0 && d-a>=0){ Po=Po+(dil+(d*16)+e-(a*17))+","; } else { var zz2=YYY.charAt(YYY.length-8); if(zz1 != zz2 && e-a>=0 && d-a>=0 && zz2!="/"){ PP=PP+(dil+(d*16)+e-(a*17))+","+YYY+","; } break;} } for(var a=1;a<e+1;a++){ YYY=document.images[dil+(d*16)+e+(a*15)].src; if(YYY == (sra+"W65.jpg") && d+a<=15 && e-a>=0){ Po=Po+(dil+(d*16)+e+(a*15))+","; } else { var zz2=YYY.charAt(YYY.length-8); if(zz1 != zz2 && d+a<=15 && e-a>=0 && zz2!="/"){ PP=PP+(dil+(d*16)+e+(a*15))+","+YYY+","; } break;} } for(var a=1;a<16-e;a++){ YYY=document.images[dil+(d*16)+e-(a*15)].src; if(YYY == (sra+"W65.jpg") && e+a<16 && d-a>=0){ Po=Po+(dil+(d*16)+e-(a*15))+","; } else { var zz2=YYY.charAt(YYY.length-8); if(zz1 != zz2 && e+a<16 && d-a>=0 && zz2!="/"){ PP=PP+(dil+(d*16)+e-(a*15))+","+YYY+","; } break;} } } if(zz=="S" || zz=="C"){ for(var a=1;a<16-e;a++){ YYY=document.images[dil+(d*16)+e+a].src; if(YYY == (sra+"W65.jpg") && e<15){ Po=Po+(dil+(d*16)+e+a)+","; } else { var zz2=YYY.charAt(YYY.length-8); if(zz1 != zz2 && e<15 && zz2!="/"){ PP=PP+(dil+(d*16)+e+a)+","+YYY+","; } break;} } for(var a=1;a<e+1;a++){ YYY=document.images[dil+(d*16)+e-a].src; if(YYY == (sra+"W65.jpg") && e!=0){ Po=Po+(dil+(d*16)+e-a)+","; } else { var zz2=YYY.charAt(YYY.length-8); if(zz1 != zz2 && e!=0 && zz2!="/"){ PP=PP+(dil+(d*16)+e-a)+","+YYY+","; } break;} } for(var a=1;a<16-d;a++){ YYY=document.images[dil+(d*16)+e+(a*16)].src; if(YYY == (sra+"W65.jpg") && d!=15){ Po=Po+(dil+(d*16)+e+(a*16))+","; } else { var zz2=YYY.charAt(YYY.length-8); if(zz1 != zz2 && d!=15 && zz2!="/"){ PP=PP+(dil+(d*16)+e+(a*16))+","+YYY+","; } break;} } for(var a=1;a<16;a++){ YYY=document.images[dil+(d*16)+e-(a*16)].src; if(YYY == (sra+"W65.jpg") && d-a>=0){ Po=Po+(dil+(d*16)+e-(a*16))+","; } else { var zz2=YYY.charAt(YYY.length-8); if(zz1 != zz2 && d-a>=0 && zz2!="/"){ PP=PP+(dil+(d*16)+e-(a*16))+","+YYY+","; } break;} } } if(PP!=""){ PPP=PP.split(","); OO=setTimeout('OP()',300);} } } function OP(){ var zz3=PPP[1].charAt(PPP[1].length-8); for(a=0;a<((PPP.length-1)/2);a++){ if(jj<1){ document.images[PPP[a*2]].src=sra+zz3+".jpg"; } else { document.images[PPP[a*2]].src=PPP[(a*2)+1]; } } jj<1 ? jj=1 : jj=0; OO=setTimeout('OP()',300); } function OPP() { for(a=0;a<((PPP.length-1)/2);a++){ document.images[PPP[a*2]].src=PPP[(a*2)+1]; } PPP=""; } function MO1() { if(stp){ QQ=Po.split(","); for(a=0;a<QQ.length-1;a++){ document.images[QQ[a]].src=sra+"Y_.jpg"; } } } function MO2() { if(stp){ for(a=0;a<QQ.length-1;a++){ document.images[QQ[a]].src=sra+"W65.jpg"; } clearTimeout(OO);OPP(); } }