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

Sky Lua API #76

Open
2 of 5 tasks
Unarelith opened this issue Mar 5, 2020 · 1 comment
Open
2 of 5 tasks

Sky Lua API #76

Unarelith opened this issue Mar 5, 2020 · 1 comment

Comments

@Unarelith
Copy link
Owner

Unarelith commented Mar 5, 2020

Those informations should be defined in Lua

  • Sky color
  • Fog color
  • Stars (amount, size, brightness)
  • Celestial objects: moon, sun, planets (size, speed, angle, texture, brightness, ...)
  • Possibility to change the sky in-game (see below)

For example:

mod:sky {
    id = "overworld",

    color = {
        day = {128, 255, 200},
        night = {28, 127, 50},
    },

    fog_color {
        day = {128, 255, 200},
        night = {28, 127, 50},
    },

    stars = {
        amount = 1000,
        size = 2,
        brightness = 1, -- ranges from 0 to 1
    },

    objects = {
        sun = {
            size = 20,
            speed = 1, -- 1 would be day length
            angle = 0, -- 0 would be default moon/sun plan
            texture = "sun.png",
            brightness = 1,
        }
    }
}

When dimensions will be implemented, they will use this API to know which sky to render. Done.

It should also be possible to change sky informations in-game. This could lead to more possibilities regarding sky, for example, it could be possible to change the sky when:

  • Block is placed/removed
  • Specific mob spaws
  • Specific weather event occurs
Unarelith added a commit that referenced this issue Mar 9, 2020
@Unarelith Unarelith mentioned this issue Apr 3, 2020
4 tasks
@LordDeatHunter
Copy link
Contributor

Close-proximity stars, or "Suns". Example:
Sun A does 48h rotations and Sun B does 24h rotations. When it's just Sun A, there's 65% light level on the surface, 80% for Sun B and 95% for both.

@Unarelith Unarelith mentioned this issue Jul 14, 2020
24 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants