What did i do wrong?


I am making a .hta game and I have asked on many websites for help but nothing. when I run this script I get a undefined error so please help.

<title>Sample game</title>
<h1>Hello and welcome to the death tbg(text-based-game) just answer each          question and see what you get!</h1>
<div id="question"></div>
<div id="answers"></div>
<embed src="expl.mp3" autostart="true" loop="true"
width="2" height="0">
var db = [
{	//0
    "question":"You wake up in a dark room no light all but faint shadows    dancing around the room. As you move around trying to find your way you find    a switch what do you do?",
        {"title":"Turn it on","response":1},
        {"title":"Panic, but remain still","response":2},
        {"title":"Run like mad","response":4},
{	//1
    "question":"KABOOM!!! Just kidding all you see is a cage a knife and a dead body.",
        {"title":"A DEAD BODY?!?!?!","response":5},
		{"title":"Check to see who it is like a real detective","response":7},
{	//2
    "question":"Why did you panic you scrub.",
        {"title":"You better know the key to speed(SPEEED IS KEEEEEEEEEEEEEEEY!!!!!!)","response":8},
        {"title":"Well not much to say really.","response":9},
		{"title":"You get humiliated. You try to run but you trip and die.","response":10},
{	//3
    "question":"Nice Scream. Now what",
        {"title":"You screamed. No one is there. No one can save you.","response":11},
        {"title":"Your such a wimp.","response":12},
{	//4
    "question":"You run into a killer.",
        {"title":"Go ham","response":13},
		{"title":"kill him??","response":15},
{	//14
    "question":"You try to kill him",
        {"title":"Gouge ","response":16},

var currentLocation = 0;

window.printCurrentLocation = function(){
   document.getElementById("question").innerHTML =         db[currentLocation].question;
var answers = "";
for(var i=0,l=db[currentLocation].answers.length;i<l;i++){
    answers += "<p><button       onclick='setLocation("+db[currentLocation].answers[i].response+")'>"+db[curre   ntLocation].answers[i].title+"</button></p>";
document.getElementById("answers").innerHTML = answers;

window.setLocation = function(num) {
currentLocation = num;




@11morgan11 Cussing isn't allowed on these forums, please read through the forum guidelines. I've edited your post for you this time.