Wednesday, 24 February 2010

A change in the workflow

In my original rationale i proposed to import all of my models into UT3 however after a discussion with Dean my tutor we decided that this would be a massive under taking. Since i had never used the Unreal Editor before this project, also after all the problems that i had encountered importing the character into UT3 it was decided that i would only import the character. I believe this was a good idea otherwise i doubt that i will finish everything on time, having said that i did say that i would look into importing the weapon/s and vehicle after i had finished the course. I found it very useful actually importing the character into UT3 as this gave me a much better insight into how much work really does go on implementing models into a game engine such a s Unreal.

Sunday, 21 February 2010

Time to loose some poly's.....

After experimenting with Z-Brush and XNormal i decided to look at my model again and see if i could lower my poly count down to my original budget that i had decided upon at the beginning of the year with Stas and Dean. My budget for the character model was 10,000 polys or 20,000 tris.

After adding all the new added straps and extra detail i had well over stepped this budget and my character was now standing at a whopping 12,0019 ploys or 23.674 tris. I was not happy about this and i don't believe it is good practice to over shoot by so many. In what experience i have i do know that poly budgets are a big issue in the industry and these poly budgets must be obeyed.

So i looked long and hard at my model and started chipping into it using target weld and deleting any polys that i felt were of no use or did not have a purpose or did anything to the silhouette in any way. After a couple of hours of refinement i was alot happier with the model as now i came below my agreed poly budget. Also i believe that my actual geometry looks alot better now and a hell of alot cleaner as some of my model still looked messy.

Below is exactly how many polys i was able to save which I'm very pleased about:

  • Old Mesh = 12,0019 polys or 23,674 tris

  • New Mesh = 9,904 polys or 11,099 tris

I think i should point out that i could probably could look even deeper into getting the poly count down even further but with time ticking i am happy to move on from this stage. I also think with getting my poly count down it will also help my model run smoother in UT3.

If we look at the two images below there doesn't seem to be much loss of detail either between the two models can you tell which one is which?

And the answer is ..................................................................................................................................................................................................................................

the new lower poly model is on the left with the higher poly mesh on the right. So as we can see there isn't a great difference in to two meshes at all.

Experimenting with XNormal and ZBrush

After making some refinements to my model i thought it was best to make a start with the Z-Brush work. So with my High and Low poly meshes ready i decided to put the torso into ZBrush for 3 reasons really.
  1. To familiarise myself with Z-Brush once more as it has been a while since i had used it.
  2. To bake out a normal and Ambient Occlusion map.
  3. Experiment with XNormal.

So i began to do this and after having alittle play about with ZBrush i decided to take my High and Low Poly Mesh's into XNormal.

Following some tutorials on the site i found XNormal really easy to use and i thought everything was going great. I baked out the Normal map really easily no problem and i also baked out the Ambient Occlusion. (I have to say that the Ambient Occlusion that it produced was way better than the previous Ambient Occlusion i produced in 3DS MAx itself.)

However things did not run smoothly, when i applied the Normal map to my lower poly model the Normal map did not seem to work properly and i wasn't happy with the way things had turned out. (I'm sorry i haven't got any images to show the result as i accidentally deleted the Normal map that i produced by accident).

After thinking things over i believe that the error was occurring because when i produced the lower and high poly meshes i deleted all the straps and fine detail on the lower mesh and this is something i shouldn't of done. I could be wrong on this maybe i was doing something in 3DS Max I'm not entirely sure. So this got me thinking??

Sunday, 14 February 2010

Time for some adjustments..

Having successfully getting my model into UT3 and running around, i met up with John once again and he suggested that i should go back and study my model and see what modifications and adjustments i could do to make the character even better.
  • The first thing that we agreed on was, my model through the production stage had lost all its muscle definition definition.
  • The human anatomy was wrong i.e. arms length to the leg proportions in particular.
  • Looking at the model i decided that some more added detail was needed.
  • A higher poly character would be created to add in straps and other fine detail. This high poly mesh would be taken into Z-Brush and this would create my Normal map, specular maps etc. Once the Normal maps were created the normal map would be applied to a lower poly mesh.
  • Also added into the model to bring out the silhouette even more and to make the model more interesting some blades were added to the left arm and a rocket launcher on the right. I shall be adding a emissive map onto the blades in order for it not to look like a Predator rip off. I think this will look rather cool as well and add something extra to the model.

