Timer Troubles

Post here your questions about Actionscript and Java server side extensions development.

Moderators: Lapo, Bax

Post Reply
Mather
Posts: 11
Joined: 15 Aug 2007, 08:36

Timer Troubles

Post by Mather »

Hi, Ive been using the SetTimeout function to run a few events in our system, the function is running from an actionscript extension called WowCommands, every now and then however the timer seems to go a bit haywire and seems to miss a command and start spamming the output window with messages similar to this:

Code: Select all

Exception in thread "Timer-56510" org.mozilla.javascript.WrappedException: Wrapp
ed java.lang.NullPointerException (WowCommands.as#255)
        at org.mozilla.javascript.Context.throwAsScriptRuntimeEx(Context.java:17
57)
        at org.mozilla.javascript.MemberBox.invoke(MemberBox.java:170)
        at org.mozilla.javascript.NativeJavaMethod.call(NativeJavaMethod.java:24
3)
        at org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:66)

        at org.mozilla.javascript.gen.c11._c12(WowCommands.as:255)
        at org.mozilla.javascript.gen.c11.call(WowCommands.as)
        at org.mozilla.javascript.optimizer.OptRuntime.callProp0(OptRuntime.java
:119)
does anyone know what could be causing this or alternatively a sort of onEnterFrame equivalent function that could be run on the extension where i can constantly update values manually and give me a bit better control?

Cheers

Scott.
User avatar
Lapo
Site Admin
Posts: 23438
Joined: 21 Mar 2005, 09:50
Location: Italy

Post by Lapo »

The null pointer exception seems to be caused at line 225 of your WowCommands.as
What is happening at that line? Probably you're manipulating an object that is null

Btw, what version of SFS do you use?
Lapo
--
gotoAndPlay()
...addicted to flash games
Post Reply