Procedurally generated 3D Characters

This topic is 1035 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

Recommended Posts

This question is purely out of curiosity.
I was wondering if it is possible to make a game in Unreal Engine 4 where along with procedurally generated terrain the enemies too are procedurally generated.
Like when you first start the game both the terrain and enemies you encounter will remain the same until you start a new game where again it will be procedurally generated.
Also can it be done, if possible with the blueprint system in Unreal Engine 4.
Any help is appreciated.

Share on other sites

1) I was wondering if it is possible to make a game in Unreal Engine 4 where along with procedurally generated terrain the enemies too are procedurally generated.
2) Like when you first start the game both the terrain and enemies you encounter will remain the same until you start a new game where again it will be procedurally generated.
3) Also can it be done, if possible with the blueprint system in Unreal Engine 4.
4) Any help is appreciated.
1) Yes. 2) Yes. 3) It might require C++, but any C++ that you write can be exposed to the blueprint system for tweaking/configuration/remixing. 4) You'll have to get specific.

Share on other sites

For the enemy part, which can be generalized to character, you can use morphing to generate new head and body.

You have to use the same vertex description for each mesh used in the morphing, you simply blend each mesh using a weight.

Edited by Alundra

Share on other sites

This question is purely out of curiosity.
I was wondering if it is possible to make a game in Unreal Engine 4 where along with procedurally generated terrain the enemies too are procedurally generated.
Like when you first start the game both the terrain and enemies you encounter will remain the same until you start a new game where again it will be procedurally generated.
Also can it be done, if possible with the blueprint system in Unreal Engine 4.
Any help is appreciated.

Are you talking about something like the game Spore or procedurally placed? There is a BIG difference!

Share on other sites

If he speaks about Spore procedural style, he will have to use retargeting intensely.

Edited by Alundra

Share on other sites

"Procedurally generated 3d characters"

I would suspect he is talking about the meshes as I am pretty sure we are all aware that it would be quite easy to generate a pseudo-random number of enemies with pseudo-random stats which have all been pseudo-randomly placed.

For the enemy part, which can be generalized to character, you can use morphing to generate new head and body.

You have to use the same vertex description for each mesh used in the morphing, you simply blend each mesh using a weight.

You wouldn't happen to have a bookmark or two on this? Sounds very interesting!

Share on other sites
You wouldn't happen to have a bookmark or two on this? Sounds very interesting!

You simply send multiple vertex buffer which use the same index buffer then on the vertex shader you simply blend them using weight for each.

Here how could be the vertex shader input struct for one reference + 4 morph target :

struct VS_INPUT
{
// Reference buffer.
float4 pos0  : POSITION0;
float3 norm0 : NORMAL0;
float2 tex0  : TEXCOORD0;

// Morph Buffer 1.
float4 pos1  : POSITION1;
float3 norm1 : NORMAL1;

// Morph Buffer 2.
float4 pos2  : POSITION2;
float3 norm2 : NORMAL2;

// Morph Buffer 3.
float4 pos3  : POSITION3;
float3 norm3 : NORMAL3;

// Morph Buffer 4.
float4 pos4  : POSITION4;
float3 norm4 : NORMAL4;
};

You simply blend them like that :

// Compute the position.
float4 position = IN.pos0;
position += (IN.pos1 - IN.pos0) * weights.r;
position += (IN.pos2 - IN.pos0) * weights.g;
position += (IN.pos3 - IN.pos0) * weights.b;
position += (IN.pos4 - IN.pos0) * weights.a;

// Compute the normal.
float3 normal = IN.norm0;
normal += (IN.norm1 - IN.norm0) * weights.r;
normal += (IN.norm2 - IN.norm0) * weights.g;
normal += (IN.norm3 - IN.norm0) * weights.b;
normal += (IN.norm4 - IN.norm0) * weights.a;
Edited by Alundra

Share on other sites

Here is a similar example.

http://stainlessbeer.weebly.com/using-the-mesh.html

This one is used for expressions, but the exact same code can be used to generate faces for characters, you just change the expressions for other models.

It's exactly the same principle as Alundra pointed you at.

1. 1
2. 2
3. 3
frob
20
4. 4
Rutin
19
5. 5

• 32
• 13
• 11
• 9
• 18
• Forum Statistics

• Total Topics
632555
• Total Posts
3007066

×