Here's a very simple foliage shader than moves in the wind, and a script that sets the required global shader values. To change the direction the wind is blowing, simple rotate the object that the WindControl script is on.
It works by panning a world space noise texture across the mesh and offsetting the vertices.
To control the strength of the effect over the foliage, you'll need to paint vertex colours into the mesh - with the alpha (A) value controlling how much each vertex is ...
2020-02-25 06:55:52 +0000 UTC
View Post
I've been put onto MaterialPropertyBlocks as a way to avoid creating Material Instances, useful when you just need to make a small change to an existing material (thanks Daniel Snd!) - so I thought I'd put together a little demo scene using them to create a Glow on Mouse Over effect - with an included pop wobble and fade afterwards.
Now I *think* this is friendly on memory and doesn't create material instances, it certainly looks to be behaving how I expect it to, but I haven't done ext...
2020-02-17 03:41:15 +0000 UTC
View Post
Here is a flexible hit impact effect, using a simple script to fire off a bunch of particles at the same time. You can use it by just spawning the prefab and having triggerOnStart = true (although you will have to destroy it afterwards), or better yet, just keep it around and call Trigger() when you need it.
I plan on expanding out the particle multi-emitter to make it more flexible and controllable in the future - this version is just enough to get the impact effect running. I imagine ...
2020-02-10 05:54:36 +0000 UTC
View Post
I've converted my old Shader Replacement Jittery outline over to the Post Processing Stack. It no longer requires a second camera and a shader replacement pass and a render texture! Hooray!
I've also made up a bunch of other outline variations that you can play around with. I've separated them out into different post processing effects to keep things lighter, but if there's a combination or variation that you'd like but isn't there, let me know and I can put it together for you.
<...
2020-01-21 04:06:22 +0000 UTC
View Post
Here's a Breath of the Wild-style teleportation effect, which combines a glow dissolve shader with some trail particles, all wrapped up in a helpful script.

