• API(eca&lua)
  • Lua
  • API
  • Point

Point

create

function Point.create(x: number, y: number, z?: number)
  -> Point

坐标转化为点

@param x — 点X坐标

@param y — 点Y坐标

@param z — 点Z坐标

get_angle_with

(method) Point:get_angle_with(other: Point)
  -> number

获取与另一个点的方向

get_by_handle

function Point.get_by_handle(py_point: Point.HandleType)
  -> Point

根据py对象创建点

get_distance_with

(method) Point:get_distance_with(other: Point)
  -> number

获取与另一个点的距离

get_point

(method) Point:get_point()
  -> Point

get_point_by_res_id

function Point.get_point_by_res_id(res_id: integer)
  -> Point

get_point_in_path

function Point.get_point_in_path(path: table, index: integer)
  -> Point

路径中的点

@param path — 目标路径

@param index — 索引

get_point_offset_vector

function Point.get_point_offset_vector(point: Point, direction: number, offset: number)
  -> Point

点向方向偏移

@param point — 点

@param direction — 偏移方向点

@param offset — 偏移量

get_random_point

(method) Point:get_random_point(radius: any)
  -> Point

获取圆形范围内的随机点

get_x

(method) Point:get_x()
  -> number

点的x坐标

get_y

(method) Point:get_y()
  -> number

点的y坐标

get_z

(method) Point:get_z()
  -> number

点的z坐标

handle

Point.HandleType

map

table

move

(method) Point:move(x?: number, y?: number, z?: number)
  -> Point

移动点

res_id

integer?

type

string

x

number

y

number

z

number

Point.HandleType

py.FPoint