Clean up of code.

This commit is contained in:
Sacha Ligthert 2023-12-04 01:27:19 +01:00
parent 371de84218
commit 0d7a141830

14
game.go
View File

@ -169,22 +169,8 @@ func quit(game *Game) {
}
func (game *Game) randPos() Position {
//var safe bool = false
var pos Position
// for !safe {
// x := rand.Intn(80)
// y := rand.Intn(24)
// if x == 0 || x == 79 || y == 0 || y == 23 {
// safe = false
// } else {
// pos.x = x
// pos.y = y
// safe = true
// }
// }
x := 1 + rand.Intn(77)
y := 1 + rand.Intn(22)