I've tried to make it as flexible as possible - there are a bunch of tweakable settings to create different dissolve/teleport/disintegration effects - but if you don't need all the extras, the shader can be simplified quite a bi...
2020-01-09 02:37:28 +0000 UTC
View Post
Here's a fun way to do dynamic smoke trails and fire without particles, using lineRenderers. It's not the best for realistic smoke, but if you're after stylised trails, you can get some nice smooth motion with this approach.
As with the other lineRenderer FX, most of the work is done via script and not in shader. Although I am pretty happy with the toony fire that's included here. There are a lot of options to tweak in the inspector for different looks and motions - if anything is confu...
2019-12-24 06:56:47 +0000 UTC
View Post
Hi Everybody!
This is a post to explain my intentions for this Patreon going forward.
The first thing that's new is I've put together a contents page at www.pucklovesgames.com which lists all the assets that are currently available to patrons. I've had some people unable to find older assets, so hopefully this makes it easier to see everything that's available in one place.
I've also rewritten the Patreon int...
2019-12-10 03:56:11 +0000 UTC
View Post
Here's a rain shader that uses a blurred screen texture (done via a command buffer) to create a bloomed light refracting through the drops. As its base, it's using the blurry refraction example from here ( https://docs.unity3d.com/Manual/GraphicsCommandBuffers.html ).
The particle system has CommandBufferBlurRefractionHDR.cs (a version of the script in the command buffer example, tweaked ...
2019-12-03 13:52:00 +0000 UTC
View Post
Includes a proximity zapper when you don't want to place end positions manually.
2019-11-01 05:36:53 +0000 UTC
View Post
I've put together a little script to make Zappy Zaps.
The shader itself is about as basic as it gets - all the work is done in script. I've included a few happy debug gizmos so you can position the electricity exactly where you want it, including letting it arc in a curve and randomising the middle position for some nice variation. I hope it comes in handy!

I still am deeply d...
2019-10-29 04:58:12 +0000 UTC
View Post
Here's a way to make smokey projectile trails using the standard Unity Linerenderer. It can be used for standard gunfire, lasers, and also a lighting gun type of effect. -ZAP!-
A lot of the work is done via script, to pass data to the line renderer and material.
Each projectile trail uses it's own Linerenderer and Material instance, which works fine, but isn't ideal or as optimised as it could be - unfortunately those are the limitations of the Unity Linerenderer, which don'...
2019-10-15 06:38:47 +0000 UTC
View Post
I had another go at the chunky polygonal tool explosions, this time simplifying the shader to not require custom vertex streams at all - everything is done with the point light. There wasn't a real reason to leave the non-lit shader stuff in there since it should probably always be used with a point light anyway.
I also split off the spikes so that it's a more generic 'lit smoke' shader, so now it can be used for fire smoke as well.
There's also a particle pushing force applied du...
2019-10-08 04:11:42 +0000 UTC
View Post
I had a crack at a toonsplosion effect after being (re)inspired by Breath of the Wild toony effects. Particularly this gorgeous explosion by Gregory Oliveira https://twitter.com/godsgreg/status/1178716163489927169?s=20
I went with a chunky polygonal look for this so far, but it's still up in the air and I'm sure I'll be tweaking it more in the future. Gotta add those cool arc...
2019-10-07 12:36:00 +0000 UTC
View Post
Hi everybody! I've been making up a few community requested shaders and effects over on Discord, so here's a quick update for those of you who missed them but wanted to have a look. If you aren't on Discord already, head on over, I'm almost always there to answer questions, and to work up quick shader examples like these. I love requests, hit me up!
--------------------
First up, using stencils to mask particles so they always stay behind a mesh, in order to create a '...
2019-09-17 00:32:11 +0000 UTC
View Post
Two simple laser type effects. One using a line renderer and raycasts that would work well as a laser sight on a weapon, and the other one that's more like some sci-fi scanner but that doesn't have any collision checks.
I started by playing with an idea of how to make cheaper 3d noise - it didn't pan out the way I wanted it to, but it's serviceable for this effect - the "smoke" in these lasers is the one noise texture, sampled from three directions and then multiplied on itself.
2019-09-13 13:33:48 +0000 UTC
View Post
This is a different approach to that pulse shader from earlier- this one is much more flexible since you don't need to have it on all the environment materials - it uses an expanding sphere to draw the circular edge on the ground (via depth fading).
There's also a variation which adds in a rim (via fresnel), and a third one which also distorts the interior of the sphere, for EMP type effects perhaps.
They can overlap each other, and work from both inside and out.
Just ...
2019-08-30 07:24:01 +0000 UTC
View Post
(Sorry, reupload, the last post was behaving funky)
Here's a simple shader that shows how you could send a wobbly pulse out over the environment using world space (top down mapping) noise. It's very bare bones, but it should give you an idea of how to achieve similar effects.
Let me know if you have any questions or suggestions!

Edit: Updated the files to make the p...
2019-08-16 01:10:17 +0000 UTC
View Post
Here's a world mapped fireball, just using a sphere mesh that's been stretched, tapered and then bumped up with noise. It has vertex colours (alpha) painted in a gradient from one side of the sphere to the other to control the taper/stretching area.
Instead of using 2 meshes for the layers of fire, it might be possible (better?) to do it with an outline in the shader - just to keep it down to one object.
2019-08-12 03:12:26 +0000 UTC
View Post
A good approach for stopping foliage, grass, and other objects from getting in the way of the camera is to fade them out via the camera depth (or distance from camera) multiplied by a circular screen space mask. You can use dither transparency so you don't need to swap to a transparent shader, that way they can remain opaque, shadow receiving objects.
This is all done in shader, so it works without having to manually check if the object is occluding the camera, and you can just apply it...
2019-08-12 03:03:25 +0000 UTC
View Post
A nice simple way to pop out the silhouette of a cave entrance or other level detail is to use a silhouette card to fill the area with a tint of light. With some depth fade it gives the impression of a localised fog that fades away as you approach - great for helping to highlight an area in a controllable and stylised way.
I first heard about it in this wonderful talk about the Art of Abzu https://www....
2019-08-05 04:30:54 +0000 UTC
View Post
A pretty simple idea really, but something that I think looks pretty cool - add in a stepped depth fade where a weapon trail meets underlying geometry, to create a temporary 'cut line' as the trail passes through other geometry. The same way you might add a cheap shoreline to a water shader. Works well on weapon-aligned trail renderers and 'swish' meshes.
You can get a reasonably consistent line width by compensating for the view direction - here I've multiply the depth fade by the view...
2019-07-31 03:28:24 +0000 UTC
View Post
One of the exciting things I'm working on lately is resurrecting a passion project I've been sitting on for a while. A toon shaded adventure game with the vibes of Zelda but the combat of Dark Souls. Part of that process has been updating and improving the Shaders. I'd previously made them all in Shader Forge, so I'm bringing them across to Amplify Shader Editor and adding some of the new tricks I've learned in the last few years.
Here's the current triplanar environment shader for the ...
2019-07-30 06:33:30 +0000 UTC
View Post
There are many ways to make a toon shader, and many bells and whistles you can include on it depending on the way you want your game to look. Here's a basic example toon shader with some of the little touches I like to add to my own toon shaders.
The main feature that I'm a big fan of, and I include in every toon shader, is that the light wraps around an object to create a rim light even when the normals shouldn't allow it. When the light is behind the object (dot product of the negated...
2019-07-30 03:15:16 +0000 UTC
View Post
Here's a sketchy shader, with cross hatched shadows, outlines (internal and external) and a matcap rimlight. It's also using that funky "object stabilised screenspace mapping" that I worked out here that locks the hatching to the object and prevents a lot of texture swimming when the camera or object moves.
It is 100% inspired by 2019-06-24 03:30:08 +0000 UTC
View Post
I've been playing around with a 3d skybox setup lately. I haven't polished out all the rough edges yet but I wanted to share what I've got so far to let people have a play and give any feedback and suggestions.
One limitation with Unity is that it doesn't handle extremely far distances very well. Just from a rendering perspective - shadows fade out very early, and then the camera clipping plane itself cuts off very far geometry. But not only that, if you ever want the player to travel t...
2019-06-12 13:05:30 +0000 UTC
View Post
Rendering shadows on transparent surfaces is not a trivial thing to do in the Unity standard rendering pipeline, due to the way transparency is rendered after all the other shadow receiving opaque geometry. But by re-using the same shader replacement trick from the last two FX posts, we can force Unity to render at least one extra pass of shadows on transparent materials.
Basically we render the water twice, once with an opaque shader receiving shader, and capture that in a render...
2019-05-29 04:28:14 +0000 UTC
View Post
I've tweaked the previous Shader Replacement effect that was used for a jittery Edge Breakup, and used it instead to add colour to the shadows as a post processing effect.
It's pretty much the same setup - using shader replacement to create a render texture mask that is then fed into a saturation material. The mask uses split the shadow interior, shadow rim, and everything else into separate RGB channels so you can have control over the different sections.
Feels like this is just ...
2019-05-06 00:27:13 +0000 UTC
View Post
With a small tweak to the post process material used in the previous Edge Wobble effect, you can get a pretty funky jittery outline. Instead of just wobbling the UVs of the screengrab pass, you wobble the outline mask, one minus it (so the white outline mask becomes a black outline), and then multiply it back on the screengrab.
Use the exact same setup as the previous effect, but just replace the "Edge Breakup PP Mat" with the shader/material attached here ("SketchEdgePP.mat"). Here are...
2019-04-16 23:43:56 +0000 UTC
View Post
I've been working on a little Edge Breakup effect, for non-photorealistic rendering uses. I first saw a lovely implementation of this in the VR short "Age of Sail" - I highly recommend you check that out if you have a VR headset, it's free on Steam as part of the Google Spotlight Stories. If you don't have a VR headset, you can view a recording of it on youtube here: https://www.youtube.com/watch?v=TH3HOcRay...
2019-04-15 05:10:14 +0000 UTC
View Post
Start with a texture as opacity. Here I'm using a flat splat texture to better show the offset layering.

Take a copy of this, offset it by the LightDir in tangent space by adding to the UVs. Do this again with an increased offset and then layer them together. This is the shadow side.

Now ta...
2019-04-02 11:06:04 +0000 UTC
View Post