| Home Page | Recent Changes | Preferences

Vehicles

Vehicles are a stock part of UT2004. Earlier vesions had to rely on custom coding.

UT2004

Classes

Here is a brief list of stock vehicle classes for UT2004.

UT2003 and earlier

Vehicle Types

  • Land: Low Hover, Wheeled

    Cars, Motorcycles, Tanks

  • Air: High Hover, Winged

    Airplanes, Helicopters

  • Sea: Low Hover, Float, Submergible

    Boats, Submarines

  • Other: Space/Fixed

    Space Ships, Stationary Turrets, ect...

General Info

  • Making a custom KVehicle car
    1. Grab the code used with the Bulldog by SubClassing Bulldog and BulldogTire
    2. In your new class, switch the StaticMeshs to your liking.
    3. Modify variables like (Answer Needed) to change the vehicle's "response".
  • A Rotating Vehicle Turret

    You need a karma constraint to make it rotate. I'd recommend "KHinge".

  • Using a Mover as a Vehicle
    • Forcibly allows a pre-defined path of movement (like tracks for a train or the transit system in Half-Life).
    • See Mover Topics.
  • Suspension Systems
    • Pre-packaged vehicles use 'coil-over' suspension (I think) instead of 'leaf' suspension.
    • In ut2003/4, these systems are created from Karma joints.

Technical

One of the most important things about vehicles is that players/bots can to enter and exit them. Furthermore, vehicles have some code that controls firing and some variables that get set when someone wants to steer or throttle.

Setting Up

Modifications

  • /TakeDamage - When a vehicle is destroyed, the driver doesn't die, but takes a lot of damage.
  • /Passengers - Getting more passengers in the vehicle!

Bugs and Issues

The vehicle code has some small and big bugs. We try to list them all here and state how to fix them.

  • /Exiting - Issues with exiting the vehicle.
  • /Replication - Issues with Replication
  • Suicide - Issues with suicide while in a vehicle.

    If you suicide whilst in a vehicle, you die, but remain in the vehicle so you can't re-spawn. To fix it you would need to continually check that the driver still exists, and exit the vehicle if not.

  • My vehicle won't move! - The Vehicle appears 'stuck' in the map, even if it shouldn't be.
    • Karma-Collision issues. Set a simplified collision hull for it. Check out "static mesh modeling" for that.
    • Bad subClassing - Unlikely, but code in a super-class could be messing up your vehicle data. This should be obvious when you look at your class tree. For example, a "plane" shouldn't be subClassed from a "car".
      • Try 'not' to subClass a type of vehicle that is radically different then what you want.
      • As an alternative, try overwriting any irrelevant functions with a blank one, or your own version. Although, this would be tricky work as any functions with return values 'should' return 'something' when requested.
  • My vehicle won't show up ingame

    Vehicles only show up in vehicle gametypes, or more specifically in gametypes that have bAllowVehicles=True. The only default gametypes supporting vehicles out-of-the-box are Assault, Onslaught and Vehicle CTF.

Tips and Tricks

  • Modify your vehicle-data while in-game.

    If you run the game in a window, type 'editactor class=bulldog' at the console. It should pop up a big properties dialog like in the editor that will let you tweak numbers while driving around.

  • In-game graph of vehicle data

    If you run the game in a window, try typing 'graph show' at the console with a vehicle in the level, and you should see a scrolling line-graph pop up. The data on the graph is from the GraphData function. Check out the code at line 681 of KCar.

External Links

UT2003 and earlier

