Hydros

Hydros are beams whose length can be varied on demand.

They’re used for many things, including steering racks, hydraulic cylinders, and actuators for doors.

Their length is defined using electrics .

With a factor of 1, sending a command of 1 to a beam will cause it to double in length, while a command of -0.5 will cause the beam to half in length. Smaller factors will result in a smaller length variation.

Required arguments

string
type
Name of the first node
string
type
Name of the second node

Optional arguments

number
type
steering_input
default
Defines the electrics that will be used to actuate this hydro
number
type
Extension/compression limit as a proportion of the hydro’s length.

A value of 0.5 will result in the hydro halving in length at when the input is -1, and an extension to 1.5 times the hydro’s initial length when the input is 1.

Negative values will cause the hydro to contract instead of expanding with positive input values and vice versa.

number
type
2
default
Defines the longest the hydro can become.

Defined as a portion of the initial length, with 2.0 meaning the hydro can become twice it’s initial length, and 1.0 meaning it cannot become longer than it’s initial length.

Gets overwritten by “factor”

number
type
1
default
Defines the shortest the hydro can become.

Defined as a portion of the initial length, with 0.5 meaning the hydro can become half it’s initial length, and 1.0 meaning it cannot become shorter than it’s initial length.

Gets overwritten by “factor”

number
type
1
default
Multiplicator of the input value.

Used along with inLimit and outLimit. Gets overwritten by “factor”.

Negative values will cause the hydro to contract instead of expanding with positive input values and vice versa.

number
type
0
default
Offset the hydro’s center.
Changes the electric value that will arrive at the hydro’s center. Used to offset the hydro’s center value. Has no effect on the hydro’s limits.
number
type
2
default
How fast the hydro contracts
number
type
inRate
default
How fast the hydro expands
number
type
inRate
default
How fast the hydro contracts towards the center
number
type
Defines how much steering wheel angle this hydro will match to

This is center to lock angle. Standard steering will be around 450~500, with older cars and trucks having slightly more angle, and racing cars having less angle.

This drives the “steering” electric used for steering wheel props.

number
type
-1
default
The electric value at which the hydro will be fully in.
All values of the electric above this will result in the hydro staying at full lock.

number
type
1
default
The electric value at which the hydro will be fully out.
All values of the electric above this will result in the hydro staying at full lock.

As they are for the most part a special type of beam , hydros can use a most of the arguments related to standard beams like beamSpring, beamDamp, beamPrecompression, etc.

Examples

    "hydros": [
        ["id1:","id2:"],
        {"beamPrecompression":1.0, "beamType":"|NORMAL", "beamLongBound":1, "beamShortBound":1},
        {"beamSpring":8001000,"beamDamp":50,"beamDeform":"FLT_MAX","beamStrength":125000},
        ["fh6r","fx5l", {"factor": 0.14,"steeringWheelLock":510,"inRate":1.25,"outRate":1.25}],
        ["fh6l","fx5r", {"factor":-0.14,"steeringWheelLock":510,"inRate":1.25,"outRate":1.25}],
        {"beamPrecompression":1.0, "beamType":"|NORMAL", "beamLongBound":1, "beamShortBound":1},
    ],
    "hydros": [
        ["id1:","id2:"],
        {"beamDeform":175000,"beamStrength":"FLT_MAX"},
        {"beamSpring":20001000,"beamDamp":5000},
        {"beamPrecompression":1.0},
        {"breakGroupType":1},
        {"breakGroup":"dump_hydros"},
        ["tfr2r","tfr1r", {"inputSource":"tilt","inLimit":0,"outLimit":1.9,"inRate":0.2,"outRate":0.2,"inputFactor":1.0}],
        ["tfr2l","tfr1l", {"inputSource":"tilt","inLimit":0,"outLimit":1.9,"inRate":0.2,"outRate":0.2,"inputFactor":1.0}],
        {"beamPrecompression":1.0},
        {"breakGroupType":0},
        {"breakGroup":""},
    ],
Last modified: May 6, 2024

Any further questions?

Join our discord
Our documentation is currently incomplete and undergoing active development. If you have any questions or feedback, please visit this forum thread.