I am currently detecting a button click, and then creating a room based on the button that is clicked, and the width and height of a certain div element. After the room forms, there is an option to return to the previous selection via another button. While the room forms, and the back button works as well, if I once more try creating the room after going back, the room doesn’t form, despite it still existing in the hierarchy. I am checking for button clicks using
initialize. I tried shifting the
jquery code to
update, but that understandably returns undefined for the width and height as the HTML was defined only in
initialize. Is there any reason why the room doesn’t form for a second time?
PROJECT - https://playcanvas.com/editor/scene/943414 (to debug, click let’s go, then any height, and then BTDV. Repeat. If any height is clicked for the second time, it won’t work.)
EDIT - The entire
ui.js file seems to be disabled. Why could this be?