Help:Importing static meshes

From Killing Floor Wiki
Jump to: navigation, search

Importing Static Meshes are important to mappers who want to make their map feel more original or just want something new to add to their map. To import a model, you need to put it into a format UE2.5 can read and make it understand that it is a Static Mesh, it won't allow the importation of .max files as it can't read that.
The only file-type it can read is a .ASE file.

Exporting to .ASE[edit]

This is the scene i start with, a low poly car, several lights and a plane beneath it.
ISM Image1.jpg

We only wish to export the car, nothing else, not even the tires, we'll export that later as a separate object to preserve unwrap space.
So with the car highlighted/selected we go to File -> export -> export selected. In max 2010 the "file" menu has been changed with he Autodesk logo. So if you have Max 2010 this should be the end result:
ISM Image2.jpg

Press it and then go to the bottom and change the filetype to ASCII Scene export (.ASE filetype) and give your model a name.
ISM Image3.jpg

Once you press "Save", the following menu should appear:
ISM Image4.jpg

We don't really need to change any settings if we want to import a Static Mesh and seeing we're using "export selected" we don't need to tick off things like lights as we haven't got any lights selected. So go ahead and press "Ok"
There you have it, now we have exported your model into a .ASE file.

Importing into KF SDK[edit]

Now that we have the .ASE file we need to import it into Killing Floor, so boot up the SDK. Now go to the Static Mesh browser and press File -> Import.
ISM Image5.jpg

Now go to your where you placed yourmodel.ASE, select it and press "open".
After that you should see this window:
ISM Image6.jpg

Now we see it is trying to save the model in the 22Patch package. We will want to definitely change this. Rule of thumb NEVER adjust any package unless it is your own and it hasn't been released to the public, if you do import your model into an existing package, exist the KF SDK and do not save the package in question.
ISM Image7.jpg

So i renamed my package to "Tutorial_import_meshes", gave it a group namely "Car" and the name stays the name i gave to the original .ASE file.
Now you might think "how can I add a model to a package that doesn't exist yet?", well the answer to that is simple it will autocreate the package when there isn't one yet. So go ahead and press "Ok".
If all went well, it should give you an error, namely that it can't find a material on this model; well obviously, we haven't imported the texture yet, so ignore it.

Now you should see your own package with model in it.
ISM Image8.jpg

Congratulations, you just imported your very own textureless model into Killing Floor!

Applying a texture to the Static Mesh[edit]

note: to follow this part you need to know how to import textures, if you don't, then follow this tutorial first! Importing Textures
So now we have imported a model, but it has this ugly bubble texture around it, we'll need to change that to our own texture. So go to the Texture Browser and open your texture package that has your model it's texture in (or import it into a new texture package). Now highlight it as if you were going to apply it to a surface. Note that you should make sure you have no surfaces selected in the 3D viewport as otherwise they'll get your model's texture applied.
Now navigate back to your Static Mesh browser (with the texture still highlighted) and select your Static Mesh. At the bottom there is a "Materials" tab, open it and then open the "0" tab. Now select the Material line and press "Use", after that move a bit around in the 3d viewport of the Static mesh browser to see your texture being applied.
ISM Image9.jpg

Saving your packages[edit]

So now you've sucessfully imported a model and textured it, you'll want to save the package at this stage if you want to reuse it later, so go to File -> Save and then just press "Save".

There you have it.

Extra info[edit]

Don't give Texture packages and Static Mesh packages the same name, It will give problems along the line due to Unreal 2.5 not making a difference between the two, so in effect you'll get 2 files that are insanely large when you shouldn't. Use a naming convention for all your packages, using a suffix such as "_Statics" or "_Text" will make sure these problems will never arise.