• Reference
  • LUA API
  • Classes
  • Point

Point

The point is one of the base elements within the project, and can be used as a prefabricated position, or a coordinate record.

Functions

get_point_by_scene_id

Get area by scene ID.

Parameter

VariableTypeDescription
scene_idnumberID in the edit scene.

Return

TypeDescription
regionRegion.
cli.get_point_by_scene_id(scene_id)

get_lua_point_from_py

Create points from py objects.

Parameter

VariableTypeDescription
py_pointtablePy layer object.

Return

TypeDescription
pointPoint.
point.get_lua_point_from_py(py_point)

set_collision

Set the collision.

Parameters

VariableTypeDescription
is_collision_effectbooleanWhether the collision is in effect.
is_land_effectbooleanGround collision switch.
is_air_effectbooleanAerial collision switch.
point:set_collision(is_collision_effect, is_land_effect, is_air_effect)

get_ground_collision

Get the collision type of the map at this point.

Return

TypeDescription
numberCollision type of the target point.
point:get_ground_collision()

get_view_block_type

Gets the view type of the map at the point's location.

Return

TypeDescription
numberView type of the target point.
point:get_view_block_type()

get_point_x

The X coordinate of the point.

Parameter

VariableTypeDescription
pointpointTarget point.

Return

TypeDescription
numberX coordinate of the point.
cli.get_point_x(point)

get_point_y

The Y coordinate of the point.

Parameter

VariableTypeDescription
pointpointTarget point.

Return

TypeDescription
numberY coordinate of the point.
cli.get_point_y(point)

get_point_z

The Z coordinate of the point.

Parameter

VariableTypeDescription
pointpointTarget point.

Return

TypeDescription
numberZ coordinate of the point.
cli.get_point_z(point)

get_point_by_xy

Convert coordinates to points.

Parameters

VariableTypeDescription
xnumberX coordinate of the point.
ynumberY coordinate of the point.

Return

TypeDescription
pointPoint.
cli.get_point_by_xy(x, y)

get_point_offset_vector

Point offset in the direction.

Parameters

VariableTypeDescription
pointpointPoint.
directionnumberPoint of offset direction.
offsetpointOffset amount.

Return

TypeDescription
pointPoint.
cli.get_point_offset_vector(point, direction, offset)

get_point_in_path

The point in the path.

Parameters

VariableTypeDescription
pathtableTarget path.
indexnumberIndex.

Return

TypeDescription
pointPoint.
cli.get_point_in_path(path, index)