ZERSTORENGAMES

OCEAN AND BOATS SIMULATOR / GUIDE 4 OF 5

Recipes

Floating objects, your own input, AI boats, storms, paint and wave-tank tests, step by step.

On this page

Short, complete answers to common tasks. Each one works in a blank level with an NA Ocean and an NA Boat.

Float any object on the waves

For a buoy, a crate or debris, use the wave height. You don't need the boat physics.

  1. On Tick, call the ocean's Get Wave Height at the object's location.
  2. Set the object's Z to that height minus half its draught.
  3. For a little motion, ease towards that height with FInterp To.

Drive a boat from your own input

  1. Get the boat's NA Ship Motion component and turn its Helm on (category Motion > Helm): the helm functions set her orders only then. The sea trials pawn does this for the boat it drives.
  2. On your throttle axis: Helm Levers (Lever -1, Direction = axis value, Delta Time = world delta seconds).
  3. On your steering axis: Helm Wheel (Direction = axis value, Delta Time).
  4. On release: Helm Levers Let Go (-1).

Make an AI boat follow waypoints

  1. Turn on Helm on her NA Ship Motion component (as above). Each tick, compute the bearing from the boat to the next waypoint.
  2. Turn the difference with her heading into a wheel position: Helm Set Wheel (clamp(difference / 30, -1, 1)).
  3. Set her speed with Helm Levers towards the order you want, or give each engine its own order with Set Propulsor Order.
  4. When she is within two lengths of the waypoint, take the next one.

Start a scene at sea, already moving

After the level loads, call the boat's NA Ship Motion Start Underway (Knots). The boat starts at that speed on her heading, with her engines at the matching order. Nothing ramps up.

Change the sea from a trigger volume

On Begin Overlap:

  1. Set the ocean's Beaufort to the new force (with Preset Beaufort), or Preset to a wave form.
  2. Call Apply Sea State. For a slow build-up, raise the force by one every minute or so, or switch on Sea Follows Wind and change the wind instead (Set Wind Override Beaufort on the NA Wind subsystem).

A storm with Ultra Dynamic Weather

  1. Put Ultra Dynamic Weather and the NA Ocean in the level. The plugin reads its wind by itself.
  2. Switch on Sea Follows Wind on the ocean.
  3. Change the weather in Ultra Dynamic Weather. The sea builds and falls with its wind, over Wind Follow Seconds.

A boat with a different paint and name

  1. Duplicate a boat definition.
  2. In its configurations, set the hull colour, or change the topsides paint slot's tint.
  3. Give her a name. On an NA Boat with a boat definition, set Design > Paint > Markings > Name (category Boat > Design); Boat Name is only for an NA Boat set up without a definition. The name is drawn on the hull at the NAME_* sockets, in a colour that contrasts with the paint.

Test a boat in regular waves

Pick Wave Tank on the start screen (or open NA_Map_WaveTank and press Play), then set the force, the wave length (in her lengths) and the direction in the panel (M), and sail. The panel measures over the last seconds:

  • speed;
  • pitch, heave and roll;
  • the hardest blows on her bow;
  • how often she slams. Change the waves live with the panel's - and + buttons.

Cookie preferences

Choose whether to allow YouTube videos. You can change your mind at any time using Cookie settings at the bottom of every page.

Cookie policy · Privacy policy