Posted: 29 Jan 2009, 11:43
Hi Lapo.
According to the server logs when I restart the server, I have version 1.6.5.01. According to the admin console, I have the same version. So I'm assuming that the install is all ok and I'm on the right version.
I installed the Java NPC example in the simple chat zone and ran it. I received the following line in the log:
INFO | jvm 1 | 2009/01/29 13:27:34 | -----> SERVER READY <-----
Looking into the code, I see that this is written in the handleInternalEvent function. So, it seems that the server IS sending the message and the extension is receiving it.
BUT...
I also changed the code of the jsonSample.as extension of the simple chat zone to the following:
These lines do not trace for this zone at all, and same for my personal extension when looking for "serverReady".
So it seems that the java extensions receive the event, but the actionscript ones do not...
Another thing to note, is that when running the NPC example, I get the following output:
So the NPC creation didn't work for me. And I got the same NPC creation failed for my own NPC in my extension as mentioned in my previous post.
I tried the suggestion of pt_dev and set the ServerIP to *, restarted the server, and got the same error for the NPC example, but my NPC for my extension actually worked...
But at the end of the day, I still don't ever get the 'serverReady' event in my actionscript extension...
According to the server logs when I restart the server, I have version 1.6.5.01. According to the admin console, I have the same version. So I'm assuming that the install is all ok and I'm on the right version.
I installed the Java NPC example in the simple chat zone and ran it. I received the following line in the log:
INFO | jvm 1 | 2009/01/29 13:27:34 | -----> SERVER READY <-----
Looking into the code, I see that this is written in the handleInternalEvent function. So, it seems that the server IS sending the message and the extension is receiving it.
BUT...
I also changed the code of the jsonSample.as extension of the simple chat zone to the following:
Code: Select all
function handleInternalEvent(evt)
{
trace("*** handleInternalEvent! ***");
trace("***"+evt.name+"***");
}So it seems that the java extensions receive the event, but the actionscript ones do not...
Another thing to note, is that when running the NPC example, I get the following output:
Code: Select all
INFO | jvm 1 | 2009/01/29 13:38:10 | 13:38:10.078 - [ INFO ] > [TaskScheduler] ... started ::
INFO | jvm 1 | 2009/01/29 13:38:10 | 13:38:10.078 - [ INFO ] > [BlueBoxHandler]... started ::
INFO | jvm 1 | 2009/01/29 13:38:10 | 13:38:10.078 - [ INFO ] > [EventWriter] ..... started :: 1 thread(s)
INFO | jvm 1 | 2009/01/29 13:38:10 | 13:38:10.078 - [ INFO ] > [SystemHandler] ... started :: 1 thread(s)
INFO | jvm 1 | 2009/01/29 13:38:10 | 13:38:10.078 - [ INFO ] > [ExtensionHandler]. started :: 1 thread(s)
INFO | jvm 1 | 2009/01/29 13:38:10 | 13:38:10.078 - [ INFO ] > [DeadChannelsPolicy: strict]
INFO | jvm 1 | 2009/01/29 13:38:10 | 13:38:10.078 - [ INFO ] > Server is up and running!
INFO | jvm 1 | 2009/01/29 13:38:10 | -----> SERVER READY <-----
INFO | jvm 1 | 2009/01/29 13:38:10 | [ it.gotoandplay.extensions.examples.npc.NpcAvatarExample2 ]: NpcRoom created.
INFO | jvm 1 | 2009/01/29 13:38:11 | 13:38:10.968 - [ WARNING ] > NPC creation failed, due to I/O error. Local socket connection failed.
INFO | jvm 1 | 2009/01/29 13:38:11 | Exception in thread "SystemHandler-1" java.lang.NullPointerException
INFO | jvm 1 | 2009/01/29 13:38:11 | at it.gotoandplay.smartfoxserver.extensions.ExtensionHelper.joinRoom(ExtensionHelper.java:671)
INFO | jvm 1 | 2009/01/29 13:38:11 | at it.gotoandplay.extensions.examples.npc.NpcAvatarExample2.setupUser(NpcAvatarExample2.java:153)
INFO | jvm 1 | 2009/01/29 13:38:11 | at it.gotoandplay.extensions.examples.npc.NpcAvatarExample2.initNpcUsers(NpcAvatarExample2.java:111)
INFO | jvm 1 | 2009/01/29 13:38:11 | at it.gotoandplay.extensions.examples.npc.NpcAvatarExample2.prepareNpcs(NpcAvatarExample2.java:65)
INFO | jvm 1 | 2009/01/29 13:38:11 | at it.gotoandplay.extensions.examples.npc.NpcAvatarExample2.handleInternalEvent(NpcAvatarExample2.java:184)
INFO | jvm 1 | 2009/01/29 13:38:11 | at it.gotoandplay.smartfoxserver.controllers.MessageHandler.dispatchEvent(MessageHandler.java:147)
INFO | jvm 1 | 2009/01/29 13:38:11 | at it.gotoandplay.smartfoxserver.controllers.SystemHandler.processEvent(SystemHandler.java:185)
INFO | jvm 1 | 2009/01/29 13:38:11 | at it.gotoandplay.smartfoxserver.controllers.SystemHandler.run(SystemHandler.java:143)
INFO | jvm 1 | 2009/01/29 13:38:11 | at java.lang.Thread.run(Unknown Source)I tried the suggestion of pt_dev and set the ServerIP to *, restarted the server, and got the same error for the NPC example, but my NPC for my extension actually worked...
But at the end of the day, I still don't ever get the 'serverReady' event in my actionscript extension...