Types
collide-cache: basicsource
Fields
type: type
num-tris: int32
num-prims: int32
num-prims-u: uint32
ignore-mask: pat-surface
proc: process-drawable
collide-box: bounding-box
collide-box4w: bounding-box4w
collide-with: collide-kind
prims: collide-cache-prim
tris: collide-cache-tri
Methods
debug-draw(obj: collide-cache) => nonesource
Debug draw all the things in the collide cache!
fill-and-probe-using-line-sphere(obj: collide-cache, arg0: vector, arg1: vector, arg2: float, arg3: collide-kind, arg4: process, arg5: collide-tri-result, arg6: pat-surface) => floatsource
fill-and-probe-using-spheres(obj: collide-cache, arg0: collide-using-spheres-params) => symbolsource
fill-and-probe-using-y-probe(obj: collide-cache, arg0: vector, arg1: float, arg2: collide-kind, arg3: process-drawable, arg4: collide-tri-result, arg5: pat-surface) => floatsource
fill-using-bounding-box(obj: collide-cache, arg0: bounding-box, arg1: collide-kind, arg2: process-drawable, arg3: pat-surface) => nonesource
fill-using-line-sphere(obj: collide-cache, arg0: vector, arg1: vector, arg2: float, arg3: collide-kind, arg4: process-drawable, arg5: pat-surface) => nonesource
fill-using-spheres(obj: collide-cache, arg0: collide-using-spheres-params) => nonesource
fill-using-y-probe(obj: collide-cache, arg0: vector, arg1: float, arg2: collide-kind, arg3: process-drawable, arg4: pat-surface) => nonesource
initialize(obj: collide-cache) => nonesource
Clear the collide-cache.
probe-using-line-sphere(obj: collide-cache, arg0: vector, arg1: vector, arg2: float, arg3: collide-kind, arg4: collide-tri-result, arg5: pat-surface) => floatsource
probe-using-spheres(obj: collide-cache, arg0: collide-using-spheres-params) => symbolsource
probe-using-y-probe(obj: collide-cache, arg0: vector, arg1: float, arg2: collide-kind, arg3: collide-tri-result, arg4: pat-surface) => floatsource
fill-from-background(obj: collide-cache, bsp-find-mesh-func: function, import-mesh-func: function) => nonesource
This terrible function fills the collide cache with background tris from a bounding box.
fill-from-foreground-using-box(obj: collide-cache) => nonesource
fill-from-foreground-using-line-sphere(obj: collide-cache) => nonesource
fill-from-foreground-using-y-probe(obj: collide-cache) => nonesource
fill-from-water(obj: collide-cache, arg0: water-control) => nonesource
load-mesh-from-spad-in-box: unknown
collide-cache-method-27: unknown
collide-cache-method-28: unknown
collide-cache-method-29: unknown
puyp-mesh: unknown
puyp-sphere(obj: collide-cache, arg0: collide-puyp-work, arg1: collide-cache-prim) => vectorsource
unpack-background-collide-mesh: unknown
collide-cache-prim: structuresource
Fields
prim-core: collide-prim-core
extra-quad: uint128
ccache: collide-cache
prim: collide-shape-prim
first-tri: uint16
num-tris: uint16
unused: uint8
world-sphere: vector
collide-as: collide-kind
action: collide-action
offense: collide-offense
prim-type: int8
Methods
resolve-moving-sphere-tri: unknown
resolve-moving-sphere-sphere: unknown
collide-cache-tri: structuresource
Fields
vertex: vector
extra-quad: uint128
pat: pat-surface
prim-index: uint16
user16: uint16
user32: uint32
collide-list: structuresource
collide-list-item: structuresource
collide-puss-sphere: structuresource
collide-puss-work: structuresource
Fields
closest-pt: vector
tri-normal: vector
tri-bbox4w: bounding-box4w
spheres-bbox4w: bounding-box4w
spheres: collide-puss-sphere
Methods
collide-puss-work-method-9: unknown
collide-puss-work-method-10: unknown
collide-puyp-work: structuresource
Fields
best-u: float
ignore-pat: pat-surface
tri-out: collide-tri-result
start-pos: vector
move-dist: vector
collide-using-spheres-params: structuresource
Fields
spheres: inline-array
num-spheres: uint32
collide-with: collide-kind
proc: process-drawable
ignore-pat: pat-surface
solid-only: basic
collide-work: structuresource
Variables
BIG_COLLIDE_CACHE_SIZE: unknownsource
Types
collide-puls-work: structuresource
pc-fffuls-work: structuresource
Functions
collide-cache-using-box-test(arg0: vector) => symbolsource
collide-cache-using-line-sphere-test(arg0: vector) => symbolsource
Check if the input sphere is in the rotated bounding box volume of the current
line-sphere query.
collide-cache-using-y-probe-test(arg0: vector) => symbolsource
make-collide-list-using-line-sphere-inst-test(arg0: collide-fragment, arg1: instance-tie) => symbolsource
Check if a collide-fragment at a given instance is in the rotated bounding box volume
of the current line-sphere query.
Variables
Types
collide-edge-edge: structuresource
Fields
ignore: basic
etri: collide-edge-tri
vertex-ptr: inline-array
outward: vector
edge-vec-norm: vector
collide-edge-hold-item: structuresource
Fields
next: collide-edge-hold-item
rating: float
split: int8
edge: collide-edge-edge
center-pt: vector
outward-pt: vector
collide-edge-hold-list: structuresource
Fields
num-allocs: uint32
num-attempts: uint32
head: collide-edge-hold-item
items: collide-edge-hold-item
attempts: qword
Methods
debug-draw(obj: collide-edge-hold-list) => objectsource
add-to-list!: unknown
collide-edge-tri: structuresource
collide-edge-work: structuresource
Fields
ccache: collide-cache
cshape: collide-shape
num-verts: uint32
num-edges: uint32
num-tris: uint32
cache-fill-box: bounding-box
within-reach-box: bounding-box
within-reach-box4w: bounding-box4w
search-pt: vector
search-dir-vec: vector
max-dist-sqrd-to-outward-pt: float
max-dir-cosa-delta: float
split-dists: float
outward-offset: vector
local-cache-fill-box: bounding-box
local-within-reach-box: bounding-box
local-player-spheres: sphere
world-player-spheres: sphere
local-player-hanging-spheres: sphere
world-player-hanging-spheres: sphere
local-player-leap-up-spheres: sphere
world-player-leap-up-spheres: sphere
verts: vector
edges: collide-edge-edge
tris: collide-edge-tri
hold-list: collide-edge-hold-list
Methods
search-for-edges(obj: collide-edge-work, arg0: collide-edge-hold-list) => symbolsource
Iterate through edges, adding them to the collide-edge-hold-list, if they are good
debug-draw-edges(obj: collide-edge-work) => objectsource
debug-draw-tris(obj: collide-edge-work) => nonesource
debug-draw-sphere(obj: collide-edge-work) => symbolsource
compute-center-point!(obj: collide-edge-work, arg0: collide-edge-edge, arg1: vector) => floatsource
collide-edge-work-method-14(obj: collide-edge-work, arg0: vector, arg1: vector, arg2: int) => floatsource
find-grabbable-edges!: unknown
find-grabbable-tris!: unknown
should-add-to-list?(obj: collide-edge-work, arg0: collide-edge-hold-item, arg1: collide-edge-edge) => symbolsource
find-best-grab!: unknown
check-grab-for-collisions(obj: collide-edge-work, arg0: collide-edge-hold-item, arg1: edge-grab-info) => symbolsource
edge-grab-info: structuresource
Fields
world-vertex: vector
local-vertex: vector
actor-cshape-prim-offset: int32
actor-handle: handle
hanging-matrix: matrix
edge-vertex: vector
center-hold: vector
tri-vertex: vector
left-hand-hold: vector
right-hand-hold: vector
center-hold-old: vector
edge-tri-pat: uint32
Methods
edge-grab-info-method-9(obj: edge-grab-info) => symbolsource
debug-draw(obj: edge-grab-info) => symbolsource
Variables
Types
pbhp-stack-vars: structuresource
Variables
Types
collide-frag-mesh: basicsource
collide-fragment: drawablesource
drawable-inline-array-collide-fragment: drawable-inline-arraysource
drawable-tree-collide-fragment: drawable-treesource
Fields
type: type
id: int16
bsphere: vector
length: int16
data: drawable
data-override: drawable-inline-array
Functions
moving-sphere-sphere-intersect(arg0: vector, arg1: vector, arg2: vector, arg3: vector) => floatsource
pc-port-raw-ray-sphere-implementation(rad: float, vf1-val: vector, vf2-val: vector) => floatsource
This is one of the main primitives for collision.
Assumes a sphere of radius rad is at the origin.
Handles:
- miss (return MISS)
- behind (return MISS)
- too far away (return MISS)
- inside (return 0)
raw-ray-sphere-intersect(arg0: float) => floatsource
DANGER: this function takes two arguments by vf registers.
As a result, it doesn't work properly in OpenGOAL. See the functions below.
ray-circle-intersect(ray-origin: vector, ray-dir: vector, circle-origin: vector, radius: float) => floatsource
Intersect ray with circle. Circle is on the y plane and this throws out the y components
of ray-origin, circle-origin, and ray-dir
ray-cylinder-intersect(ray-origin: vector, ray-dir: vector, cyl-origin: vector, cyl-axis: vector, cyl-rad: float, cyl-len: float, pt-out: vector) => floatsource
Intersect with a cylinder.
Currently this is untested.
ray-plane-intersect(arg0: vector, arg1: vector, arg2: vector, arg3: vector, arg4: vector, arg5: vector, arg6: vector) => floatsource
Unused.
ray-sphere-intersect(ray-origin: vector, ray-dir: vector, sph-origin: vector, radius: float) => floatsource
Intersect a ray and sphere. Will return 0 if you are in the sphere, -huge number if you don't hit it.
Returns the length of the ray to the first intersection.
Variables
COLLISION_MISS: unknownsource
Variables
*collide-test-flag*: symbolsource
Types
collide-mesh: basicsource
Fields
type: type
joint-id: int32
num-tris: uint32
num-verts: uint32
vertex-data: inline-array
tris: collide-mesh-tri
Methods
debug-draw-tris(obj: collide-mesh, arg0: process-drawable, arg1: int) => nonesource
Draw a collide-mesh.
overlap-test(obj: collide-mesh, arg0: collide-mesh-cache-tri, arg1: vector) => symbolsource
should-push-away-test: unknown
sphere-on-platform-test: unknown
populate-cache!(obj: collide-mesh, arg0: collide-mesh-cache-tri, arg1: matrix) => nonesource
collide-mesh-math-1: unknown
collide-mesh-math-2: unknown
collide-mesh-cache: basicsource
Fields
type: type
used-size: uint32
max-size: uint32
id: uint64
data: uint8
Methods
allocate!(obj: collide-mesh-cache, arg0: int) => intsource
is-id?(obj: collide-mesh-cache, arg0: int) => symbolsource
Is this our id?
next-id!(obj: collide-mesh-cache) => uintsource
Reset all used entries in the cache and increment the id.
If the id is zero, set it to 1
collide-mesh-cache-tri: structuresource
collide-mesh-tri: structuresource
collide-tri-result: structuresource
Variables
COLLIDE_MESH_CACHE_SIZE: unknownsource
Types
sopt-work: structuresource
spat-work: structuresource
Types
collide-probe-stack: structuresource
Fields
data: collide-probe-stack-elem
Functions
collide-probe-collide-fragment-tree-make-list(arg0: drawable-tree-collide-fragment, arg1: collide-list) => nonesource
Given a collide fragment tree, make a list.
Note: you must have more than 8 collide fragments, so you have more than 1 level in the tree.
collide-probe-instance-tie-tree-make-list(arg0: drawable-tree-instance-tie, arg1: collide-list) => intsource
Given a TIE instance tree, make a list.
Unlike tfrag, they explicitly support the < 8 node case
collide-probe-make-list(arg0: level, arg1: collide-list) => nonesource
Run the probe algorithm on an entire level.
collide-upload-vu0() => nonesource
Upload the probe program to VU0.
creates-new-method?(arg0: type, arg1: int) => symbolsource
Is the method with the given ID in the given type a new method for this type?
describe-methods(arg0: type) => symbolsource
Print information about the methods of a type.
interpolate(arg0: float, arg1: float, arg2: float, arg3: float, arg4: float) => floatsource
misty-ambush-height(arg0: vector) => floatsource
misty-ambush-height-probe(arg0: vector, arg1: float) => floatsource
Hack to manually compute the ground height in misty ambush.
overrides-parent-method?(arg0: type, arg1: int) => symbolsource
Does the method with the given ID in the given type override a method of its parent?
pke-collide-test() => nonesource
probe-traverse-collide-fragment(arg0: drawable-tree-collide-fragment, arg1: int) => nonesource
Print out all levels of a drawabl-tree-collide-fragment.
probe-traverse-draw-node(arg0: draw-node, arg1: int) => nonesource
Print out info for a draw node, and recursively its children. They forgot to finish this one.
probe-traverse-inline-array-node(arg0: drawable-inline-array-node, arg1: int) => nonesource
Print out a drawable-inline-array-node, and recursively all children
Variables
const collide-vu0-block: vu-functionsource
Types
collide-overlap-result: structuresource
Fields
best-dist: float
best-from-prim: collide-shape-prim
best-to-prim: collide-shape-prim
best-from-tri: collide-tri-result
Methods
reset!(obj: collide-overlap-result) => nonesource
Reset the result.