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

Add [Overlay] overrides to background design.ini #665

Merged
merged 1 commit into from
Feb 21, 2022

Conversation

Crystalwarrior
Copy link
Contributor

Add background overlay overrides so you don't have to copy-paste the same file if you're just using it across multiple pos
To make this work:

  1. Create a design.ini in your background folder
  2. Set up the overlays, like so:
[Overlays]
bg_name = overlay_name
  1. Now, you'll be able to re-use the same overlay for multiple backgrounds, which removes tedium and allows you to even improve file size!

Closes #642

…same file if you're just using it across multiple pos
@@ -3749,6 +3749,11 @@ void Courtroom::set_scene(QString f_desk_mod, QString f_side)
f_background = f_side;
f_desk_image = f_side + "_overlay";
}

QString desk_override = ao_app->read_design_ini("overlays/" + f_background, ao_app->get_background_path("design.ini"));
if (desk_override != "")
Copy link
Member

Choose a reason for hiding this comment

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

For the future, I prefer isEmpty() over comparing with an empty string

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

Successfully merging this pull request may close these issues.

Background's design.ini should allow to over ride bg/overlay pairs
2 participants