Facepunch / sbox-issues

176 stars 12 forks source link

Party System #5538

Closed garrynewman closed 4 months ago

garrynewman commented 6 months ago

Bring back the party system.

### Stage One
- [x] Clients can create a party
- [x] Clients can join a party
- [x] Party leader is signalled
- [x] Clients follow the party leader
- [x] Party members are listed
### Stage Two
- [x] Party members can talk to each other
- [x] Party members can voice chat to each other
- [x] Can leave a party while in-game
- [ ] Can kick/mute/chat to a party while in game
### Stage Three
- [x] Party can be made public
- [x] List public parties that aren't full
- [x] Make it obvious when a public party is joinable
- [ ] Allow friends to join party
- [ ] Invite friends to party
### Coding
- [x] Api allowing games to get party members
- [x] Api allowing hosts to get the party status of clients
trundlr commented 6 months ago

What happens when a party joins a game that is not meant for parties? Should we be able to specify if our game supports parties?

garrynewman commented 6 months ago

Seems like in that case the game won't be multiplayer, so I don't think it'd need specifically tagging as a non party game

yuberee commented 6 months ago

I can see some multiplayer games where you want to discourage teaming up like battle royales, but at that point it would use custom networking so not sure if party system would be compatable.

Retroeer commented 6 months ago

I think adding support for servers persisting between switching scenes should be on there as well no? The main use case I'd see is a main lobby scene where you party up with friends before heading into the game

CarsonKompon commented 6 months ago

I can see some multiplayer games where you want to discourage teaming up like battle royales, but at that point it would use custom networking so not sure if party system would be compatable.

I think the way Garry intends is that on game start you can query the Party, see if one exists and who is in it, and decide whatever you want to do from there.

That way it's 100% up to the discretion of the developer if having a party should send you to a different scene or what-have-you with them all (So if no party, you see main menu, if in party and host it sends you to a hosted game scene, and if in party and not host you put them in a scene that attempts to connect them to the host)

trundlr commented 6 months ago

I can see some multiplayer games where you want to discourage teaming up like battle royales, but at that point it would use custom networking so not sure if party system would be compatable.

I think the way Garry intends is that on game start you can query the Party, see if one exists and who is in it, and decide whatever you want to do from there.

That way it's 100% up to the discretion of the developer if having a party should send you to a different scene or what-have-you with them all.

Just thinking from the user experience perspective, if a user joins a game that supports multiplayer, but splits the party up so they aren't playing together, it would be easier to just show them that the game doesn't support party play from the menu.

That said, while it's definitely more of a niche case - I can see it being annoying for party hosts to have to manually enter and download games to find out if they can actually play it with their friends.

garrynewman commented 6 months ago

We're really talking about two ways of joining a game.

  1. You're the host. You start the game, and your party join you.
  2. You all join an existing server/host.

1 is easy, the game should be able to query the host and see info about the party, make special considerations on whatever it wants to do.

  1. is less simple. We can definitely pass along that we're in a party on join, and pass the details of the other party members. But I think it's really up to the game on what to do with that information.
CarsonKompon commented 6 months ago

Just thinking from the user experience perspective, if a user joins a game that supports multiplayer, but splits the party up so they aren't playing together, it would be easier to just show them that the game doesn't support party play from the menu.

Ah yes I see. I think it's maybe best if there's a popup when you go to play a game that doesn't support parties/multiplayer. "This game doesn't support multiplayer! Instead all party members will enter their own session!". I can see people partying up to play jam games that are singleplayer so they are all just queuing into their own individual sessions but still connected via party chat so the host can take them from game-to-game.

anthonysharpy commented 6 months ago

It'd be nice to also have the functionality like VR chat with the world portals. Something like:

One thing I want to be able to do is to send people to other gamemodes from my gamemode, for example

MD485 commented 6 months ago

Can kick/mute/chat to a party while in game

I have a question about this one.
Is the intention to have two active VOIPs in sessions?

While there is benefit to that ala how people play game in discord with their friends and talk in game when they want to, I do think that with party chat in consoles and discord in pc, games have become markedly more asocial and a little less fun because of it.

It might be nice to force people to talk in game chat, but still allow them to type to each other, but that would be a strong decision.

A fun ancillary feature to this system might be the ability to play single player games solo while still in the party's lobby, for situations where someone just has to "do something for a bit", it's like cool I'll play some levels of mazing then.

You could also allow the party leader to send everyone into a single player game, that might be a fun collaborative experience for fresh releases, people discovering the game together and chatting to each other in voip/text chat.

garrynewman commented 5 months ago

Yeah it does get a bit muddy around the chat. Swings and roundabouts.

On the one hand you don't want people to be able to cheat in games by dead people talking to live people etc, and you want to encourage interacting with rest of the game.

On the other hand if you limit any of that then people will just use discord etc anyway and you'll have all the same problems.

I think probably making it an option in the party and defaulting it to "just use game voice chat" might be the way to go.