Asset Modernization Guide – Procedural Examples

Asset Guide – Procedural Examples

This is a simple guide to an asset in the Unity3D Asset Store called “Procedural Examples”.  It states that it requires Unity 3.5.6 or higher which was written about five years ago so this asset is old and has experienced substantial rot and when you import it it doesn’t run.  This guide will help you get it running in 2017.1 and help you experience most (if not all of what it has to offer).

https://www.assetstore.unity3d.com/en/?&_ga=2.258807946.1438654072.1502225756-817480689.1498423427#!/content/5141

Most of it actually works (after you do this one thing).

I wrestled with this asset for a few minutes and got nowhere so feeling dismayed I put it away and came back to it a few days later and when I looked at it with a fresh set of eyes and a new determination I decided to start removing things that didn’t work to see if any of it would work at all.

First I found several significant errors in the Lightning script so I tried to update them, but I didn’t get very far before I got discouraged and had to admit I don’t know enough about the old particle systems vs the new to be able to port this script.  At that point I gave up and just deleted that script and gave up on that particular example but if anyone knows an easy way to get it working again let me know.

Once I did that all of the rest of the examples worked quite well!

How to use the procedural examples

When you import the asset into a new project you get this: (note: ignore the Textures folder – I added that later).

Unity5 Procedural Examples Asset Folder
Unity5 Procedural Examples Asset Folder

In the top level directory is the set of examples and all of them except for Lightning bolt work just fine. Just double click on them and go for it.

Some really cool results and effects

Most of them are either self-explanatory or come with simple in-game instructions in the top right. My favorites are below (Extrusion was actually really cool)

Unity5 Procedural Examples Extrusion
Unity5 Procedural Examples Extrusion
Unity5 Procedural Examples Heightmap
Unity5 Procedural Examples Heightmap
Unity5 Procedural Examples Extrusion
Unity5 Procedural Examples Extrusion

Quality

There are still some bugs here for example in the extrusion example if you make the ‘time’ too long then that shape just disappears saying that the triangles are out of bounds.  As a result these aren’t going to be good platforms for production code but using their techniques and building upon them is certainly a workable implementation.

Conclusion about the Unity5 Procedural Examples

This is a good set of examples for how to manipulate meshes procedurally and I’m glad that its out there.  It could clearly use a refresh and one of the examples doesn’t work at all but otherwise its informative and pretty easy to get working and could be of value to a lot of us developers.  Thanks Unity Technologies!

 

Leave a Reply

Your email address will not be published. Required fields are marked *