move multiple object on isometric map

is it possible to move multiple objects within an isometric map without defining them as sprites?

so for example I have a 4x4 wall (built out of 16 tiles), when a certain condition is true I want all of the tiles to move to new locations

as far as I can see there is no mte.moveSpriteTo() which is for non sprite layers, am I wrong in thinking this?

if so is there another way I can move these tiles?

I know the start and end locX/Y of each tile, but just dont know how to transition between them

any help would be appreciated

Tiles are generally meant to be static objects that remain fixed at their map location. What you can do is spawn a sprite from the tile, remove the tile, and move the resulting sprite to your new position. For example:

local tile = mte.getTileObj(startLocX, startLocY, tileLayer) local tileSprite = tile:makeSprite() mte.changeSpriteLayer(tileSprite, tileLayer + 1) mte.updateTile({locX = startLocX, locY = startLocY, layer = tileLayer, tile = 0}) mte.moveSpriteTo({sprite = tileSprite, locX = endLocX, locY = endLocY, time = 1000})

It is also technically possible to move a tile object by directly manipulating it’s x any y properties as you would any other displayObject, if you really have to do so. This example assumes you’re still using an isometric map:

local tile = mte.getTileObj(startLocX, startLocY, tileLayer) --Insert into a higher layer so it doesn't move beneath the other tiles local layerObj = mte.getLayerObj({layer = tileLayer + 1}) layerObj:insert(tile) --Calculate the true destination coordinates local endPosX, endPosY = mte.locToLevelPos(endLocX, endLocY) local endPos = mte.isoTransform2(endPosX, endPosY) --Move the tile, then update the new tile location with the index of the old tile --and remove the old tile. local destroy = function(event) mte.updateTile({locX = endLocX, locY = endLocY, layer = tileLayer, tile = tile.index}) mte.updateTile({locX = startLocX, locY = startLocY, layer = tileLayer, tile = 0}) end transition.to(tile, {time = 1000, x = endPos[1], y = endPos[2], onComplete = destroy})

Tiles are generally meant to be static objects that remain fixed at their map location. What you can do is spawn a sprite from the tile, remove the tile, and move the resulting sprite to your new position. For example:

local tile = mte.getTileObj(startLocX, startLocY, tileLayer) local tileSprite = tile:makeSprite() mte.changeSpriteLayer(tileSprite, tileLayer + 1) mte.updateTile({locX = startLocX, locY = startLocY, layer = tileLayer, tile = 0}) mte.moveSpriteTo({sprite = tileSprite, locX = endLocX, locY = endLocY, time = 1000})

It is also technically possible to move a tile object by directly manipulating it’s x any y properties as you would any other displayObject, if you really have to do so. This example assumes you’re still using an isometric map:

local tile = mte.getTileObj(startLocX, startLocY, tileLayer) --Insert into a higher layer so it doesn't move beneath the other tiles local layerObj = mte.getLayerObj({layer = tileLayer + 1}) layerObj:insert(tile) --Calculate the true destination coordinates local endPosX, endPosY = mte.locToLevelPos(endLocX, endLocY) local endPos = mte.isoTransform2(endPosX, endPosY) --Move the tile, then update the new tile location with the index of the old tile --and remove the old tile. local destroy = function(event) mte.updateTile({locX = endLocX, locY = endLocY, layer = tileLayer, tile = tile.index}) mte.updateTile({locX = startLocX, locY = startLocY, layer = tileLayer, tile = 0}) end transition.to(tile, {time = 1000, x = endPos[1], y = endPos[2], onComplete = destroy})

if i have one tree object on 4 tile and different layer, so how can select it from map ?   

if i have one tree object on 4 tile and different layer, so how can select it from map ?