Skip to main content
Skip to main content

shallowWaterSimulationPaintVelocityRect

shallowWaterSimulationPaintVelocityRect

Description

Adds velocity into the simulation in the shape of a rectangle.

Definition

shallowWaterSimulationPaintVelocityRect(entityId shallowWaterSimulation, float x, float y, float width, float height, float velocityX, float velocityY, float? paintHeight)

Arguments

entityIdshallowWaterSimulationid of the shallow water simulation
floatxx position of the rectangle center (world coordinates)
floatyy position of the rectangle center (world coordinates)
floatwidthwidth of the rectangle (world size)
floatheightheight of the rectangle (world size)
floatvelocityXvalue to be added to the x component of velocity
floatvelocityYvalue to be added to the y component of velocity
float?paintHeight[optional] height that the paint should happen at. will only be painted if waterHeight in that location >= paintHeight