Fix bug where we were still placing psuedo-random objects down

This commit is contained in:
Marc Di Luzio 2020-07-25 23:39:13 +01:00
parent a235f6a5f5
commit 113090fbcb

View file

@ -2,7 +2,6 @@ package rove
import ( import (
"log" "log"
"math/rand"
"github.com/mdiluz/rove/pkg/maths" "github.com/mdiluz/rove/pkg/maths"
"github.com/mdiluz/rove/proto/roveapi" "github.com/mdiluz/rove/proto/roveapi"
@ -111,15 +110,6 @@ func (a *chunkBasedAtlas) populate(chunk int) {
} }
} }
// Set up any objects
for i := 0; i < len(c.Tiles); i++ {
if rand.Intn(16) == 0 {
c.Objects[i] = Object{Type: roveapi.Object_RockLarge}
} else if rand.Intn(32) == 0 {
c.Objects[i] = Object{Type: roveapi.Object_RockSmall}
}
}
a.Chunks[chunk] = c a.Chunks[chunk] = c
} }