Saltar al contenido principal

Kit water

22 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​

The water kit authors UE 5 Water-plugin content in the editor world: water bodies (river, lake, ocean, custom), water zones, the water spline and its per-point metadata, landscape carving, buoyancy and surface queries. Every tool needs UE 5.0+ and the Water plugin enabled; the kit module is only loaded when the plugin is on, so when edit.search_tools shows no water.* tool, enable the plugin (Edit > Plugins > Water) and restart the editor. All water tooling lives here — the landscape kit has no water tools.

Actors are referenced with actor: the outliner label, the object name, or the actor path (the same resolver as every other kit; zero or several matches are an error).

1. Bodies and zones​

  • water.list_bodies / water.get_body report label, path, class, type (River, Lake, Ocean, Custom), location, owning zone (5.1+), splinePoints, affectsLandscape and material.
  • water.add_body {type, name, location, rotation} spawns a body with the class default spline; water.remove_body deletes it.
  • A water zone renders every body inside its extent: water.add_zone {name, location}, water.list_zones, water.get_zone, water.remove_zone. After large edits call water.rebuild_zone to force the water mesh and water info texture to regenerate.
  • water.audit_world lists bodies and zones with warnings (no bodies, bodies without a material, fewer than two spline points, bodies outside any zone and zones rendering nothing on 5.1+). It never fails on an empty world; read warnings.

2. Settings, material and landscape carving​

  • water.get_settings {actor, keys} reads reflected properties. For a body they are read from its WaterBodyComponent (where all body settings live in UE 5); for a zone from the zone actor. Empty keys returns every editable top-level property with its current text value — use it to discover names.
  • water.set_settings {actor, settings:[{key,value}]} writes values in engine text form; dotted paths reach struct members (WaterHeightmapSettings.FalloffSettings.FalloffWidth, CurveSettings.ChannelDepth, zone ZoneExtent, OverlapPriority...). Every key is resolved before the first write, and each write runs the editor change notification, so the body or zone rebuilds as in the details panel. A value that does not parse restores the values already written and returns E_INVALID_ARG.
  • water.set_material {actor, material} assigns the surface material.
  • water.get_carve / water.set_carve expose the landscape interaction as one typed struct: affectsLandscape, blendMode (AlphaBlend, Min, Max, Additive), falloffMode (Angle, Width), falloffAngle, falloffWidth, edgeOffset, zOffset, useCurveChannel, channelDepth, channelEdgeOffset, curveRampWidth. set_carve writes all fields: read, modify, write back.

3. Spline and river metadata​

  • water.list_spline_points returns each point's body-relative and world location plus its water metadata (depth, width, velocity, audioIntensity) and whether the spline is closed.
  • water.add_spline_point {actor, index, location, world} inserts at index (-1 appends); water.set_spline_point moves a point; water.remove_spline_point removes one (a body keeps at least two points). world:false (default) means relative to the water body.
  • water.set_river_point {actor, index, depth, width, velocity, audioIntensity} writes the per-point metadata in one call (all four values). Width and velocity matter for rivers; depth for every spline body.
  • Every spline edit runs the water spline's change path (metadata sync + data-changed broadcast), which rebuilds the body and its landscape carve.

4. Buoyancy and queries​

  • water.add_buoyancy {actor, pontoons:[{location, radius, socket}]} adds a BuoyancyComponent to a level actor, or replaces the pontoons of the one it already has (created tells which). The actor floats only when its root primitive simulates physics; the reply warns otherwise.
  • water.query_surface {actor, location} returns the surface point, normal, velocity, depth and heightAboveSurface (negative = submerged) for a world location — useful to place floating props.

Recipe: a river that carves a landscape​

  1. water.add_zone {name:'WaterZone', location:{x:0,y:0,z:0}} (skip if water.list_zones has one).
  2. water.add_body {type:'river', name:'River01', location:{x:0,y:0,z:100}}.
  3. water.list_spline_points {actor:'River01'}; then water.set_spline_point / water.add_spline_point to lay out the course (body-relative centimetres).
  4. water.set_river_point {actor:'River01', index:i, depth:200, width:1500, velocity:150} per point.
  5. water.get_carve {actor:'River01'}, adjust (affectsLandscape:true, falloffWidth, channelDepth), water.set_carve with the full struct.
  6. water.set_material if the default water material is not wanted.
  7. water.rebuild_zone {actor:'WaterZone'} and water.audit_world to confirm no warnings.

