Scroll screenspace texture with CustomMaterial

So I have this shader that scrolls a screenspace texture in the y direction:

But when I apply this to customMaterial, the texture won’t scroll.

Does anyone know what I’m doing wrong?

Small mistake:

material.getEffect().setFloat('time', u_time);

should be:

material.getEffect().setFloat('u_time', u_time);


Thanks for finding the mistake Evgeni :smiley: :smiley: