this post was submitted on 18 Jun 2024
1 points (100.0% liked)
Fediverse
28362 readers
1221 users here now
A community to talk about the Fediverse and all it's related services using ActivityPub (Mastodon, Lemmy, KBin, etc).
If you wanted to get help with moderating your own community then head over to !moderators@lemmy.world!
Rules
- Posts must be on topic.
- Be respectful of others.
- Cite the sources used for graphs and other statistics.
- Follow the general Lemmy.world rules.
Learn more at these websites: Join The Fediverse Wiki, Fediverse.info, Wikipedia Page, The Federation Info (Stats), FediDB (Stats), Sub Rehab (Reddit Migration), Search Lemmy
founded 1 year ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
only in itself, it can be "temporarily solved" using an extension (like what Forgejo has for relations to Git, e.g. commits) for realtime, it could be something like how godot implements P2P multiplayer (over ICE/TURN/STUN) for federation between servers
I'm not sure if ActivityPub allows for an extension like that. And I mean if you open up a separate direct channel via TURN... It'll be incompatible with something like Mastodon anyways, so I then don't see a good reason for why to bother with the additional overhead of AP in the first place. I mean you could then just send the status updates in some efficient binary representation as data packets directly do the other players. So why use ActivityPub that needs to encode that in some JSON, send it to your home instance, which handles it, puts it in the outbox, sends HTTP POST requests to the inboxes of your teammates where it then needs to be retrieved by them... In my eyes it's just a very complicated and inefficient way of transferring the data and I really don't see any benefits at all.
So instead of extending AP and wrapping the game state updates into AP messages, I'd just send them out directly and skip AP altogether. That probably reduces the program code needed to be written from like 20 pages to 2 and makes the data arrive nearly instantly.
I suppose I could imagine ActivityPub being part of other things in a game, though. Just not the core mechanics... For example it could do the account system. Or achievements or some collectibles which can then be commented and liked by other players.
The TURN channel could be used ONLY for live multiplayer interactions (and everything else that needs dynamic state updates), while everything else (e.g. game data, achievements, avatar data, other static things) would be in AP