This commit is contained in:
Josh Deprez 2021-07-23 17:05:35 +10:00 committed by Josh Deprez
parent b9ab613167
commit aa6cbbf295

View file

@ -51,7 +51,7 @@ func (g *Game) Layout(outsideWidth, outsideHeight int) (w, h int) {
return g.ScreenWidth, g.ScreenHeight return g.ScreenWidth, g.ScreenHeight
} }
// Sort sorts the components by draw order. // Sort sorts the components by Z position.
// Non-Drawers are sorted before all Drawers. // Non-Drawers are sorted before all Drawers.
func (g *Game) Sort() { func (g *Game) Sort() {
// SliceStable to avoid z-fighting (among Non-Drawers and equal Drawers) // SliceStable to avoid z-fighting (among Non-Drawers and equal Drawers)