Strange Error in Flash 11

Software: Away3D 3.x

10th Planet, Newbie
Posted: 30 November 2011 01:37 PM   Total Posts: 2

Got something that works OK in Flash Player 10 but not 11. I’d like to try to put it in the showcase at sometime, but need to sort this first.

The development version is at

uncommonpeople.co.uk/?show=2011

You have to pick the dev template “Uncommon People 2011b” off the menu at the top to see it (the blue bar at the top tells you what to do).

Normally you click a band to select it, at which point it floats to the middle and also shows its members. Double-clicking brings up a profile of the band. This is fine for people with the FlashPlayer v.10 plugin. However, if you’ve got v.11 you can’t do the single-click to select the band, although the double-click action still works to open the profiler.

It’s a bit hard to post the code as it’s a client site but wondered if anyone with a trace version can make anything of the errors?

We get:

TypeError: Error #1009: Cannot access a property or method of a null object reference.
at com::Band/remove()
at com::Marker/onMouseUp()
at com::Band/onMouseUp()
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at away3d.core.base::Object3D/dispatchMouseEvent()
at away3d.containers::View3D/bubbleMouseEvent()
at away3d.containers::View3D/fireMouseEvent()
at away3d.containers::View3D/onMouseUp()

...at the time you click.

Not after free help on a commercial project - just wondering if anybody has had anything similar.

Thanks in advance.

&

   

Avatar
theMightyAtom, Sr. Member
Posted: 30 November 2011 09:04 PM   Total Posts: 669   [ # 1 ]

From the error stack (the error is at Band.remove, the rest is just the path of the event), I would say this was a problem in Band class rather than anything to do with Away3D. Both Band and Marker get the mouse call, is this as it should be? Do you use the debugger? That will show you the actual line where things go wrong.

I would say this is the most common error you see when programming AS3.
It happens when you reference an object that hasn’t been created yet, or has already been deleted. In a nutshell, when you do an operation on an object/variable that doesn’t exist, or is out of scope.

My advice would be to get to know the debugger in your environment (Flash IDE, FlashDevelop, Flash Builder, etc.) it will save you days of guessing :O)

Good Luck!

   

10th Planet, Newbie
Posted: 01 December 2011 11:50 PM   Total Posts: 2   [ # 2 ]

Cheers, Mighty. That’s giving me hope.

Just baffled about how it’s out of scope/non-existant for a single click yet at the same time it’s there for the double-click.

&

   
   

X

Away3D Forum

Member Login

Username

Password

Remember_me



X