i have no experiance in joining meshes together but as i saw there are some expamples in the AUMS, like a car that gets its tires attached by script. that way the tires can have a different shader attached then the car mesh.
Ill try to find an example.

EDIT: Here is an example of one of the AUMs:

Code:
Q: I want to create a car that has its wheels attached at runtime. How can I do that?

A: Here's a fully functional example for a car that moves in a circle.

STRING* wheel_mdl = "wheel.mdl";

function front_left_wheel()
{
       VECTOR wheel_offset;
       set (my, PASSABLE);
       while (1)
       {
               vec_set(wheel_offset, vector(43, -20, -15));
               vec_rotate(wheel_offset, you.pan);
               vec_add(wheel_offset.x, you.x);
               vec_set(my.x, wheel_offset.x);
               my.pan = you.pan;
               my.roll = you.roll;
               wait (1);
       }
}

function front_right_wheel()
{
       VECTOR wheel_offset;
       set (my, PASSABLE);
       while (1)
       {
               vec_set(wheel_offset, vector(43, 20, -15));
               vec_rotate(wheel_offset, you.pan);
               vec_add(wheel_offset.x, you.x);
               vec_set(my.x, wheel_offset.x);
               my.pan = you.pan;
               my.roll = you.roll;
               wait (1);
       }
}


function back_left_wheel()
{
       VECTOR wheel_offset;
       set (my, PASSABLE);
       while (1)
       {
               vec_set(wheel_offset, vector(-32, -20, -15));
               vec_rotate(wheel_offset, you.pan);
               vec_add(wheel_offset.x, you.x);
               vec_set(my.x, wheel_offset.x);
               my.pan = you.pan;
               my.roll = you.roll;
               wait (1);
       }
}
 
function back_right_wheel()
{
       VECTOR wheel_offset;
       set (my, PASSABLE);
       while (1)
       {
               vec_set(wheel_offset, vector(-32, 20, -15));
               vec_rotate(wheel_offset, you.pan);
               vec_add(wheel_offset.x, you.x);
               vec_set(my.x, wheel_offset.x);
               my.pan = you.pan;
               my.roll = you.roll;

               wait (1);

       }

}

 

action car_body() // attach this action to your car body model
{
       my.ambient = -40;
       ent_create(wheel_mdl, my.x, front_left_wheel); // create the front left wheel model
       ent_create(wheel_mdl, my.x, front_right_wheel); // create the front right wheel model
       ent_create(wheel_mdl, my.x, back_left_wheel); // create the back left wheel model
       ent_create(wheel_mdl, my.x, back_right_wheel); // create the back right wheel model
       while (1)
       {
               // simple snippet, moves the car in a circle
               c_move (my, vector(5 * time_step, 0, 0), nullvector, IGNORE_PASSABLE | GLIDE);
               my.pan += 2 * time_step; // 2 sets the radius of the rotation circle              
               wait (1);
       )
}



Basically you can do it with all stuff like adding armor, weapons etc.

Edit2:
ther is also this function in GS:
ent_mtlset (ENTITY*, MATERIAL*, var skin);
there you can assign each skin a different Material. Maybe helpful too.

Last edited by chris_oat; 04/10/12 10:36.