Shaders (2021 Edition)

This is sort of a continuation of:

I’ve finally started to (barely and slowly) learn shaders and am starting to get some fun visible results. Step one was to take the ship shader and gut it to the very bare minimum of an unlit shader that displays textures and meshes.

Recently I’ve also managed to play around with the vertex distortion in the harvest shader.

Another thing I want to do is experiment with distortion and refraction.


What is the top one? Where are those different colours coming from?

I believe that’s the object space vertex positions. I think the colors are default opengl colors, but the important thing is they can tell you the origin point of the object. It’s similar to being able to determine the uv mapping coords of an object.

Figured out how to get camera position and was able to rebuild reflection and refraction shaders using formulas from



wow cool! I think I’ve totally been mission out on something: how did you open that debugging window?

1 Like

I believe it’s in uisettings.lua, change the activate value for the debug menu to 1 and it should show up. You can map a few commands to it, but the only “useful” ones I’ve found are disable engine glows and disable nav lights.

1 Like

Ah okay, thanks! Might still be worth checking out.

You can’t be disscussing this without me, arr!
Not sure about reflection/refraction. Stock ones look just fine to me.
Vertex distortion is nice to have, vertex shaders are a bit of beyond me. Not sure I like how it looks like, but it may have uses.
STCR (ping, @Nathanius) got nameplates, borgification and parallax mapping with a bit of my help, though I guess I’m too lazy to produce gifs or videos of those properly.

1 Like

Obligatory images to back up @Dark_Sentinel

Name Plates (aka "regos")


I’ve never succeeded in taking a picture of the parralax mapping successfully, we’re using it on our Dilithium crystal asteroids now and are intending to cross it with the Borg transwarp effect if possible to make the gate look even better

Transwarp Gate effect

I also stole this shader for use on the shields as below

Animated shields

1 Like