Gotchas​

  • Without a WaterBodyCollision collision profile the Water editor logs a Load Errors entry whose "Add entry to DefaultEngine.ini?" action writes project config. The kit never writes config: add the profile to [/Script/Engine.CollisionProfile] yourself (QueryOnly, WorldStatic; Visibility and Camera ignored; WorldDynamic, Pawn, PhysicsBody, Vehicle, Destructible overlapped).
  • UE 5.0 has no public accessor for a body's water zone: zone is empty and the zone checks of audit_world are skipped there.
  • Ocean bodies need a water zone to render; landscape carving needs a landscape with edit layers (the Water brush is an edit-layer brush) — see landscape.list_edit_layers.
  • UE 4.27 ships only an experimental Water plugin with a different API; the kit is UE 5 only.

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 MaxAutoRisk requieren "_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 argumento dryRun. smoke = cubierto por edit.self_test.

water.add_body (riesgo 2, modifica, UE 5.0+, requiere el plugin Water, requiere mundo, smoke)​

Spawns a water body (river, lake, ocean or custom) with its default spline; returns it.

ArgumentoTipoDescripción
typestringobligatorio. river, lake, ocean or custom.
namestringobligatorio. Outliner label of the new actor.
location{x,y,z}World location in centimetres.
rotation{x,y,z}World rotation in degrees (pitch, yaw, roll).

Devuelve: items, count, warnings, message.

water.add_buoyancy (riesgo 2, modifica, UE 5.0+, requiere el plugin Water, requiere mundo, smoke)​

Gives a level actor a BuoyancyComponent with the given pontoons (replaces the pontoons when it already has one). The root must simulate physics to float.

ArgumentoTipoDescripción
actorstringobligatorio. Level actor that receives (or already has) a BuoyancyComponent.
pontoonsarray of UeaWaterPontoonobligatorio. Pontoons, replacing any existing ones (at least one).

Devuelve: actor, component, created, pontoons, warnings.

water.add_spline_point (riesgo 2, modifica, UE 5.0+, requiere el plugin Water, requiere mundo, smoke)​

Inserts a spline point at index (-1 appends); location is relative to the body unless world is true.

ArgumentoTipoDescripción
actorstringobligatorio. Water body actor.
indexintegerZero-based spline point index; -1 appends (add only). Valor predeterminado -1.
location{x,y,z}Point location in centimetres.
worldbooleantrue: location is in world space; false: relative to the water body. Valor predeterminado false.

Devuelve: water, points, closedLoop.

water.add_zone (riesgo 2, modifica, UE 5.0+, requiere el plugin Water, requiere mundo, smoke)​

Spawns a water zone (the actor that renders water bodies inside its extent); returns it.

ArgumentoTipoDescripción
namestringobligatorio. Outliner label of the new water zone.
location{x,y,z}World location in centimetres.

Devuelve: items, count, warnings, message.

water.audit_world (riesgo 0, UE 5.0+, requiere el plugin Water, requiere mundo, smoke)​

Reports water setup problems: no bodies, bodies without a zone, bodies without a material, zones without bodies.

ArgumentoTipoDescripción
actorstringWater body or water zone actor label, object name, or path.

Devuelve: items, count, warnings, message.

water.get_body (riesgo 0, UE 5.0+, requiere el plugin Water, requiere mundo, smoke)​

Returns one water body.

ArgumentoTipoDescripción
actorstringWater body or water zone actor label, object name, or path.

Devuelve: items, count, warnings, message.

water.get_carve (riesgo 0, UE 5.0+, requiere el plugin Water, requiere mundo, smoke)​

Returns how a water body carves the landscape (affectsLandscape, brush blend and falloff, channel curve).

ArgumentoTipoDescripción
actorstringWater body or water zone actor label, object name, or path.

Devuelve: water, carve.

water.get_settings (riesgo 0, UE 5.0+, requiere el plugin Water, requiere mundo, smoke)​

Reads reflected properties of a water body's WaterBodyComponent or of a water zone (empty keys: every editable top-level property).

ArgumentoTipoDescripción
actorstringobligatorio. Water body (read from its WaterBodyComponent) or water zone actor.
keysarray of stringProperty paths to read; empty returns every editable top-level property.

Devuelve: water, settings.

water.get_zone (riesgo 0, UE 5.0+, requiere el plugin Water, requiere mundo, smoke)​

Returns one water zone.

ArgumentoTipoDescripción
actorstringWater body or water zone actor label, object name, or path.

Devuelve: items, count, warnings, message.

water.list_bodies (riesgo 0, UE 5.0+, requiere el plugin Water, requiere mundo, smoke)​

Lists water body actors (river, lake, ocean, custom) with type, zone, spline point count, carve flag and material.

ArgumentoTipoDescripción
actorstringWater body or water zone actor label, object name, or path.

Devuelve: items, count, warnings, message.

water.list_spline_points (riesgo 0, UE 5.0+, requiere el plugin Water, requiere mundo, smoke)​

Lists the spline points of a water body with local/world location and per-point depth, width, velocity and audio metadata.