Here is a closer look at the extra detail i have added to the character:

First Pass successfully accomplished

After having all the problems with the textures in-game and after importing the new model into the Unreal engine i finally had success :) My character was now successfully running around in the UT3 with all textures present. This was a huge relief to me and although this error occurred i was pleased that i was able to resolve the problem be it setting me work flow back by a week or so.

Here is some videos of my character first pass successfully running round in UT3:

Thursday, 11 February 2010

Problems a foot in-game...

After importing the character into Unreal it was time to test the character in-game. After going to the Customize Player screen via settings in the main menu, it appeared that all textures where present and there was no errors. I was quite pleased to see the character in UT3 and things were looking good:

Character on the Customize Player select screen.

However things changed dramatically once the character entered a match and the camera view was changed to a third person view (This was done by press the tap button and typing in behindview with no spaces) As this video below shows, for some reason the characters torso, arms and bottom of the boots were coming out completely black:

Torso, Arms and bottom of boots are coming out black in-game.

Although all textures were not present it was still pleasing to see that my character was running well within UT3 and worked well with the animations.

After a week of pulling my hair out what hair i have left may i add, i was able to get to the root of the problem. Basically the error was occurring because back in 3DS Max and my mesh was created certain parts of the mesh had different Material ID's assigned to it and the mesh also had different smoothing groups assigned to it. For example the torso would have about 3 material ID's and the same for the smoothing groups. So once imported in the Unreal Editor i had to apply the body texture several times in order for it to appear correctly. I found out via the Epic Games Forums that each material slot within the editor should only have 1 or 2 material slots available to it. So i had to select each part of the body (Helmet, Head, Torso, 2 Shoulder pads, Legs and Boots) individually back in 3DS Max and ensure that all Material ID's were set to 1 and smoothing groups set to 1 as well.

With all material ID's and smoothing groups all sorted now i went back into the Unreal Editor and began to bring all the assets in. When it came to apply the body texture to all the body parts that i had problems with previously instead of having several Material slots now all texture would only require one material slot, with this now corrected it was time to see if this problem had been sorted in-game.

Unreal Editor naming conventions

Having no prior knowledge of the Unreal Engine / Editor i was slightly apprehensive on how i was going to get on importing the character. As mentioned before in previous posts experimenting with just actually getting the UT3 Male character into UT3 really helped me get used to the whole process. Following this video tutorial provided by John i set about importing my character into the Unreal Editor.

I think the main thing that i must first point out is how important naming everything correctly is. The Unreal Engine is very particular about this and if not followed correctly the character will simply not work properly.

Unreal requires all texture maps to be saved out as .bmp files and up to 2048 x 2048 but i believe that a 1024 x 1024 is used most of the time so the character runs smoothly within the Unreal engine. Also these textures must all be named correctly in order to save any problems that may occur further down the line in the process.

Here is how i set out the naming conventions ready for the Unreal editor:

Here is how i should name the body textures:

CharacterNameHere_MBody01_D01_V01_SK1.bmp (Body Diffuse map)
CharacterNameHere_MBody01_D01_VBlue_SK1.bmp (Blue Body Diffuse map)
CharacterNameHere_MBody01_D01_VRed_SK1.bmp (Red Body Diffuse map)
CharacterNameHere_MBody01_N01_V01_SK1.bmp (Body Normal map)
CharacterNameHere_MBody01_S01_V01_SK1.bmp (Specular map )
Here is how i should name the head textures:

