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 http://www.veoh.com/collection/HouseofUnreal/watch/v3378005eMBr65b9 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:

CharacterNameHere_Head.psk
CharacterNameHere_Torso.psk
CharacterNameHere_Goggles.psk
CharacterNameHere_Facemask.psk
CharacterNameHere_Helmet.psk
CharacterNameHere_Arms.psk
CharacterNameHere_Thighs.psk
CharacterNameHere_Boots.psk
CharacterNameHere_LShoPad01.psk
CharacterNameHere_RShoPad01..psk
CharacterNameHere_NoMesh.psk

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:

http://www.xnormal.net/1.aspx






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 :)

http://forums.epicgames.com/showthread.php?t=716007

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.