These links should be replaced only when the UnrealWiki generates its own vehicle tutorials.

  • [UDN - Creating a SVehicle]
    • Setting up your vehicle in Maya/3DsMax.
    • Importing your vehicle into UnrealEd.
  • [UDN - Creating a Helicopter]
    • Design: Physics, Control Scheme, Control Difficulty, and Aiming.
  • [Psyonix - Importing Vehicles]
    • Setting up your vehicle for export from 3DsMax.
    • Assigning vehicle animations in UnrealEd's Animation Browser.
  • [Psyonix - New Vehicles] This starts up where Psyonix's "Importing Vehicles" leaves off.
  • [UDN - Karma Cars]
  • [UDN - Creating a HotRod] nearly from scratch! This means this hotrod is not derived from any pre-packaged vehicle class (although the construction is simular to a KVehicles).
    • Setting up various aspects of a car.
    • Towing a trailer. :D
  • [UDN - Simple SVehicle Examples]
  • UDN - Vehicle References
  • [VehicleTest]

    Ugly but effective. The Engine is attached to the Vehicle Chassis which has Wheels attached, that are being powered by the Engine. After switching out some meshes, all you have to change is how much power (torque) is transmitted to each wheel, for a new vehicle. Suspension is changed in the properties of the Karma constraints. Unfortunately, it can't be re-spawned.

    odo324: Is this just a user-made KVehicle with leaf-suspension?

  • [HowStuffWorks.com] - A fantastic resource! Just search for the specific vehicle, or vehicle type. A more-than-perfect site for anyone who wishes to simulate an existing (real-life) vehicle!

UT2004

Related Topics

UT2003 and earlier

  • Vehicle Dynamics - Common forces that act upon many vehicles. Modders should consider these when creating a serious vehicle. Take note that these may or may not be karma related!
    • Traction, Buoyancy, Submergence, Aerodynamics (Thrust, Drag, Weight, and Lift), ect...
  • Vehicle /Anatomy - What different parts of a vehicle do and how each can be simulated in Unreal.
    • Land: Wheeled / Low Hover
    • Air?: Winged / High Hover
    • Sea?: Float / Submersible / Low Hover
    • Other?: Space / Fixed Turret
  • Karma - Physics and Joints, used in every vehicle! (Even if it only need's to rotate!)
  • Static Mesh Modeling - All about modeling StaticMeshes.
  • HUD - The Heads-Up-Display.
    • [Making A HUD]?.
  • Modifying The Bulldog
  • Alternative Vehicle Control - Vehicles with a visible driver. (Irrelevant with drivers of an SVehicle.)
  • Custom Vehicles - Please add links to any new vehicles you find/make.

UT2004

Discussion

Firestorm96: i dont get it how to make a vehicle :S

Riceboy: Aaaugh...cant figure out how to make a hovering/flying veichle......if anyone has a tute, PLEASE POST....for UT2003, anyway, I'm too cheap to buy 04 ^^

odo324: If my computer could actually run UT'03/'04, I would add lots more. It's long overdue 4 an upgrade. :(

SuperApe: Restructured to differentiate between UT2004 and earlier versions, where vehicles are not stock items. Added To Do tag.

Kedren: Would it be even slightly feasible to add a tutorial explaining how to add a vehicle to a map and make it usable? I'm trying to get to grips with Ued and it seems that vehicles are a particularly complex area... either that or I'm just terminally thick :) I'm trying to add an ONSRV vehicle to a DM map that I'm building just to learn with, and when I get to the place where the vehicle should be, all I see is thin air :) Thank you. :)

LordRichard2: I've tried to make an SVeh with a turret (tank) and a passenger turret and room for 4 passengers. I've modeled it but setting up bones,animating,coding, and position is very hard for me. Can someone show me a custom vehicle script i can modify and use as a base. I've tried modifying the ut2004 source but it gets tons of errors. I can use milkshape maya and am learning 3ds max i recently got...


Category To Do – This page could use some more external linkage and related topics linkage on the UT2004 side.

The Unreal Engine Documentation Site

Wiki Community

Topic Categories

Image Uploads

Random Page

Recent Changes

Offline Wiki

Unreal Engine

Console Commands

Terminology

FAQs

Help Desk

Mapping Topics

Mapping Lessons

UnrealEd Interface

UnrealScript Topics

UnrealScript Lessons

Making Mods

Class Tree

Modeling Topics

Chongqing Page

Log In