Monday, March 17, 2014

How to see thumbnails of DDS, PSD and TGA files

Use this little beauty.

Sage Thumbs - open source

A Windows Explorer extension allowing to preview many image formats


  • Extended thumbnail image view of Explorer folder
  • Thumbnail image in explorer context menu (right-click menu)
  • Extended info tips
  • Support 162 image formats (224 extensions)
  • Support additional 26 image formats via XnView plugins (if installed)
  • Send by mail support
  • One-click conversion to popular image formats support
  • Wallpaper selection support
  • Copy to clipboard support

Monday, January 27, 2014

How to create a custom flying vehicle in UDK Part 1

This one is again based on Teglegs plug n play elephant scripts, the guy is a legend and a huge contributor to the UDK forums over at Epic.

So first off you need to get hold of the files which are still available here.

The read me shows you how to get the Elephant into your game and is pretty straight forward. From here you have two choices:

  1. Stick with the naming conventions and simply import your own mesh, this will still need to be skinned but it's the fastest way to get a custom flyer into your game. Limiting you to only one flyer.
  2. Use the model, unrealscript and rig as a template and add your very own flyer.
I'm going for 2 as I want more than one flyer, 1 is easy enough and the skinning is also straight forward (and covered below.)

Firstly you need a nice low poly model, I opted for this little fella from Bitgem.

I stripped out any unwanted bones until I was down to just a series of meshes then combined them together.

In 3DS Max go to the create tab then click the 'Systems' button. Underneath you should now see 'Bones'.

Click the 'Bones' buttons, the click and drag in the viewport, click again and this will create two bones
Hit DEL to delete the last one.
Press 'w' and select the bone, making sure there's only one, now zero out all the x,y,z position then press 'e' and zero out all of the rotations.
Back to 'w' and position the main bone centrally to your model.
Name the bone 'Main'

Shift drag the bone to create a copy and name it 'Lt_Rotor'
Position this bone, back and left of your model
Shift drag the bone to create a copy and name it 'Rt_Rotor'
Position this bone, back and right of your model
Shift drag the bone to create a copy and name it 'Rt_Canard'
Position this bone, front and right of your model
Shift drag the bone to create a copy and name it 'Lt_Canard'
Position this bone, front and left of your model

Link all bones to the 'Main' bone by clicking on the link button then click and dragging from the child to the parent ie the 'Rt_Rotor' to the 'Main' bone. See the video I found and posted here.
Save your progress.

Select all the verts
Add a Skin modifier to your Editable Mesh
Underneath Bones: click Add and add the 'Main' bone
Click 'Edit Envelopes'
Click 'Vertices' underneath 'Select' and select all of the vertices on your model
Use the weight tool to make sure that all the verts are weighted 1.0 to the 'Main' bone
Click Edit Envelopes again to get out of this mode and select the 'Main' bone

Export the model, SK_VH_Plane
SK Skeletal Mesh
VH Vehicle

In geometry enable smoothing groups and turbo smooth and enable Embed Media under Embed Media.
Click OK

Go over to UDK and import this into UDK
Enable Explicit Normals
Import Materials and import Textures

From here you can drag and drop him from the content browser into the editor and see how he'll look.

Saturday, January 25, 2014

How to link bones in 3D Smax

When adding a custom vehicle I always seem to forget this bit:

Essentially you skin all the verts to the main bone and then link the child bones to the main bone too. Once you've done that when you move the main bone everything should move together.

Tuesday, January 14, 2014

How to add your UDK project to Perforce

Ok so I never finished the SVN tutorial but then that's because I never had the chance to figure it out properly.

I love Perforce and so I was excited to see it added to UDK.

So first off when you install UDK you'll need to install the client. You don't need the server because we'll be using live online servers hosted free (for one project) over at Assembla .

After you've set up your account you need to follow the instructions for setting up your client here.

But this is where I started to go around in circles as you will keep ending up with 'Partner exited Unexpectedly' error

Assembla will let you run SVN, GIT and P4 repo's but what isn't clear is how and more importantly where you do this.

