Ticket #1054 (closed defect: fixed)
[PATCH] multiplayer with no humans broken
| Reported by: | daemacles | Owned by: | MattDoerksen |
|---|---|---|---|
| Priority: | Nice to Have | Milestone: | Alpha 13 |
| Component: | UI & Simulation | Keywords: | patch |
| Cc: |
Description
It is possible to host a multiplayer game with only bots. When launched, gui/session/session.js fails because playerState is undefined.
Attachments
Change History
comment:1 Changed 13 months ago by MattDoerksen
- Keywords patch, review added
- Owner set to MattDoerksen
- Summary changed from multiplayer with no humans broken to [PATCH] multiplayer with no humans broken
For network games, check to ensure that at least 2 humans are in the game, otherwise they should be playing a single player game anyways. The only thing left to do is disable the launch game button or display a dialog box to the user saying this is why they can't start a game with just one person.
comment:2 Changed 13 months ago by k776
- Priority changed from Must Have to Nice to Have
- Milestone changed from Backlog to Alpha 10
comment:3 follow-up: ↓ 5 Changed 13 months ago by historic_bruno
- Component changed from Core engine to UI & Simulation
I disagree that we should require two human players, there's nothing wrong with only one (especially for testing purposes).
comment:5 in reply to: ↑ 3 Changed 13 months ago by MattDoerksen
Replying to historic_bruno:
I disagree that we should require two human players, there's nothing wrong with only one (especially for testing purposes).
In theory yes, but why would you need to test a single player multiplayer game? Once you get past the limitations (timing, etc.) for a multiplayer game, the same logic is being used as in a single player game. Also, single player multiplayer will be disabled in the final release anyways, so it shouldn't matter. Feel free to debate but I can't see a reason why single player multiplayer should be enabled.
comment:6 follow-ups: ↓ 7 ↓ 8 Changed 13 months ago by quantumstate
Once we get observer support then people might want to watch someone else playing single player. It seems like a pretty small use case though.
comment:7 in reply to: ↑ 6 Changed 13 months ago by MattDoerksen
Replying to quantumstate:
Once we get observer support then people might want to watch someone else playing single player. It seems like a pretty small use case though.
That's one case, and, I'm just throwing this out there, but wouldn't it be easier just to have them use a 3rd party program to stream video of the game or record the game for playback later given how much of a headache it's going to be to support this for the small number of people that will use it?
comment:8 in reply to: ↑ 6 Changed 13 months ago by feneur
Replying to quantumstate:
Once we get observer support then people might want to watch someone else playing single player. It seems like a pretty small use case though.
Wouldn't that technically be multiplayer? Just that the observer isn't actually playing. I'm not a programmer, and don't know this issue in-depth, but looking at the original description it says something about playerState. Couldn't "Observer" be a player state? (Or, in case I'm horribly wrong about what playerState might be, it still doesn't sound like "One player playing against bots, another player joining over the internet/network as an observer" shouldn't be defined as multiplayer anyway. At least from a game setup point of view.)
comment:9 follow-up: ↓ 10 Changed 12 months ago by am_butch
I don't actually see why including observer in single player is not an option. This is actually the reason I am writing this post, about half an hour ago I just wanted so see 2 bots fight each other but came across the problem in the ticket. I think this option will attract people who are more interested in programming AI rather then playing (talking of myself right now), meanwhile not affecting at all the ones who enjoy playing against the bots.
comment:10 in reply to: ↑ 9 Changed 12 months ago by quantumstate
Replying to am_butch:
I don't actually see why including observer in single player is not an option. This is actually the reason I am writing this post, about half an hour ago I just wanted so see 2 bots fight each other but came across the problem in the ticket.
This is possible currently by launching the game like this:
./pyrogenesis -quickstart -autostart="Oasis" -autostart-ai=1:qbot -autostart-ai=2:qbot
Look at the readme file in binaries/system for more options like using a random map.
comment:11 Changed 10 months ago by k776
- Keywords patch added; patch, removed
- Milestone changed from Alpha 11 to Backlog
comment:12 Changed 4 months ago by ben
- Status changed from new to closed
- Resolution set to fixed
In 13070:
comment:13 Changed 4 months ago by historic_bruno
- Keywords review removed
- Milestone changed from Backlog to Alpha 13
