var vminutes = 2;
var vseconds = 00;
var boxedanswers = 1;
var autocomplete = 1;
var gamever = 0;
var justincase1 = 0;
var justincase2 = 0;


function loadanswers()
{
	answers = new Array();
	answers.push( new inans('Harry Potter and the Philosopher\'s Stone', new Array('and the philosphers stone','the philosophers stone','philosophers stone')));
	answers.push( new inans('Harry Potter and the Chamber of Secrets', new Array('and the Chamber of Secrets','the Chamber of Secrets','Chamber of Secrets')));
	answers.push( new inans('Harry Potter and the Prisoner of Azkaban', new Array('and the Prisoner of Azkaban','the Prisoner of Azkaban','Prisoner of Azkaban')));
	answers.push( new inans('Harry Potter and the Goblet of Fire', new Array('and the Goblet of Fire','the Goblet of Fire','Goblet of Fire')));
	answers.push( new inans('Harry Potter and the Order of the Phoenix', new Array('and the Order of the Phoenix','the Order of the Phoenix','Order of the Phoenix')));
	answers.push( new inans('Harry Potter and the Half-Blood Prince', new Array('and the Half-Blood Prince','the Half-Blood Prince','Half-Blood Prince','and the HalfBlood Prince','the HalfBlood Prince','HalfBlood Prince')));
	answers.push( new inans('Harry Potter and the Deathly Hallows', new Array('and the Deathly Hallows','the Deathly Hallows','Deathly Hallows')));
	remaining = answers.length;
	displayRemaining();
}

function doEndAlert()
{
	var total = (correct + remaining);
	var percentunrounded = (correct/total) * 100;
	var percent = roundNumber(percentunrounded,2)
	if ( percent == 100 ) {
	alert("Nicely done, You named the whole series, Great Score.\nYou got all " + correct + " answers correct.\nWell done!!!");
	}
	if ( percent >= 80 && percent < 100) {
	alert("Well done! You managed to get " + correct + " correct.\nThat is " + percent + "% of the total possible answers.\nThat is an amazing score");
	}
	if ( percent >= 65 && percent < 80) {
	alert("Great Job! You managed to get " + correct + " correct.\nThat is " + percent + "% of the total possible answers.\nThat is a very good score");
	}
	if ( percent >= 40 && percent < 65) {
	alert("Good Job! You managed to get " + correct + " correct.\nThat is " + percent + "% of the total possible answers.\nThat is a good score");
	}
	if ( percent < 40) {
	alert("Not very good, I'm afraid! You managed to get " + correct + " correct.\nThat is " + percent + "% of the total possible answers.\nThat is a not a very good score, try again!");
	}
}

