kfarr / aframe-city-builder

🏗️ A-Frame project demonstrating touch controls for building a VR city scene
https://aframe.city
MIT License
87 stars 37 forks source link

undo no longer works with new ID system #21

Open kfarr opened 7 years ago

kfarr commented 7 years ago

after this commit to enable erase feature: https://github.com/kfarr/aframe-city-builder/commit/84f5a2c4f74aa9a0aeba6544768f68e273729942

it was necessary to change to uuid when creating new objects, discussion here: https://github.com/kfarr/aframe-city-builder/issues/20

this breaks the existing undo feature which simply looked for the ID 1 less than the value of the total number of city objects (https://github.com/kfarr/aframe-city-builder/blob/master/lib/builder-controls.js#L250).

undo should be fixed to support the new uuid system