Shaders on Roblox

Currently I am trying to pull of a half tone shader to pull of an interesting style for my game. However after a bit of research I can’t seem to find anything to allow custom shaders on roblox.

Half tone shader
image

I am also willing to do cel shading. However, most “cel shading” tutorials are just for the outline which is useful but doesn’t really cover creating the shadows. I have seen both of these tutorials (Tutorial 1 and Tutorial 2) but they don’t really cover what I want to achieve. The first tutorial has weird artifacting with colours from light and the second tutorial is way to bright.

Cel shading shader
image

I can’t seem to find anyway to properly do this. If it is possible to make a script that automatically bakes the shadows into the map by placing textures then it could be possible, preferably I would like shaders to just exist on roblox but if I have to run a heavy script that automatically bakes the shaders in and keep the shaders in, then I’m willing to do it.

Any advice, pointers, or resources I could use would be incredibly helpful.

3 Likes

Maybe give this a read. You could try using a surface appearance with a semi transparent texture set to overlay.

I feel like the problem with this is I can’t pull off any shadows without already knowing where the shadow is going to be. Maybe I’m misunderstanding how to do it but I can’t seem find a way to get just harsher light diffusion where it goes down it stages. I’ve kinda given up on the ability to do halftone shadows but maybe there is a way

to do it in a dynamic lighting context, without using native roblox lighting/shaders, you would have to use some maths to orient the texture overlay and that would still only account for the main game lightsource, as the resource I’ve given you is relying on a premade texture. I would say you could do some lighting maths to define a normal map or similar for a texture, but I don’t believe you can procedurally modify a texture’s normal map in runtime

1 Like

Yeah I don’t expect to be able to do any real time shadows. I will most likely do research on trying to use maths to apply a texture as a shadow. Hopefully roblox can add some shader system at some point, most game engine’s have it and to not have any real way to modify how lighting works is annoying for a lot of developers from what I have seen.

2 Likes

Yeah, I’m really hoping they add some way to do custom shaders eventually. It’s one of the only major reasons I’d consider the Roblox engine a step down from the others

1 Like