a-frame-components icon indicating copy to clipboard operation
a-frame-components copied to clipboard

Component throws error in a-frame

Open nirajupadhyay11 opened this issue 6 years ago • 0 comments

I am trying to use this component but it throws the following error -

"Entity.setObject3D` was called with an object that was not an instance of THREE.Object3D". This error comes for the line -

this.el.setObject3D(null);

for the following snippet -

update: function () {
		this.water = undefined;
		this.el.setObject3D(null);
	},

Here is my implementation in a-frame

<a-scene>
   <a-assets>
	<img id="waters-normal" src="../images/models/waternormals.jpg" crossorigin="anonymous">
	<img id="sky" src="../images/models/sky.jpg" crossorigin="anonymous">
   </a-assets>
   <a-camera postion="0 1.2 0"></a-camera>		
   <a-ada-ocean position="0 0 0" src="#water-normal" opacity="0.6" width="1000" depth="1000"></a-ada-ocean>
   <a-sky src="#sky"></a-sky>
</a-scene>

nirajupadhyay11 avatar Oct 20 '18 15:10 nirajupadhyay11