diff --git a/pkg/atlas/atlas.go b/pkg/atlas/atlas.go index aaa7fd8..e681ff2 100644 --- a/pkg/atlas/atlas.go +++ b/pkg/atlas/atlas.go @@ -11,16 +11,16 @@ type Tile byte const ( // TileNone is a keyword for nothing - TileNone = Tile(GlyphNone) + TileNone = iota // TileRock is solid rock ground - TileRock = Tile(GlyphRock) + TileRock // TileGravel is loose rocks - TileGravel = Tile(GlyphGravel) + TileGravel // TileSand is sand - TileSand = Tile(GlyphSand) + TileSand ) // Glyph returns the glyph for this tile type diff --git a/pkg/atlas/chunkAtlas.go b/pkg/atlas/chunkAtlas.go index daee6e6..1d21741 100644 --- a/pkg/atlas/chunkAtlas.go +++ b/pkg/atlas/chunkAtlas.go @@ -128,7 +128,7 @@ func (a *chunkBasedAtlas) populate(chunk int) { obj = ObjectSmallRock } if obj != ObjectNone { - c.Objects[j*a.ChunkSize+i] = Object{Type: obj} + c.Objects[j*a.ChunkSize+i] = Object{Type: ObjectType(obj)} } } } diff --git a/pkg/atlas/objects.go b/pkg/atlas/objects.go index 1b9eb87..ac847fe 100644 --- a/pkg/atlas/objects.go +++ b/pkg/atlas/objects.go @@ -8,16 +8,16 @@ type ObjectType byte // Types of objects const ( // ObjectNone represents no object at all - ObjectNone = ObjectType(GlyphNone) + ObjectNone = iota // ObjectRover represents a live rover - ObjectRover = ObjectType(GlyphRover) + ObjectRover // ObjectSmallRock is a small stashable rock - ObjectSmallRock = ObjectType(GlyphSmallRock) + ObjectSmallRock // ObjectLargeRock is a large blocking rock - ObjectLargeRock = ObjectType(GlyphLargeRock) + ObjectLargeRock ) // Glyph returns the glyph for this object type