Am now using the following code...

{
        var sphere = new Sphere({radius:3, segmentsH:3, segmentsW:3,
material:"orange#orange"});
        view.scene.addChild(sphere);
        sphere.z = 303;
        sphere.addEventListener(MouseEvent.MOUSE_DOWN, MouseDown1);
        function MouseDown1(event:MouseEvent):void{
        var request:URLRequest = new URLRequest("http://google.com";);
        navigateToURL(request);}
}


...and am still having no success. Cant figure out where I'm going
wrong...

On Feb 2, 2:32 pm, Peter Kapelyan <[email protected]> wrote:
> In your code you call a "MouseDown" function but it doesn't exist...
> You do however have a "MouseDown1" function...
> So if you change
>
> stage.addEventListener(MouseEvent.MOUSE_DOWN, MouseDown)
>
> to
>
> stage.addEventListener(MouseEvent.MOUSE_DOWN, MouseDown1)
>
> it should work.
>
> -Pete
>
>
>
> On Mon, Feb 2, 2009 at 7:56 AM, Josh27 <[email protected]> wrote:
>
> > Hello again all
>
> > Have progressed along quite nicely with the creation and positioning
> > of the buttons on my 3D globe. However, I'm now having an issue with
> > the code and actually linking the buttons to a URL. I am currently
> > using the below code...
>
> > {
> > var sphere = new Sphere({radius:3, segmentsH:3, segmentsW:3,
> > material:"orange#orange"});
> > view.scene.addChild(sphere);
> > sphere.z = 303;
> > stage.addEventListener(MouseEvent.MOUSE_DOWN, MouseDown);
> > function MouseDown1(event:MouseEvent):void
> > {
> > var request:URLRequest = new URLRequest("http://groups.google.com/
> > group/away3d-dev/");
> > navigateToURL(request);
> > }
> > }
>
> > But this isn't working at all....
>
> > Any help you guys could give would be greatly appreciated.
>
> > Many Thanks
>
> > Josh
>
> --
> ___________________
>
> Actionscript 3.0 Flash 3D Graphics Engine
>
> HTTP://AWAY3D.COM

Reply via email to