Hi, and thanks for welcoming me to the community. I have been privately tinkering on an App/Game for a few years and finally have made some good progress with the evolution of Swift.
I have some initial questions concerning where I am at because of bandwidth issues. My game is just in alpha prototyping still testing various technologies and seeing how things work out.
I want to be strict and to the point hoping some of you will be able to easily understand what I am trying to relay, (pun intended?) HAHA
Anyway, I have a game currently (May 10, 2024) running solid, with Async/Await Distributed Actor Framework, using just for the simplest case TicTacFish Bonjour Networking sample package to network players moving around SpriteKit avatars on screen with a this topography:
AppleTV 4K (2022), for viewing purposes, with an iPhone 15 Pro Max, an iPad Pro M1, and a MacBook Pro M1 Pro. Here are some bandwidth numbers:
When connecting say two, the MBP to iPad, a low 60fps "hum" from machine to machine, is at 8KB/s, when one avatar moves around "networked" the usage goes up to 40KB. I can increase or double this base value by increasing the frequency of updates or distributed actor func calls.
If both are moving i.e. updates to both the usage goes to 80KB to 160KB.
When I add the MBP to iPad with iPhone, I get a "bar" of 40KB per each, so 120-160KB but now three times the load is about 360-480KB.
When I add the 4th, the AppleTV, the usage goes up to 768KB to 1MB/s.
When I have the avatars moving faster with twice the amount of updating the Bonjour networking was up to 2MB with all 4 in concert moving at that PEAK. But like I said I cut their firing rate in half and it's about ~750KB-1MB.
My question is actually a few, but let me preface; Back in the days of the journey, using say Sockets and OpenGL, my game would run on old 802.11n bonjour networking, and if I had a similar setup with 3 players my network usage would be say around 120KB/second TOTAL! for 3 players running around. This was the same with say CFNetwork usage, or even other later technologies (what a mess), i.e. when I handled the data sending myself via Streaming Bonjour or Server stream setups. I had absolute POWER haha control over how much data was being sent.
The thing is I have been waiting for a Framework like Distributed Actors for well over 10 years, to do things like, when characters running around are picking things up having to fight over who "actually" picked things up, with distributed actors there is NO DEBATE, and believe me that is a pain to debug by yourself!
I am still in the process of cutting things down etc, and have numerous ideas to assist when I move to using the Distributed Actor Cluster Network package. But the questions I have are:
-
is this kind of "Spiraling Network Bandwidth Growth" indicative of Distributed Actor Networks, ex. when adding more actors?
Meaning "that's just the way it is?" or am I doing something wrong? -
Because I was hoping for some kind of sharing of the load when it came to "distributing" the data. But I could also see how the ActorSystem would need to distribute and verify the data at least more than once, i.e. not to just one peer, each peer would have to share and then have some kind of graphing system where a different peer would verify where the other actor(s) are at, but I just don't see that in this implementation, being the simple Bonjour ActorSystem in TicTacFish, taking that on (of course), so back to the original question.
-
I am going to move to the WebSocket verison, to check out the bandwidth, and then eventually the Cluster, but I am hoping Apple will demo a more polished version of the Distributed Actor System? Really love it! Do any of you see this happening? Or is there something else going on here that I am not too keenly observing?
THanks!
NOTE: Just to be clearer, in summary I am asking, if say, I had 3 Actors sending 40KB/s UP to a server and then the server sending three transmissions back to each at 80KB/s DOWN, i.e. 240KB/s DOWN and 120KB/s UP (server's data bandwidth) that would be pretty much all. But in a "peer to peer" setup do we usually get this out of control spiraling network bandwidth growth even with our beloved Distributed Actors?