[Mod] Beacons [beacons]

User avatar
SpaghettiToastBook
Member
 
Posts: 52
Joined: Sun Feb 22, 2015 21:11
Location: The Milky Way
In-game: STB

[Mod] Beacons [beacons]

by SpaghettiToastBook » Tue Jan 22, 2019 07:04

This mod adds beacons in several different colors:
Image

You can craft beacons with steel ingots, a mese lamp, and dye like this:
Image
You can also mix a beacon and dye to get a different-color beacon.

You can set the maximum height of a beacon's light beam in minetest.conf with the setting beacon_height. The default is 0, which means that the beam's height is unbounded.

Dependencies: None
Optional dependencies: default, dye

Download

Source

License (code and textures): CC0
Last edited by SpaghettiToastBook on Mon Feb 18, 2019 03:48, edited 1 time in total.
 

User avatar
aristotle
Member
 
Posts: 65
Joined: Wed Mar 14, 2018 23:40
GitHub: askotos
IRC: aristotle_
In-game: aristotle

Re: [Mod] Beacons [beacons]

by aristotle » Fri Jan 25, 2019 17:11

Thank you! I like your mod.

I appreciate you can set the beacon height to whatever you like, thus I set it to 1000 but this generates an error.
At line 2 you just need to convert the read value to a number:

Code: Select all
local beacon_height = tonumber(minetest.settings:get("beacon_height")) or 0


A small hint from a newbie: if you used the mod storage API, the value might be different on each map! :D
Happy builds & explorations!
 

User avatar
SpaghettiToastBook
Member
 
Posts: 52
Joined: Sun Feb 22, 2015 21:11
Location: The Milky Way
In-game: STB

Re: [Mod] Beacons [beacons]

by SpaghettiToastBook » Fri Jan 25, 2019 19:54

aristotle wrote:Thank you! I like your mod.

You're welcome!

aristotle wrote:I appreciate you can set the beacon height to whatever you like, thus I set it to 1000 but this generates an error.

Fixed!
 

User avatar
texmex
Member
 
Posts: 1580
Joined: Mon Jul 11, 2016 21:08
GitHub: tacotexmex
In-game: texmex

Re: [Mod] Beacons [beacons]

by texmex » Fri Jan 25, 2019 20:36

Cool! Good little mod, good recipe too. Code seems legit too (I’ve tried one badly coded before).

If only plantlikes could be rotated we could have sideway beacons as well…
 

Astrobe
Member
 
Posts: 236
Joined: Sun Apr 01, 2018 10:46

Re: [Mod] Beacons [beacons]

by Astrobe » Sat Feb 16, 2019 11:58

Thanks for the mod.

One issue though is that in the distance, the beam is made grey by the fog. A drastic way to fix it is to change the light beam blocks definition:
- drawtype="liquid"
- tiles="default_cloud.png"
- alpha=4

It makes the beam very faint, almost invisible. But the transparency hides some artifacts and the effect when you move away/come near looks more right.

I think it could be improved further with a less boring texture than cloud, perhaps even an animated texture.
 

User avatar
runs
Member
 
Posts: 811
Joined: Sat Oct 27, 2018 08:32
GitHub: runsy

Re: [Mod] Beacons [beacons]

by runs » Sat Feb 16, 2019 23:29

Astrobe wrote:Thanks for the mod.

One issue though is that in the distance, the beam is made grey by the fog. A drastic way to fix it is to change the light beam blocks definition:
- drawtype="liquid"
- tiles="default_cloud.png"
- alpha=4

It makes the beam very faint, almost invisible. But the transparency hides some artifacts and the effect when you move away/come near looks more right.

I think it could be improved further with a less boring texture than cloud, perhaps even an animated texture.


Cool trick :-)
 


Return to WIP Mods



Who is online

Users browsing this forum: No registered users and 3 guests