Region4
   
   
   
     
     
  MODEL TUNING
 



With the basic setup of you model done, you can tune it to whatever it's intended to be. The template model is configured similar to to 1934 Ford and should be a good place to start from.

The nodetree on this page describes the functions and significance of all the imortant XRE model values. What's not in there should in principle be left alone. You don't have to actually understand and customize it all, many of these parameters can be left as they are. The ones that really do need to be matched to your model (and to eachother) are the values on the body collision object, the wheel objects in the top wheelnodes and the suspension constraints.

I've spent countless hours testing different combinations of parameters, more than it took to design the model, so don't lose youself in trying to reinvent the wheel; it doesn't exist here. The game engine was never designed for any type of moving vehicles. That said, there are undoubtedly things I haven't gotten around to trying, so who knows what you come up with.



  MODEL PARAMETERS
 
 
BSFadeNode  
  NiControllerManager Contains 4 lighting and 19 license plate selection animations. Do not modify.
  bhkCollisionObject Root collision node
    bhkRigidBodyT Car body collision node, contains shapelist with the body convex shapes. Determines much of the car's physical behaviour.
Inertia Moment of inertia is the precise term. This is the body's mass distribution matrix. Considerably influences driving behaviour. Use the calculator to generate the relevant values, leave the rest at 0.
Center Center of mass. Greatly influences the car's driving behaviour. Too low on Z axis makes the car slippy, too high will have it tend to tip over on sharp corners. Exmeriment with this. A good place to start is 0 on x, 0 on y, 5 on z. Don't move it too far from the drive and steer control objects.
Mass Mass of the body object. Should be roughly half of the total car weight. High values (>500) increase risk of physics malfunction and should only be used on very large vehicles.
The calculator returns a suggested value based on given car body dimensions.
Friction Leave at a low value (~0.1)
Restitution Fairly unimportant as long as it's not set to 0.
Penetration Depth Doesn't seem to have much effect but you can experiment.
  CarVisElements Holds all visual meshes except for the wheels, as discussed in the Model Setup section.
  SystemBase Holds the mechanical structure of the car.
    ProjectileNode Projectile source for the front lights function in the game, do not remove.
Translation Leave centered on X axis. Move on Y axis to 15 units beyond the front of the car. Leave at 40 on Z axis.
Rotation Leave Y at -4, rest at 0.
    DriveControlNode Holds the Drive Control Wheel, see the Technical chapter.
      bhkCollisionObject  
        bhkRigidBodyT The Drive Control Wheel, contains the control wheel shape.
Inertia Should in principle be left as is, but you could experiment with the m11 (X axis) value.
Mass 10 is fine for normal weight cars. You could experiment a little.
Angular Damping

This property can be used to simulate friction energy losses, decreasing acceleration at at higher velocities. This can make up for the lack of losses on the tires. The strength of the effect depends on several factors like total mass, engine power, car wheel size. A value of 3 gives a noticable effect on average weight cars. Don't set it too high or it will cause physics malfunction.

Max Ang. Velocity This value effectively hard limits the car's velocity, though it's better to use the setup script variable for it, and leave this at 60. If your car has small wheels you might have to increase this value.
          bhkHingeConstraint Hinge connection to the car body's collision object. Do not modify.
          bhkHingeConstraint
          bhkPrismaticConstraint These constraints are the 'belts' or 'gears' between the Drive Control Wheel and the four car wheels
          bhkPrismaticConstraint
          bhkPrismaticConstraint
          bhkPrismaticConstraint
    SteerControlNode Holds the Steer Control Rudder, see the Technical chapter.
      bhkCollisionObject  
        bhkRigidBodyT The Steer Control Rudder, contains the control rudder shape.
Mass Should in principle be left at 10, 15 for heavier vehicles.
          bhkPrismaticConstraint Connects the rudder to the car body's collision object.
    SteerCenteringBlocker Holds the Steer Control Rudder, see the Technical chapter.
      bhkCollisionObject  
        bhkRigidBodyT The Steer Control Rudder, contains the control rudder shape.
