Tiles has Transform
This commit is contained in:
parent
ed5092cc3e
commit
540eab9a0f
1 changed files with 5 additions and 3 deletions
|
@ -10,11 +10,13 @@ type Tilemap struct {
|
|||
Map [][]Tile
|
||||
Src *ebiten.Image // must be a horizontal tile set
|
||||
TileSize int
|
||||
Transform ebiten.GeoM
|
||||
|
||||
ZPos
|
||||
}
|
||||
|
||||
func (t *Tilemap) Draw(screen *ebiten.Image, geom ebiten.GeoM) {
|
||||
geom.Concat(t.Transform)
|
||||
for j, row := range t.Map {
|
||||
for i, tile := range row {
|
||||
var op ebiten.DrawImageOptions
|
||||
|
|
Loading…
Reference in a new issue