Hi everyone! Let’s create another 2D effect that we can use in a game as an obstacle or an energy weapon. We’ll program an animated jagged line that resembles a lightning bolt or an electrical discharge.

Signed distance field raymarching in Godot 4, authored with nodes. Physics-driven metaballs melt into the SDF cubes in one fullscreen pass, and since every CSG op works on (color, distance) pairs, the colors blend along with the shapes.
Two free editions: Standalone shader (CC0): one .gdshader, no scripts paste onto a QuadMesh, edit map(). Godot Shaders https://godotshaders.com/shader/fullscreen-sdf-raymarching-with-smooth-csg-and-depth/
Node-based project (MIT): shapes as Node3D nodes, live editor preview, physics, up to 32 primitives and a write-up. VavLabs Mit
https://vav-labs.com/case-studies/sdf-raymarcher-godot/
Distance functions after Inigo Quilez.
youtube: https://youtu.be/Y1sd9Cx4NAs

Hello, everyone! Let’s again create a spatial shader for a 3D object. This time we’ll create a simple flag, make it wave gently in the wind, and demonstrate how we can dynamically control this effect in the vertex function.

I’m making a game where the player moves through an endless scrolling 2D world. Currently, I want the terrain to represent a sine wave, as shown in the provided illustration.
How should I setup my terrain scene to generate this terrain with collision? Or should the terrain generation be in the main game scene? If the later, what node structure should I use for my terrain?