Mass Should in principle be left at 10, 15 for heavier vehicles.
    RearWheelsNode  
      RearLeftWheelConnect The base node of the rear left wheel, used for wheel X axis positioning
        bhkCollisionObject  
          bhkRigidBodyT Collisionless link object.Leave as is.
            bhkLimitedHingeConstraint This provides suspension to the wheel, see the Technical chapter.
Pivot A, X axis This value sets the stiffness of the suspension. Smaller values make it stiffer. When increasing the car body mass this usually needs readjustment also. Make sure left and right wheels are equal.
Max Friction Amount of 'spring damping', helps to keep your wheels from oscillating. Too much friction hurts the suspension. The rear wheels usually need a little more of this than the front wheels for best results.
            bhkPrismaticConstraint Connects the wheel base to the car body's collision object with limited Z axis movement.
Min Distance Limits upward wheel movement. Adjust to match your model.
Max Distance Limits downward movement. Adjust to match your model.
        RearLeftWheelNode Holds the rear left wheel collision object and wheel mesh
          bhkCollisionObject  
            bhkRigidBodyT Wheel collision object. Contains car weel shape.
Inertia Wheel mass distribution should be kept close to center of mass, so these values are low. Leave them as they are unless your car is large and keeps wobbling a bit when parked. In that case, increase the m22 value until it doesn't. Between 1000 and 2000 should do the trick.
Mass Use the calculator to get a starting value, see if experimentation yields better results.
Friction Important value that determines the wheel's friction on it's touching surfaces. Rear wheels always need more than front wheels for stable turns. The calculator gives suggested values, ideal values depend on a variety of factors and you may end up with something quite different. Experiment.
Restitution Leave this as it is, or at least don't set it to 0.
              bhkHingeConstraint Hinges the wheel to the wheel base. Should be left as it is.
      RearRightWheelConnect see RearLeftWheelConnect section
    FrontWheelsNode  
      FrontLeftWheelConnect see RearLeftWheelConnect section
        bhkCollisionObject  
          bhkRigidBodyT see RearLeftWheelConnect section
            bhkLimitedHingeConstraint see RearLeftWheelConnect section
            bhkPrismaticConstraint see RearLeftWheelConnect section
        FrontLeftWheelControlLinkNode Additional node in the front wheel trees, provides steering.
          bhkCollisionObject  
            bhkRigidBodyT Collisionless link object, connects to the steer control rudder.
              bhkLimitedHingeConstraint Connects the link node to the wheel base
Min/Max Angle Determines how far the wheels can turn. Should normally be left at -0.6/0.6.
Max Friction Puts some resistance on turning the wheels. You should probably leave this at the template default.
              bhkPrismaticConstraint Connects the front wheels to the steer control rudder.
Max Friction Puts some resistance on turning the wheels. You should probably leave this at the template default.
          RearLeftWheelNode see RearLeftWheelConnect section
            bhkCollisionObject  
              bhkRigidBodyT Wheel collision object. Contains car weel shape.
Inertia Wheel mass distribution should be kept close to center of mass, so these values are low. Leave them as they are unless your car is large and keeps wobbling a bit when parked. In that case, increase the m22 value until it doesn't. Between 1000 and 2000 should do the trick.
Mass Use the calculator to get a starting value, see if experimentation yields better results.
Friction Important value that determines the wheel's friction on it's touching surfaces. Rear wheels always need more than front wheels for stable turns. The calculator gives suggested values, ideal values depend on a variety of factors and you may end up with something quite different. Experiment.
Restitution Leave this as it is, or at least don't set it to 0.

      FrontRightWheelConnect see FrontLeftWheelConnect section

 

 
   
   
   

(c) Ermeso 2013

 

contact