Adding custom meshes to Hammer Covering prop_static prop_dynamic & prop_physics.

Slides:



Advertisements
Similar presentations
How to Import an Excel File Using the SAS Import Wizard SAS 9 for Windows.
Advertisements

© Paradigm Publishing, Inc Excel 2013 Level 2 Unit 2Managing and Integrating Data and the Excel Environment Chapter 7Automating Repetitive Tasks.
Static Models, Maya, & Valve Modeling, Exporting, and Compiling Feb 8 th 2006.
Using Eclipse. Getting Started There are three ways to create a Java project: 1:Select File > New > Project, 2 Select the arrow of the button in the upper.
Creating Animations – Lesson 71 Creating Animations Lesson 7.
Administriva l Half-life 2 accounts – If you have your own and HL2-EP2, then you can just use that – 3500 students keep your old one – Others – before.
Lab 4 – Building your first model
Web Page Design Tips & Tricks Layering Choose Insert – Layout Objects – Layer Click anywhere along the outline of the layer box to select it Click &
Viewbox 4 Tutorial How to create a Template Please view this tutorial as a Slide Show in PowerPoint, because it contains animations that will not appear.
Creating an HTML page Skills: edit and debug HTML pages IT concepts: text editor This work is licensed under a Creative Commons Attribution-Noncommercial-
Portfolio Creation Adobe InDesign CS5. Introduction This presentation is a step by step process on how to create a professional Combat Camera Portfolio.
Portfolio Creation Adobe InDesign CS5. Introduction This presentation is a step by step process on how to create a professional Combat Camera Portfolio.
Microsoft ® Office PowerPoint ® 2003 Training Playing movies [Your company name] presents:
Microsoft ® Office Word 2007 Training Mail Merge II: Use the Ribbon and perform a complex mail merge [Your company name] presents:
© 2008 The McGraw-Hill Companies, Inc. All rights reserved. M I C R O S O F T ® Customizing Themes and Master Slides Lesson 11.
Working with SharePoint Document Libraries. What are document libraries? Document libraries are collections of files that you can share with team members.
Laboratory Exercise 8- Carrying Out Presentations Office Productivity Tools 2 Laboratory Exercise # 8 Carrying Out Presentations Objectives: At the end.
Using Audacity Created by: Stephanie Anderson Dublin Unified School District Dublin, California.
XP Tutorial 6 New Perspectives on Microsoft Windows XP 1 Microsoft Windows XP Searching for Information Tutorial 6.
Transferring Course Materials to the Web. Creating a Web Site With a Template To create a Web site with a template 1.Start FrontPage. 2.On the File menu,
Google Training By: Amy Shannon and Dave Auwerda.
XP Tutorial 5 Buttons, Behaviors, and Sounds. XP New Perspectives on Macromedia Flash MX Buttons Interactive means that the user has some level.
Click your mouse for next slide Flash – Introduction and Startup Many times on websites you will see animations of various sorts Many of these are created.
Creating a Web Site to Gather Data and Conduct Research.
Intro to C++. Getting Started with Microsoft Visual Studios Open Microsoft Visual Studios 2010 Click on file Click on New Project Choose Visual C++ on.
Spreadsheets in Finance and Forecasting Presentation 9 Macros.
A First Look At Microsoft Visual Basic Lesson 1. What is Microsoft Visual Basic? Microsoft Visual Basic is a software development tool, which means it.
Fall 2005 Using FrontPage to Enhance Blackboard - Darek Sady1 Using FrontPage to Enhance Blackboard 1.Introduction 2.Starting FrontPage 3.Creating Documents.
McGraw-Hill/Irwin ©2009 The McGraw-Hill Companies, All Rights Reserved Business Driven Information Systems 2e Plug-In T6: Basic Skills and Tools Using.
Adobe InDesign CS5 – Illustrated Unit E: Using Master Pages Adobe InDesign CS5 – Illustrated Unit E: Using Master Pages.
Step 1. Import pics from your picture collection file. In order to edit a particular image, be sure it is highlighted/ selected. Here are buttons for.
McGraw-Hill/Irwin © 2008 The McGraw-Hill Companies, All Rights Reserved Plug-In T6: Basic Skills and Tools Using Access 2010 Business Driven Technology.
Introduction to PowerPoint Curriculum Implementation Day Friday, November 3, 2006 K.J. Benoy.
Images search site #1: This site is good for images for mood/ tone/ history (sometimes)
© 2008 The McGraw-Hill Companies, Inc. All rights reserved. WORD 2007 M I C R O S O F T ® THE PROFESSIONAL APPROACH S E R I E S Lesson 13 Templates.
RIGHT Mouse Button Formatting Cut Copy Paste Save LEFT Mouse Button MAIN BUTTON Single clicks Double clicks Drag Highlight.
Introduction to Half Life 2 Modding ● Seminar Five – The Texturiser – The story so far: ● Creating a mod via Source SDK ● Introduction to Hammer ● Basic.
LATTICE TECHNOLOGY, INC. For Version 10.0 and later XVL Web Master Tutorial For Version 10.0 and later.
McGraw-Hill/Irwin © The McGraw-Hill Companies, All Rights Reserved TECHNOLOGY PLUG-IN T6 Basic Skills Using Access.
XP New Perspectives on Microsoft Office FrontPage 2003 Tutorial 7 1 Microsoft Office FrontPage 2003 Tutorial 7 – Creating and Using Templates in a Web.
Configuring IQmol for Windows machines, use version!
Using Advanced Options Lesson 14 © 2014, John Wiley & Sons, Inc.Microsoft Official Academic Course, Microsoft Word Microsoft Word 2013.
Engineering Drawing Standard Paper Size: A0: 841 x 1189 mm A1: 594 x 841 mm A2: 420 x 594 mm A3: 297 x 420 mm A4: 210 x 297 mm A: 8.5 x 11 in B: 11 x 17.
Administriva l Half-life 2 accounts – If you have your own and HL2-EP2, then you can just use that – 3500 students keep your old one – Others – get it.
Melissa White REMC Updated for Power Point 2007 by Jan Harding Chippewa Valley Schools Used with permission.
®® Microsoft Windows 7 for Power Users Tutorial 3 Managing Folders and Files.
What is PowerPoint? By Kettina L. Robinson. Unit Questions What do I want to accomplish? What do I want to accomplish? What content do I need to cover?
Photoshop Image Slicing. Reasons to Image Slide To create links out of sliced images To optimise different areas. (flat areas of colour, such as logos,
Administriva l James will run a hands on tutorial in WEB 130 today at 3:30 and again at 2:00 and 3:30 on Thursday. l Can everyone that wants to attend,
To play, start slide show and click on circle Lesson 1 Lesson 1 Lesson 2 Lesson 2 Lesson Lesson 3.
Copyright © Texas Education Agency, All rights reserved.1 Web Technologies Motion Graphics & Animation.
Animations Sampler Click the Animations tab, then choose Custom Animation.
Page 1 of 8 Stanford Continuing Studies CS 38 ·Hands-on Graphics Production for the Web Week Five EXERCISE 2: ANIMATION 1) Launch Fireworks. 2) Open blackbackground-stanford.gif.
Yingcai Xiao Game Development with Unity3D Inside/Outside Unity3D.
Body System Here Enter group members names here. Save Your Work! This is a good time to start saving your work. Go to FILE, then Save As…, then change.
Open the standard.idw template. Save copy as a different file name. If you want to create as a template, save to the c:\Program Files\Autodesk \Inventor10.
Perform a complete mail merge Lesson 14 By the end of this lesson you will be able to complete the following: Use the Mail Merge Wizard to perform a basic.
Chapter 10 Creating a Template for an Online Form Microsoft Word 2013.
Animation, Maya, & Valve Modeling, Exporting, and Compiling Feb 10 th 2006.
Using a set-up file to read ASCII data into Stata
Note to trainers The videos in this presentation provide closed-caption files, and they’re on by default because it’s often easier for viewers of all.
Searching for Information
Using a template to create a document
Embedding Graphics in Web Pages
Microsoft PowerPoint 2007 – Unit 2
CSC/FAR 020, Computer Graphics
Creating your first website
Creating your first website
Tutorial 8 Sharing, Integrating, and Analyzing Data
Presentation transcript:

