🤑 Indie game store🙌 Free games😂 Fun games😨 Horror games
👷 Game development🎨 Assets📚 Comics
🎉 Sales🎁 Bundles

Post your nodes below! Sticky

A topic by helyx created 1 year ago Views: 1,947 Replies: 8
Viewing posts 1 to 9

Sorry, accidentally deleted old post. Reposted it.

(Edited 2 times)

Ngon node.

This node generates a regular polygon with rotation.

Source can be found here

(Edited 4 times)

Here are mine...

Brightness:

You can change the brightness of the texture, also useful for creating blend masks, which you can put in the blend factor


Preview:

Creates a tiled preview of the texture, unfortunately getting rid of some resolution


Custom Scatter:

I found the default scattering algorithm too slow, so I did the reasonable thing and coded a new one...
It's a lot faster and offers more controll of the scale and amount, but doesn't do anit aliasing as nicely

I knocked this up rather quickly, but it does its job. It's a poor man's edge detection node. You can choose the intensity of the effect and one of three different neighbourhoods (Moore, Von Neumann and a 2D neighbourhood). There's also two variants of Moore (normal and "skinny", which removes one direction to provide a half-way house between that and Von Neumann) and two variants of the 2D neighbourhood (vertical and horizontal). The sensitivity is divided by three to give finer tuning, as quite often only the lowest values are particularly useful.

Here's the link: Differ.

And here's an example:

Developer

Excellent thread. Loving all of your nodes.

I might make some of these official!

(Edited 1 time)

Here's a really simple one, but I've found it useful when checking to see how well images tile.

Offset

It offsets your image by an inputted value.

I'm not sure if it would be considered bad practice to use getTileSize() within init() to limit the fields, but it does seem to work. If you increase the size of the image while using Offset you do need to add a new instance to be able to offset by higher values, but nothing actually breaks. If it bothers you just replace the two instances of getTileSize() within init() with 64.

Edit:

Here's another simple one: Simple Color.

It takes RGB values and colourizes the image, which can be faster than using the existing colourize node when you just want shades of one particular colour. As the result tends to be a bit smooth for pixel art, there's a quantize feature which acts like a palette knife, cutting down the number of colours used. If you want, you can set all three RGB values to their maximum and just output a quantized heightmap.

Since taking this screenshot I changed the spelling to the American spelling to match the existing nodes.

(Edited 2 times)

I made a normal map generator, as well as a created a sobel edge detector in then process....

Haven't tested the normal maps yet, but I checked with images online and they seemed to match up, so they should work...

(Edited 1 time)

Been having lots of fun with this, here are the nodes I've made:


Gray noise:

randomly mixes each pixel on the output between the two inputs.

http://pastebin.com/HFWBwJYS

Direction:

For use with directional blur. Makes each point point toward the center. Offset rotates these.

http://pastebin.com/U2mQU5d6

Regulate:


Makes the pixels be 'regular' as in regular polygons, snapping them to repeating values and also looping them after a certain value. This is basically just a neat way of rounding numbers thrown in with the modulo function.

http://pastebin.com/6m6LiP9Y

Distance:

Gets the distance (abs(a-b)) between the two inputs.

http://pastebin.com/MADwG7jT

Lump:

Highlights pixels of around a certain brightness. Named as such due to how it looks when graphed:

More hill shaped really, but lump sounded better.

http://pastebin.com/GCYmCQ1r

Edge Distance:

Tries to get the distance from a dark spot each pixel is. Lags exponentially with tile size, not sure how to optimize it. :/

http://pastebin.com/WhhEWXSM

Lerp:

Linearly interpolates between two inputs, based on a third input. If t is 0, it returns the first one. If t is 1, it returns the second one. If t is anywhere in between, it returns a mix of the two inputs. Each input is an input parameter.
http://pastebin.com/s2tCfU8K

Square pattern:

Gives a chessboard type pattern, with the option for more than two colors. Due to a weird bug, the only sizes that don't have strange artifacting are numbers in 2^x, so the size input uses that.

http://pastebin.com/zk0gGyCz

(Note: there were some visual errors with the nodes that have been fixed since the pictures were taken.)


Been having fun with this tool, keep on accidentally calling it a game. Hope people find these useful!



edit: some more:

Inflate Heightmap:

This raises up a texture by a heightmap. Not pictured is also an option to set whether it loops off the top of the image or not.

Good for visualizing heightmaps you make. Note that without a surface input it will all be one color, shading just came from the lighting node.

http://pastebin.com/UnZWpQXH


Vector to Direction and Direction to Vector:

Don't know how often these would be useful, but I made these too.

http://pastebin.com/bjBcmLz0

http://pastebin.com/10m4c9b7

(Edited 2 times)

It ain't very impressive but here:

minmax.lua - Sets White and Black/Max and Min values

Turn on auto to automatically get the highest and lowest value, or you can fine-tune it manually.

http://pastebin.com/jaiCKrr4

edit: Just noticed navot's brightness node already has a Min/Max. Oops.