Updating upto 1000 users per second.

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

Moderators: Lapo, Bax

maSteve
Posts: 2
Joined: 12 Jun 2018, 00:05

Updating upto 1000 users per second.

Postby maSteve » 12 Jun 2018, 00:18

Hello,

I'm working on a resource based game(a small fun little projecting that i am using to testing the bounds of my skill and software that is available to me) , the general overview is each player will have Up to 40 resources ticking per second. I have the logic sorted for this, doing 40000+ calculations in around 17ms using smart fox task scheduler.

Now i am wondering what is the best way to test the data sent out to the clients each tick. My data structure is 40 arrays of doubles output to one SFSObject that is sent to each user currently connected. Will this work?

I suppose what my question is, is there a way to simulate 1000 users connected? So i can measure/adjust my code.


Thanks :)
User avatar
Lapo
Site Admin
Posts: 23026
Joined: 21 Mar 2005, 09:50
Location: Italy

Re: Updating upto 1000 users per second.

Postby Lapo » 12 Jun 2018, 07:47

Hi,
there. You can build a local test fairly easily. Here's an article that will help you with that:
https://smartfoxserver.com/blog/buildin ... test-tool/

My data structure is 40 arrays of doubles output to one SFSObject that is sent to each user currently connected. Will this work?

Yes, I don't think there's any problem with that.
If I understand it correctly you're going to send this data structure every 1 sec to all players. Correct?
If so, I don't see any problems with that.

Hope it helps
Lapo
--
gotoAndPlay()
...addicted to flash games
maSteve
Posts: 2
Joined: 12 Jun 2018, 00:05

Re: Updating upto 1000 users per second.

Postby maSteve » 12 Jun 2018, 11:01

Thank you for the link i did look for this i must have missed it!

If I understand it correctly you're going to send this data structure every 1 sec to all players. Correct?

Yes this is correct :)
User avatar
Lapo
Site Admin
Posts: 23026
Joined: 21 Mar 2005, 09:50
Location: Italy

Re: Updating upto 1000 users per second.

Postby Lapo » 12 Jun 2018, 15:17

maSteve wrote:Thank you for the link i did look for this i must have missed it!

If I understand it correctly you're going to send this data structure every 1 sec to all players. Correct?

Yes this is correct :)

To search for specific topics you can start from our documentation website:
http://docs2x.smartfoxserver.com/

Click the "Search the docs" button at top of the menu (right hand side) and search for key words.

Cheers
Lapo

--

gotoAndPlay()

...addicted to flash games

Return to “SFS2X Questions”

Who is online

Users browsing this forum: No registered users and 98 guests