How can i receive packets from the client?

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

Moderators: Lapo, Bax

tulparid
Posts: 8
Joined: 01 Jan 2021, 08:56

How can i receive packets from the client?

Postby tulparid » 03 Jan 2021, 05:14

I am trying to get Login Packet and other packets sent from the client using LoginEventHandler extension.
User avatar
Lapo
Site Admin
Posts: 22999
Joined: 21 Mar 2005, 09:50
Location: Italy

Re: How can i receive packets from the client?

Postby Lapo » 04 Jan 2021, 15:52

Hi,
sorry your question is not clear.
It sounds like you're developing a server side extension. Check this introduction here:
http://docs2x.smartfoxserver.com/Extens ... uick-start

The example shows you how to handle a custom client request to sum two numbers.

As regards handling a login request, check this article:
https://smartfoxserver.com/blog/how-to- ... tom-login/

But also take a look at this component:
http://docs2x.smartfoxserver.com/Extens ... -assistant
which may simplify your job, if you're working with a database to verify user credentials.

Hope it helps
Lapo
--
gotoAndPlay()
...addicted to flash games

Return to “SFS2X Questions”

Who is online

Users browsing this forum: Baidu [Spider] and 60 guests