NOTE: This library is intended for STATIC objects, such as terrain or decorations, NOT for things that will be moving around, like blobs.
Each atom gets a new variable called 'autojoin', which can be set to either 13, 16 or 47 depending on the kind of joining that you want for that object.
icon = 'cave_walls.dmi'
icon_state = "13"
autojoin = 13
Aside from that, all that's left is to determine what each object wants to join to. Do they join with the edge of the map? Do they join to other objects of their own type? Do they join to objects with a specific attribute? You can decide what each object joins to by overriding the atom.JoinMatch(direction) function, like this:
icon_state = "river.dmi"
icon_state = "16"
autojoin = 16
var/step = get_step(src, direction)
// Return 1 if you want to join with the edge.
// Do you want to join with turfs of same type?
if(step.type == src.type)
// Join with other turfs using the 'water' attribute.
// Don't join with anything.
You can also view Autojoining.dm to see how the default JoinMatch function is arranged.
Once you've decided which objects will be autojoining and which other objects they'll be joining to, then you're all set and the library will take care of the rest.