refactor: simple
This commit is contained in:
parent
2d1b3400fd
commit
1a8e4c5b89
|
@ -29,13 +29,7 @@ export default class TilesView extends Container {
|
|||
|
||||
chunksForExtent([x, y, w, h]) {
|
||||
const [tw, th] = this.tiles.tileSize;
|
||||
/* eslint-disable no-param-reassign */
|
||||
x /= tw;
|
||||
w /= tw;
|
||||
y /= th;
|
||||
h /= th;
|
||||
/* eslint-enable no-param-reassign */
|
||||
return this.chunksForUnitExtent([x, y, w, h]);
|
||||
return this.chunksForUnitExtent([x / tw, y / th, w / tw, h / th]);
|
||||
}
|
||||
|
||||
chunksForUnitExtent([x, y, w, h]) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user