Page 1 of 1

[Solved] How to enlarge torch range?

PostPosted: Fri Dec 30, 2016 17:13
by yawin
Hi everyone!

I'm creating a torch for a mod I'm doing. I would like it to illuminate a huge block radius. Changing "light_source" only changes the intensity of light, the range of that light, however, remains. How can I change that range so that the torch illuminates as much distance as I want?

Re: How to enlarge torch range?

PostPosted: Fri Dec 30, 2016 17:56
by hajo
There are only 4 bits for the light-level, i.e. 0-15. Completely dark is 0.
The sun has max light, at 15, everything else can only have max 14.

Stepping down the lightlevel by 1 with every block of distance,
and you see why there is a max range for lightsources.

So, just set the time of day to get the sun out (see light-switch in tutorial).

Re: How to enlarge torch range?

PostPosted: Fri Dec 30, 2016 22:21
by yawin
hajo wrote:There are only 4 bits for the light-level, i.e. 0-15. Completely dark is 0.
The sun has max light, at 15, everything else can only have max 14.

Stepping down the lightlevel by 1 with every block of distance,
and you see why there is a max range for lightsources.

So, just set the time of day to get the sun out (see light-switch in tutorial).


I can't use that because if I want to illuminate a cave, the sunlight does not get inside.

Re: How to enlarge torch range?

PostPosted: Mon Jan 02, 2017 16:20
by paramat
You can't, in Minetest light range is limited to 16 nodes.

Re: How to enlarge torch range?

PostPosted: Wed Jan 04, 2017 04:09
by twoelk
+ some time ago I created a cave with sunlight inside


Just recently after seeing some science fiction film about living in an ice age, I had thought of a game where plantlife would only be possible around large light sources as the sun wouldn't be light enough for that job, just as on some of the planets (or large moons) farther from the sun. This could be a technical device or some plant like them large trees at the beginning of the Silmarillion in Valinor as described by Tolkien. For this to work though the light these sources could spread should reach a lot farther than 16 nodes. If I let a tree grow 100 nodes high the light should spread farther than the tree is high. Right now it would probably not reach the ground from the bottom most leaves.
Being able to use an alternative large light source that lights a considerable area as part of some special game design would be usefull indeed. Not only for fantasy themes but also for science fiction and mining related themes.

Re: How to enlarge torch range?

PostPosted: Thu Jan 05, 2017 04:51
by yzelast
For this problem I imagined something like this:

X = torch
B = invisible light block
r = light

The default torch

r r r r r r r r r r r
r r r r r X r r r r
r r r r r r r r r r r

A "stronger torch"

r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r
r r r r r B r r r r r r r r r r B r r r r r r r r r r B r r r r r r
r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r
r r r r r B r r r r r r r r r r X r r r r r r r r r r B r r r r r r
r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r
r r r r r B r r r r r r r r r r B r r r r r r r r r r B r r r r r r
r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r r

I'm almost sure it will be much more heavier to run,but i think that will "simulate" a larger torch.

But there is another problem: a stronger torch will need to illuminate a higher and lower height, so a single "strong " torch would need a lot of light blocks.

Re: How to enlarge torch range?

PostPosted: Thu Jan 05, 2017 10:39
by Napiophelios
yawin wrote:Hi everyone!

I'm creating a torch for a mod I'm doing. I would like it to illuminate a huge block radius. Changing "light_source" only changes the intensity of light, the range of that light, however, remains. How can I change that range so that the torch illuminates as much distance as I want?


you need a mini sun source