Skip to content

Commit

Permalink
remove redundant code
Browse files Browse the repository at this point in the history
  • Loading branch information
Edward358-AI committed May 14, 2024
1 parent 4c96851 commit c9f715f
Showing 1 changed file with 0 additions and 20 deletions.
20 changes: 0 additions & 20 deletions game.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,32 +42,12 @@ tiles.addEventListener("click", (e) => {
e.target.style.backgroundColor = "#0040ff"
if (each.type == "select") {
playerdata.selectSeeds--
if (playerdata.selectSeeds == 0) {
choosing.children[2].disabled = true
select.using = false
choosing.value = "noselect"
}
} else if (each.type == "brown") {
playerdata.brownSeeds--
if (playerdata.brownSeeds == 0) {
choosing.children[3].disabled = true
brown.using = false
choosing.value = "noselect"
}
} else if (each.type == "gold") {
playerdata.goldSeeds--
if (playerdata.goldSeeds == 0) {
choosing.children[4].disabled = true
gold.using = false
choosing.value = "noselect"
}
} else {
playerdata.seeds--
if (playerdata.seeds == 0) {
choosing.children[1].disabled = true
plain.using = false
choosing.value = "noselect"
}
}
let usedFert = false
playerdata.water--
Expand Down

0 comments on commit c9f715f

Please sign in to comment.