CharacterNameHere_MHead01_D01_V01_SK1.bmp (Head Diffuse map)
CharacterNameHere_MHead01_N01_V01_SK1.bmp (Head Normal map)
CharacterNameHere_MHead01_S01_V01_SK1.bmp (Head Specular map)

CharacterNameHere_BioPic.bmp (This is the profile picture within UT3 on the character select screen)
Here is how i should name the body parts in 3DS Max:


Skinning the character...

With a basic texture now down on the character i really wanted to get my model into the Unreal engine so the next phase of the process was to add the bones inside of my mesh. Way back in September in order to get used to the Unreal Editor i imported the UT3 male default character that is free to download successfully into Unreal. However way back in September i didn't need to skin the character as this was already done for me. I had only previously touched upon skinning once before back on the foundation degree and even then it was a bit daunting to say the least. With this previous knowledge of Skinning i seemed to quickly get to grips with the whole process and after a while quite enjoyed it, it was very relaxing.
The first thing that i would like to point out and which was probably the hardest part of the skinning process was understanding which bones should be added to each part of my mesh. It took a while to get to grips with this and it was a case of experimentation in order to get the mesh correctly interacting with the Unreal skeleton.

Below is a list of which bones i settled on and to which area of the mesh they were assigned to:
  • Helmet (Top of Head) - Bones assigned to Helmet = b_Head
  • Head - Bones assigned to Head = b_Head, b_Neck and b_Spine2

  • Torso - Bones assigned to Torso = b_Hips, b_LeftClav, b_RightClav, b_Root, b_Spine, b_Spine1 and b_Spine2
  • RightShoulderPad - Bones assigned to the Right Shoulderpad = b_RightShoulderPad

  • LeftShoulderPad - Bones assigned to the Left Shoulderpad = b_LeftShoulderPad

  • Legs - Bones assigned to the Legs = b_Hips, b_LeftLegUpper and b_RightLegUpper

  • Boots - Bones assigned to the Boots = b_LeftAnkle, b_LeftLeg, b_LeftToe, b_RightAnkle, b_RightLeg and b_RightToe

Some experimentation had to be done in order for my mesh to correctly follow the Unreal skeleton. This part of the process was basically shifting the weights from one bone to the next after a bone had been weighted i would play the simple animation that had been added into the Unreal Tournament male skeleton to see if my whole mesh followed the bones correctly.

Below is some before and after videos of how the skinning process went:

Torso before Skinning

Hand before Skinning

Arm before Skinning

I found skinning very much as a trial and error type of process as to get the mesh to fit along side the skeleton was very experimental. I found that not all vertices would have the same weight assigned to them. To solve these issues i found it easier to solve the problem by rotating the skeleton to extreme body angles. Although in the real world a human body cannot move to such angles i found this the best route to go down.

With the whole mesh now attached to the skeleton i noticed that when i played the animation the shoulderpads did not follow the arms correctly. At first i panicked and thought that i had made an error somewhere down the line. The arms would go right through the shoulderpads but after some guidance from Dean he reassured me that this was perfectly OK as the shoulderpads would be moving independently with the Unreal Engine/Editor.

I think it is worth mentioning another problem i encountered when i had successfully imported my character into UT3. When the character died in-game part of the waist area would stay upright and cause the poly's to stretch. I think this was to do with not skinning the character properly and assigning the waist area to the wrong set of bones.

Stretching of the polys in-game

X Normal??

Before i talk about skinning the character i just want to mention an application that John has told me to use to bake out my normal and ambient occlusion maps in. This application is called X Normal, it is free to download and generates much better looking results regarding normal, ambient occlusion and displacement maps. There are plenty of tutorials actually on the site and looking at a few of the videos it looks very simple to use with a great end product.

X Normal can be found at the following URL:

Wednesday, 3 February 2010

Feedback from the Unreal Community

Having created the basic texture i decided to post this work up on the Unreal Community forums to get some feedback off them. I have to say that i have some really good feedback off them regarding the textures and it was even suggested to do different types of camo outfits for the character i.e. Urban, Forest, Artic, Spec Ops etc.
I thought this was a great idea and so i went away and fleshed out some textures to see how it looked. I have even received a 5 star rating which im absolutely chuffed about as the Unreal Community take things very seriously :)

