Removed conflicting and redundant logic
This commit is contained in:
@ -46,7 +46,7 @@ const previewPlacedMapObject = computed(() => ({
|
||||
|
||||
function updatePreviewPosition(pointer: Phaser.Input.Pointer) {
|
||||
const tile = getTile(props.tileMap, pointer.worldX, pointer.worldY)
|
||||
if (!tile || previewPosition.value.x === tile.x && previewPosition.value.y === tile.y) return
|
||||
if (!tile || (previewPosition.value.x === tile.x && previewPosition.value.y === tile.y)) return
|
||||
|
||||
previewPosition.value = { x: tile.x, y: tile.y }
|
||||
}
|
||||
|
Reference in New Issue
Block a user