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

Improve cloud particles #3003

Merged
merged 5 commits into from
Nov 8, 2024
Merged

Conversation

bruhmoent
Copy link
Member

@bruhmoent bruhmoent commented Jul 7, 2024

PR reopened due to simplesquirrel.

This PR:

  • Enables the change of X and Y speeds,
  • Renames the intensity setting to 'amount'
  • Adds an option for fog

@Frostwithasideofsalt
Copy link
Member

Could someone Re-run the builds?

@tobbi
Copy link
Member

tobbi commented Oct 16, 2024

@bruhmoent Can you rebase against latest master? That'll cause the builds to be rerun.

void
CloudParticleSystem::apply_fog_effect(DrawingContext& context)
{
float opacity = fog_max_value * (static_cast<float>(m_current_amount) - static_cast<float>(fog_start_amount)) / (static_cast<float>(max_amount) - static_cast<float>(fog_start_amount));
Copy link
Member

@MatusGuy MatusGuy Oct 17, 2024

Choose a reason for hiding this comment

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

What's going on with all the casting? These are floats. Is it because they're const? Constants should go to the top of this cpp file and should be marked constexpr and should be written in UPPER_CASE instead.

Copy link
Member Author

Choose a reason for hiding this comment

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

Iirc I had some sort of warning that made VS refuse to compile

@Frostwithasideofsalt
Copy link
Member

thought i had reviewed this earlier.

@MatusGuy MatusGuy merged commit c0ca3aa into SuperTux:master Nov 8, 2024
32 of 33 checks passed
@tobbi
Copy link
Member

tobbi commented Nov 8, 2024

Luckily, the CI failure was unrelated.

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.

4 participants