Opened 8 years ago

Last modified 4 years ago

#2982 new defect

[PATCH] The "preserve match settings" should also save player-assignments

Reported by: mimo Owned by:
Priority: Nice to Have Milestone: Backlog
Component: UI – Game setup Keywords: patch
Cc: Patch:

Description

Take a 2-player skirmish map, choose to play as player 2, then quit. When back to the game selection window, the player is back as player 1 and player 2 is unassigned.

Attachments (1)

preserveSettingsFix.patch (3.5 KB ) - added by Alex 8 years ago.
Not the best approach but it's working now.

Download all attachments as: .zip

Change History (16)

comment:1 by mimo, 8 years ago

Summary: The "preserve match seetings" sets player 2 unassigned after playing as player 2The "preserve match settings" sets player 2 unassigned after playing as player 2

comment:2 by Alex, 8 years ago

This is a (at least to me) known behaviour :P

I guess I'll just apply AIs to previously non-AI being slots.

comment:3 by Alex, 8 years ago

No, not working properly yet.

comment:4 by Alex, 8 years ago

Owner: set to Alex
Status: newassigned

by Alex, 8 years ago

Attachment: preserveSettingsFix.patch added

Not the best approach but it's working now.

comment:5 by Alex, 8 years ago

Keywords: review added

comment:6 by Alex, 8 years ago

Priority: Nice to HaveShould Have
Summary: The "preserve match settings" sets player 2 unassigned after playing as player 2[PATCH] The "preserve match settings" sets player 2 unassigned after playing as player 2

comment:7 by Stan`, 8 years ago

Keywords: patch added
Milestone: BacklogAlpha 18

comment:8 by Itms, 8 years ago

Keywords: review removed
Milestone: Alpha 18Alpha 19

comment:9 by mimo, 8 years ago

Milestone: Alpha 19Alpha 20

comment:10 by Stan`, 7 years ago

Owner: Alex removed
Status: assignednew

comment:11 by elexis, 7 years ago

Milestone: Alpha 20Backlog

Backlogging due to lack of progress.

comment:12 by elexis, 7 years ago

Keywords: review added
Milestone: BacklogAlpha 21
Priority: Should HaveNice to Have

An apparently working patch can be found at #3804

comment:13 by elexis, 7 years ago

Keywords: review removed
Milestone: Alpha 21Backlog
Summary: [PATCH] The "preserve match settings" sets player 2 unassigned after playing as player 2[PATCH] The "preserve match settings" should also save player-assignments

The fundamental problem is that the persistmatchsettings doesn't save the playerassignments (only save the playerdata, which includes AI settings and civs).

Saving playerassignments is something which would also help with rehosting, but has to be taken care of properly. Whomever changes this will have to ensure that the file not only grow but also shrinks (i.e. also delete assignments instead of only adding assignments inbetween games) and that the game doesn't break when trying to load matchsettings of an older version of 0AD.

Notice g_PlayerAssignments is saved in gamesetup.js and m_PlayerAssignments in NetServer.cpp.

comment:14 by elexis, 5 years ago

refs #4780

comment:15 by Imarok, 4 years ago

Component: UI & SimulationGame setup

Move tickets to Game Setup as UI & Simulation got some sub components.

Note: See TracTickets for help on using tickets.