Hi Vanessa
It is such a shame that the lighting is based on changing the color of the blocks. But your mod is good regardless.
I have a small bug in your mod to report though:
The roofing tile slope nodeboxes are implemented wrong. You have probably not noticed because the slopes.lua file specifies a detail level of 256. ow I find this overkill compared to having several 1000 of these rendered in the same scene (combined with SW rendering we get client death).
Anyway. If you lower the detail to say '4' you will observe that the node is now exactly one block above where i should be. With detail 256 it is 1/256th of a block above the one below it.
The slope reads for example:
Code: Select all
slopeboxedge[i+1]={-0.5, -0.5+(4/detail), (i/detail)-0.5, 0.5, (i/detail)-0.5+(5/detail), 0.5}
What it should read is this:
Code: Select all
slopeboxedge[i+1]={-0.5, (i/detail)-0.5, (i/detail)-0.5, 0.5, (i/detail)-0.5+(1/detail), 0.5}
The key point being the constants 4 and 5.
The same issue is with the corner pieces as well. While you are at it, do set the detail default to 16. It is plenty.
Take a look at the technic/indev branch and the cnc_api.lua file if you want more inspiration.
Best regards.
Edit. As a curtsey here's the correct lines of code:
Code: Select all
homedecor_register_outer_corner = function(modname, subname, groups, images, description)
local slopeboxedge = {}
local detail = homedecor_detail_level
for i = 0, detail-1 do
slopeboxedge[i+1]={-0.5, -0.5+(i/detail), (i/detail)-0.5, 0.5-(i/detail), (i/detail)-0.5+(1/detail), 0.5}
end
Code: Select all
homedecor_register_inner_corner = function(modname, subname, groups, images, description)
local slopeboxedge = {}
local detail = homedecor_detail_level
for i = 0, detail-1 do
slopeboxedge[i+1]={-0.5, -0.5+(4/detail), -0.5, 0.5-(i/detail), (i/detail)-0.5+(5/detail), 0.5}
slopeboxedge[i+detail+1]={-0.5, -0.5+(i/detail), (i/detail)-0.5, 0.5, (i/detail)-0.5+(1/detail), 0.5}
end
Code: Select all
homedecor_register_slope = function(modname, subname, recipeitem, groups, images, description)
local slopeboxedge = {}
local detail = homedecor_detail_level
for i = 0, detail-1 do
slopeboxedge[i+1]={-0.5, (i/detail)-0.5, (i/detail)-0.5, 0.5, (i/detail)-0.5+(1/detail), 0.5}
end