Adding custom meshes to Hammer Covering prop_static prop_dynamic & prop_physics

Models in Hammer use the.mdl extension, and there is no way to export straight from a modelling package (3DSMax) to this format, we must export a number of files in the.smd format which contain animation, mesh and collision data, and use a script file (.qc) to compile all the data into the final.mdl which hammer can use. First off, you will need a tool to export from 3DSMax to the.smd format, the best is a 3 rd party plugin found at (google cannonfodder tools). Download, extract (winrar) and copy both files to your /3dsmax8/plugins directory.

Now we can download the example meshes for this tutorial, find them at source.com/downloads/gamesdesign_ws.ziphttp:// source.com/downloads/gamesdesign_ws.zip Extract, and open prop_static_ws.max. When 3DSMax loads, you will have a scene containing a simple mesh with a material assigned to it. We are going to export this mesh for use as a static mesh (prop_static) in hammer, so go to file-export and find a suitable directory (commonly the modelsrc folder of your mod. This is where we export the.smd files, so locate the format on the filetypes dropdown. We need two.smd files to export all the information in this scene; a reference file which contains mesh and texture information, and a skeletal animation file which contains bone movement information. Export a file named ‘reference.smd’ and choose the ‘reference’ type in the exporter window. Go to file-export again and export ‘idle.smd’ choosing the ‘skeletal animation’ option this time.

