Height is the amount of tiles on the y-axis of the spritesheet only if the sprite sheet is symmetric with no border.
()
| 184 | // Height is the amount of tiles on the y-axis of the spritesheet |
| 185 | // only if the sprite sheet is symmetric with no border. |
| 186 | func (s Spritesheet) Height() float32 { |
| 187 | return s.height / s.Cell(0).Height() |
| 188 | } |
| 189 | |
| 190 | func generateSymmetricSpriteRegions(totalWidth, totalHeight float32, cellWidth, cellHeight, borderWidth, borderHeight int) []SpriteRegion { |
| 191 | var spriteRegions []SpriteRegion |