I’m making a game where players play as a computer virus and I was wanting the bits of the path they stand on to start glitching when they move off them. I’m trying to find a good tutorial for a glitch shader but the only on I found seemingly doesn’t work. Does anyone have any recommendations for tutorials that I can use.
I would first learn the basics of shaders if you haven’t done that already. Then proceed to disssect existing shaders (either from images, videos or code.) and try to understand how they are made.
What you told so far makes me think that this might be either a screen space effect, or something you build into shader of some objects in your environment. Then you would need to pass the position of the object causing the distortion to the shader/image effect. Then use that as a limiting factor so that you can mask out or adjust intensity of the effect accordingly so that it’s not happening everywhere, but close to where that position is.
But I think it would be useful to first clarify and focus the idea and see what you exactly want to happen so that you can think about how to actually build it. Vague descriptions and ideas don’t usually go far.
For the actual visual glitches (2D movements of the pixels) there are some good pointers and theory in the book of shaders. Search for it. But basically if you are trying to build classic digital screen (or analog too) glitches, you manipulate UV coordinates so that you can make different areas move at different times and with different intensity. Time is often used as an input so that you simulate something that changes over time, like flicker of the screen, wobbly scanlines or moving digital image blocks etc.