New models

Creating new content for Trespasser!

Moderators: TresCom Support Team, TresCom Board Managers, TresCom Developers

Teromen
Parasaurolophus
Parasaurolophus
Posts: 258
Joined: Sun Jun 25, 2017 11:48 pm

New models

Post by Teromen »

What's the best way to create models for trespasser? I use 3dsmax.

I made a simple crate but it wont export as a tpm properly. I'm pretty sure it's how I applied the texture. I used a material in 3dsmax. Seems like they have to be stored in the tpm file instead. Does the exported mesh need a special name?

Edit: I canexport models from TresEd, import to Max and export back again, then import back to TresEd just fine so it has to be how the textures are stored.

On a side note, what do you name your collision mesh so it knows to import it properly?
User avatar
TheIdiot
T-Rex
T-Rex
Posts: 4345
Joined: Thu Feb 20, 2014 9:13 pm
Location: Canada, eh?

Re: New models

Post by TheIdiot »

What's the best way to create models for trespasser? I use 3dsmax.
It's definitely Max. I think everyone here uses it, though it's probably possible to use other programs and then import it to Max before converting it to TPM. The TPM script is only for Max so it's going to have to end up there in the end anyway.
I made a simple crate but it wont export as a tpm properly. I'm pretty sure it's how I applied the texture. I used a material in 3dsmax. Seems like they have to be stored in the tpm file instead.
Hmm. I don't bother with the Max material editor when making TPMs. I usually just drag and drop the texture onto the model, and that's that. But yes, the textures are indeed stored in the TPM. They must also be indexed 256-colour BMPs, and no larger than 256x256. You can use 24-bit textures as well, but those have a lot of problems associated with them. And if you need to do transparency, including a Grayscale transparency map is required. When you need to make transparent materials, I find the easiest thing to do is to use a text editor to edit the exported TPM file after exporting from Max, but before importing, and just add in the "OpacityMap" line (you can check other TPAs for an example).
Edit: I canexport models from TresEd, import to Max and export back again, then import back to TresEd just fine so it has to be how the textures are stored.
Yes, but there tend to be serious smoothing errors when you do that. You'll have to fidget around with it a bit in Max in order to fix the smoothing groups. You might even have to re-do them entirely.
On a side note, what do you name your collision mesh so it knows to import it properly?
Tres doesn't do collision meshes. You have to make individual physics boxes for the model instead. And they MUST be boxes, or they will have serious problems. Typically these are named "FBox00-00" or "FHouse00-00" for physics that aren't attached via T-Script to the model, which are usually used for stationary objects, or "$FBox00-00" and "$FRock00-00" for mobile objects. Objects that are referenced and attached in the T-Script MUST begin with the $ in order to work correctly.
Teromen
Parasaurolophus
Parasaurolophus
Posts: 258
Joined: Sun Jun 25, 2017 11:48 pm

Re: New models

Post by Teromen »

Error message in max.

maxscript

Error: STeroShack1-00

Error: warning: Not all scene objects could be exported

Note: its a simple box mesh. i dragged the texture onto it from a folder. Still wont export. Maybe the mesh is scaled too large?
User avatar
TheIdiot
T-Rex
T-Rex
Posts: 4345
Joined: Thu Feb 20, 2014 9:13 pm
Location: Canada, eh?

Re: New models

Post by TheIdiot »

Teromen wrote:Error message in max.

maxscript

Error: STeroShack1-00

Error: warning: Not all scene objects could be exported

Note: its a simple box mesh. i dragged the texture onto it from a folder. Still wont export. Maybe the mesh is scaled too large?
Seems you're trying to export something other than an Editable Mesh. Your object has to be in the Editable Mesh mode in Max when you export, you can't export an Editable Poly or a Box or Tube, etc. Simply convert it prior to exporting and it should be fixed.
Teromen
Parasaurolophus
Parasaurolophus
Posts: 258
Joined: Sun Jun 25, 2017 11:48 pm

Re: New models

Post by Teromen »

Ahh, that fixed it. Thanks for the help.
User avatar
Draconisaurus
T-Rex Killer
T-Rex Killer
Posts: 14045
Joined: Mon Dec 06, 2004 5:21 pm
Antispam: No
Location: Isla Sorna
Contact:

Re: New models

Post by Draconisaurus »

TI, didn't know you evaded the Material Editor... It's rather simple at is basis, and for Tres you only need to manipulate a few elements of it. I don't currently have Max on this computer to refer to, but when you open the Material Editor, for any given one of the spheres displayed, you can apply a Diffuse Map (the color texture) and an Opacity Map (the transparency texture). There is a button for "apply material to object". "Multi/Sub-object" materials are only slightly more complicated; set the number of sub-materials it will have, manipulate them as normal, and each number associated with each material is used in EditableMesh as the material ID, down at the bottom. Select faces/polys and type in the material number you want it to have. I suppose I might eventually do some basic Max tutorials as relevant to Tres modding..
User avatar
TheIdiot
T-Rex
T-Rex
Posts: 4345
Joined: Thu Feb 20, 2014 9:13 pm
Location: Canada, eh?

Re: New models

Post by TheIdiot »

Draconisaurus wrote:TI, didn't know you evaded the Material Editor... It's rather simple at is basis, and for Tres you only need to manipulate a few elements of it. I don't currently have Max on this computer to refer to, but when you open the Material Editor, for any given one of the spheres displayed, you can apply a Diffuse Map (the color texture) and an Opacity Map (the transparency texture). There is a button for "apply material to object". "Multi/Sub-object" materials are only slightly more complicated; set the number of sub-materials it will have, manipulate them as normal, and each number associated with each material is used in EditableMesh as the material ID, down at the bottom. Select faces/polys and type in the material number you want it to have. I suppose I might eventually do some basic Max tutorials as relevant to Tres modding..
Yeah, I know how to use it, but to me it's way easier and faster to just drag-n-drop and then fix transparency later. :P
User avatar
Draconisaurus
T-Rex Killer
T-Rex Killer
Posts: 14045
Joined: Mon Dec 06, 2004 5:21 pm
Antispam: No
Location: Isla Sorna
Contact:

Re: New models

Post by Draconisaurus »

I think it's more a matter of that you're accustomed to it and don't wish to burst your habit bubble ;) But if you've already tried it and prefer that method, I guess that's how it is..
Teromen
Parasaurolophus
Parasaurolophus
Posts: 258
Joined: Sun Jun 25, 2017 11:48 pm

Re: New models

Post by Teromen »

Do you export the physics separately from the model? And can I export all the physics volumes in one mesh?

edit: What's the script to attach them to the model?
User avatar
machf
T-Rex Killer
T-Rex Killer
Posts: 12368
Joined: Thu Apr 24, 2003 11:20 pm
Location: Lima, Peru
Contact:

Re: New models

Post by machf »

Movable objects have their physics objects (beginning with "$") attached to them via scripts, immovable ones either have bool Tangible set to "true" (when they are of a basic rectangular shape) or set to "false" and "detached" physics objects (beginning with "F") placed in the proper spots, those objects are, likewise, immovable. And physics objects are set to bool Visible = false, of course...

When you export a Movable object, its physics subobjects are automatically exported together with it (note that you should export the BASE object, the one with an index of "-00" at the end of its name, not its other instances). When you export an immovable one, you need to manually select the physics objects placed in its position for export too. Or if you want, you can export them separately, since they are independent entities, after all.

Take a look at the Script Reference here (the CInstance entry), and look at the last two entries in the "Physics" section...
Visit The Carnivores Saga - a forum devoted to modding Action Forms' Carnivores, Carnivores 2 and Carnivores: Ice Age games
Tres WIP: updated T-Script Reference and File Formats documents
Sound name listings for the Demo (build 117), Retail (build 116), Beta 103, Beta 99, Beta 97, Beta 96, Build 55, PC Gamer Alpha (build 32) and E3 1998 Alpha (build 22) TPA files
User avatar
Draconisaurus
T-Rex Killer
T-Rex Killer
Posts: 14045
Joined: Mon Dec 06, 2004 5:21 pm
Antispam: No
Location: Isla Sorna
Contact:

Re: New models

Post by Draconisaurus »

...And if you're still having trouble with this by tomorrow, a nice juicy hands-on tutorial should be finished available showing what it looks like to do this.
Teromen
Parasaurolophus
Parasaurolophus
Posts: 258
Joined: Sun Jun 25, 2017 11:48 pm

Re: New models

Post by Teromen »

Awesome. Can't wait to watch it. Trespasser editing has been a learning experience. As it isn't very documented.

I get this error with my 3dsmax models in geomadd.

"Loading object import files...
File: "C:\Unreal Editing\TrespasserEditing\Tools\Geometry export to 3ds\New folder (7)\T_GiantBoxA1.tpm"
NOTE: File format version not supported, file may not load correctly.
NOTE: Could not find value file "C:\Unreal Editing\TrespasserEditing\Tools\Geometry export to 3ds\New folder (7)\T_GiantBoxA1.values.txt". Mesh: TGiantBoxA1
Mesh: FGiantBoxA1
Instance: TGiantBoxA1
Instance: FGiantBoxA1
"

Of course the model is visible inside TredEd, i just can't get physics to work yet.
User avatar
Draconisaurus
T-Rex Killer
T-Rex Killer
Posts: 14045
Joined: Mon Dec 06, 2004 5:21 pm
Antispam: No
Location: Isla Sorna
Contact:

Re: New models

Post by Draconisaurus »

Ignore the file format warning... happens all the time and has never caused an issue that I'm aware of.
As for the value file. Check the text of the filename very carefully. I make this mistake now and again... Most common errors is leaving of the ".values" part of the filename. Look at a working one if you need an example.
Teromen
Parasaurolophus
Parasaurolophus
Posts: 258
Joined: Sun Jun 25, 2017 11:48 pm

Re: New models

Post by Teromen »

Here is the model if you wanna have a glance. It's just a simple crate. I moved the physics to the side so that it is easy to see. In the game you just walk right through where the physics should be blocking.

Edit: Do you have a generic values file for non moving entities?
Attachments
TeroBox1.zip
(57.82 KiB) Downloaded 429 times
TeroCrateJPG1.jpg
TeroCrateJPG1.jpg (15.57 KiB) Viewed 16865 times
User avatar
Draconisaurus
T-Rex Killer
T-Rex Killer
Posts: 14045
Joined: Mon Dec 06, 2004 5:21 pm
Antispam: No
Location: Isla Sorna
Contact:

Re: New models

Post by Draconisaurus »

Alright, so. Nice that you're learning how to make physics boxes, however an object which is already a box can make its own physics - no need for a physics model. Be sure that the pivot point of the object is centered within the object; Max's "center pivot to object" option does an operation which is not recognized by Tres scripts (let us know if you need help figuring this part out).

As for the values file - in Trespasser Twilight go to "\Script Reference\Example Value Tables", where you'll find several example text files. For a simple crate such as the one above you'll want "Exmpl-Box.values.txt".
Post Reply