AssetGen - Create a game asset in a single click

Important note: only works with recent builds of Blender 2.8: https://builder.blender.org/download/
Download: https://github.com/Linko-3D/AssetGen

AssetGen is a free addon (GPL License) that automates the tasks to get a game assets ready for video games from an High Poly model. While it takes several hours to get an asset ready from an high poly, this addon does that in a matter of few clicks. It is ideal for all your static assets.

Latest video:

Installation:

Go to “Edit > Preferences…”, open the Add-ons menu then click on “Install…”.
Import the whole .zip. In the search bar search for AssetGen and enable it. Don’t forget to click on “Save User Settings”.

Credit: It is developed by Srdan Ignjatovic aka zero025 ([email protected]) and surpervised by Danyl Bekhoucha aka Linko ([email protected]).

12 Likes

This looks really interesting… I’m going to have to play with this. Thanks.

Quite intriguing, nice job, will also have a play

I hope it will be useful, personally it helped me a lot during game jams. :slight_smile:

In a future update the generated albedo map will be improved a lot. Currently it is only based on the curvature map and you can use optionnally an AO and shadow (normal map’s B channel) for the grayscale. In the update the addon will use a generate smooth curvature map from the normal map and a slightly more detailled curvature map node setup to get the grayscale, then applies the gradient and at the end apply a thickness map for blood as an option. And you will still have the dirt, grunge and snow in post-effects.

Current albedo:


New albedo:


Albedo node setup:


