tile count is now calculated as "tiles on x" times "tiles on y"
This commit is contained in:
parent
bfb354a3cf
commit
f162a29b3c
|
@ -44,8 +44,7 @@ Spritesheet* spritesheet_from_texture(SDL_Texture* texture, IVector tile_size) {
|
|||
|
||||
self->tile_size = tile_size;
|
||||
self->tile_shear = self->resolution.x / self->tile_size.x;
|
||||
self->tile_count = self->resolution.x / self->tile_size.x + self->resolution.y / self->tile_size.y;
|
||||
|
||||
self->tile_count = self->resolution.x / self->tile_size.x * self->resolution.y / self->tile_size.y;
|
||||
return self;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue