Added defences against shaders not compiling