Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create new game_info entry for when an MP campaign advances to the next scenario #4281

Open
Pentarctagon opened this issue Aug 26, 2019 · 5 comments

Comments

@Pentarctagon
Copy link
Member

commented Aug 26, 2019

From Discord/IRC:

<Soliton> i meant to mention that mp campaigns are handled poorly so far.
<Soliton> as in advancing to the next scenario.
<Soliton> that should create a new entry.

@Pentarctagon Pentarctagon added the MP label Aug 26, 2019

@Pentarctagon Pentarctagon self-assigned this Aug 26, 2019

@ProditorMagnus

This comment has been minimized.

Copy link
Contributor

commented Aug 26, 2019

How is their replay handled?

@soliton-

This comment has been minimized.

Copy link
Member

commented Aug 26, 2019

You can detect advancing if an already started game is started again.
Since the DB code is only in server.cpp so far you may want to add a game::is_started() or so function.

@gfgtdf

This comment has been minimized.

Copy link
Contributor

commented Aug 26, 2019

How is their replay handled?

iirc not at all onyl the replay of the last game is saved, iirc there is also a seperate bug entry for that

@gfgtdf

This comment has been minimized.

Copy link
Contributor

commented Aug 26, 2019

related issue: #1492

@soliton-

This comment has been minimized.

Copy link
Member

commented Aug 26, 2019

Good point about the replay. A separate issue but sure would be great to fix that as well.

Probably just needs a save_replay() call at the right spot...

@Pentarctagon Pentarctagon added the Bug label Aug 26, 2019

Pentarctagon added a commit to Pentarctagon/wesnoth that referenced this issue Aug 26, 2019
Update a game's ID when advancing to the next scenario.
On receiving "store_next_scenario", increment wesnothd's game id counter and assign the game the new id.
Currently this is relevant for when an MP campaign advances to the next scenario, in order to avoid primary key conflicts as well as insert a new game_info row for the new scenario.

Also fixes wesnoth#4281 by adding a db call in "store_next_scenario" to insert the next scenario's game_info row.
Pentarctagon added a commit to Pentarctagon/wesnoth that referenced this issue Aug 30, 2019
Update a game's ID when advancing to the next scenario.
On receiving "store_next_scenario", increment wesnothd's game id counter and assign the game the new id.
Currently this is relevant for when an MP campaign advances to the next scenario, in order to avoid primary key conflicts as well as insert a new game_info row for the new scenario.

Also fixes wesnoth#4281 by adding a db call in "store_next_scenario" to insert the next scenario's game_info row.
Pentarctagon added a commit to Pentarctagon/wesnoth that referenced this issue Sep 4, 2019
Update a game's ID when advancing to the next scenario.
On receiving "store_next_scenario", increment wesnothd's game id counter and assign the game the new id.
Currently this is relevant for when an MP campaign advances to the next scenario, in order to avoid primary key conflicts as well as insert a new game_info row for the new scenario.

Also fixes wesnoth#4281 by adding a db call in "store_next_scenario" to insert the next scenario's game_info row.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.