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

Better fog API structure (visible, colours etc) #14176

Open
Zughy opened this issue Dec 28, 2023 · 2 comments
Open

Better fog API structure (visible, colours etc) #14176

Zughy opened this issue Dec 28, 2023 · 2 comments
Labels
@ Client / Audiovisuals Request / Suggestion The issue makes a suggestion for something that should be done but isn't a new feature. @ Script API

Comments

@Zughy
Copy link
Member

Zughy commented Dec 28, 2023

Problem

Currently, MT fog is quite limited, with people in these years requesting features like colour (#7284) and tweakable cloud fog (#7838). Also, players can turn it off by just pressing F3, breaking whatever aim the modder had (#14163)

Solutions

First of all, I suggest a visible parameter, both to create coherence with other celestial vault elements (sun, moon, stars and clouds) and to avoid this -1 hack on fog_distance, fog_start and whatever parameter may come next. I maintain a mod that includes an in-game editor for the celestial vault, and implementing fog hasn't been fun as I had to treat these parameters as a special case. Furthermore, it can be a nice way to tackle #14163, enforcing visible when declared (no matter if true or false)

Then I'd move fog_sun_tint, fog_moon_tint and fog_tint_type into fog

Last but not least, I wonder why fog is in set_sky. Like, in my mind is a weather condition, not a component of the celestial vault. Wouldn't be better to have a separate set_fog() function?

Alternatives


Additional context

No response

@Zughy Zughy added @ Script API @ Client / Audiovisuals Request / Suggestion The issue makes a suggestion for something that should be done but isn't a new feature. labels Dec 28, 2023
@lhofhansl
Copy link
Contributor

I agree with most of your suggestions. Where to put it in the API is always hard. Is it where you set clouds? Is it where you set lighting?

@Zughy
Copy link
Member Author

Zughy commented Jan 6, 2024

Definitely not lighting, it's not a light phenomenon. It's humidity coming from the soil, so it doesn't belong to the celestial vault either. In my mind it's something on its own, related to visibility

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
@ Client / Audiovisuals Request / Suggestion The issue makes a suggestion for something that should be done but isn't a new feature. @ Script API
Projects
None yet
Development

No branches or pull requests

2 participants