gravityPointUnitDistance

    Constant to set/get the distance at which the gravity strength is equal to the gravity controlled by .areaParamGravity. For example, on a planet 100 meters in radius with a surface gravity of 4.0 m/s², set the gravity to 4.0 and the unit distance to 100.0. The gravity will have falloff according to the inverse square law, so in the example, at 200 meters from the center the gravity will be 1.0 m/s² (twice the distance, 1/4th the gravity), at 50 meters it will be 16.0 m/s² (half the distance, 4x the gravity), and so on.

    PhysicsServer3D.swift:392
    case gravityPointUnitDistance

    The above is true only when the unit distance is a positive number. When this is set to 0.0, the gravity will be constant regardless of distance.

    Other cases

    • case gravityOverrideMode

      Constant to set/get gravity override mode in an area. See AreaSpaceOverrideMode for possible values.

    • case gravity

      Constant to set/get gravity strength in an area.

    • case gravityVector

      Constant to set/get gravity vector/center in an area.

    • case gravityIsPoint

      Constant to set/get whether the gravity vector of an area is a direction, or a center point.

    • case linearDampOverrideMode

      Constant to set/get linear damping override mode in an area. See AreaSpaceOverrideMode for possible values.

    • case linearDamp

      Constant to set/get the linear damping factor of an area.

    • case angularDampOverrideMode

      Constant to set/get angular damping override mode in an area. See AreaSpaceOverrideMode for possible values.

    • case angularDamp

      Constant to set/get the angular damping factor of an area.

    • case priority

      Constant to set/get the priority (order of processing) of an area.

    • case windForceMagnitude

      Constant to set/get the magnitude of area-specific wind force.

    • case windSource

      Constant to set/get the 3D vector that specifies the origin from which an area-specific wind blows.

    • case windDirection

      Constant to set/get the 3D vector that specifies the direction in which an area-specific wind blows.

    • case windAttenuationFactor

      Constant to set/get the exponential rate at which wind force decreases with distance from its origin.