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

Fix compound balance mode index #5774

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

0HyperCube
Copy link
Contributor

@0HyperCube 0HyperCube commented Dec 28, 2024

Brief Description of What This PR Does

The id for the compound balance mode option button now corresponds to the values given in the BalanceDisplayType enum.

public enum BalanceDisplayType
{
/// <summary>
/// Calculate things as if all processes run at max speed
/// </summary>
MaxSpeed = 0,
/// <summary>
/// Displaying things when setting ATP balance to be 0 (so only run things as fast as they need to be to live)
/// </summary>
EnergyEquilibrium = 1,

Related Issues

I noticed that the compound balance mode option button didn't work properly and also produced this log:

Unknown compound balance type: 2

Progress Checklist

Note: before starting this checklist the PR should be marked as non-draft.

  • PR author has checked that this PR works as intended and doesn't
    break existing features:
    https://wiki.revolutionarygamesstudio.com/wiki/Testing_Checklist
    (this is important as to not waste the time of Thrive team
    members reviewing this PR)
  • Initial code review passed (this and further items should not be checked by the PR author)
  • Functionality is confirmed working by another person (see above checklist link)
  • Final code review is passed and code conforms to the
    styleguide.

Before merging all CI jobs should finish on this PR without errors, if
there are automatically detected style issues they should be fixed by
the PR author. Merging must follow our
styleguide.

@revolutionary-bot
Copy link

The lead programmer for Thrive is currently on vacation until 2025-01-07. Until then other programmers will try to make pull request reviews, but please be patient if your PR is not getting reviewed.

PRs may be merged after multiple programmers have approved the changes (especially making sure to ensure style guide conformance and gameplay testing are good). If there are no active experienced programmers who can perform merges, PRs may need to wait until the lead programmer is back to be merged.

@hhyyrylainen hhyyrylainen added this to the Release 0.8.1 milestone Dec 28, 2024
@hhyyrylainen hhyyrylainen requested review from a team December 28, 2024 18:13
Copy link
Member

@dligr dligr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can confirm the outlined issue. Regarding the changes, I have noticed that the order of the items in CompoundBalanceDisplay.tscn is different than that of the enum in the code, which leads to the dropdown options corresponding to wrong display types. So, I think that the order should be reversed, either in the .tscn file or in the C# code.

@0HyperCube 0HyperCube force-pushed the fix-compound-balance-mode branch from 6d28f60 to b4a40b8 Compare December 28, 2024 21:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: In progress
Development

Successfully merging this pull request may close these issues.

4 participants