Hi Ian,

The following (revised just now) HelloAway3D.as code works on CS3.

HTH,

David Z

// --- begin AS3 source HelloAway3D.as --- //
package 
{
    import flash.display.*;
    import flash.events.*;
    import flash.utils.*;
    
    import away3d.containers.*;
    import away3d.primitives.*;
    import away3d.materials.*;
    
    [SWF(backgroundColor="#222266", frameRate="60", width="600",
height="400")]
    public class HelloAway3D extends Sprite
    {
        public var view:View3D;
        public var sphere:Sphere;
        
        public function HelloAway3D()
        {
            view = new View3D({x:stage.stageWidth/2,
y:stage.stageHeight/2});
            addChild(view);

            sphere = new Sphere({material:new WireColorMaterial(0xFF7700,
0xCC4400), radius:250, segmentsW:12, segmentsH:9});

            view.scene.addChild(sphere);
            view.camera.lookAt(sphere.center.position);

            addEventListener(Event.ENTER_FRAME, onEnterFrame);
        }

        private function onEnterFrame(event:Event):void
        {
            view.render();
            sphere.rotationY = getTimer() / 100;
        }

    }

}
// --- end AS3 source: HelloAway3D.as --- //


-----Original Message-----
From: [email protected] [mailto:[email protected]] On
Behalf Of tictox
Sent: Tuesday, July 28, 2009 8:26 PM
To: away3d.dev
Subject: [away3d] Re: a sad start to checking up on away3d


UPDATE::

changing my publish settings to target flash player 9 removed the
error mentioned above and brought a new error in ::

ArgumentError: Error #1063: Argument count mismatch on
away3d.primitives::Sphere(). Expected 0, got 2.
        at HelloAway3D()


IF your API has been changed so that the Shere constructor does not
take any params .. should you not think about updating your examples
folder?

???????????????????????????????

On Jul 29, 5:17 am, tictox <[email protected]> wrote:
> Hi All at Away3d,
>
> I just svn'ed the latest build of your engine , and just like the last
> time i did this , a few months back , when taking your HelloAway3D
> class hooking it up to a fla as the  document class , included the src
> folder in the publish settings and got the same error i was faced with
> last time ::
>
> TypeError: Error #1034: Type Coercion failed: cannot convert
> flash.geom::matri...@271a8ac1 to away3d.core.math.Matrix3D.
>         at away3d.containers::View3D()
>         at HelloAway3D()
>
> this is on a new pc as well...
>
> Im on windows vista basic sp1 using flash cs4 strict mode is disabled
> so  what is the issue here? I not new to flash or 3D engines and have
> successfully used Papervision3d and Alternativa3d , but am curious to
> play with your engine every now and then when i get a gap , last time
> i gave it half an hour only to never get a single thing rendering?
>
> This makes me feel like a real nube pondering to myself .. how is
> everyone else getting this to work ?
>
> thanks
> Ian


Reply via email to