//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=3; attempts=0; attemptsMax=1;
var score=0; scoreMax=3; 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="Localizados."; messageTime=""; messageError="Aí non está o país que buscamos."; messageErrorG="Aí non está o país que buscamos."; messageAttempts="Consulta Internet e volve a intentalo."; 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="MDJjb2VsbG8"; 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=[["236","243","0","0"],["269","219","0","0"],["273","197","0","0"],["291","205","0","0"],["298","217","0","0"],["281","233","0","0"],["263","248","0","0"],["240","259","0","0"],["222","271","0","0"],["199","274","0","0"],["196","269","0","0"],["210","253","0","0"],["165","15","1","1"],["187","7","1","1"],["220","8","1","1"],["229","25","1","1"],["224","35","1","1"],["228","50","1","1"],["233","73","1","1"],["212","74","1","1"],["190","67","1","1"],["183","60","1","1"],["173","58","1","1"],["161","56","1","1"],["65","191","2","2"],["84","193","2","2"],["94","216","2","2"],["107","244","2","2"],["118","261","2","2"],["141","245","2","2"],["167","215","2","2"],["201","179","2","2"],["212","142","2","2"],["185","102","2","2"],["182","78","2","2"],["173","62","2","2"],["163","60","2","2"],["156","87","2","2"],["142","81","2","2"],["147","65","2","2"],["113","59","2","2"],["88","71","2","2"],["65","87","2","2"],["49","104","2","2"],["28","118","2","2"],["15","124","2","2"],["5","141","2","2"],["2","168","2","2"],["0","187","2","2"],["1","202","2","2"],["15","212","2","2"],["33","205","2","2"]];
var backSrc="02coello_resources/media/paises.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(236,243),new Point(269,219),new Point(273,197),new Point(291,205),new Point(298,217),new Point(281,233),new Point(263,248),new Point(240,259),new Point(222,271),new Point(199,274),new Point(196,269),new Point(210,253)],[new Point(165,15),new Point(187,7),new Point(220,8),new Point(229,25),new Point(224,35),new Point(228,50),new Point(233,73),new Point(212,74),new Point(190,67),new Point(183,60),new Point(173,58),new Point(161,56)],[new Point(65,191),new Point(84,193),new Point(94,216),new Point(107,244),new Point(118,261),new Point(141,245),new Point(167,215),new Point(201,179),new Point(212,142),new Point(185,102),new Point(182,78),new Point(173,62),new Point(163,60),new Point(156,87),new Point(142,81),new Point(147,65),new Point(113,59),new Point(88,71),new Point(65,87),new Point(49,104),new Point(28,118),new Point(15,124),new Point(5,141),new Point(2,168),new Point(0,187),new Point(1,202),new Point(15,212),new Point(33,205)]];
var game=[];indexGame=0;
var area=["0","1","2"];
var areaSolved=["N","N","N"];
var areaWord=["Nova Zelanda","Papúa Nova Guinea","Australia"];
var areaHelp=["Nova Zelanda","Papúa Nova Guinea","Australia"];
var areaWrong=["","",""];
var initMessageError="Aí non está o país que buscamos.";
var wordPointX=["236","180","65"];
var wordPointY=["243","50","191"];
var areaColor=["#F0F0F0","#F0F0F0","#F0F0F0"];
var pathMedia="02coello_resources/media/"
var auMP3=["","",""];
var auOGG=["","",""];
var colorWord="#FF8000";
colorText="#000000";colorButton="#D5D200";colorBack="#FFFFFF";colorSele="#DC5A15";goURLNext=true;goURLRepeat=true;tiAval=true;
fMenssage="Verdana, Geneva, sans-serif";fActi="Verdana, Geneva, sans-serif";fEnun="Verdana, Geneva, sans-serif";
