Hi,
I saw on this example http://docs2x.smartfoxserver.com/ExamplesUnity/object-movement, they update each player's coordinate on UserVariables. Currently, I'm working on a fast action shooting game and I use ExtensionRequest and ExtensionResponse to broadcast each player's position, so I wanna know which method has better performance ?
Which one has better performance ? Updating User Variables or sending Extension Response continuously ?
-
- Posts: 4
- Joined: 23 Oct 2017, 01:46
Re: Which one has better performance ? Updating User Variables or sending Extension Response continuously ?
Hi,
using ExtensioRequest and response is certainly the most flexible way to do it, as you can decide which data you want to send. Also ExtensionRequest allows you to switch between UDP and TCP protocols for every call, while UserVariables are TCP only.
Hope it helps
using ExtensioRequest and response is certainly the most flexible way to do it, as you can decide which data you want to send. Also ExtensionRequest allows you to switch between UDP and TCP protocols for every call, while UserVariables are TCP only.
Hope it helps
-
- Posts: 4
- Joined: 23 Oct 2017, 01:46
Re: Which one has better performance ? Updating User Variables or sending Extension Response continuously ?
Lapo wrote:Hi,
using ExtensioRequest and response is certainly the most flexible way to do it, as you can decide which data you want to send. Also ExtensionRequest allows you to switch between UDP and TCP protocols for every call, while UserVariables are TCP only.
Hope it helps
Ok, so comparing ExtensionRequest (using TCP) with UserVariables, which one has better performance ?
Re: Which one has better performance ? Updating User Variables or sending Extension Response continuously ?
I am not sure what you mean by performance?
If we're talking about hardware performance there is no difference. If we're talking about network performance there can be a minimal difference based on how you build the objects that you send. (e.g. smart use of numeric data types to minimize bandwidth)
In general the performance difference is negligible. What changes is the flexibility. Custom extension calls are more a bit more flexible because you can structure objects as you want.
Cheers
If we're talking about hardware performance there is no difference. If we're talking about network performance there can be a minimal difference based on how you build the objects that you send. (e.g. smart use of numeric data types to minimize bandwidth)
In general the performance difference is negligible. What changes is the flexibility. Custom extension calls are more a bit more flexible because you can structure objects as you want.
Cheers
Who is online
Users browsing this forum: No registered users and 51 guests