Page 1 of 1

Mapping a Model

Posted: Sun Jun 03, 2007 5:33 am
by *GCC*Nigel
The tutorial wasn't too descriptive...
1. Where do I save the 'map' of the model?
2. What type of file do I save the 'map' of the model as?
3. Are there any texture restrictions for 'maps' of models?
4. expanding on 1: I have a models, scripts, and textures folder for multiple models, where should I put the 'map' of the model, or what type of files should I put it with?
5. Do I have to compile the 'map' of the model and the model in anyway to get them to funtion together?
6 Is there anything special I have to do to either 'map' or model when putting it in a PK3?

Worst of all: Pictures were broken! :shock:

Posted: Sun Jun 03, 2007 10:37 am
by bdbodger
That is in the SDK for SH but works the same for mohaa
Creating collision for a Static Mesh



1) Step One convert your new model to a static mesh with the tools provided.

2) Open Moh Radiant

3) Select the new mesh from the model selection it should appear in the radiant window.

Fig 1

Image

4) Open the appropriate texture, for this example we will use the metal texture under the common texture directory.

Image

5) Begin to the trace the model with brushes making sure you have the metal texture selected.

Fig3a

Image

Fig3b


Image


6) Select the model that was being used as the template, and delete it from your level.



Fig4

Image



7) Save the final version as a .map file with same name as the static mesh, and then place it in the mainta\models\static directory. Once this has been completed anytime this model is placed in a level it will reference the newly created collision.


8) Create a test room with the new model, use the wuss console command to give your self all the weapons.



Fig5


Image

9) Fire the different weapons testing to make sure that the collision is working as designed with each weapon.

Posted: Sun Jun 03, 2007 6:48 pm
by *GCC*Nigel
Yeah I did all that, and it doesn't work. I can still run through it. What type of file should the static model be (where should I put the .map file)?

I used the texture_paper from Common to make my model, does it matter what texture I use?

Posted: Sun Jun 03, 2007 11:36 pm
by bdbodger
The model is a static model like any other mohaa model made in a progam like lightray3D or somthing . What this is is just clip brushes made in the shape of the model to make it solid . You can add a model to your map and do the same thing you don't need this but what they are saying is if you make just the clipbrushes into a .map file and put it in the static directory along with your model.tik then any time you add your model to a map it will be solid after the map is compiled . It only works for static models for script model you have to add collision a different way by making the clip brushes a script object and having the script model target the script object . If you want an example open up pak0.pk3 and look in the models/static directory there are several .map files there for example you will find

45cal_crate.tik
45cal_crate.map

It is all about collision making static models solid

Posted: Mon Jun 04, 2007 12:58 am
by *GCC*Nigel
How can you tell if something is a static or script model? I'm acting as a middle man right now, so it's a little hard to communicate what my buddy is saying, but he's got his model so it comes up in radiant in it's own folder (milkshape) and then I can select it from there.

Posted: Mon Jun 04, 2007 2:08 am
by bdbodger
If you don't make it a script model in radiant then it isn't one . If the .tik for the model is in the static directory ( models that don't move should be ) then it is a static model . If the model is in the milkshape directory then you can ether move it and edit the tik or just leave it and use clip brushes in radaint to give it collision . Like I said you don't have to go through the trouble of making a .map file for the model all that does is add the collision for you when you use your model in a map and compile it instead of you giving it collision with clip brushes when you create each map .

Posted: Wed Jun 06, 2007 2:36 am
by *GCC*Nigel
My model without a map is walk-through-able (You can walk through it). I thought adding a map of the model would add the colisions needed to make the barrier more realistic, IE you can't walk through it, shoot through it, etc. If I just moved it to the static folder, presto, problem solved? Or am I missing something?

I was thinking of scripting in the location of the barrier so I could use the same map with differant layouts each time. I had the idea that it would be easier to script in a single model instead of a model with a clip placed directly over it multiple times. Am I wrong? (dangit, hit my funny bone)

Posted: Wed Jun 06, 2007 3:00 am
by bdbodger
step 1 : move model and tik to the static directory
step 2 : edit .tik to show the right paths
step 3 : create a .map file for collision and save in same directory as tik
step 4 : add model to a level map
step 5 : compile the level map
step 6 : create a pk3 containing your map , model , .tik , textures , shaders and collision .map
step 7 : have lots and lots of fun with your new model


You may only have to move the .tik to the static directory and not the skb or skc files .