Catching Server Events

Post here your questions about SFS2X. Here we discuss all server-side matters. For client API questions see the dedicated forums.

Moderators: Lapo, Bax

Post Reply
ConceptDog
Posts: 3
Joined: 14 Dec 2010, 15:42

Catching Server Events

Post by ConceptDog »

Hi All,

I'm trying to catch the USER_LOGIN event inside handleServerEvent within a class that extends SFSExtension.

Testing from a flash client, I can see the command come in, but breakpointing the handleServerEvent code I've written through a debugger doesn't show that I'm even seeing the event.

Can I catch events directly within SFSExtension without adding a specific event handler, or do I need to add a specific class to catch those events?

Thanks
dragagon
Posts: 19
Joined: 05 Dec 2010, 00:23

Post by dragagon »

make sure in the admin panel that you have the check box that says "Custom Login" otherwise you will see the message but your custom handler won't be called.
ConceptDog
Posts: 3
Joined: 14 Dec 2010, 15:42

Post by ConceptDog »

Thanks for the response.

It seems like you have to register for server events through external classes no matter what.

I'm not sure when the handleServerEvent inside an extended SFSExtension class would receive an event, but it doesn't appear to by default.
Post Reply