Kit physics
58 herramientas. Generado a partir del código fuente del plugin; no lo edites a mano.
Las descripciones de las herramientas y de los argumentos se muestran en inglés porque reflejan el schema de las herramientas (el mismo texto que el agente recibe en
tools/list).
Guía
Use physics for project physics policy, physical-material assets, and collision queries during
Play-in-Editor. Use component to change a component's collision and simulation settings, mesh
for static mesh collision, and skel for PhysicsAssets.
For a selected primitive component, physics.inspect_body starts a physics-profile workflow.
Use the typed body collision, simulation, gravity, damping, mass, and hit-event tools to prepare
it, then run PIE and use the live velocity, wake/sleep, impulse, force, torque, and velocity tools.
Start by discovering the project contract:
physics.get_project_settings {}
physics.list_surface_types {}
physics.list_collision_channels {}
physics.list_collision_profiles {}
Project timing and named surfaces are persistent configuration changes and therefore require confirmation under the normal risk policy:
physics.set_project_settings {"substepping":"true","maxSubstepDeltaTime":"0.008333","maxSubsteps":"8"}
physics.set_surface_types {"surfaces":[{"type":1,"name":"Concrete"},{"type":2,"name":"Mud"}]}
Create the physical material through the asset kit, then tune its response here. density is in
g/cm³; friction is non-negative and restitution is from 0 to 1:
asset.create_physical_material {"folder":"/Game/Physics","name":"PM_Rubber"}
physics.duplicate_material {"source":"/Engine/EngineMaterials/DefaultPhysicalMaterial","destination":"/Game/Physics/PM_Ice"}
physics.set_material {"material":"/Game/Physics/PM_Rubber","friction":"1.1","staticFriction":"1.3","restitution":"0.65","density":"1.2","surfaceType":"2","overrideFrictionCombineMode":"true","frictionCombineMode":"max"}
physics.get_material {"material":"/Game/Physics/PM_Rubber"}
Assign the material to a mesh component with component.set_physics, or to a material asset with
material.set_physical_material; those tools own the assignment relationship.
While PIE is running, query the runtime world by any listed channel. The queries report only the
first blocking response. Pass actor labels in ignoreActors when the trace origin belongs to the
player or a probe actor:
physics.line_trace {"start":{"x":0,"y":0,"z":500},"end":{"x":0,"y":0,"z":-500},"channel":"Visibility","ignoreActors":["Player"]}
physics.sweep {"shape":"sphere","start":{"x":0,"y":0,"z":100},"end":{"x":1000,"y":0,"z":100},"radius":25,"channel":"Camera"}
physics.overlap_blocking {"shape":"box","start":{"x":500,"y":0,"z":100},"radius":50,"halfHeight":50,"extentZ":100,"channel":"Visibility"}
Box dimensions use radius, halfHeight, and extentZ as X/Y/Z half extents. A capsule needs
halfHeight >= radius. line_trace, sweep, and overlap_blocking require an active PIE world;
they intentionally do not run against the editor world.
Test bodies and constraints
The body and constraint tools need a placed actor. To experiment without touching project actors,
spawn a movable engine-cube body and a PhysicsConstraintActor (its component is always
MyConstraintComp), edit them, then delete them. Engine physical materials are read-only; copy
one with physics.duplicate_material before physics.set_material.
physics.spawn_body_actor {"label":"Crate","location":{"x":0,"y":0,"z":300}}
physics.spawn_constraint_actor {"label":"Hinge","actor1":"Crate","location":{"x":0,"y":0,"z":350}}
physics.set_constraint_swing1_limit {"actor":"Hinge","component":"MyConstraintComp","motion":"limited","limit":30}
physics.delete_actors {"actors":["Hinge","Crate"]}
During PIE use the transient variants, which spawn into the play world and initialise the constraint immediately; they disappear when PIE stops:
physics.spawn_test_body {"label":"Crate","location":{"x":0,"y":0,"z":300},"simulate":true}
physics.spawn_test_constraint {"label":"Hinge","actor1":"Crate"}
physics.apply_body_impulse {"actor":"Crate","vector":{"x":0,"y":0,"z":500},"velocityChange":true}
physics.get_constraint_force {"actor":"Hinge","component":"MyConstraintComp"}
physics.delete_actors only removes actors that own a primitive or constraint component (use
actor.delete for anything else). Editor-world spawns are undoable; PIE spawns are not recorded.
Herramientas
Leyenda. riesgo 0 = solo lectura, 1 = operación inofensiva del editor, 2 = modifica un asset, 3 = elimina/reemplaza un asset, 4 = proyecto/configuración/build, 5 = potencialmente destructivo (las llamadas por encima de
MaxAutoRiskrequieren"_confirm": true). modifica = se ejecuta en una transacción (edit.undo la revierte). requiere PIE / requiere mundo = se rechaza sin una sesión PIE / sin un nivel abierto. requiere el plugin = no disponible cuando el plugin está desactivado. dryRun = acepta el argumentodryRun. smoke = cubierto poredit.self_test.
physics.apply_body_force (riesgo 2, modifica, requiere PIE, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
vector | {x,y,z} | obligatorio. Force, impulse, torque, or location vector. |
velocityChange | boolean | Treat an impulse as a velocity change. Valor predeterminado false. |
Devuelve: actor, component, values, message.
physics.apply_body_impulse (riesgo 2, modifica, requiere PIE, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
vector | {x,y,z} | obligatorio. Force, impulse, torque, or location vector. |
velocityChange | boolean | Treat an impulse as a velocity change. Valor predeterminado false. |
Devuelve: actor, component, values, message.
physics.apply_body_impulse_at_location (riesgo 2, modifica, requiere PIE, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
impulse | {x,y,z} | obligatorio. Impulse vector. |
location | {x,y,z} | obligatorio. World location in centimetres. |
Devuelve: actor, component, values, message.
physics.apply_body_torque (riesgo 2, modifica, requiere PIE, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
vector | {x,y,z} | obligatorio. Force, impulse, torque, or location vector. |
velocityChange | boolean | Treat an impulse as a velocity change. Valor predeterminado false. |
Devuelve: actor, component, values, message.
physics.break_constraint (riesgo 2, modifica, requiere PIE, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
actor | string | obligatorio. Actor label, name, or path. |
component | string | obligatorio. PhysicsConstraintComponent name. |
Devuelve: constraint, values.
physics.clear_body_mass_override (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
actor | string | obligatorio. Actor label, name, or path in the editor or PIE world. |
component | string | Primitive component name; empty selects the first primitive component. |
Devuelve: actor, component, values, message.
physics.delete_actors (riesgo 3, modifica, destructivo, requiere mundo, smoke)
Deletes actors that own a primitive or physics-constraint component from the editor world (or the PIE world while PIE runs).
| Argumento | Tipo | Descripción |
|---|---|---|
actors | array of string | obligatorio. Actor labels, names, or paths. Each must own a primitive or constraint component. |
Devuelve: values, surfaces, channels, message.
physics.disable_constraint_collision (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
enabled | boolean | obligatorio. New enabled state. |
Devuelve: constraint, values.
physics.duplicate_material (riesgo 2, modifica, smoke)
Copies a PhysicalMaterial (engine or project) to a new project asset so it can be edited with physics.set_material.
| Argumento | Tipo | Descripción |
|---|---|---|
source | string | obligatorio. Source PhysicalMaterial asset path (engine assets allowed). |
destination | string | obligatorio. Destination object path, for example /Game/Physics/PM_Rubber. |
Devuelve: material, friction, staticFriction, restitution, density, surfaceType, overrideFrictionCombineMode, frictionCombineMode, overrideRestitutionCombineMode, restitutionCombineMode.
physics.enable_body_gravity (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
enabled | boolean | obligatorio. New enabled state. |
Devuelve: actor, component, values, message.
physics.enable_body_hit_events (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
enabled | boolean | obligatorio. New enabled state. |
Devuelve: actor, component, values, message.
physics.enable_body_simulation (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
enabled | boolean | obligatorio. New enabled state. |
Devuelve: actor, component, values, message.
physics.get_body_angular_velocity (riesgo 0, requiere PIE, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
actor | string | obligatorio. Actor label, name, or path in the editor or PIE world. |
component | string | Primitive component name; empty selects the first primitive component. |
Devuelve: actor, component, values, message.
physics.get_body_velocity (riesgo 0, requiere PIE, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
actor | string | obligatorio. Actor label, name, or path in the editor or PIE world. |
component | string | Primitive component name; empty selects the first primitive component. |
Devuelve: actor, component, values, message.
physics.get_constraint_force (riesgo 0, requiere PIE, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
actor | string | obligatorio. Actor label, name, or path. |
component | string | obligatorio. PhysicsConstraintComponent name. |
Devuelve: constraint, values.
physics.get_material (riesgo 0, smoke)
Returns the portable physical response values of a PhysicalMaterial asset.
| Argumento | Tipo | Descripción |
|---|---|---|
material | string | obligatorio. PhysicalMaterial asset path or unique name. |
Devuelve: material, friction, staticFriction, restitution, density, surfaceType, overrideFrictionCombineMode, frictionCombineMode, overrideRestitutionCombineMode, restitutionCombineMode.
physics.get_project_settings (riesgo 0, smoke)
Returns cross-version project physics timing and degree-of-freedom defaults.
Sin argumentos.
Devuelve: values, surfaces, channels, message.
physics.inspect_body (riesgo 0, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
actor | string | obligatorio. Actor label, name, or path in the editor or PIE world. |
component | string | Primitive component name; empty selects the first primitive component. |
Devuelve: actor, component, values, message.
physics.inspect_constraint (riesgo 0, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
actor | string | obligatorio. Actor label, name, or path. |
component | string | obligatorio. PhysicsConstraintComponent name. |
Devuelve: constraint, values.
physics.line_trace (riesgo 0, requiere PIE, smoke)
Performs a blocking line trace in the active PIE world.
| Argumento | Tipo | Descripción |
|---|---|---|
start | {x,y,z} | obligatorio. Query start in centimetres. |
end | {x,y,z} | obligatorio. Query end in centimetres. |
Devuelve: hit, hit, message.
physics.list_collision_channels (riesgo 0, smoke)
Lists engine and project collision-channel names for scene queries.
Sin argumentos.
Devuelve: values, surfaces, channels, message.
physics.list_collision_profiles (riesgo 0, smoke)
Lists collision profiles; component.physics owns applying a profile to a component.
Sin argumentos.
Devuelve: values, surfaces, channels, message.
physics.list_surface_types (riesgo 0, smoke)
Lists project-defined physical surface names.
Sin argumentos.
Devuelve: values, surfaces, channels, message.
physics.overlap_blocking (riesgo 0, requiere PIE, smoke)
Tests whether a sphere, box, or capsule overlaps a blocking object in the active PIE world.
| Argumento | Tipo | Descripción |
|---|---|---|
shape | string | Shape kind: sphere, box, or capsule. Valor predeterminado TEXT("sphere"). |
start | {x,y,z} | obligatorio. Start / overlap centre in centimetres. |
end | {x,y,z} | Sweep end in centimetres; ignored by overlap. |
radius | number | Sphere radius, capsule radius, or box X half extent in centimetres. Valor predeterminado 50.0. |
halfHeight | number | Capsule half-height or box Y half extent in centimetres. Valor predeterminado 50.0. |
extentZ | number | Box Z half extent in centimetres. Valor predeterminado 50.0. |
rotation | {x,y,z} | Shape rotation in degrees for box and capsule queries. |
Devuelve: hit, hit, message.
physics.set_body_angular_damping (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
value | number | obligatorio. Value in the units named by the tool. |
Devuelve: actor, component, values, message.
physics.set_body_channel_response (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
channel | string | obligatorio. Collision channel name. |
response | string | obligatorio. ignore, overlap, or block. |
Devuelve: actor, component, values, message.
physics.set_body_collision_mode (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
mode | string | obligatorio. no_collision, query_only, physics_only, or query_and_physics. |
Devuelve: actor, component, values, message.
physics.set_body_collision_profile (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
profile | string | obligatorio. Registered collision-profile name. |
Devuelve: actor, component, values, message.
physics.set_body_linear_damping (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
value | number | obligatorio. Value in the units named by the tool. |
Devuelve: actor, component, values, message.
physics.set_body_linear_velocity (riesgo 2, modifica, requiere PIE, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
vector | {x,y,z} | obligatorio. Force, impulse, torque, or location vector. |
velocityChange | boolean | Treat an impulse as a velocity change. Valor predeterminado false. |
Devuelve: actor, component, values, message.
physics.set_body_mass_kg (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
value | number | obligatorio. Value in the units named by the tool. |
Devuelve: actor, component, values, message.
physics.set_constraint_angular_break (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
enabled | boolean | obligatorio. Enable breaking. |
threshold | number | obligatorio. Break threshold. |
Devuelve: constraint, values.
physics.set_constraint_angular_drive_params (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
positionStrength | number | obligatorio. Position gain. |
velocityStrength | number | obligatorio. Velocity gain. |
forceLimit | number | obligatorio. Force limit. |
Devuelve: constraint, values.
physics.set_constraint_angular_orientation_drive (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
x | boolean | Enable X. Valor predeterminado false. |
y | boolean | Enable Y. Valor predeterminado false. |
z | boolean | Enable Z. Valor predeterminado false. |
Devuelve: constraint, values.
physics.set_constraint_angular_velocity_drive (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
x | boolean | Enable X. Valor predeterminado false. |
y | boolean | Enable Y. Valor predeterminado false. |
z | boolean | Enable Z. Valor predeterminado false. |
Devuelve: constraint, values.
physics.set_constraint_angular_velocity_target (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
value | {x,y,z} | obligatorio. Target position, velocity, or angular velocity. |
Devuelve: constraint, values.
physics.set_constraint_linear_break (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
enabled | boolean | obligatorio. Enable breaking. |
threshold | number | obligatorio. Break threshold. |
Devuelve: constraint, values.
physics.set_constraint_linear_drive_params (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
positionStrength | number | obligatorio. Position gain. |
velocityStrength | number | obligatorio. Velocity gain. |
forceLimit | number | obligatorio. Force limit. |
Devuelve: constraint, values.
physics.set_constraint_linear_position_drive (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
x | boolean | Enable X. Valor predeterminado false. |
y | boolean | Enable Y. Valor predeterminado false. |
z | boolean | Enable Z. Valor predeterminado false. |
Devuelve: constraint, values.
physics.set_constraint_linear_position_target (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
value | {x,y,z} | obligatorio. Target position, velocity, or angular velocity. |
Devuelve: constraint, values.
physics.set_constraint_linear_velocity_drive (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
x | boolean | Enable X. Valor predeterminado false. |
y | boolean | Enable Y. Valor predeterminado false. |
z | boolean | Enable Z. Valor predeterminado false. |
Devuelve: constraint, values.
physics.set_constraint_linear_velocity_target (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
value | {x,y,z} | obligatorio. Target position, velocity, or angular velocity. |
Devuelve: constraint, values.
physics.set_constraint_linear_x_limit (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
motion | string | obligatorio. free, limited, or locked. |
limit | number | obligatorio. Limit distance cm or angle degrees. |
Devuelve: constraint, values.
physics.set_constraint_linear_y_limit (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
motion | string | obligatorio. free, limited, or locked. |
limit | number | obligatorio. Limit distance cm or angle degrees. |
Devuelve: constraint, values.
physics.set_constraint_linear_z_limit (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
motion | string | obligatorio. free, limited, or locked. |
limit | number | obligatorio. Limit distance cm or angle degrees. |
Devuelve: constraint, values.
physics.set_constraint_swing1_limit (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
motion | string | obligatorio. free, limited, or locked. |
limit | number | obligatorio. Limit distance cm or angle degrees. |
Devuelve: constraint, values.
physics.set_constraint_swing2_limit (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
motion | string | obligatorio. free, limited, or locked. |
limit | number | obligatorio. Limit distance cm or angle degrees. |
Devuelve: constraint, values.
physics.set_constraint_twist_limit (riesgo 2, modifica, requiere mundo, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
motion | string | obligatorio. free, limited, or locked. |
limit | number | obligatorio. Limit distance cm or angle degrees. |
Devuelve: constraint, values.
physics.set_material (riesgo 2, modifica, smoke)
Updates portable physical response values of a PhysicalMaterial asset.
| Argumento | Tipo | Descripción |
|---|---|---|
friction | string | Dynamic friction, non-negative. |
staticFriction | string | Static friction, non-negative. |
restitution | string | Bounciness from zero through one. |
density | string | Density in grams per cubic centimetre, non-negative. |
surfaceType | string | Surface type number (0..62). |
overrideFrictionCombineMode | string | Override friction combination mode. |
frictionCombineMode | string | Friction combination: average, min, multiply, or max. |
overrideRestitutionCombineMode | string | Override restitution combination mode. |
restitutionCombineMode | string | Restitution combination: average, min, multiply, or max. |
Devuelve: material, friction, staticFriction, restitution, density, surfaceType, overrideFrictionCombineMode, frictionCombineMode, overrideRestitutionCombineMode, restitutionCombineMode.
physics.set_project_settings (riesgo 4, modifica)
Saves selected project physics timing defaults to DefaultEngine.ini.
| Argumento | Tipo | Descripción |
|---|---|---|
substepping | string | Enable synchronous physics substepping. |
substeppingAsync | string | Enable asynchronous physics substepping where supported. |
maxPhysicsDeltaTime | string | Maximum simulation delta in seconds, greater than zero. |
maxSubstepDeltaTime | string | Maximum substep delta in seconds, greater than zero. |
maxSubsteps | string | Maximum substeps, from 1 through 16. |
defaultDegreesOfFreedom | string | Default degree-of-freedom mode: full3d, yz, xz, or xy. |
Devuelve: values, surfaces, channels, message.
physics.set_surface_types (riesgo 4, modifica)
Saves named physical-surface types to DefaultEngine.ini.
| Argumento | Tipo | Descripción |
|---|---|---|
surfaces | array of UeaPhysicsSurface | obligatorio. Surface names to create or update. |
Devuelve: values, surfaces, channels, message.
physics.sleep_body (riesgo 2, modifica, requiere PIE, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
actor | string | obligatorio. Actor label, name, or path in the editor or PIE world. |
component | string | Primitive component name; empty selects the first primitive component. |
Devuelve: actor, component, values, message.
physics.spawn_body_actor (riesgo 2, modifica, requiere mundo, smoke)
Spawns a movable StaticMeshActor (default engine cube) in the editor world, optionally simulating physics.
| Argumento | Tipo | Descripción |
|---|---|---|
label | string | obligatorio. Actor label for the new actor. |
mesh | string | Static mesh asset; defaults to the engine cube. Valor predeterminado TEXT("/Engine/BasicShapes/Cube"). |
location | {x,y,z} | World location in centimetres. |
simulate | boolean | Enable physics simulation on the mesh component. Valor predeterminado false. |
Devuelve: actor, component, values, message.
physics.spawn_constraint_actor (riesgo 2, modifica, requiere mundo, smoke)
Spawns a PhysicsConstraintActor in the editor world joining actor1 and actor2 (empty = world). Its component is MyConstraintComp.
| Argumento | Tipo | Descripción |
|---|---|---|
label | string | obligatorio. Actor label for the new constraint actor. |
actor1 | string | First constrained actor label/name; empty constrains to the world. |
actor2 | string | Second constrained actor label/name; empty constrains to the world. |
location | {x,y,z} | World location in centimetres. |
Devuelve: constraint, values.
physics.spawn_test_body (riesgo 1, requiere PIE, smoke)
Spawns a transient simulated StaticMeshActor in the running PIE world for force/velocity experiments.
| Argumento | Tipo | Descripción |
|---|---|---|
label | string | obligatorio. Actor label for the new actor. |
mesh | string | Static mesh asset; defaults to the engine cube. Valor predeterminado TEXT("/Engine/BasicShapes/Cube"). |
location | {x,y,z} | World location in centimetres. |
simulate | boolean | Enable physics simulation on the mesh component. Valor predeterminado false. |
Devuelve: actor, component, values, message.
physics.spawn_test_constraint (riesgo 1, requiere PIE, smoke)
Spawns a transient PhysicsConstraintActor in the running PIE world and initialises it between actor1 and actor2 (empty = world).
| Argumento | Tipo | Descripción |
|---|---|---|
label | string | obligatorio. Actor label for the new constraint actor. |
actor1 | string | First constrained actor label/name; empty constrains to the world. |
actor2 | string | Second constrained actor label/name; empty constrains to the world. |
location | {x,y,z} | World location in centimetres. |
Devuelve: constraint, values.
physics.sweep (riesgo 0, requiere PIE, smoke)
Sweeps a sphere, box, or capsule for the first blocking hit in the active PIE world.
| Argumento | Tipo | Descripción |
|---|---|---|
shape | string | Shape kind: sphere, box, or capsule. Valor predeterminado TEXT("sphere"). |
start | {x,y,z} | obligatorio. Start / overlap centre in centimetres. |
end | {x,y,z} | Sweep end in centimetres; ignored by overlap. |
radius | number | Sphere radius, capsule radius, or box X half extent in centimetres. Valor predeterminado 50.0. |
halfHeight | number | Capsule half-height or box Y half extent in centimetres. Valor predeterminado 50.0. |
extentZ | number | Box Z half extent in centimetres. Valor predeterminado 50.0. |
rotation | {x,y,z} | Shape rotation in degrees for box and capsule queries. |
Devuelve: hit, hit, message.
physics.wake_body (riesgo 2, modifica, requiere PIE, smoke)
Sin descripción.
| Argumento | Tipo | Descripción |
|---|---|---|
actor | string | obligatorio. Actor label, name, or path in the editor or PIE world. |
component | string | Primitive component name; empty selects the first primitive component. |
Devuelve: actor, component, values, message.