unreal.PhysicalMaterial

class unreal.PhysicalMaterial(outer=None, name='None')

Bases: unreal.Object

Physical materials are used to define the response of a physical object when interacting dynamically with the world.

C++ Source:

  • Module: PhysicsCore

  • File: PhysicalMaterial.h

Editor Properties: (see get_editor_property/set_editor_property)

  • density (float): [Read-Write] Density: Used with the shape of the object to calculate its mass properties. The higher the number, the heavier the object. g per cubic cm.

  • destructible_damage_threshold_scale (float): [Read-Write] Destructible Damage Threshold Scale: How much to scale the damage threshold by on any destructible we are applied to

  • friction (float): [Read-Write] Friction: Friction value of surface, controls how easily things can slide on this surface (0 is frictionless, higher values increase the amount of friction)

  • friction_combine_mode (FrictionCombineMode): [Read-Write] Friction Combine Mode: Friction combine mode, controls how friction is computed for multiple materials.

  • override_friction_combine_mode (bool): [Read-Write] Override Friction Combine Mode: If set we will use the FrictionCombineMode of this material, instead of the FrictionCombineMode found in the project settings.

  • override_restitution_combine_mode (bool): [Read-Write] Override Restitution Combine Mode: If set we will use the RestitutionCombineMode of this material, instead of the RestitutionCombineMode found in the project settings.

  • raise_mass_to_power (float): [Read-Write] Raise Mass to Power: Used to adjust the way that mass increases as objects get larger. This is applied to the mass as calculated based on a ‘solid’ object. In actuality, larger objects do not tend to be solid, and become more like ‘shells’ (e.g. a car is not a solid piece of metal). Values are clamped to 1 or less.

  • restitution (float): [Read-Write] Restitution: Restitution or ‘bounciness’ of this surface, between 0 (no bounce) and 1 (outgoing velocity is same as incoming).

  • restitution_combine_mode (FrictionCombineMode): [Read-Write] Restitution Combine Mode: Restitution combine mode, controls how restitution is computed for multiple materials.

  • sleep_angular_velocity_threshold (float): [Read-Write] Sleep Angular Velocity Threshold: How low the angular velocity can be before solver puts body to sleep.

  • sleep_counter_threshold (int32): [Read-Write] Sleep Counter Threshold: How many ticks we can be under thresholds for before solver puts body to sleep.

  • sleep_linear_velocity_threshold (float): [Read-Write] Sleep Linear Velocity Threshold: How low the linear velocity can be before solver puts body to sleep.

  • static_friction (float): [Read-Write] Static Friction: Static Friction value of surface, controls how easily things can slide on this surface (0 is frictionless, higher values increase the amount of friction)

  • surface_type (PhysicalSurface): [Read-Write] Surface Type: To edit surface type for your project, use ProjectSettings/Physics/PhysicalSurface section

property density

[Read-Only] Density: Used with the shape of the object to calculate its mass properties. The higher the number, the heavier the object. g per cubic cm.

Type

(float)

property destructible_damage_threshold_scale

[Read-Only] Destructible Damage Threshold Scale: How much to scale the damage threshold by on any destructible we are applied to

Type

(float)

property friction

[Read-Only] Friction: Friction value of surface, controls how easily things can slide on this surface (0 is frictionless, higher values increase the amount of friction)

Type

(float)

property friction_combine_mode

[Read-Only] Friction Combine Mode: Friction combine mode, controls how friction is computed for multiple materials.

Type

(FrictionCombineMode)

property override_friction_combine_mode

[Read-Write] Override Friction Combine Mode: If set we will use the FrictionCombineMode of this material, instead of the FrictionCombineMode found in the project settings.

Type

(bool)

property override_restitution_combine_mode

[Read-Write] Override Restitution Combine Mode: If set we will use the RestitutionCombineMode of this material, instead of the RestitutionCombineMode found in the project settings.

Type

(bool)

property raise_mass_to_power

[Read-Only] Raise Mass to Power: Used to adjust the way that mass increases as objects get larger. This is applied to the mass as calculated based on a ‘solid’ object. In actuality, larger objects do not tend to be solid, and become more like ‘shells’ (e.g. a car is not a solid piece of metal). Values are clamped to 1 or less.

Type

(float)

property restitution

[Read-Only] Restitution: Restitution or ‘bounciness’ of this surface, between 0 (no bounce) and 1 (outgoing velocity is same as incoming).

Type

(float)

property restitution_combine_mode

[Read-Only] Restitution Combine Mode: Restitution combine mode, controls how restitution is computed for multiple materials.

Type

(FrictionCombineMode)

property sleep_angular_velocity_threshold

[Read-Only] Sleep Angular Velocity Threshold: How low the angular velocity can be before solver puts body to sleep.

Type

(float)

property sleep_counter_threshold

[Read-Only] Sleep Counter Threshold: How many ticks we can be under thresholds for before solver puts body to sleep.

Type

(int32)

property sleep_linear_velocity_threshold

[Read-Only] Sleep Linear Velocity Threshold: How low the linear velocity can be before solver puts body to sleep.

Type

(float)

property static_friction

[Read-Only] Static Friction: Static Friction value of surface, controls how easily things can slide on this surface (0 is frictionless, higher values increase the amount of friction)

Type

(float)

property surface_type

[Read-Only] Surface Type: To edit surface type for your project, use ProjectSettings/Physics/PhysicalSurface section

Type

(PhysicalSurface)