Just made this file for a new project. thought id upload it.
in the file just add the shader to the object. the cube is the light source. may need to rename it in the shader to not get mixed up. its name is still “Cube” so be careful.
The fault is in line 18 of the vertex shader. This is the line 30 of the script.
It generates a vector of 3 floats and tries to write the vec3 into a single float. Also multiply something with 1.0 is useless so I removed it.