Fix architectural issue with ChanceCardManager #236

Merged
40457809 merged 3 commits from owen/chanceCardSerialization into dev 2026-03-15 21:27:37 +00:00
40457809 commented 2026-03-15 13:13:00 +00:00 (Migrated from gitlab.eeecs.qub.ac.uk)

ChanceCardManager is a static class, meaning that it's not serialized with GameSystem. This could cause some potential issues if the contents of ChanceCardManager.CARDS changes between saving and loading.

This MR converts ChanceCardManager to a normal class taht is instantated and stored in GameSystem (like PolicyManager). This also allows the chance card pool to be dynamic (can be set via GameSystemBuilder).

ChanceCardManager is a static class, meaning that it's not serialized with GameSystem. This could cause some potential issues if the contents of ChanceCardManager.CARDS changes between saving and loading. This MR converts ChanceCardManager to a normal class taht is instantated and stored in GameSystem (like PolicyManager). This also allows the chance card pool to be dynamic (can be set via GameSystemBuilder).
40441512 (Migrated from gitlab.eeecs.qub.ac.uk) approved these changes 2026-03-15 13:13:00 +00:00
40457809 commented 2026-03-15 13:13:01 +00:00 (Migrated from gitlab.eeecs.qub.ac.uk)

requested review from @40441188, @40446360, @40444856, @40435022, @40439721, and @40441512

requested review from @40441188, @40446360, @40444856, @40435022, @40439721, and @40441512
40457809 commented 2026-03-15 13:13:01 +00:00 (Migrated from gitlab.eeecs.qub.ac.uk)

assigned to @40457809

assigned to @40457809
40457809 (Migrated from gitlab.eeecs.qub.ac.uk) scheduled this pull request to auto merge when all checks succeed 2026-03-15 13:13:12 +00:00
40441512 commented 2026-03-15 21:27:35 +00:00 (Migrated from gitlab.eeecs.qub.ac.uk)

approved this merge request

approved this merge request
40457809 commented 2026-03-15 21:27:37 +00:00 (Migrated from gitlab.eeecs.qub.ac.uk)

mentioned in commit 932d4056a1

mentioned in commit 932d4056a14d4d41fa257144a976baa02cef9732
40457809 (Migrated from gitlab.eeecs.qub.ac.uk) merged commit 932d4056a1 into dev 2026-03-15 21:27:37 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
owenryan/carbonopoly!236
No description provided.