aframevr / aframe-inspector

:mag: Visual inspector tool for A-Frame. Hit *<ctrl> + <alt> + i* on any A-Frame scene.
https://aframe.io/aframe-inspector/examples/
MIT License
655 stars 203 forks source link

fix when saving the scene with a-frame watcher and color is changed #585

Closed khcd closed 5 years ago

khcd commented 5 years ago

I noticed when changing material color it wasn't being saved with aframe watcher due to an undefined in the entityupdate listener, other material properties seemed to be ok. I didn't test all of them as color was main concern.

Let me know if this is the best way to fix it.

previous payload when changing color:

{"sphere1":{"position":"0 1.234885180247932 -5","material":{},"box1":{"material":{}}}

now:

{"sphere1":{"position":"0 1.234885180247932 -5","material":{"color":"#4494ef"}},"box1":{"material":{"color":"#d93336"}}}

**Additions: fix CI build, I choose node 8 to be safe although can be changed to LTS

khcd commented 5 years ago

@fernandojsg Any feedback on this one? I can create a corresponding issue if required.