center spawn position in the middle of a tile, instead of the upper left corner
This commit is contained in:
parent
92137dc0a3
commit
9e835620f1
1 changed files with 2 additions and 2 deletions
|
@ -650,8 +650,8 @@ export class GameScene extends ResizableScene implements CenterListener {
|
|||
for (const layer of this.mapFile.layers) {
|
||||
if (layerName === layer.name && layer.type === 'tilelayer' && (layerName === "start" || this.isStartLayer(layer))) {
|
||||
const startPosition = this.startUser(layer);
|
||||
this.startX = startPosition.x;
|
||||
this.startY = startPosition.y;
|
||||
this.startX = startPosition.x + 16;
|
||||
this.startY = startPosition.y + 16;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue