Unexport render internal methods.

This commit is contained in:
Sascha L. Teichmann 2016-04-24 13:31:13 +02:00
parent 6ab45d13c0
commit 67a16e2d3e
1 changed files with 4 additions and 4 deletions

View File

@ -275,17 +275,17 @@ func (r *Renderer) RenderBlock(block *Block, colors *Colors) (err error) {
return
}
func (a Area) Contains(x, z int16) bool {
func (a Area) contains(x, z int16) bool {
return x >= a.X1 && x <= a.X2 && z >= a.Z1 && z <= a.Z2
}
func (a Area) IsHigher() bool {
func (a Area) higher() bool {
return a.Z2-a.Z1 > a.X2-a.X1
}
func areasContain(areas []Area, x, z int16) bool {
for _, r := range areas {
if r.Contains(x, z) {
if r.contains(x, z) {
return true
}
}
@ -317,7 +317,7 @@ func (r *Renderer) UncoveredAreas(newAreas, oldAreas []Area) []Area {
var xFirst bool
// Try to extend in the direction with most gain
// of blocks.
if area.IsHigher() { // Higher means to win more blocks in x direction.
if area.higher() { // Higher means to win more blocks in x direction.
xFirst = true
}
dirs: