Hi I am using away3d 2.5.2 and i am new to away3d. While i am creating
a cube the following error can be showned.

>>>>>1067: Implicit coercion of a value of type Cube to an unrelated type 
>>>>>away3d.core.base:Object3D.<<<<<<

Is it any wrong with my code.. please help me.


my code:

package{
        import flash.display.*;
        import flash.events.*;
        import away3d.containers.View3D;
        import away3d.primitives.*;
        public class Cube extends Sprite{
                private var view:View3D;
                public function Cube(){
                        stage.frameRate=30;
                        addChild(view=new View3D({x:100,y:200}));
                        view.addEventListener(Event.ENTER_FRAME,onFrame);
                        var cube:Cube=new Cube();
                        view.scene.addChild(cube);
                }
                private function onFrame(ev:Event):void{
                        view.render();
                }
        }
}

Reply via email to