//Creado con Ardora - www.webardora.net
//bajo licencia Attribution-NonCommercial-NoDerivatives 4.0 International (CC BY-NC-ND 4.0)
//para otros usos contacte con el autor
var timeAct=360; timeIni=360; timeBon=0;
var successes=0; successesMax=6; attempts=0; attemptsMax=2;
var score=0; scoreMax=6; scoreInc=1; scoreDec=1
var typeGame=0;
var tiTime=false;
var tiTimeType=0;
var tiButtonTime=true;
var textButtonTime="Comenzar";
var tiSuccesses=true;
var tiAttempts=true;
var tiScore=true;
var startTime;
var colorBack="#FFFDFD"; colorButton="#91962F"; colorText="#000000"; colorSele="#FF8000";
var goURLNext=false; goURLRepeat=false;tiAval=false;
var scoOk=0; scoWrong=0; scoOkDo=0; scoWrongDo=0; scoMessage=""; scoPtos=10;
var fMenssage="Verdana, Geneva, sans-serif";
var fActi="Verdana, Geneva, sans-serif";
var fEnun="Verdana, Geneva, sans-serif";
var timeOnMessage=5; messageOk="¡ Así se hace, muy bien!"; messageTime=""; messageError="Fíjate en la cantidad que se pide."; messageErrorG="Fíjate en la cantidad que se pide."; messageAttempts="Tercer fallo. Volvemos a empezar."; isShowMessage=false;
var urlOk=""; urlTime=""; urlError=""; urlAttempts="";
var goURLOk="_blank"; goURLTime="_blank"; goURLAttempts="_blank"; goURLError="_blank"; 
borderOk="#008000"; borderTime="#FF0000";borderError="#FF0000"; borderAttempts="#FF0000";
var wordsGame="MDVyb21hbm9z"; wordsStr = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";
function giveZindex(typeElement){var valueZindex=0; capas=document.getElementsByTagName(typeElement);
for (i=0;i<capas.length;i++){if (parseInt($(capas[i]).css("z-index"),10)>valueZindex){valueZindex=parseInt($(capas[i]).css("z-index"),10);}}return valueZindex;}
var points=[["101","41","0","0"],["234","39","0","0"],["236","6","0","0"],["0","5","0","0"],["1","39","0","0"],["432","39","1","1"],["545","37","1","1"],["545","2","1","1"],["319","1","1","1"],["317","41","1","1"],["110","146","2","2"],["231","143","2","2"],["235","109","2","2"],["1","99","2","2"],["1","146","2","2"],["433","148","3","3"],["545","144","3","3"],["546","105","3","3"],["313","102","3","3"],["318","147","3","3"],["110","244","4","4"],["231","242","4","4"],["231","203","4","4"],["2","199","4","4"],["3","245","4","4"],["431","244","5","5"],["544","244","5","5"],["544","199","5","5"],["312","198","5","5"],["318","243","5","5"]];
var backSrc="05romanos_resources/media/MILES2.png";
var Shape = function () {this.x=undefined;this.y=undefined;};
Shape.prototype={fill:function(context){context.save();context.fillStyle=this.fillStyle;this.createPath(context);context.fill();context.restore();},
stroke:function(context){context.save();this.createPath(context);context.stroke();context.restore();},
isPointInPath:function(context,x,y){this.createPath(context);return context.isPointInPath(x, y);},};
var Polygon=function(){this.points = [];this.numInd=0;};Polygon.prototype=new Shape();Polygon.prototype.addPoint=function(x,y){this.points.push(new Point(x,y));};
Polygon.prototype.createPath=function (context) {if (this.points.length === 0)return;context.beginPath();
context.moveTo(this.points[0].x,this.points[0].y);for (var i=0; i < this.points.length; ++i) {context.lineTo(this.points[i].x,this.points[i].y);}context.closePath();};
var Point=function(x,y){this.x=x;this.y=y;};var shapes=[];
var polygonPoints=[[new Point(101,41),new Point(234,39),new Point(236,6),new Point(0,5),new Point(1,39)],[new Point(432,39),new Point(545,37),new Point(545,2),new Point(319,1),new Point(317,41)],[new Point(110,146),new Point(231,143),new Point(235,109),new Point(1,99),new Point(1,146)],[new Point(433,148),new Point(545,144),new Point(546,105),new Point(313,102),new Point(318,147)],[new Point(110,244),new Point(231,242),new Point(231,203),new Point(2,199),new Point(3,245)],[new Point(431,244),new Point(544,244),new Point(544,199),new Point(312,198),new Point(318,243)]];
var game=[];indexGame=0;
var area=["0","1","2","3","4","5"];
var areaSolved=["N","N","N","N","N","N"];
var areaWord=["648","500 148","610 058","600 048","640 008","646 002"];
var areaHelp=["648","500 148","610 058","600 048","640 008","646 002"];
var areaWrong=["","","","","",""];
var initMessageError="Fíjate en la cantidad que se pide.";
var wordPointX=["101","432","110","433","110","431"];
var wordPointY=["41","39","146","148","244","244"];
var areaColor=["#FF8000","#FF8000","#FF8000","#FF8000","#FF8000","#FF8000"];
var pathMedia="05romanos_resources/media/"
var auMP3=["","","","","",""];
var auOGG=["","","","","",""];
var colorWord="#000000";
colorText="#000000";colorButton="#FF8000";colorBack="#FFFFFF";colorSele="#EBD0AB";goURLNext=true;goURLRepeat=true;tiAval=true;
fMenssage="Verdana, Geneva, sans-serif";fActi="Verdana, Geneva, sans-serif";fEnun="Verdana, Geneva, sans-serif";
