Time Nick Message 02:58 ShadowNinja Merging #11871 and #11919 in 10m. 02:59 ShadowBot https://github.com/minetest/minetest/issues/11871 -- Cap damage overlay duration to 1 second by Wuzzy2 02:59 ShadowBot https://github.com/minetest/minetest/issues/11919 -- Fix vector.from_string returning a table without vector metatable by Desour 11:19 MTDiscord is the object property "colors" a functional feature? according to GreenXenith, it has been in the engine for 9 years and the commit was e42eeec: "New object property which allows changing the color and alpha of mesh materials. Due to the current lighting systems it doesn't work yet, but the full implementation is there", is there a chance this still doesnt work, as when GreenXenith tried it and it didnt work 11:24 celeron55 the colors do get given to irrlicht via setMeshColor() 11:25 MTDiscord nothing seems to happen, however 11:25 celeron55 // Set mesh color (only if lighting is disabled) 11:25 celeron55 if (!m_prop.colors.empty() && m_glow < 0) 11:25 celeron55 setMeshColor(mesh, m_prop.colors[0]); 11:25 celeron55 but only if glow < 0 11:27 celeron55 i mean, that gives setMeshColor() the first one from colors of course 11:28 MTDiscord but m_glow < 0 is impossible 11:28 MTDiscord so, not only is it impossible to evaluate, but it wont even use all the colors as documented? 11:28 celeron55 so when glow < 0, colors[0] is for... manually forcing the mesh to be colored as if the mesh was displayd under lighting of such color 11:29 celeron55 but otherwise colors is not used at all 11:29 celeron55 wait 11:29 MTDiscord again, glow cant be < 0 11:29 celeron55 i missed all the other uses of colors 11:29 MTDiscord the other uses require directional lighting which we don't have 11:30 sfan5 of course glow can be < 0, it's even documented 11:30 celeron55 well lua_api.txt does say glow can be < 0 11:30 MTDiscord Ah, right that is what thats supposed to do 11:31 celeron55 what i don't know whether that system actually works or is used by anyone 11:31 MTDiscord Well glow less than 0 works as intended (disables lighting) but the colors certainly still dont work 11:33 celeron55 hmm, setMeshColor isn't an irrlicht thing, it just sets the vertex colors of all the meshbuffers 11:35 MTDiscord pretty sure we ignore those colors in the shaders though 11:35 celeron55 ah shaders 11:35 celeron55 does it work with shaders disabled? 11:36 MTDiscord Nope 11:36 celeron55 the only way that wouldn't be visible is if something else sets them to something else right after before the mesh is shown... or if you have to tell irrlicht the meshbuffers were modified, i really should remember how this works 11:39 celeron55 yes i think it's set to something else right after 11:40 celeron55 nothing prevents GenericCAO::updateLight from ending up calling setMeshColor() when glow < 0 11:41 celeron55 and when shaders are enabled the shader version of the same thing happens even when glow < 0 11:41 celeron55 wait 11:41 celeron55 i'm absolutely blind 11:42 celeron55 literally at the beginning of GenericCAO::updateLight it says "if (m_glow < 0) return;" 11:42 MTDiscord lmao 11:42 MTDiscord loool 11:42 MTDiscord xD 11:43 celeron55 i think realistically the only way to find out what actually happens is a debugger... 11:46 celeron55 does someone have a minimal mod handy that tries to use this? 11:51 celeron55 well i do now 11:56 celeron55 the glow=-1 of a luaentity does get transferred up to GenericCAO::m_glow and is handled in GenericCAO::updateLight like it should be 11:57 celeron55 that's the diff for testing it http://paste.dy.fi/7gK 11:58 celeron55 though i sure hope that's the correct way to specify color for that field 11:58 celeron55 wait of course it's not 11:58 MTDiscord yes, colors wants colorspec from what i saw 11:59 celeron55 add one more {} because it's a list of colors 11:59 MTDiscord oh yes 11:59 celeron55 and of course it doesn't give any error 8) 12:00 MTDiscord by the way, https://github.com/minetest/minetest/blob/master/doc/lua_api.txt#L7190 contradicts https://github.com/minetest/minetest/blob/master/doc/lua_api.txt#L7215 12:01 celeron55 wait what 12:01 celeron55 the m_glow < 0 stuff happens only for m_prop.visual == "upright_sprite" 12:01 celeron55 :D 12:01 MTDiscord it doesnt say that textures = {itemname} is deprecated on 7215,, and that you should use wield_item = itemname 12:02 celeron55 and IT WORKS 12:03 MTDiscord ? 12:03 celeron55 as long as you have upright_sprite, glow < 0 it works 12:03 celeron55 somebody just forgot to add the glow < 0 stuff into other visuals in GenericCAO 12:04 celeron55 but... it only works *with* shaders 12:05 celeron55 this is so broken it might as well be removed 16:01 appguru sfan5: I'm getting a -Wsign-compare warning, should I cast to u32? Should be irrelevant as this is in an if-branch which checks whether the signed value is positive anyways. 16:02 sfan5 yes 16:02 sfan5 sign-compare is a stupid warning anyway