as3 error message

hi,

i a currently developing a space invaders style flash game and have came across the following error message:

TypeError: Error #1009: Cannot access a property or method of a null object reference.
at UFOGame/endGameLevel2()
at UFOGame/checkForAlienHits()

i have searched through the code and am unsure what it means. the function endGameLevel2() is to display the game over screen but this error is only displayed when you advance to level3 and not when it is game over.

any help would be greatly appreciated.

thanks

some code would help to understand your problem, but it seams you are trying to acess a property or method of a null object reference… what more can I say :stuck_out_tongue:

thanks smartarse

pensamente is correct - without seeing more of the code, that error is virtually meaningless on its own.

Cannot access a property or method of a null object reference. means this:
You Cannot access a property or method of a null object reference.

Something is not instantiated or defined, so ya didn’t set a variable. Ya can’t access a variable that doesn’t have a value obviously. What exactly do you expect us to tell you without any code? Anyways don’t bother posting it because this type of error happens because you were sloppy and didn’t set a variable so you should fix that yourself.