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

CustomBottleRelic card icons render inconsistently from base game bottle relics #243

Open
dbjorge opened this issue Feb 2, 2020 · 0 comments

Comments

@dbjorge
Copy link

dbjorge commented Feb 2, 2020

CustomBottleRelic renders an icon of the bottle relic at the top-right of associated cards using the patch in RenderRelicOnCard, which patches AbstractCard::renderCard to achieve the effect. However, there are several inconsistencies with the base game:

  • The base game uses a scale factor of card.drawScale * Settings.scale * 1.5F, where RenderRelicOnCard is currently using card.drawScale * 0.8F. See below screenshot from master deck view, left 2 cards using base game relics and right card using a CustomBottleRelic:
    image

  • As of writing, the base game only sometimes renders the relic icon at the top-right corner of the card (ie, the base game does it in fewer places than BaseMod, in particular, not in the player's hand). The places where the base game currently renders the relic icons are:

    • CardGroup::renderMasterDeck
    • CardGroup::renderMasterDeckExceptOneCard
    • CardGroup::renderShowBottled
    • CardGroup::renderExceptOneCardShowBottled
    • MasterDeckViewScreen::render
    • GridCardSelectScreen::render

I noted a few other inconsistencies where it felt less obvious whether BaseMod should be adding corresponding logic for custom bottle relics; all of these are things that I think a basic bottle relic would need, but either you'd need to extend the CustomBottleRelic interface for them or there might be less-basic bottle relics that wouldn't want them:

  • The base game recalculates bottle relic descriptions when corresponding cards are upgraded (see AbstractPlayer::bottledCardUpgradeCheck) (would probably need to add setDescriptionAfterLoad to CustomBottleRelic to accomodate this)
  • The base game includes the bottled fields as part of makeStatEquivalentCopy
  • DollysMirror and Duplicator reset the "is in bottle" fields of base game duplicated cards to false, diverging from the usual behavior of makeStatEquivalentCopy.
  • FountainOfCurseRemoval omits curses bottled in base-game relics
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant