Skip to main content
source

Types


check-vector-collision-with-nav-spheres-info

check-vector-collision-with-nav-spheres-info: structuresource
Fields
u: float
intersect: vector
normal: vector
nav-avoid-spheres-params: structuresource
Fields
current-pos: vector
travel: vector
pref-dir: vector
out-travel: vector
closest-sphere-dist2: float
avoiding-sphere?: symbol
nav-callback-info: structuresource
Fields
callback-count: int32
callback-array: function
nav-control: structuresource
Fields
flags: nav-control-flag
callback-info: nav-callback-info
process: process
pad0: uint32
shape: collide-shape
nearest-y-threshold: meters
nav-cull-radius: meters
sec-per-frame: float
target-speed: meters
acceleration: meters
turning-acceleration: meters
max-rotation-rate: float
speed-scale: float
sphere-count: int32
sphere-array: inline-array
root-sphere-id: uint8
sphere-mask: uint8
pad1: uint8
sphere-id-array: uint8
extra-nav-sphere: vector
root-nav-sphere: vector
state: nav-state
Methods
debug-draw(obj: nav-control) => nonesource
point-in-bsphere?(obj: nav-control, arg0: vector) => symbolsource

Is the given point ([[vector]]) outside of the nav-mesh bounds sphere radius

find-poly-containing-point-1(obj: nav-control, arg0: vector) => nav-polysource

Find nav-poly containing this point.

cloest-point-on-mesh(obj: nav-control, arg0: vector, arg1: vector, arg2: nav-poly) => nav-polysource
find-nearest-poly-to-point(obj: nav-control, arg0: vector) => nav-polysource

Find the nav-poly closest to this point in the nav-mesh.

project-point-onto-plane-of-poly(obj: nav-control, arg0: nav-poly, arg1: vector, arg2: vector, arg3: vector) => nonesource

Move a point to the be on the plane containing the given nav-poly. Return the normal too

find-poly-containing-point-2(obj: nav-control, arg0: vector) => nav-polysource

Find nav-poly containing this point - same as 1

is-above-poly-max-height?(obj: nav-control, arg0: vector, arg1: float) => symbolsource

Is the point in a poly, and lower than a max height?

is-in-mesh?(obj: nav-control, arg0: vector, arg1: float) => symbolsource

Is this point in the mesh?

avoid-spheres-1!(obj: nav-control, arg0: nav-avoid-spheres-params) => symbolsource
avoid-spheres-2!(obj: nav-control, arg0: nav-avoid-spheres-params) => symbolsource
clamp-vector-to-mesh-cross-gaps(obj: nav-control, arg0: vector, arg1: nav-poly, arg2: vector, arg3: float, arg4: symbol, arg5: clamp-travel-vector-to-mesh-return-info) => nonesource
clamp-vector-to-mesh-no-gaps(obj: nav-control, arg0: vector, arg1: nav-poly, arg2: vector, arg3: clamp-travel-vector-to-mesh-return-info) => nonesource
find-first-sphere-and-update-avoid-params(obj: nav-control, arg0: vector, arg1: nav-avoid-spheres-params) => floatsource
set-spheres-from-nav-ids(obj: nav-control) => nonesource

Set up spheres from sphere ids previously found by find-sphere-ids-from-sphere-hash

add-root-sphere-to-hash!(obj: nav-control, arg0: vector, arg1: int) => symbolsource

Add our root sphere to the hash (if enabled with output-sphere-hash flag) at the given location.

get-max-rotation-rate(obj: nav-control) => floatsource
get-sphere-mask(obj: nav-control) => uintsource
get-target-speed(obj: nav-control) => meterssource
enable-extra-sphere!(obj: nav-control) => nonesource

Sets a flag indicating that this nav-control has an extra-nav-sphere.

disable-extra-sphere!(obj: nav-control) => nonesource

Clears a flag indicating that this nav-control has an extra-nav-sphere.

copy-extra-nav-sphere!(obj: nav-control, arg0: sphere) => nonesource

Copies the given sphere into extra-nav-sphere

set-extra-nav-sphere-xyz!(obj: nav-control, arg0: sphere) => nonesource

Set the extra-nav-sphere with the data in the given sphere

set-extra-nav-sphere-radius!(obj: nav-control, arg0: float) => nonesource

Set's extra-nav-sphere's radius

set-nearest-y-thres!(obj: nav-control, arg0: float) => nonesource

Set nearest-y-threshold

set-nav-cull-radius!(obj: nav-control, arg0: meters) => nonesource

Set nav-cull-radius

set-speed-scale!(obj: nav-control, arg0: float) => nonesource

Set speed-scale

set-target-speed!(obj: nav-control, arg0: meters) => nonesource

Set target-speed

set-acceleration!(obj: nav-control, arg0: meters) => nonesource

Set acceleration

set-turning-acceleration!(obj: nav-control, arg0: meters) => nonesource

Set turning-acceleration

set-max-rotation-rate!(obj: nav-control, arg0: float) => nonesource

Set max-rotation-rate

set-sphere-mask!(obj: nav-control, arg0: uint) => nonesource

TODO - probably an enum - Set sphere-mask

remove!(obj: nav-control) => nonesource

Remove this nav-control from the nav-mesh it belongs to.

init!(obj: nav-control, arg0: collide-shape) => nonesource

Initializes the [[nav-control]], setting shape with the provided collide-shape

display-marks?(obj: nav-control) => symbolsource

Returns if navigation related marks should be displayed

nav-control-method-44: unknown
find-first-sphere-intersecting-ray(obj: nav-control, arg0: vector, arg1: vector, arg2: vector) => spheresource

Find the first sphere that this ray intersects

find-sphere-ids-from-sphere-hash(obj: nav-control, arg0: symbol) => nonesource

Use sphere-hash to look up navigation sphere IDs and save them.

nav-gap-info: structuresource
Fields
dest: vector
poly: nav-poly
nav-state: structuresource
Fields
flags: nav-state-flag
nav: nav-control
user-poly: nav-poly
mesh: nav-mesh
current-poly: nav-poly
virtual-current-poly: nav-poly
next-poly: nav-poly
target-poly: nav-poly
rotation-rate: float
speed: meters
prev-speed: meters
pad0: uint32
travel: vector
target-post: vector
current-pos: vector
current-pos-local: vector
virtual-current-pos-local: vector
velocity: vector
heading: vector
target-dir: vector
accel: vector
Methods
debug-draw(obj: nav-state) => nonesource
nav-state-method-10(obj: nav-state) => nonesource
plan-over-pat1-polys-using-route(obj: nav-state, arg0: nav-gap-info) => symbolsource
get-velocity(obj: nav-state, arg0: vector) => vectorsource
get-travel(obj: nav-state, arg0: vector) => vectorsource
get-heading(obj: nav-state, arg0: vector) => vectorsource
get-target-post(obj: nav-state, arg0: vector) => vectorsource
get-speed(obj: nav-state) => meterssource
get-rotation-rate(obj: nav-state) => floatsource
try-projecting-to-current-poly(obj: nav-state, arg0: vector, arg1: object, arg2: vector) => symbolsource
get-current-poly(obj: nav-state) => nav-polysource
copy-nav-state!(obj: nav-state, arg0: pointer) => nonesource

Copies the nav-state the given pointer points to into the current object

nav-state-method-21: unknown
nav-state-method-22: unknown
nav-state-method-23: unknown
turn-and-navigate-to-destination(obj: nav-state) => nonesource
navigate-using-route-portals-wrapper(obj: nav-state) => nonesource
navigate-using-best-dir-recompute-avoid-spheres-1-wrapper(obj: nav-state) => nonesource
navigate-within-poly-wrapper(obj: nav-state) => nonesource
compute-travel-speed(obj: nav-state) => nonesource
nav-state-method-29(obj: nav-state) => nonesource
nav-state-method-30(obj: nav-state) => nonesource
navigate-using-best-dir-recompute-avoid-spheres-2(obj: nav-state) => nonesource
update-travel-dir-from-spheres(obj: nav-state) => nonesource
compute-speed-simple(obj: nav-state) => nonesource
navigate-v1!(obj: nav-state) => nonesource
reset-target!(obj: nav-state) => nonesource
add-offset-to-target!(obj: nav-state, arg0: vector) => nonesource
navigate-v2!(obj: nav-state) => nonesource
set-current-poly!(obj: nav-state, arg0: nav-poly) => nonesource
nav-state-method-39: unknown
do-navigation-to-destination(obj: nav-state, arg0: vector) => nonesource
clamp-vector-to-mesh-cross-gaps(obj: nav-state, arg0: vector) => symbolsource
set-target-post!(obj: nav-state, arg0: vector) => nonesource
set-travel!(obj: nav-state, arg0: vector) => nonesource
set-velocity!(obj: nav-state, velocity: vector) => nonesource
set-heading!(obj: nav-state, arg0: vector) => nonesource
set-speed!(obj: nav-state, arg0: meters) => nonesource
reset!(obj: nav-state, arg0: nav-control) => nonesource
nav-state-method-48: unknown
navigate-using-best-dir-use-existing-avoid-spheres(obj: nav-state, arg0: nav-avoid-spheres-params) => nonesource
nav-state-method-50(obj: nav-state) => nonesource
navigate-using-route-portals(obj: nav-state) => nonesource
navigate-using-best-dir-recompute-avoid-spheres-1(obj: nav-state) => nonesource
navigate-within-poly(obj: nav-state) => nonesource
clamp-travel-vector(obj: nav-state) => nonesource
source

Types


nav-control-cfs-work: structuresource
Fields
in-dir: vector
right-dir: vector
best-dir: vector
temp-dir: vector
away-dir: vector
best-dir-angle: degrees
ignore-mask: uint64
initial-ignore-mask: uint64
i-sphere: int32
i-first-sphere: int32
i-inside-sphere: int32
inside-sphere-dist: float
sign: float
travel-len: float
dist2: float
inside-dist: float
rand-angle: float
dir-update: basic
debug-offset: vector

Functions


add-collide-shape-spheres

add-collide-shape-spheres(arg0: nav-control, arg1: collide-shape, arg2: sphere) => nonesource

add-nav-sphere

add-nav-sphere(nav: nav-control, sphere: sphere, max-spheres: int) => nonesource

Adds the given sphere to the nav-control sphere-array so long as
max-spheres is less than nav-control sphere-count

circle-ray-intersection?

circle-ray-intersection?(arg0: vector, arg1: vector, arg2: float, arg3: vector) => symbolsource

circle-tangent-directions

circle-tangent-directions(arg0: vector, arg1: vector, arg2: vector, arg3: vector) => vectorsource

compute-dir-parm

compute-dir-parm(arg0: vector, arg1: vector, arg2: vector) => floatsource

debug-nav-validate-current-poly

debug-nav-validate-current-poly(arg0: nav-mesh, arg1: nav-poly, arg2: vector) => symbolsource

debug-report-nav-stats

debug-report-nav-stats() => nonesource

Does nothing

find-closest-circle-ray-intersection

find-closest-circle-ray-intersection(arg0: vector, arg1: vector, arg2: float, arg3: int, arg4: inline-array, arg5: int) => intsource

get-nav-control

get-nav-control(arg0: process-drawable, arg1: nav-mesh) => nonesource

Given a process-drawable get the associated nav-control using either:
- the provided nav-mesh arg
- the nav-mesh associated with the process-drawable [[entity]]
If no nav-mesh is set or found, set the entity entity-perm-status to TODO and return an error.
Note that this doesn't actually return the nav-control, but instead adds this process-drawable to the nav-mesh.

test-xz-point-on-line-segment?

test-xz-point-on-line-segment?(arg0: vector, arg1: vector, arg2: vector, arg3: float) => symbolsource

vector-rotate-y-sincos!

vector-rotate-y-sincos!(arg0: vector, arg1: vector, arg2: float, arg3: float) => floatsource

Variables


*nav-last-triangle-test-count*: intsource
*nav-triangle-test-count*: intsource
source

Types


nav-enemy: enemysource
Fields
type: type
name: string
mask: process-mask
clock: clock
parent: pointer
brother: pointer
child: pointer
ppointer: pointer
self: process-tree
pool: dead-pool
status: symbol
pid: int32
main-thread: cpu-thread
top-thread: cpu-thread
entity: entity-actor
level: level
state: state
next-state: state
trans-hook: function
post-hook: function
event-hook: function
allocated-length: int32
pad-unknown-0: uint32
heap-base: pointer
heap-top: pointer
heap-cur: pointer
stack-frame-top: stack-frame
connection-list: connectable
stack: uint8
root: trsqv
node-list: cspace-array
draw: draw-control
skel: joint-control
nav: nav-control
align: align-control
path: path-control
vol: vol-control
fact: fact-info
link: actor-link-info
part: sparticle-launch-control
water: water-control
sound: ambient-sound
carry: carry-info
rbody: rigid-body-control
state-flags: state-flags
state-time: time-frame
root-override: collide-shape
focus-status: focus-status
root-override2: collide-shape-moving
fact-info-override: fact-info-enemy
enemy-flags: enemy-flag
enemy-info: enemy-info
hit-points: int32
gnd-collide: uint32
attack-id: uint32
persistent-attack-id: uint32
water-max-height: meters
water-surface-height: meters
desired-angle: degrees
jump-why: uint64
penetrated-by-all: penetrate
penetrated-flinch: penetrate
penetrated-knocked: penetrate
reaction-time: time-frame
notice-time: time-frame
state-timeout: time-frame
auto-reset-penetrate-time: time-frame
hit-focus-time: time-frame
last-draw-time: time-frame
starting-time: time-frame
fated-time: time-frame
focus-pos: vector
event-param-point: vector
jump-dest: vector
focus: enemy-focus
incoming: enemy-attack-info
actor-group: pointer
actor-group-count: int32
neck: joint-mod
on-notice: symbol
on-active: symbol
on-hostile: symbol
on-death: symbol
idle-anim-player: idle-control
rand-gen: symbol
enemy-info-override: nav-enemy-info
frustration-point: vector
move-dest: vector
frustration-time: time-frame
blocked-start-time: time-frame
restore-nav-radius-time: time-frame
nav-radius-backup: float
Methods
set-enemy-info!(obj: nav-enemy, arg0: nav-enemy-info) => nonesource

In addition to setting the enemy-info, also init the neck-joint if applicable from it

init-enemy-behaviour-and-stats!(obj: nav-enemy, arg0: nav-enemy-info) => nonesource

Initializes a bunch of enemy fields related to how they should react, how many hitpoints they should have, etc

taunt: unknown
pacing: unknown
circling: unknown
stop-chase: unknown
debug-control: unknown
nav-enemy-method-142(obj: ashelin, arg0: nav-control) => nonesource
nav-enemy-method-143(obj: nav-enemy, arg0: nav-control) => nonesource
nav-enemy-method-144(obj: nav-enemy) => time-framesource
nav-enemy-method-145(obj: nav-enemy, arg0: nav-control) => nonesource
nav-enemy-method-146(obj: nav-enemy, arg0: nav-control) => nonesource
nav-enemy-method-147(obj: nav-enemy, arg0: nav-control) => nonesource
nav-enemy-method-148(obj: nav-enemy, arg0: nav-control) => nonesource
nav-enemy-method-149(obj: nav-enemy, arg0: nav-control) => nonesource
nav-enemy-method-150(obj: nav-enemy, arg0: nav-control) => nonesource
nav-enemy-method-151(obj: nav-enemy, arg0: nav-control) => nonesource
nav-enemy-method-152(obj: nav-enemy, arg0: nav-control) => nonesource
nav-enemy-method-153(obj: nav-enemy, arg0: nav-control) => nonesource
nav-enemy-method-154(obj: nav-enemy, arg0: nav-control) => nonesource
nav-enemy-method-155(obj: nav-enemy) => nonesource
nav-enemy-method-156(obj: nav-enemy) => nonesource
nav-enemy-method-157(obj: nav-enemy, arg0: vector) => nav-polysource
nav-enemy-method-158(obj: nav-enemy, arg0: vector) => objectsource
nav-enemy-method-159(obj: nav-enemy, arg0: vector) => symbolsource
nav-enemy-method-160(obj: nav-enemy) => nonesource
nav-enemy-method-161(obj: nav-enemy) => nonesource
nav-enemy-method-162(obj: nav-enemy) => nonesource
nav-enemy-method-163(obj: nav-enemy) => symbolsource
nav-enemy-method-164(obj: nav-enemy) => nonesource
nav-enemy-method-165(obj: nav-enemy) => nonesource
nav-enemy-method-166(obj: nav-enemy) => nonesource
nav-enemy-method-167(obj: nav-enemy) => nonesource
nav-enemy-method-168(obj: nav-enemy) => floatsource
nav-enemy-method-169(obj: nav-enemy, arg0: float, arg1: symbol) => floatsource
nav-enemy-method-170(obj: nav-enemy) => nonesource
nav-enemy-method-171(obj: nav-enemy) => nonesource
nav-enemy-method-172(obj: nav-enemy) => nonesource
nav-enemy-method-173(obj: nav-enemy) => nonesource
nav-enemy-method-174(obj: nav-enemy) => symbolsource
nav-enemy-method-175(obj: nav-enemy) => symbolsource
nav-enemy-method-176(obj: nav-enemy) => nonesource
nav-enemy-method-177(obj: nav-enemy) => nonesource
nav-enemy-debug-control-info: basicsource
Fields
type: type
enable: basic
steering: float
throttle: float
nav-enemy-info: enemy-infosource
Fields
type: type
fact-defaults: fact-info-enemy-defaults
use-die-falling: symbol
use-victory: symbol
use-jump-blocked: symbol
debug-draw-neck: symbol
jump-debug-draw: symbol
move-to-ground: symbol
hover-if-no-ground: symbol
idle-anim-script: pointer
idle-anim: int32
notice-anim: int32
hostile-anim: int32
hit-anim: int32
knocked-anim: int32
knocked-land-anim: int32
die-anim: int32
die-falling-anim: int32
victory-anim: int32
jump-wind-up-anim: int32
jump-in-air-anim: int32
jump-land-anim: int32
neck-joint: int32
look-at-joint: int32
bullseye-joint: int32
sound-hit: sound-name
sound-die: sound-name
notice-distance: meters
notice-distance-delta: meters
proximity-notice-distance: meters
default-hit-points: int32
gnd-collide-with: collide-spec
overlaps-others-collide-with-filter: collide-spec
penetrate-flinch: penetrate
penetrate-knocked: penetrate
movement-gravity: meters
friction: float
slip-factor: float
attack-shove-back: meters
attack-shove-up: meters
attack-mode: symbol
attack-damage: int32
recover-gnd-collide-with: collide-spec
jump-height-min: meters
jump-height-factor: float
knocked-seek-ry-clamp: float
knocked-soft-vxz-lo: float
knocked-soft-vxz-hi: float
knocked-soft-vy-lo: float
knocked-soft-vy-hi: float
knocked-medium-vxz-lo: float
knocked-medium-vxz-hi: float
knocked-medium-vy-lo: float
knocked-medium-vy-hi: float
knocked-hard-vxz-lo: float
knocked-hard-vxz-hi: float
knocked-hard-vy-lo: float
knocked-hard-vy-hi: float
knocked-huge-vxz-lo: float
knocked-huge-vxz-hi: float
knocked-huge-vy-lo: float
knocked-huge-vy-hi: float
knocked-yellow-vxz-lo: float
knocked-yellow-vxz-hi: float
knocked-yellow-vy-lo: float
knocked-yellow-vy-hi: float
knocked-red-vxz-lo: float
knocked-red-vxz-hi: float
knocked-red-vy-lo: float
knocked-red-vy-hi: float
knocked-blue-vxz-lo: float
knocked-blue-vxz-hi: float
knocked-blue-vy-lo: float
knocked-blue-vy-hi: float
shadow-size: meters
shadow-max-y: meters
shadow-min-y: meters
shadow-locus-dist: meters
gem-joint: int32
gem-seg: uint32
gem-no-seg: uint32
gem-offset: sphere
callback-info: nav-callback-info
use-momentum: symbol
use-frustration: symbol
use-stop-chase: symbol
use-circling: symbol
use-pacing: symbol
walk-anim: int32
turn-anim: int32
run-anim: int32
taunt-anim: int32
run-travel-speed: meters
run-acceleration: meters
run-turning-acceleration: meters
walk-travel-speed: meters
walk-acceleration: meters
walk-turning-acceleration: meters
maximum-rotation-rate: degrees
notice-nav-radius: meters
frustration-distance: meters
frustration-time: time-frame
blocked-time: time-frame
circle-dist-lo: float
circle-dist-hi: float
nav-mesh: nav-mesh
Methods
copy-nav-enemy-info!(obj: nav-enemy-info, obj-to-copy: nav-enemy-info) => nonesource

Copies the provided nav-enemy-info into the current object

source

Functions


nav-enemy-chase-post

nav-enemy-chase-post() => nonesource

nav-enemy-debug-control-post

nav-enemy-debug-control-post() => nonesource

nav-enemy-die-falling-post

nav-enemy-die-falling-post() => nonesource

nav-enemy-face-focus-post

nav-enemy-face-focus-post() => nonesource

nav-enemy-falling-post

nav-enemy-falling-post() => nonesource

nav-enemy-flee-post

nav-enemy-flee-post() => nonesource

nav-enemy-patrol-post

nav-enemy-patrol-post() => nonesource

nav-enemy-simple-post

nav-enemy-simple-post() => nonesource

nav-enemy-stare-post

nav-enemy-stare-post() => nonesource

nav-enemy-travel-post

nav-enemy-travel-post() => nonesource
nav-enemy-turn-to-face-dir(arg0: vector, arg1: float) => nonesource
nav-enemy-turn-to-face-point(arg0: vector, arg1: float) => nonesource

Variables


*nav-enemy-callback-info*: nav-callback-infosource
*nav-enemy-debug-control-info*: nav-enemy-debug-control-infosource
*nav-enemy-dummy-shadow-control*: shadow-controlsource
*nav-enemy-null-callback-info*: nav-callback-infosource
*nav-enemy-physics-callback-info*: nav-callback-infosource
source

Types


clamp-travel-vector-to-mesh-return-info

clamp-travel-vector-to-mesh-return-info: structuresource
Fields
found-boundary: symbol
intersection: vector
boundary-normal: vector
prev-normal: vector
next-normal: vector
poly: nav-poly
gap-poly: nav-poly
edge: int8
ignore: uint8
vert-prev: vector
vert-0: vector
vert-1: vector
vert-next: vector
nav-find-poly-parms: structuresource
Fields
point: vector
y-threshold: float
ignore: uint8
poly: nav-poly
dist: float
point-inside?: symbol
nav-mesh: basicsource
Fields
type: type
work: nav-mesh-work
poly-array: inline-array
static-sphere-count: uint8
poly-count: uint8
nav-control-count: uint8
max-nav-control-count: uint8
route: pointer
poly-hash: grid-hash
nav-control-array: inline-array
sphere-hash: sphere-hash
static-sphere: inline-array
user-list: engine
next-nav-mesh: surface
prev-nav-mesh: surface
bounds: vector
origin: vector
entity: entity
link-array: inline-array
link-count: uint8
flags: nav-mesh-flag
pad1: uint8
nearest-y-threshold: meters
water-max-height: meters
pad2: uint32
Methods
debug-draw(obj: nav-mesh) => nonesource
nav-mesh-method-10(obj: nav-mesh, arg0: vector, arg1: vector, arg2: nav-poly) => nav-polysource
poly-centroid(obj: nav-mesh, arg0: nav-poly, arg1: vector) => vectorsource
poly-centroid-local(obj: nav-mesh, arg0: nav-poly, arg1: vector) => vectorsource
lookup-poly-on-route-to-target(obj: nav-mesh, arg0: nav-poly, arg1: nav-poly) => nav-polysource
get-route-portal(obj: nav-mesh, arg0: nav-poly, arg1: nav-poly, arg2: nav-route-portal) => inline-arraysource
initialize-mesh!(obj: nav-mesh) => nonesource
move-along-nav-ray!(obj: nav-mesh, ray: nav-ray) => nonesource
try-move-along-ray(obj: nav-mesh, arg0: nav-poly, arg1: vector, arg2: vector, arg3: float) => meterssource
clamp-vector-to-mesh-cross-gaps(obj: nav-mesh, arg0: vector, arg1: nav-poly, arg2: vector, arg3: float, arg4: symbol, arg5: clamp-travel-vector-to-mesh-return-info) => nonesource
clamp-vector-to-mesh-no-gaps(obj: nav-mesh, arg0: vector, arg1: nav-poly, arg2: vector, arg3: clamp-travel-vector-to-mesh-return-info) => nonesource
set-normals-from-adjacent-bounds(obj: nav-mesh, arg0: clamp-travel-vector-to-mesh-return-info) => nonesource
find-adjacent-bounds-one(obj: nav-mesh, arg0: vector, arg1: nav-poly, arg2: int, arg3: int) => nonesource
compute-bounding-box-from-vertices(obj: nav-mesh, arg0: vector, arg1: vector) => nonesource
init-from-entity(obj: nav-mesh, arg0: entity-nav-mesh) => nonesource

Initialize this mesh from an entity.

handle-birth(obj: nav-mesh) => nonesource

Handle the parent nav-mesh-entity birth.

handle-kill(obj: nav-mesh) => nonesource

Handle the parent nav-mesh-entity kill.

update-navigation(obj: nav-mesh) => nonesource
new-nav-control(obj: nav-mesh, arg0: process-drawable) => nav-controlsource
remove-nav-control(obj: nav-mesh, arg0: nav-control) => nonesource
add-process-drawable-to-navmesh(obj: nav-mesh, arg0: process-drawable, arg1: symbol) => nonesource
remove-process-drawable(obj: nav-mesh, arg0: process-drawable) => nonesource
change-to(obj: nav-mesh, arg0: process-drawable) => nonesource
link-by-id(obj: nav-mesh, arg0: uint) => symbolsource

arg1 is a nav-mesh-link id

unlink-by-id(obj: nav-mesh, arg0: uint) => symbolsource

arg1 is a nav-mesh-link id

nav-mesh-method-34(obj: nav-mesh, arg0: vector, arg1: vector, arg2: float) => floatsource
nav-mesh-method-35(obj: nav-mesh, arg0: vector, arg1: vector, arg2: float) => floatsource
debug-draw-poly(obj: nav-mesh, arg0: nav-poly, arg1: rgba) => nonesource
point-in-poly?(obj: nav-mesh, arg0: nav-poly, arg1: vector) => symbolsource
nav-mesh-method-38(obj: nav-mesh, arg0: nav-poly, arg1: vector, arg2: vector, arg3: vector, arg4: pointer) => vectorsource
closest-point-on-boundary(obj: nav-mesh, arg0: nav-poly, arg1: vector, arg2: vector) => nonesource
project-point-onto-plane-of-poly-local(obj: nav-mesh, arg0: nav-poly, arg1: vector, arg2: vector, arg3: vector) => nonesource
project-point-into-poly-2d(obj: nav-mesh, arg0: nav-poly, arg1: vector, arg2: vector) => nonesource
find-poly-containing-point-local(obj: nav-mesh, arg0: nav-find-poly-parms) => nav-polysource
find-nearest-poly-to-point-local(obj: nav-mesh, arg0: nav-find-poly-parms) => nav-find-poly-parmssource
is-in-mesh-local?(obj: nav-mesh, arg0: vector, arg1: float, arg2: float) => symbolsource
link-to-other-mesh(obj: nav-mesh, arg0: nav-mesh-link) => symbolsource
unlink-mesh(obj: nav-mesh, arg0: nav-mesh-link) => nonesource
nav-mesh-link: structuresource
Fields
id: uint32
dest-mesh-id: uint32
src-link-poly-id: uint8
src-switch-poly-id: uint8
dest-link-poly-id: uint8
dest-switch-poly-id: uint8
dest-mesh: nav-mesh
nav-mesh-work: structuresource
Fields
vert0-table: int8
vert1-table: int8
edge-mask-table: uint8
pad0: uint32
deg-to-rad: float
rad-to-deg: float
nav-poly-min-dist: float
nav-poly-epsilon: float
sphere-array: sphere
debug: nav-mesh-work-debug
work-struct-in-scratch: int8
mesh-struct-in-scratch: int8
polys-in-scratch: int8
mesh: nav-mesh
nav: basic
poly0: nav-poly
poly1: nav-poly
poly-id: int32
nav-mesh-work-debug: structuresource
Fields
debug-vec1: vector
debug-vec2: vector
debug-vec3: vector
debug-vec4: vector
debug-vec5: vector
debug-vec6: vector
debug-vec7: vector
debug-vec8: vector
debug-vec9: vector
debug-vec10: vector
debug-vec11: vector
debug-vec12: vector
sphere-array: sphere
nav-poly: structuresource
Fields
data: uint8
vertex: vector
vertex0: vector
vertex1: vector
vertex2: vector
vertex3: vector
id: uint8
pat: uint8
vertex-count: uint8
link: uint8
adj-poly: uint8
adj-poly0: uint8
adj-poly1: uint8
adj-poly2: uint8
adj-poly3: uint8
min-y: float
max-y: float
nav-ray: structuresource
Fields
current-pos: vector
dir: vector
dest-pos: vector
current-poly: nav-poly
next-poly: nav-poly
len: meters
last-edge: int8
ignore: uint8
terminated: symbol
reached-dest: symbol
hit-boundary: symbol
hit-gap: symbol
nav-route-portal: structuresource
Fields
vertex: nav-vertex
next-poly: nav-poly
edge-index: int8
nav-sphere: structuresource
Fields
trans: sphere
nav-vertex: vectorsource
Fields
data: float
x: float
y: float
z: float
w: float
quad: uint128

Functions


debug-validate-current-poly

debug-validate-current-poly() => symbolsource

init-ray

init-ray(arg0: nav-ray) => nonesource
nav-sphere-from-cam() => nonesource

point-poly-intersection?

point-poly-intersection?(arg0: nav-mesh, arg1: vector, arg2: int, arg3: inline-array) => symbolsource

vector-normalize-unity!

vector-normalize-unity!(arg0: vector) => vectorsource

vector-normalize-unity-copy!

vector-normalize-unity-copy!(arg0: vector, arg1: vector) => vectorsource
source

Types


nav-engine: structuresource
Fields
spr-addr: uint32
nav-work-addr: uint32
nav-mesh-addr: nav-mesh
poly-array-addr: uint32
hash-sphere-addr: uint32
hash-buckets-addr: uint32
buf-nav-control-count: int8
max-pass-count: int8
output-sphere-hash: uint8
work-buf-array: nav-engine-spr-buffer
spr-work: nav-mesh-work
mem-work: nav-mesh-work
spr-mesh: nav-mesh
mem-mesh: nav-mesh
spr-poly-array: uint32
mem-poly-array: inline-array
hash-sphere-list: uint32
hash-buckets: uint32
to-spr-wait: uint32
from-spr-wait: uint32
Methods
inc-spr-addr!(obj: nav-engine, arg0: uint) => uintsource

Adds the given integer to spr-addr and returns it

lay-out-spad-memory(obj: nav-engine, arg0: nav-mesh) => nonesource
set-up-mem-work(obj: nav-engine) => nonesource
add-spheres-from-mesh-user-list(obj: nav-engine, arg0: sphere-hash, arg1: nav-mesh) => nonesource
add-all-spheres(obj: nav-engine) => nonesource
do-sphere-lookups(obj: nav-engine) => nonesource
update-nav-controls-pipelined-in-spr(obj: nav-engine) => nonesource
update-nav-controls-in-spr(obj: nav-engine) => nonesource
upload-nav-to-spr: unknown
download-nav-from-spr: unknown
do-callbacks(obj: nav-engine, arg0: nav-engine-spr-buffer) => nonesource
reloc-ptrs-to-spad: unknown
reloc-ptrs-to-mem: unknown
nav-engine-spr-buffer: structuresource
Fields
mem-addr: pointer
mem-nav: uint32
spr-addr: inline-array
spr-nav: uint32
q-size: uint32
i-nav: uint8
done: int8
nav-count: int8
i-pass: int8

Functions


connection-list-validate

connection-list-validate(arg0: inline-array) => symbolsource

connection-validate

connection-validate(arg0: connection) => nonesource

debug-validate-nav-poly

debug-validate-nav-poly(arg0: nav-mesh-link, arg1: nav-poly) => nonesource

find-nearest-nav-mesh

find-nearest-nav-mesh(arg0: vector, arg1: float) => nav-meshsource

get-nav-mesh

get-nav-mesh(arg0: actor-id) => nav-meshsource

inc-mod3

inc-mod3(arg0: int) => intsource

Increments and returns the provided [[int]], if the value exceeds 2, wrap back to 0

init-ray-dir-local

init-ray-dir-local(arg0: nav-ray, arg1: nav-poly, arg2: vector, arg3: vector, arg4: float) => nonesource

init-ray-local

init-ray-local(arg0: nav-ray, arg1: nav-poly, arg2: vector, arg3: vector) => nonesource
nav-control-validate(arg0: process-drawable) => nonesource
nav-mesh-connect-from-ent(arg0: process-drawable) => symbolsource

Connect this process to the nav-mesh associate with the entity that spawned the process

nav-mesh-route-table-bit-index(arg0: nav-mesh, arg1: uint, arg2: int) => intsource
nav-normal-from-3-points(arg0: vector, arg1: vector, arg2: vector, arg3: vector) => nonesource
nav-ray-test(arg0: nav-mesh, arg1: nav-poly, arg2: vector, arg3: vector) => meterssource

plane-height-at-xz-point

plane-height-at-xz-point(arg0: plane, arg1: vector) => floatsource

point-poly-distance-min

point-poly-distance-min(arg0: nav-mesh-work, arg1: nav-poly, arg2: float, arg3: nav-poly) => floatsource

point-to-poly-boundary

point-to-poly-boundary(arg0: nav-poly, arg1: vector, arg2: vector) => floatsource

poly-in-height-range?

poly-in-height-range?(arg0: nav-poly, arg1: float, arg2: float) => symbolsource

ray-ccw-line-segment-intersection?

ray-ccw-line-segment-intersection?(arg0: vector, arg1: vector, arg2: vector, arg3: vector) => symbolsource

ray-line-segment-intersection?

ray-line-segment-intersection?(arg0: vector, arg1: vector, arg2: vector, arg3: vector) => symbolsource

vu-point-triangle-intersection?

vu-point-triangle-intersection?(arg0: vector, arg1: vector, arg2: vector, arg3: vector) => symbolsource

Variables


*debug-nav-control-output*

*debug-nav-control-output*: symbolsource

*debug-nav-control*

*debug-nav-control*: symbolsource

*debug-nav-mesh-output*

*debug-nav-mesh-output*: symbolsource

*debug-nav-ray*

*debug-nav-ray*: nav-raysource

*debug-offset*

*debug-offset*: vectorsource

*debug-ray-offset*

*debug-ray-offset*: vectorsource

*default-nav-mesh*

*default-nav-mesh*: nav-meshsource
*nav-mesh-work*: nav-mesh-worksource