ArgumentoTipoDescripción
actorstringWater body or water zone actor label, object name, or path.

Devuelve: water, points, closedLoop.

water.list_zones (riesgo 0, UE 5.0+, requiere el plugin Water, requiere mundo, smoke)​

Lists water zone actors.

ArgumentoTipoDescripción
actorstringWater body or water zone actor label, object name, or path.

Devuelve: items, count, warnings, message.

water.query_surface (riesgo 0, UE 5.0+, requiere el plugin Water, requiere mundo, smoke)​

Queries a water body at a world location: surface point and normal, velocity, depth, and height above the surface.

ArgumentoTipoDescripción
actorstringobligatorio. Water body actor.
location{x,y,z}World location to query, in centimetres.

Devuelve: surfaceLocation, surfaceNormal, velocity, depth, heightAboveSurface.

water.rebuild_zone (riesgo 2, modifica, UE 5.0+, requiere el plugin Water, requiere mundo, smoke)​

Forces a water zone to rebuild its water mesh and water info texture.

ArgumentoTipoDescripción
actorstringWater body or water zone actor label, object name, or path.

Devuelve: items, count, warnings, message.

water.remove_body (riesgo 3, modifica, destructivo, UE 5.0+, requiere el plugin Water, requiere mundo, smoke)​

Deletes a water body actor.

ArgumentoTipoDescripción
actorstringWater body or water zone actor label, object name, or path.

Devuelve: items, count, warnings, message.

water.remove_spline_point (riesgo 3, modifica, destructivo, UE 5.0+, requiere el plugin Water, requiere mundo, smoke)​

Removes a spline point (a body keeps at least two points).

ArgumentoTipoDescripción
actorstringobligatorio. Water body actor.
indexintegerZero-based spline point index. Valor predeterminado 0.

Devuelve: water, points, closedLoop.

water.remove_zone (riesgo 3, modifica, destructivo, UE 5.0+, requiere el plugin Water, requiere mundo, smoke)​

Deletes a water zone actor.

ArgumentoTipoDescripción
actorstringWater body or water zone actor label, object name, or path.

Devuelve: items, count, warnings, message.

water.set_carve (riesgo 2, modifica, UE 5.0+, requiere el plugin Water, requiere mundo, smoke)​

Writes the complete landscape carve settings of a water body (read them with water.get_carve first).

ArgumentoTipoDescripción
actorstringobligatorio. Water body actor.
carveUeaWaterCarveComplete carve settings (read them first with water.get_carve).

Devuelve: water, carve.

water.set_material (riesgo 2, modifica, UE 5.0+, requiere el plugin Water, requiere mundo, smoke)​

Sets the water surface material of a water body.

ArgumentoTipoDescripción
actorstringobligatorio. Water body actor.
materialstringobligatorio. Water surface material or material instance.

Devuelve: water, settings.

water.set_river_point (riesgo 2, modifica, UE 5.0+, requiere el plugin Water, requiere mundo, smoke)​

Writes the per-point water metadata of a spline point: depth, river width, flow velocity and audio intensity.

ArgumentoTipoDescripción
actorstringobligatorio. Water body actor (river, lake or ocean spline).
indexintegerZero-based spline point index. Valor predeterminado 0.
depthnumberChannel depth at the point in centimetres (>= 0). Valor predeterminado 100.
widthnumberRiver width at the point in centimetres (> 0; rivers only). Valor predeterminado 1000.
velocitynumberFlow velocity scalar at the point (rivers). Valor predeterminado 100.
audioIntensitynumberAudio intensity at the point (0..1). Valor predeterminado 0.

Devuelve: water, points, closedLoop.

water.set_settings (riesgo 2, modifica, UE 5.0+, requiere el plugin Water, requiere mundo, smoke)​

Assigns reflected properties on a water body's WaterBodyComponent or on a water zone, then runs the editor change notification so the water rebuilds. All keys are validated before any is written.

ArgumentoTipoDescripción
actorstringobligatorio. Water body (settings live on its WaterBodyComponent) or water zone actor.
settingsarray of UeaKeyValueProperty assignments in engine text form; dotted paths reach struct members (e.g. WaterHeightmapSettings.FalloffSettings.FalloffWidth).

Devuelve: water, settings.

water.set_spline_point (riesgo 2, modifica, UE 5.0+, requiere el plugin Water, requiere mundo, smoke)​

Moves an existing spline point; location is relative to the body unless world is true.

ArgumentoTipoDescripción
actorstringobligatorio. Water body actor.
indexintegerZero-based spline point index; -1 appends (add only). Valor predeterminado -1.
location{x,y,z}Point location in centimetres.
worldbooleantrue: location is in world space; false: relative to the water body. Valor predeterminado false.

Devuelve: water, points, closedLoop.