Log into your account on
Go to your project page
Click on the Admin tab
Under the tools section click 'More'
Finally in here you can Add your P4 repro

Now we have a P4 tab in the top menu which has 'Instructions' link underneath that is populated with your user settings, host and port information which is awesome.

Once you have this set up you need to set your depot to stream

 'p4 client -S //depot/main -o | p4 client -i'

If you are considering putting everything under an initial revision then you might save yourself some pain and remember that some files in the config folder (particularly the ones that check that you've updated your UnrealScript) need to be writable.
So once you've submitted revision 1 you'll need to check them back about again.

Friday, October 25, 2013

How to create a custom HUD in UDK

UTGFxHudWrapper is the wrapper that deals with the Unreal Script side of the movie or movies ie checks if they are loaded, toggles visibility etc and stores the Class of the MinimapHUDClass in it's Default properties:


GFxMinimapHud on the other hand is the Unreal script that delves deeper into the Flash movie itself:

    TeamStatsMC = GetVariableObject("_root.teamStats");
    PlayerStatsMC = GetVariableObject("_root.playerStats");
It also stores the reference to the actual Gfx movie you want to use in it's Default properties:

To create your own HUD simply extend these two classes and point to your own custom gfx movie

//CWHud .uc
class CWHud extends UTGFxHUDWrapper;

class CWMinimapHUD extends GFxMinimapHud;
The HUD is instantiated inside the PlayerController Class:
//CWPlayerController .uc
CWPlayerController extends UTPlayerController; 

reliable client function ClientSetHUD(class<HUD> newHUDType)
if(myHUD != none)
myHUD = spawn(class'CWHud', self);

Custom flying vehicle scripts

Here's the scripts from Teglegs's flying code for reference.

I don't have a model to hand but as udkc is dead I wanted to post this for prosperity, that and it's the best plug n play script I've come across.




Wednesday, October 23, 2013

How to make a custom weapon in UDK pt 2

The fastest way to get your own custom weapon is to extend what Epic have already put in place. Extending a weapon already in game is by far the best way to get started in this case we're using the Shock Rifle 'UTWeap_ShockRifle' class, In the previous post I named my shotgun model 'cw_weapon05' and imported it into my 'CWWeapons' package so the path to the skeletal mesh is 'CWWeapons.Mesh.cw_weapon05' taking a look at the CW_TestGun.uc class below shows that we only need to override the mesh, attachment class and pickup mesh.


class CW_TestGun extends UTWeap_ShockRifle;


// Weapon SkeletalMesh
Begin Object Name=FirstPersonMesh
End Object


Begin Object Name=PickupMesh
End Object


class CWAttachment_TestGun extends UTAttachment_ShockRifle;

Begin Object Name=SkeletalMeshComponent0
End Object


How to make a custom weapon in UDK

As always these are my notes and not in anyway the best way to do this. Purely the way I have done.
First off you need a gun model, I tried downloading a few free ones but as always you end up spending more time trying to crowbar whatever you find into shape, than you may have done modelling from scratch.

I created a very rudimentary shotgun shape in 3dsMax from a cylinder. Once you have this you need to add a Skin modifier to the mesh then add to this two bones. The bones will be identified in UnrealScript so if you are going to write your own then they can be whatever you want but if you're reading this then I guess we follow Epics lead.

The first bone wants to be the root bone and will ideally be inside the handle of the weapon (think of it as where the players right hand will be) the second will be along the barrel (players left hand)

These will need to be named 'b_gun_root' and 'b_gun_lefthand' Rig the bones so that all vertices are weighted completely to the 'b_gun_root' bone and none weighted to the 'b_gun_lefthand'

Following this add an Unwrap UVW and export the whole thing out as a .fbx file then go into UDK and import the fbx file into your package.

  1. Create / download 3d model
  2. Add Skin modifier
  3. Add 'b_gun_root' bone weighted to 1
  4. Add 'b_gun_lefthand' bone weighted to 0
  5. Add Unwrap UVW
  6. Export as fbx
  7. Import into custom package in UDK