RNG – Blood: Procedural GPU Blood for URP


- Seven hit presets: bullet, close bullet, shotgun, headshot, blunt, blade and ... Easy to set up ... Two draw calls for all blood, flight, drying and fading run on the GPU, no garbage ...


by rengi.dev


Price History +

Procedural GPU blood for URP: drops in flight, splatter on floors and walls, wall runs, merging puddles, pools under bodies, footprints and drying. One line of code per hit.

Features:
- Drops in flight, splats on floors and walls, wall runs, merging puddles, pools under bodies, bloody footprints
- Blood dries and fades over time
- 7 hit presets (bullet, close bullet, shotgun, headshot, blunt, blade, explosion), all tunable in one settings asset
- Stains projected on the depth buffer: no decal projectors, no textures
- Two draw calls for all blood, zero GC allocations at runtime
- Adjustable limits for drops, splats, pools and footprints
- Setup window that checks and fixes URP settings in one click
- Blood Emitter and Blood Footprints components, no code needed
- Hit event for add-ons
- Green censored mode and gore-off switch
- Interactive demo scene and full documentation

Render pipeline: Universal Render Pipeline only (Built-in and HDRP not supported)
Unity version: 6000.0 or newer (tested on 6000.0, 6000.3, 6000.6)

Supported OS: tested on Windows with DirectX 11, DirectX 12, Vulkan and OpenGL Core. Other URP platforms are expected to work but have not been tested yet.

Documentation: included in the package, Rengidev/Blood/Documentation/README.md

RNG Blood is a procedural blood system for the Universal Render Pipeline. One line of code per hit gives you drops in flight, splats on floors and walls, runs that drip down walls, puddles that merge, pools that grow under bodies, bloody footprints and blood that dries over time. All blood in the scene is drawn on the GPU in two draw calls, without textures.


What it does
- Drops fly on a ballistic arc computed in the vertex shader and stretch with speed.
- Landing drops leave splats, rays, streaks or heavy blots, stretched by the angle they hit at.
- Drops that hit a wall leave runs that drip down over the next seconds.
- Fresh splats that land close together merge into one growing puddle.
- A body leaves a pool that grows under it and follows it while it exists.
- Blood dries: glossy red turns dark, matte and brown, then fades out.
- Walkers that step into a wet pool leave fading bloody footprints.
- Stains are projected onto the depth buffer, so they wrap over floors, ramps and walls without decal projectors. Stains on glass are drawn on the pane.
- Seven hit presets: bullet, close bullet, shotgun, headshot, blunt, blade and explosion. Every value is tunable.
- Any colour, a censored colour mode and an off switch for a gore option.
- A public hit event for add-ons such as dismemberment, sounds or hit marks.


Easy to set up
- Call Blood.Spawn(hit, direction) from your weapon code and you are done.
- Blood Emitter component for UnityEvents, Animation Events and Timeline, no code needed.
- A Setup window checks your URP settings and fixes them with one click.
- A live settings panel: tune every value with sliders while the game runs and save the result as a settings asset.
- Two demo scenes: a cinematic Crime Scene with old dried blood and a fresh impact, and a Hit Demo with a crash test dummy that reacts to every hit, six blood colours and the settings panel. Everything in the screenshots and the trailer is included in the package.
- Every setting has a tooltip. Full documentation is included.


Performance
Two draw calls for all blood, flight, drying and fading run on the GPU, no garbage collection at runtime. Measured on a GeForce RTX 5060 at 3840 x 2160: 0.1 ms when idle, 0.7 ms at the start of a fight, 2.9 ms with about 1000 stains on screen from a top-down camera. CPU: about 0.2 ms per hit. Limits for drops, splats, pools and footprints are settings, so you can trade amount for speed.


Requirements and limits
- Unity 6000.0 or newer with the Universal Render Pipeline. Tested on Unity 6000.0, 6000.3 and 6000.6 with DirectX 11, DirectX 12, Vulkan and OpenGL Core on Windows.
- Depth Texture must be on in your URP asset. The Setup window turns it on.
- The Built-in Render Pipeline and HDRP are not supported.
- VR single pass instanced rendering is not supported in this version.
- Mobile devices have not been profiled yet. Measured mobile numbers and lighter quality levels are planned for an update.
- No dependencies besides URP. No third-party code or assets.