Game Dev Tycoon

by nukeboy212

HTML

<h1 id = title>
GameDev.io
</h1>
<button id = "start">
Create A game
</button>
<button id = "tyc">
Tycoon
</button>
<button id = "fps">
FPS
</button>
<button id = "third">
Third Person
</button>

<input placeholder = "Type in Price" type="number"  id = "inputMon">

<button id = "Home">
Home
</button>

<button id = "Back">
Back
</button>

JavaScript

var money = 1000
var followers = 0
var moneygain = Math.floor(Math.random() * 3);
var gameprice = 0;
console.log(moneygain)
$("#tyc").hide();
$("#fps").hide();
$("#third").hide();
$("#inputMon").hide();
$("#Home").hide();
$("#Back").hide();


$("#start").click(function(){
$("#start").hide();
$("#title").text("Choose Your Genre");
$("#tyc").show();
$("#fps").show();
$("#third").show();
$("#Home").show();
});

$("#tyc").click(function(){
$("#inputMon").show();
$("#fps").hide();
$("#tyc").hide();
$("#third").hide();
$("#Back").show();
})
$("#fps").click(function(){
$("#inputMon").show();
$("#tyc").hide();
$("#fps").hide();
$("#third").hide();
$("#Back").show();
})
$("#third").click(function(){
$("#inputMon").show();
$("#tyc").hide();
$("#fps").hide();
$("#third").hide();
$("#Back").show();
})

$("#Home").click(function(){
$("#title").text("GameDev.io")
$("#start").show();
$("#tyc").hide();
$("#fps").hide();
$("#third").hide();
$("#inputMon").hide();
$("#Home").hide();
$("#Back").hide();
})

$("#Back").click(function(){
$("#inputMon").hide();
$("#tyc").show();
$("#fps").show();
$("#third").show();
$("#Back").hide();
})