Hello. I made this tutorial so that people that are not graphic artists or coders can help as well. As you know, there are lots of items in the game, and a lot of people was willing to model them all. But now that almost all of them are done, we need to import them. But who is going to do such job? don't look at me...
I found this little standalone application which fits perfectly our needs. It will work for static meshes.
Download here:
http://www.teamxtcgames.com/files/3D%20Object%20Viewer%20v3.5.zip Lets begin...
We need: 1 model file in 3ds format. 1 texture in any image format.
-Open the application and load the mesh.
-Once it is loaded, select Texture Object and search for the texture file to check if the mapping works.
-After that you will have to reposition the gun so that the handle is right in the center of all three axis'.
To do this select Limb Control from the menu. And move (or type in) the Offset values until the gun is centered. Remember, the center is where the character's hand will be.
Change rotation if needed.
-Now export as DirectX mesh, and place that model inside data/critters, and the texture file inside data/textures. Please name the mesh with the prefix "WP_" and the texture with "ITEM_"
-Now open _fohuman.fo3d and locate the "Right Handle" Layer. Below this first line there are a series of "Values". Add the value for the new weapon in a new line, with the item ID number (found in server/data/itemlist.lst). Then Attach WP_modelfilehere.x Texture 0 Item_texturehere.tga.
example
Value 394 Attach WP_gausspistol.x Texture 0 item_gauss_pistol.tga
-After that, paste the line from another weapon, from Link to the end. I used 10mm pistol coordinates. These coordinates should work for all pistols in theory. If it's a rifle, copy it from some other rifle, and so...
-Test it. In my case it looks bigger than it should. So I have to change this Scale value.
That's it.
ps: yeah, it's still big.
The weapons in 3ds are here, but they might be outdated. You might need to check Graf's repository.
http://www.mediafire.com/?afu2uifjqaccc01I'll see if I can find something that converts into 3ds from obj.
Post your exported file along with it's _fohuman line here. I'll download them and add them to the repository