[Question] Is it possible to selectively receive AOI updates

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

Moderators: Lapo, Bax

Void*
Posts: 75
Joined: 15 Feb 2021, 13:49

[Question] Is it possible to selectively receive AOI updates

Postby Void* » 26 Mar 2023, 13:14

Bit of an odd one. Whilst we don't transmit a lot of data (around 4-5kb/sec to each player), some users are still struggling on slower end connections, and mobile *G connections.

For lower end graphical hardware, we use a setting to lower the number of rendered players (as it's not important in most cases) to increase their performance.
Is there something similar we can do for those on struggling internet connections? Can we bypass, or selectively toggle, AOI updates?

The only thing I can think of so far is to completely isolate them from the AOI (remove their player object/user), or, place them in a certain MMOAPI Position that is guaranteed not to be used by any other player.

Please let me know if there is a graceful way to include this functionality.

Please note: that the way the server and the extensions are configured, it wouldn't really be feasible to give them their own Room *on demand*. By On Demand, I mean via client side command, so I'd like to avoid this avenue if possible.
User avatar
Lapo
Site Admin
Posts: 23008
Joined: 21 Mar 2005, 09:50
Location: Italy

Re: [Question] Is it possible to selectively receive AOI updates

Postby Lapo » 26 Mar 2023, 13:56

Hi,
no there's no such options. By your description the application is already well optimized in terms of networks usage: 4-5kb/sec is really not much by today standards and most slow mobile connections should be able to deal with it.

What is probably happening to the clients you've mentioned is that they are incurring in a lot of lag, maybe due to physical distance from the server? Or really bad mobile providers :(

Unfortunately there will always be a small % of users that will not meet the base requirements and will struggle to keep up with the packet/rate. Given the numbers you have mentioned I'd expect this % to be very small.

Cheers
Lapo
--
gotoAndPlay()
...addicted to flash games
Void*
Posts: 75
Joined: 15 Feb 2021, 13:49

Re: [Question] Is it possible to selectively receive AOI updates

Postby Void* » 27 Mar 2023, 12:00

Some days are better than others, I'd say on average it's ~10% of the playerbase. This number is *high* considering, but it makes sense given the context of where these players are (both in a geographic and general network context). So the % I'm not worried about.

I'll see what I can do about the protocol itself, there are definitely places left for optimisation that I've intentionally left (no need to pre-optimise if you don't need to). Your idea about the lag is probably correct, I just wish there was a way we could stop them from disconnecting. The disconnections are client forced; a bit like if you were to unplug the WiFi/Ethernet, so the server still thinks they're connected until the session idle timeout kicks in.
It's inconvenient for them as they're constantly having to reconnect - hence why I was wondering if we could essentially let them play by themselves so the only network communication is query -> response, rather than a real-time stream.

Anyway, thanks for you reply :)
User avatar
Lapo
Site Admin
Posts: 23008
Joined: 21 Mar 2005, 09:50
Location: Italy

Re: [Question] Is it possible to selectively receive AOI updates

Postby Lapo » 29 Mar 2023, 08:48

hence why I was wondering if we could essentially let them play by themselves so the only network communication is query -> response, rather than a real-time stream.

Not sure I follow. How would players be able to play by themselves other than by connecting to the server?
The query -> response model you mentioned is essentially what happens when you're connected to SFS. There is no streaming. Streaming is done when there's a source producing a continuous flow of data and clients receive them in chunks (like YT, Twitch etc...) but with zero interactivity.

Maybe you can clarify...?
Cheers
Lapo

--

gotoAndPlay()

...addicted to flash games
Void*
Posts: 75
Joined: 15 Feb 2021, 13:49

Re: [Question] Is it possible to selectively receive AOI updates

Postby Void* » 30 Mar 2023, 09:33

Sorry, the way I talk about what's happening with the server obviously won't be what you're used to ^.^

By "real-time streaming" I mean the continuous updates needed by other players' actions (i.e. They begin movement, they change direction, they interact with the world... any 3rd party update).

By "query -> response", I mean to suggest that the only network communication would be responses initiated by a player's own actions. (i.e. I cannot move to this location, I need to change map, I need to talk to this NPC... any 1st person update)

By "play by themselves", I mean to remove other players from their world view (not play offline), so that the game appears to be single player. This works in most cases as the player vs player element is very structured regarding where and when it happens.

To further on this topic though (regarding the disconnections and the AOI updates) I implemented map instancing into our game and forced a couple of maps to be single player instances reducing the network traffic to almost nothing (chat updates + ping, essentially) and people still get thrown off by the client (Socket error 1006, no further information given by the browser) so it didn't fix anything, but we do have a useful new tool now at least :)

Return to “SFS2X Questions”

Who is online

Users browsing this forum: No registered users and 57 guests