Below are the texture that i produced that was requested by some of the members of the Unreal Community:

Instead of posting up new threads all the time Ive decided to keep this thread open and update this thread on a regular basis.

Tuesday, 2 February 2010

Texturing the character

With the Unwrap complete it was now time to start texturing the character this part of the process i really enjoy as to me it is at this point that things really start to seem to come to life. I started off with a base colour for the body and slowly built up the texture also checking back what it looked like on the model. Here's is two images to show the base metal texture and then some more finer detail added:

Base texture Concept texture

Again for the head texture i quickly put together a texture just to get something down:

This texture is by no means complete i just wanted to get a general texture down and apply it to my model to get a feel for it. Below is the above textures applied to my model:

Front view Side view
Although these textures are not fully complete it gave me a good idea on how the character is looking and with some basic textures laid down i thought i should move on to skinning the character in order for me to be able to import into the Unreal Editor.
I would like to also say at this point that during my texturing i have found a couple of websites that provide good quailty textures available to download for free.
Here are the URL's for the sites:

Unwrapping the character

Firstly i just want to apologise for not updating my blog recently i have got so caught up in developing my character i haven't had time to post anything i also had a major issue which i will get onto later on another post.

I have to say that Unwrapping isn't my favourite part of the process (I don't think many people do) but having said that i did learn some more things i never knew you could do within 3DS Max. As my character is to be built for Unreal Tournament 3 my UV Layouts had to be set out in a particular way. Below the images show how i should set out my UV's according to Unreal.

Head UV Layout

Body UV Layout

Looking at the layout of the head i immediately noticed how much wasted space area there was as i have always been told to use up as much space as possible as this unused spaces is loss of memory. So why unreal set out the UV's in this way i don't really know the answer to, John or Dean might be able to answer that one for me. Any ideas guys?

So following these rules i produced the following UV Layouts:

Head UV Layout

Body UV Layout

The Unwrapping took alot of hours to do and i had particular trouble around the jet pack area as is such the amount of detail around this area. During this time and experimenting with my Unwrapping i got to know a thing called Pelt Mapping i had now prior knowledge of this. I only found out about it whilst searching on youtube watching some tutorials on it the Pelt Mapping can be found under Map Parameters within 3DS Max. Although this was a handy little tool i never eventually used it as i was 100% confident that i could use it to its full potential, so i ended up unwrapping all the UV's manually. Another thing i never knew about was once a UVW Unwrap has been added to the stack and unwrapping had begun. It was possible to collapse the stack back down the an editable poly and make adjustments to the mesh. Once another UVW Unwrap was added to the stack the previous Unwrap was still present. This was extremely useful as i found whilst unwrapping that i encountered some 5 sided polys and this helped me eradicate any 5 sided polys from my model.

After a couple of weeks work i was finally happy here is how the Unwrap looked on my model with a checker applied from the Material Editor. I tried to keep all the checkers to equal size as much as possible in order to keep the resolution at equal length. Below is some screen grabs to illustrate this:

I'm very pleased how the unwrapping has gone and i have to say its the best unwrap that i have ever done. Having said this its only my second time of unwrapping a character here is the first character i created on the Foundation Degree 2 years ago:

As you can see from my previous attempt of building a character i feel i have greatly improved my skills in this area i understand the process alot more and how to go achieving good results when unwrapping. This will not just include unwrapping a character but also for any other object that i will build in the future.

Whilst i am here doing a crit of my previous work i might as well point out a few things i noticed when looking at my last attempt of a character. The first thing i would like to point out is the actual layout of the UV's if we look below there is alot of unused space in the layout this is also bad as this is wasted memory:

Also i would like to point out how many polys/tris that where used on my last character the following two screen grabs show just how many unnecessary tris was used and therefore this character just simply wouldn't work if attempted to be used in something like Unreal etc.