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

Draw all horizons and sky base, in front of stars #7932

Merged
merged 1 commit into from Dec 6, 2018
Merged

Draw all horizons and sky base, in front of stars #7932

merged 1 commit into from Dec 6, 2018

Conversation

paramat
Copy link
Contributor

@paramat paramat commented Dec 3, 2018

Draw all horizons and sky base, in front of stars

Move star draw to before sun glow texture draw and before sun draw,
not currently essential but the logical order. Will be necessary if
a 'no far ground' option is added, to draw stars behind the sun.
/////////////////////////

screenshot_20181203_052922

^ PR

Closes #7920
When the player is high enough for ground level to not be rendered or loaded, instead of seeing stars through the MT world below there is now a sense of the dark world below.

Recent testing in MT master with more and larger stars shows that stars are already hidden below E and W horizons:

screenshot_20181202_062332

Now we know of this, the dark rectangle is noticeable on the left with normal stars in MT master:

screenshot_20181201_042216

As the stars rotate with time they appear from behind, and disappear behind, these E and W rectangles.
This PR fixes the inconsistency, completes the horizons and moves the sky base drawing to later to be in front of sun, moon and stars. Only 2 more quads are drawn.
/////////////////////////////

Additionally we could have a 'groundless' option that does not draw the 'far cloudy fog things', the sun horizon glow texture, or the 5 quads that hide sun, moon and stars.
In this case the sun and moon would have to always be drawn for their complete circles. This would be like being in deep space between sun and moon, in daytime the blue sky would suggest a completely air world hanging in space.
This would be suitable for 'groundless' worlds like skyblock or floating islands, and if time is set to night, suitable for space games.

I could code this later if it's decided to be necessary.

@Fixer-007
Copy link
Contributor

I did not understand your post exactly, but consider the situation if you spawned in some sort of space station, so the stars/sun/moon needs to be visible in all directions in some use cases.

@paramat
Copy link
Contributor Author

paramat commented Dec 3, 2018

Indeed, i can add a clientside (for now, could possibly be part of 'set sky' later) option for that as described if required, either in this PR or in a follow-up PR.

Move star draw to before sun glow texture draw and before sun draw,
not currently essential but the logical order. Will be necessary if
a 'no far ground' option is added, to draw stars behind the sun.
@ghost
Copy link

ghost commented Dec 5, 2018

I would approve commit 1, it's a nice touch, good job, but I have not contributed to Minetest, sorry! I think mostly everyone will also agree to merge it.

However, I think commit 2 can be controversial because there are games that don't need it and others that do, and that was smart of you to request comments on the forum. I think it should be merged as well as it will make space themed or surreal themed games easier, such as Skyblock-clones and space adventures. Even for end users this has a positive effect, those just wanting to build a spaceship in singlenode. Obviously, it's not server-side but nonetheless would be an improvement over the current horizon space hybrid we've got right now IIRC.

Cheers.

builtin/settingtypes.txt Outdated Show resolved Hide resolved
@paramat
Copy link
Contributor Author

paramat commented Dec 6, 2018

I'm collecting opinions in the forum https://forum.minetest.net/viewtopic.php?f=5&t=21528
I think i prefer to merge commit 1 now as it's obvious, can always code something later.
EDIT: 2nd commit deleted.

@paramat paramat added the Trivial The change is a trivial bug fix, documentation or maintenance change, as per the Git Guidelines label Dec 6, 2018
@paramat paramat merged commit 08884d2 into minetest:master Dec 6, 2018
@paramat paramat deleted the fullhorizon branch December 8, 2018 04:11
Wuzzy2 pushed a commit to Wuzzy2/minetest that referenced this pull request Dec 11, 2018
Move star draw to before sun glow texture draw and before sun draw,
not currently essential but the logical order. Will be necessary if
a 'no far ground' option is added, to draw stars behind the sun.
osjc pushed a commit to osjc/minetest that referenced this pull request Jan 23, 2019
Move star draw to before sun glow texture draw and before sun draw,
not currently essential but the logical order. Will be necessary if
a 'no far ground' option is added, to draw stars behind the sun.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bugfix 🐛 PRs that fix a bug @ Client / Audiovisuals Trivial The change is a trivial bug fix, documentation or maintenance change, as per the Git Guidelines
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Stars are rendered below horizon
3 participants