[Mod] Skylayer [0.5]

Grigor
Member
Posts: 21
Joined: Sun Dec 01, 2019 05:55

Re: [Mod] Skylayer [0.5]

by Grigor » Post

Hi Xeranas, been playing around with your mod. I have limited experience doing Minetest-type programming. I was wondering if you could tell me please:

a) Which command(s) might I use to change the default sky colors (using the method in your demo6)
b) Which file do I put the command in? (init.lua?)

I use my own sun and moon textures and "weather_pack" (Copyright (c) 2017 Artūras Norkus)

I know I could just run the game and type in "/sl_demo6_on" but is there a way to automate it, and make it default?

User avatar
xeranas
Member
Posts: 162
Joined: Fri Feb 05, 2016 11:06

Re: [Mod] Skylayer [0.5]

by xeranas » Post

Hi Grigor,
If you want default sky probably it's best is to define callback when a player joins the server (minetest.register_on_joinplayer). You can check callback and combine skylayer API add layer call (skylayer.add_layer).

Here minimalistic sample which sets default sky for the server (with changed moon and sun textures):
https://gitlab.com/rautars/skylayer_demo

Grigor
Member
Posts: 21
Joined: Sun Dec 01, 2019 05:55

Re: [Mod] Skylayer [0.5]

by Grigor » Post

Thanks, Xeranas... will try that out. Thanks for the lead (and for all your mods!)

...That works just as needed. This is the green light for me to embrace Mintest 5.3X. Didn't like the default sky color at all.

Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests