Blender is an Opensource 3d modeling program which once you setup and learn, it's one way to make md3 files for Smokin' Guns.

I've tried to cover many operating systems (although not mac at time of writing) and use a colouring standard: Yellow for Topics, Green for operating system subsections, Blue for notes, and Red for important.

1) Download Current Blender 2.4 (32bit ((even if you're on 64bit*-see section note, Windows)) and not v2.5) from blender.org2) Open the Installer and follow the wizard: Next, Read the License agree to continue, Some options for the install, and Choose where to install.3) Make sure to choose to use the application data Directory when it asks, it should be the default anyways."Please specify where you wish to install Blender's user data files.-> Use the application Data directory ( Requires windows 2000 or better)"4) Finish the Setup and when it's done make sure blender starts.

* Note: At the time of writing there is only 32bit Blender 2.4 for Windows

Under Ubuntu (32 or 64) in most cases:

1) Open Synaptic Package Manager ( System > Administration > Synaptic ) 2) Search for Blender3) If it's 2.4 version (like 2.49.2-dfsg-2ubuntu2) Right click and select "Mark for installation", if it's 2.5 Read the Installation Under Linux.4) Hit the Apply button at top of window, and when it's done Blender should be installed.

Under Linux:

1) Goto http://www.blender.org in your web browser and download either Linux x86-32 or Linux x86-64 depending on what linux you're running, with a Version number of 2.49b (2.49.2) or newer.2) extract it, either with a GUI program or terminal

Note: In all the example file paths I'm just using the default name 'Owner' Replace with your user name.Where to save the scripts under Windows 7 / Vista:

Before you can save the scripts you will have to enable viewing of hidden files.

Open up your Windows "Control Panel"a) If using Classic/Large Icons/small Icons: Find "Folder Options" Iconb) If using default Category View: Hit the green text "Appearance and Personalization", and then the Green "Folder Options".-> Click the View Tab-> Change the Radio button from "Don't show hidden files, folders, or drives" to "Show hidden files, folders, and drives".-> Hit Apply button in lower right-> Hit okay to close the "Folder options" Window.

Before you can save the scripts you will have to enable viewing of hidden files. The "folder options" should just be under the "View" menu of all my computer windows-> Click the View Tab-> Change the Radio button from "Don't show hidden files, folders, or drives" to "Show hidden files, folders, and drives".-> Hit Apply button in lower right-> Hit okay to close the "Folder options" Window.

If they aren't there You should just have to just have to update the Menus:->Hit the Button in very top left, the one with a Bold 'i' (called "User Preferences")->Choose "Scripts Window", the one with little green snake next to it->Now you will have a "Scripts" Menu, click it and hit "Update Menus"->Change the "Scripts Window" back to "User Preferences" by hitting the button in top left again

If they still aren't there you may have saved the scripts to the wrong folder, double check their location,. Try moving them around.

Last edited by Plates on Wed Feb 23, 2011 6:13 am, edited 1 time in total.

Note: The next part of this Tutorial uses blender and Smokin' Guns fodler structure, which are the same across all platforms. So when I talk about folders they will be inside the '/smokinguns' sub folder, so the models folder is '/smokinguns/models' in your game folder.

IMPORTANT NOTICE To Windows 7 & Vista users : Windows 'User Access Control' will likely cause a lot of problems for you if you have your "Smokin' Guns" folder inside the standard "Programs Files" folder.

I high recommend you create a folder inside your user folder and move it there. Example:

If leave it in the "C:\Programs Files" Folder UAC will take your changes to files in the folder and cache them in the "VirtualStore" which can leave you with old versions of files, or even files that windows shows you as deleted still being visible to the compiler.

If you choose to leave it there, make sure to check your VirtualStore Folder if you have any problems

The first thing todo is setup the workspace by creating some more 'windows' by splitting the 3D View window a few times. Todo this hover your mouse along one of the edges around the 3D View window, the cursor will change to a rescaling icon with 2 points, press space and you should get this message:

When you left click on "Split area" you will get a verticle line you can move around, when you left click again it will split the window along that line.

the 3 Windows on the right have each been given a view of 2 Dimensions (Top, Side Front or x/y, z/y, z/x) by using the view menu on each.

Some basic ways to adjust the camera are to either use the 'view' menu. You can also use hold the mouse wheel, Shift + Mouse wheel, and Ctrl + Mouse wheel.

You can Select everything, or Deselect anything you have selected by pressing 'a', since the cube is pink in my screenshot it means It's selected. I to select the 'Camera' and 'Lamp' but not the cube, so I press 'a' then use the right click, and Shift+Right click to select them.

I don't want them so by pressing 'delete' key a message will pop-up asking me if I want to erase selected objects, left click and now there will just be the cube.

Now I select the cube (right click) and rename to barrel in the ME and OB boxes in lower left

Also I want to change this object's material to 'barrel' so I go to the Shading tab (f5), and change it's name.

I'm going to be saving this in the Smokin' Guns folder, as models\tutorial\barrel.blend

Editing the Mesh

Hitting Tab with the cube selected will change to "edit mode"

Occlude Background geometry by hitting the 4th button that looks like an opaque cube

Notice the 3 buttons to the left of the "Occlude background geometry", these are the selection modes: Vertex, Edge, and Face.

You should memorize some basic keyboard shortcuts before I continue:'e' - Extrude's' - Scale'g' - Graband pressing 'x', 'y', or 'z' after these shortcuts you can restrict the action to just that axis.

"Ctrl + R" - Loop Subdivide

Pressing Space brings up a menu with a lot of other tools that you will find handy.

Animated Gif of making the barrel:

Frames:->1 ) The Starting Cube with everything selected in edit mode->2 ) Subdivide, press space, Edit > Edges > Subdivide->3 ) Subdivide again->4 ) Scaling along the Z axis->5 ) Rounding the barrel out by selecting the Faces on side then grabbing them and moving along either the x or y axis->6 ) Round out by grabbing the edges->7 ) Selecting all the faces on the top and Extruding, but not moving them, just left clicking->8 ) With all the faces still selecting I hover over the top view and scale them down->9 ) Extrude the faces again but this time along the 'z' axis->10-12 ) Repeating 7-9 on the bottom->13-14 ) preforming a Loop Subdivide and placing it->15-16 ) doing a second loop subdivide->17 ) Selecting all the faces of what will become the metal straps and extruding them but not moving them->18 ) Hovering the mouse over the top view I 'Scale' the straps out->19-20 ) Adjust the straps a bit with grabbing and scaling along 'z' axis->21 ) Giving the barrel a bulge in middle by selecting the middle ring and hovering over the 'top' view to scale it out.->22 ) Scale and grab the top and bottom a bit to round out the barrel.

Last edited by Plates on Wed Feb 23, 2011 7:39 am, edited 6 times in total.

Now to texture "Seams" must be marked along the barrel to make texturing easier.

The first 6 seams are the two rings around the top and bottom of the barrel, and the 4 rings where the metal straps on the barrel meet the wood.

Now to mark a Seam from the top of the barrel, all the way to the bottom of the barrel.

Now I change the main window from "3D view" to "UV/Image Editor" and create a new Texture (Image > New ((or Ctrl+N)) ).

The New Image is named "barrel" and given a 256x256 size, I changed the colour from Black to a Bright Purple (255, 0, 255).

In one of the 3D view Windows I still have open I hover my mouse over and press 'a' to select everything (still in edit mode).

Then press 'u' to bring up "UV Calculations" Menu and select "Unwrap", there should now be the UV Coordinates layed out ontop on the texture in the "UV/Image Editor" window.

Now using most of the same shortcuts you can select and move vertexes and edges in the UV editor.'s' - scale'r' - rotate'b' - Box select'a' - select all/deselect

I've rearranged the UV coordinates on the texture to help me latter, if this were model you were going to use you would want to fill up a lot more of the empty space I have left.

Now I switch the "UV/Image Editor" Window back to 3D view, and change from "Edit Mode" to "Texture Paint".

Notice the "Paint" Bow in the Panels below the 3D view (If you don't see it hit F9 to switch the panel to Editing).

Change the Opacity to 1.0, and the brush size to something larger, like 80 or so. Changed the colour to Brown by clicking on coloured box above "Opacity", and painted the whole barrel that colour adjusting camera to get everything.

Once everything was covered I went in with darker colour and brush with the size of 6, and drew along the vertical edges of the barrel. (Make sure the view is 'Solid' and not 'Textured' to see edges)

Now I switch the main "3D View" Window Back to "UV/Image Editor" and select my barrel texture and "Save As" /models/tutorial/barrel.tga, then save the model /models/tutorial/barrel.blend

I Close blender and switch to Gimp and Touch up the texture, covering the Pink with basetones. After I'm done editing I just save (/models/tutorial/barrel.tga) and Open blender.

Back in blender I open the model, and select everything in one of the "3D View" Windows. I then move the UV coordinates in the "UV/Image Editor" to line up right on the new texture.

Scaling & exporting

I switch the Main Window back to "3D View" and zoom out until I see the whole grid, and scale the barrel up till it almost fills the whole grid.

I save the model /models/tutorial/barrel.blend and then export. To Export I go File > Export > Quake 3 (md3)... , and export it /models/tutorial/barrel.md3. When asked for a shader path to barrel I put:

=> Material > Edit Materials=> Select the material from the drop down menu and rename it to something memorable "lp_whitecedar" for example=> Model > Edit Model Meta Data=> Make a key pair "MD3_PATH" / "models/lp_thuja/"=> Make a shader and add it to the shaderlist