I have posted tutorials on how the maps have been created:
New Curvature node setup: https://blender.stackexchange.com/a/72602/23134
Curvature smooth node setup: https://blender.stackexchange.com/a/100637/23134
Thickness map: https://blender.stackexchange.com/a/100725/23134
Fake hand painted texture (stylized albedo: https://blender.stackexchange.com/a/90153/23134

I have also created a node setup to make a fake hand drawn lines effect (borderlands), we could include it in the addon:
Without curvature smooth: https://i.stack.imgur.com/gUp7W.png
With curvature smooth: https://i.stack.imgur.com/st4xQ.jpg

1 Like

is bevel shader work with this addon ?

Yes it works, the addon will bake a normal map from the node setup you have created. It will also generate a curvature map and a roughness map (inverted curvature) from the bevel and displacement effect.

Remember to set the bevel sample at 16 and to apply an edge split modifier for you high poly hard surface models. The normal map is always baked at 16 samples to capture the details of the bevel effect.

Demo on a cube with another used as boolean to make a crack and the bevel shader. I just clicked on generate asset and used the Dota Rock crafted preset.


I get some lines on the edges, if someone has an idea on how to fix this, tell me. :slight_smile:

So I’ll just uninstall xNormal huh. That is amazing work. Thank you.

1 Like

Hi, this addon looks incredibly useful. I have a question. You say that it only works with static game assets? what do you mean exactly? if im making a game character, and i have a high poly, cant i just make a low poly version of it? lets say i have the head, arms, etc, separated in different objects, cant i just pick each one, make a low poly and then again join all of em?

With “join” i dont mean, joining vertices, i mean grouping all the meshes in one. Or for example, if im making a robot, that is composed by hard surfaces, mostly, cant this “method” applied to it? it will be like just doing it onto separated meshes.

Keeping in mind, i dont want textures or materials i just want the decimated mesh to be used as baked from the high poly. I also dont want a normal map since imma going to entirely texture and bake on spainter.

Thanks, and i really hope you keep working on this addon. I dont know why this thread doesnt have more feedback.

Good job. Thanks

Amazing work. Thank you.

Hi, I had a play with this at last and it seems very good. There were a couple of things that might be covered but I couldn’t figure out:

When the texture folding is set to ON the decimation doesn’t seem to use the symmetry option so the middle UV triangles get squashed resulting in stretched mapping down the X axis.

If I start from a low poly shape and use subdivision surface (simple) to create the high poly model for detailed sculpting then it would be nice to be able to use the low poly shape with the generated UVs and textures (as it’s almost always going to be better than the decimated version)

I will do some more playing around and try to give some more positive feedback.

Did you use the default cube with hard edges and generated UVs? If so that won’t bake correctly because it is unwrapped in a cross, with hard edges the faces need to be separate UV islands with padding.

I’ve done a bit more experimentation and made a couple of minor mods to the code here https://github.com/paddywwoof/AssetGen/commit/3244e769ffe28b19bf04a4a9343c99b9f1c7deb5
Most are in the GA.py where I tried various ways to get the decimation to work nicely. I think it’s a bit better if I shrinkwrap the LOD0 to the hi-res object. In the end the best way seemed to be to use the ‘Selected to active’ option.
All in all this seems a useful tool

Hi,

sorry for not answering I did a (long) pause and we were waiting for Blender 2.8.

paddywwoof: you can uncheck the texture baking, generate your LoD0, fix the vertices then use Selected to Active, it will still generate your LoDs. The new version will have button directly available to not bake the textures.

The shrinkwarp alone won’t fix the vertex overlapping and if we perform a slight smooth before the vertices won’t be aligned on the peaks, I mean if the model has spikes the low poly vertices won’t be aligned to the tipping points and the normal map will look weird (+ we will need to expand the cage even more). Sometimes when you smooth the high poly where you had overlapping vertices on your low poly the decimation fixes it.

n3mes1s: by Static meshes I mean the decimation only keeps your high poly details, it won’t generate edge loops for a rigging and deformations. So if you make characters it is better to make them statues. But you can still try in Mixamo to auto-rig a game character generated with the addon the result could be good enough for a small game jam project.
With hard surface model you can’t decimate too much but it will remove the model triangle on flat surfaces automatically.
You can uncheck all the texture baking options.

For the new addon I am thinking of an uber shader that the addon adds on the high poly. The user will have access to sliders to adjust the amount of Pointiness, AO, Top Lighting, Vertical Gradient and tweak the ColorRamp. The Inverted AO node will be used to add relief and SSS effects. We can include presets of ColorRamp like Grayscale for a base paint but also, rock, metal, etc. It won’t support the metallic and roughness because the node setup will be connected to an emissive node for quick preview and backing.
This means that a single texture will be baked for the Albedo, no compositing and ID Masks will be needed the workflow faster.
In Cycles render mode he will see what the texture looks like in the High Poly, be able to tweak it and once he clicks Generate, he will see the low poly in Eevee with the textures plugged in the Principled shader. He will have the possibility to automatically export the game asset and textures each time the generate game asset is clicked. This will allow to edit the high poly, generate the low poly and textures and see it automatically updated in Eevee and Godot (or other game engine).

The new GUI (still WIP):

3 Likes

The node setup for the texturing is complete. A button will add this grayscale node group in your shader to help you texture your asset directly on the high poly. For now you can download the node setup here: https://drive.google.com/file/d/1Jf65FaMZcXqwDIWLGv1euKMCP8xYl9TD/view?usp=sharing

We will probably work on the new addon after the release of the release candidate at the end of the month.

2 Likes

I see what you did there and it’s not bad, but… The curvature output could use some more contrast. It would be awesome if you could make it look like handplane baker’s output.

Edit: just noticed you updated the node group since I downloaded it. The Linear output looks closer already, though still some minor differences right at the sharpest edges:

Hi.

I have updated the node setup, it should be close to handplane now. The opacity should not be at the maximum though, like recommended by this Dota artist: https://steamcommunity.com/sharedfiles/filedetails/?id=316375622
If you want the same result you must generate the curvature from the normal map with a pixel width of 4 and a slight blur then convert it to Linear with a gamma node at 2.2: https://blender.stackexchange.com/a/72602/23134 Keep the grayscale in sRGB to work in Blender.

I have added SSS and a 45 degrees front light and tweaked the default settings.

1 Like

I have made a video of my progresses.

You will be able to create your diffuse texture on your high poly, stylize your mesh and generate mobile game assets (or very optimized). In this demo I create a stylized barrel for a mobile game:

In the final version with the GUI, each time you will generate your assets your LoDs and textures will be automatically exported to your game engine. So you will just have to swap between your high poly in Blender and game asset in the engine so you will be able to update and tweak it very quickly.

6 Likes

Hello, the addon for Blender 2.8 is available, some features don’t work properly yet but it is usable for your projects. The Auto Export.glb is not working yet, later it will export it at the path you have entered, this will allow to update your asset in Godot automatically. The addon takes the name of your active selection for your game asset, material and textures.
The addon now includes tools to help you create your high poly.

Download: https://t.co/omwdvnCFch

The Base Texture material, you can append it in your project, it will be included in the future: https://t.co/UqzROApeoh

A video of how to work with it:

The Axe generator tool:

4 Likes

Hi, I can see you’re doing lots of development and I’m looking forward to using the finished article. I just did a quick run with the current work in progress and noticed an error due to GA.py line 472 ->-> line 141 in export_obj.py:

‘PrincipledBSDFWrapper’ object has no attribute ‘normalmap_strength’

glb and glTF options worked ok but not sure how to import those into Unity (given that I’m stuck with 2017.4 as linux isn’t too high a priority for them yet)