asamy / forgottenmapeditor

Map editor written in lua for Open Tibia. Written with OtClient's framework.
Other
46 stars 20 forks source link

Undo / Redo - issues #54

Closed mindrage closed 10 years ago

mindrage commented 10 years ago

When using a ground pallette and you drag it over the same tile more than once, upper items will disappear, and they are not recognized by the undo operation. So they arent revertable

Update: Seems to be an general Brush issue, grounds should replace the current ground and not add as an new item.

Undo and redo only works for 1 tile at the time, a better thing to do is to make a framework for "map edits" Example: MapEditor:preformAction(tiles, action(tile))

MapEditor.preformAction stored the action and the "previous state" of that tile, that way be able revert all changes in one Undo/Redo

asamy commented 10 years ago

Seems to be an general Brush issue, grounds should replace the current ground and not add as an new item.

Fixed now.

For the undo thing, I just fixed some issues with it, can you try again?

asamy commented 10 years ago

Closing this as I got no response and it shall be fixed.