'; //Write it to the frame TopFrame.document.clear(); TopFrame.document.open(); TopFrame.document.write(OutString); TopFrame.document.close(); } function DisplayExercise(){ //Build the output string var OutString = ''; OutString += ''; OutString += ''; OutString += '
'; OutString += TitleCode; OutString += Buttons1; OutString += BuiltExercise; OutString += Buttons2; OutString += BuiltClues; OutString += NavBar; OutString += '
'; if (is.CRAPBrowser){OutString=ResolveAllURLs(OutString);} //Write it to the frame BottomFrame.document.clear(); BottomFrame.document.open(); BottomFrame.document.write(OutString); BottomFrame.document.close(); } function BuildClue(ClueNum,x,y,Across){ var OutString = ''; if (Across == true){ if (ClueNum >= A.length){ return ''; } if (A[ClueNum] == null){ return ''; } OutString = ClueNum + '. ' + A[ClueNum]; OutString += GetAnswer; OutString = ReplaceStuff('[BoxName]', 'BA'+ClueNum, OutString); //Find out how long the answer is AnsLength = 0; i = x; j = y; while (j= D.length){ return ''; } if (D[ClueNum] == null){ return ''; } OutString = ClueNum + '. ' + D[ClueNum]; OutString += GetAnswer; OutString = ReplaceStuff('[BoxName]', 'BD'+ClueNum, OutString); //Find out how long the answer is AnsLength = 0; i = x; j = y; while (i 0){ OutString += ' '; } OutString = OutString + 'Down: ' + ClueNum + '. ' + D[ClueNum]; OutString += GetAnswer; OutString = ReplaceStuff('[BoxName]', 'BD'+ClueNum, OutString); //Find out how long the answer is AnsLength = 0; i = x; j = y; while (i-1){ FirstBit = InString.substring(0, i); LastBit = InString.substring(i + Token.length, InString.length); InString = FirstBit + Replacement + LastBit; i = InString.indexOf(Token); } return InString; } L = new Array(); L[0] = new Array('M','O','N','T','A','G','N','A','','','C','','','','','V',''); L[1] = new Array('O','','O','','','H','','','','V','I','A','G','G','I','O',''); L[2] = new Array('S','','R','','F','I','U','M','E','','T','','I','','','I',''); L[3] = new Array('S','U','D','','','A','','','S','','T','','T','','T','','V'); L[4] = new Array('O','','','A','','C','E','N','T','R','A','L','E','','E','R','A'); L[5] = new Array('','','A','L','','C','','','I','','','','','','R','','L'); L[6] = new Array('','C','','P','R','I','M','A','V','E','R','A','','','R','','L'); L[7] = new Array('','A','','I','','A','','','O','','','U','','M','A','R','E'); L[8] = new Array('','T','','','','I','','R','','','','T','','A','','',''); L[9] = new Array('N','E','V','E','','O','V','E','S','T','','U','','I','','',''); L[10] = new Array('','N','','','','','','G','','','I','N','V','E','R','N','O'); L[11] = new Array('','A','P','P','E','N','N','I','N','I','','N','','L','','',''); L[12] = new Array('C','','O','','','','','O','','','C','O','L','L','I','N','A'); L[13] = new Array('O','','V','','','L','','N','','','O','','','A','','','C'); L[14] = new Array('M','','E','S','T','A','T','E','','','L','','','','','','Q'); L[15] = new Array('O','','R','','','G','','','','','','','','','','','U'); L[16] = new Array('','P','O','R','T','O','','','','','C','A','S','C','A','T','A'); C = new Array(); C[0] = new Array(1,0,2,0,0,3,0,0,0,0,4,0,0,0,0,5,0); C[1] = new Array(0,0,0,0,0,0,0,0,0,6,0,0,7,0,0,0,0); C[2] = new Array(0,0,0,0,8,0,0,0,9,0,0,0,0,0,0,0,0); C[3] = new Array(10,0,0,0,0,0,0,0,0,0,0,0,0,0,11,0,12); C[4] = new Array(0,0,0,13,0,14,0,0,0,0,0,0,0,0,15,0,0); C[5] = new Array(0,0,16,0,0,0,0,0,0,0,0,0,0,0,0,0,0); C[6] = new Array(0,17,0,18,0,0,0,0,0,0,0,19,0,0,0,0,0); C[7] = new Array(0,0,0,0,0,0,0,0,0,0,0,0,0,20,0,0,0); C[8] = new Array(0,0,0,0,0,0,0,21,0,0,0,0,0,0,0,0,0); C[9] = new Array(22,0,0,0,0,23,0,0,0,0,0,0,0,0,0,0,0); C[10] = new Array(0,0,0,0,0,0,0,0,0,0,24,0,0,0,0,0,0); C[11] = new Array(0,25,26,0,0,0,0,0,0,0,0,0,0,0,0,0,0); C[12] = new Array(27,0,0,0,0,0,0,0,0,0,28,0,0,0,0,0,29); C[13] = new Array(0,0,0,0,0,30,0,0,0,0,0,0,0,0,0,0,0); C[14] = new Array(0,0,31,0,0,0,0,0,0,0,0,0,0,0,0,0,0); C[15] = new Array(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0); C[16] = new Array(0,32,0,0,0,0,0,0,0,0,33,0,0,0,0,0,0); G = new Array(); G[0] = new Array('','','','','','','','','','','','','','','','',''); G[1] = new Array('','','','','','','','','','','','','','','','',''); G[2] = new Array('','','','','','','','','','','','','','','','',''); G[3] = new Array('','','','','','','','','','','','','','','','',''); G[4] = new Array('','','','','','','','','','','','','','','','',''); G[5] = new Array('','','','','','','','','','','','','','','','',''); G[6] = new Array('','','','','','','','','','','','','','','','',''); G[7] = new Array('','','','','','','','','','','','','','','','',''); G[8] = new Array('','','','','','','','','','','','','','','','',''); G[9] = new Array('','','','','','','','','','','','','','','','',''); G[10] = new Array('','','','','','','','','','','','','','','','',''); G[11] = new Array('','','','','','','','','','','','','','','','',''); G[12] = new Array('','','','','','','','','','','','','','','','',''); G[13] = new Array('','','','','','','','','','','','','','','','',''); G[14] = new Array('','','','','','','','','','','','','','','','',''); G[15] = new Array('','','','','','','','','','','','','','','','',''); G[16] = new Array('','','','','','','','','','','','','','','','',''); A = new Array(); A[1]='Zona molto elevata'; A[6]='Spostamento da una città ad un\'altra'; A[8]='Lungo corso d\'acqua'; A[10]='Punto cardinale '; A[14]='Lazio, Toscana, Umbria sono in Italia ...'; A[15]='Un periodo geologico'; A[16]='a+il='; A[18]='Una stagione tiepida nell\'emisfero nord'; A[20]='Vasta superficie d\'acqua '; A[22]='Precipitazione atmosferica solida'; A[23]='Punto cardinale'; A[24]='Una stagione fredda nell\'emisfero nord'; A[25]='Catena montagnosa dell\'Italia'; A[28]='Zona mediamente elevata'; A[31]='Una stagione calda nell\'emisfero nord'; A[32]='Riparo per le barche'; A[33]='Acqua che precipita'; D = new Array(); D[1]='Il mare non calmo'; D[2]='Punto cardinale'; D[3]='Montagna con neve permanente '; D[4]='Agglomerato urbano'; D[5]='Pronome di cortesia'; D[7]='Escursioni'; D[9]='Aggettivo riferito ad una stagione calda'; D[11]='Il nostro pianeta'; D[12]='Zona pianeggiante'; D[13]='Montagne del nord Italia'; D[17]='Una serie di montagne'; D[19]='Una stagione tiepida'; D[20]='Montagna degli Appennini in Abruzzo'; D[21]='Divisione politica dell\'Italia'; D[26]='Non ricco'; D[27]='Famoso lago del nord Italia'; D[28]='con+il='; D[29]='Liquido potabile'; D[30]='Superficie d\'acqua circondata da terra'; function StartUp(){ BuildExercise(); WriteFeedback(Instructions); DisplayExercise(); } function CheckAnswers(){ var AllCorrect = true; var TotLetters = 0; var CorrectLetters = 0; //Check each letter for (var i=0; i©Half-Baked Software. Loading...'; } //--> //]]>