How can I get User.Properties in Client side (C#)

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

Moderators: Lapo, Bax

hungpq
Posts: 2
Joined: 08 Dec 2022, 03:35

How can I get User.Properties in Client side (C#)

Postby hungpq » 08 Dec 2022, 03:40

Dear SFS team,

I'm newbie here and try to get User.Properties in Client side (C#) I find that I can do it in server side with user.getProperty() but not in Client (C#). Please help and thanks in advance
User avatar
Lapo
Site Admin
Posts: 23026
Joined: 21 Mar 2005, 09:50
Location: Italy

Re: How can I get User.Properties in Client side (C#)

Postby Lapo » 08 Dec 2022, 10:48

Hi,
User.properties are server-side only. They can't be accessed from client side.

What you need to use instead is User Variables, which are custom values attached to a client and are constantly kept updated from both client and server side.
Take a look at the documentation here, for more details and examples:
http://docs2x.smartfoxserver.com/Develo ... -variables

Cheers
Lapo
--
gotoAndPlay()
...addicted to flash games
hungpq
Posts: 2
Joined: 08 Dec 2022, 03:35

Re: How can I get User.Properties in Client side (C#)

Postby hungpq » 09 Dec 2022, 02:09

Great thanks

Return to “SFS2X Questions”

Who is online

Users browsing this forum: No registered users and 87 guests