Now we compile the.smd files using the.qc, before we continue, make sure the ‘hide extensions for known filetypes’ option in Windows is off. Create a new text document and rename it to xxxx.qc. Double click on it and it will ask you to specify a program to run, browse to your steam/steamapps/(name of active account)/sourcesdk/bin folder and choose ‘studiomdl.exe’, this is the program which compiles the.smd information into the final.mdl. Now open the.qc with notepad and use the example.qc on the next page to set up the script.

//prop_static_ws.qc //your directory which contains the.smd files you exported from 3DSMax $cd "C:\unimod\modelsrc\prop_static_ws" //directory within steamapps/yourmod/models and name of final model $modelname "prop_static_ws.mdl" //needed to show hammer the model is to be treated as a prop_static $staticprop //your reference.smd $body studio "reference.smd" //uniform scale modifier – change value to modify the size of the object in hammer without re-exporting from 3DSMax $scale 3.0 //directory containing the materials for the mesh $cdmaterials "models" //skeletal animation.smd (not used in in static meshes, but required anyway) $sequence idle "idle.smd" loop fps 15 //collision information – the physical presence the object has in the game world. Using the same reference file from before will auto-generate an optimised collision box, if you wish this to be a custom shape, you use another.smd which has been exported as a reference $collisionmodel “reference.smd" { $Mass 100 $concave }

Save and close notepad, and double-click on the.qc file. Because we associated it with studiomdl.exe earlier, it will now compile the model. You will now find a collection of files in the output directory you specified in the.qc the most important is the.mdl. Double click on it and you will be asked which program to associate it with, browse to the same ‘bin’ directory as before, and choose hlmv.exe, the half-life model viewer. The model will now open in the viewer, and should look something like this: The pink/black checkerboard shows us the texture cannot be found, so copy the.vmt and the.vtf that came with the mesh into the materials folder you specified in the.qc. Load up the model viewer again and the material will be applied to the mesh. On the next page we will look at the.vmt for a model’s material.

//gen_democharge.vmt //notice that model materials use the ‘VertexLitGeneric’ shader, as opposed to the ‘LightmappedGeneric’ shader which bsp (world) materials use. "VertexLitGeneric" { "$baseTexture" "models/gen_democharge“ //the $model tag shows the engine that the material is for a mesh "$model" 1 //controls the type of surface the model will have, check the accompanying propdata.txt for a complete list. "$surfaceprop" "metal“ "$envmap" "env_cubemap“ "$envtint" "[ ]“ //"$bumpmap" "models\generic\gen_democharge_normal“ //"$normalmapalphaenvmapmask" 1 }

Now you can use the prop_static entitity within hammer to load your mesh into a level. Next, we will look at prop_dynamic and prop_static entities.

Dynamic and physics meshes use many of the same steps which the static mesh tutorial covers, as such I will skip over the common steps, check back if you forget how to do something. Dynamic meshes are animated props which commonly repeat an indefinitely looping animation within the game. If you load the prop_dynamic_ws.max example you can see a simple object with a 30 frame looping animation set up already. When you load it, 3DSMax will ask you to locate a missing texture, don’t worry about this, it is a placeholder material without which studiomdl.exe is incapable of compiling a model. Export the skeletal animation and reference.smd files as before and create a new.qc file. The.qc for a dynamic mesh looks a little different, the main changes are highlighted on the next page.

//prop_dynamic_ws.qc $cd "C:\unimod\modelsrc\prop_dynamic_ws" $modelname "prop_dynamic_ws.mdl" //importantly there is no $staticprop tag $body studio "reference.smd" $cdmaterials "models" //the skeletal animation.smd now contains useful information, ensure the ‘loop’ switch is present if you want a looping animation and that the playback fps value is the same as in 3DSMax $sequence idle "idle.smd" loop fps 30 $collisionmodel "reference.smd" { $Mass 100 $concave }

Compile the mesh and load hammer, create a prop_dynamic entity, specify our mesh as the world model and enter the name of our looping animation into the * box (in this case, ‘idle’. The animation will now play indefinitely in your level.

Prop_physics Load the example.max and export the skeletal and reference.smd files. Bring up the.qc and we’ll see what is different:

//prop_physics_ws.qc $cd "C:\unimod\modelsrc\prop_physics_ws" $modelname "prop_physics_ws.mdl" //no $staticprop $body studio "reference.smd" $cdmaterials "models" $surfaceprop "metal" $sequence idle "idle.smd" loop fps 15 //defines the mass of the object – how heavy it is in game $collisionmodel "reference.smd" { $Mass 5 } //Defines the physical properties of the objects, the “metal.Small” is a template, check the propdata.txt file for a complete list. You can also write your own custom template, use the valve wiki to find all the commands and their appropriate values. $keyvalues { "prop_data" { "base""metal.Small" }

Compile the model and load it into hammer using the prop_physics entity.