Data Structures | |
struct | HitFile |
struct | ColliderBackupEntry |
struct | HitFileHeader |
struct | HitAssetCollider |
Functions | |
s32 | collision_heap_create (void) |
void * | collision_heap_malloc (s32 size) |
void | collision_heap_free (void *) |
void | load_hit_data (s32 idx, HitFile *hit) |
void | _add_hit_vert_to_buffer (Vec3f **buf, Vec3f *vert, s32 *bufSize) |
s32 | _get_hit_vert_index_from_buffer (Vec3f **buffer, Vec3f *vert, s32 *bufferSize) |
void | backup_map_collision_data (void) |
void | func_8005AF84 (void) |
void | func_8005AF8C (void) |
void | initialize_collision (void) |
void | load_map_hit_asset (void) |
void | restore_map_collision_data (void) |
void | load_battle_hit_asset (const char *hitName) |
void | parent_collider_to_model (s16 colliderID, s16 modelIndex) |
void | update_collider_transform (s16 colliderID) |
s32 | get_collider_flags (s32 colliderID) |
void | get_flat_collider_normal (s32 colliderID, f32 *x, f32 *y, f32 *z) |
void | get_collider_center (s32 colliderID, f32 *x, f32 *y, f32 *z) |
s32 | test_ray_triangle_general (ColliderTriangle *triangle, Vec3f *vertices) |
s32 | test_ray_triangle_down (ColliderTriangle *triangle, Vec3f *vertices) |
s32 | test_ray_triangle_horizontal (ColliderTriangle *triangle, Vec3f *vertices) |
s32 | test_ray_colliders (s32 ignoreFlags, f32 startX, f32 startY, f32 startZ, f32 dirX, f32 dirY, f32 dirZ, f32 *hitX, f32 *hitY, f32 *hitZ, f32 *hitDepth, f32 *hitNx, f32 *hitNy, f32 *hitNz) |
s32 | test_ray_zones (f32 startX, f32 startY, f32 startZ, f32 dirX, f32 dirY, f32 dirZ, f32 *hitX, f32 *hitY, f32 *hitZ, f32 *hitDepth, f32 *hitNx, f32 *hitNy, f32 *hitNz) |
f32 | test_ray_collider_horizontal (s32 ignoreFlags, s32 colliderID, f32 x, f32 y, f32 z, f32 length, f32 yaw) |
s32 | test_ray_entities (f32 startX, f32 startY, f32 startZ, f32 dirX, f32 dirY, f32 dirZ, f32 *hitX, f32 *hitY, f32 *hitZ, f32 *hitDepth, f32 *hitNx, f32 *hitNy, f32 *hitNz) |
Test a general ray from a given starting position and direction against all entities. | |
struct HitFileHeader |
struct HitAssetCollider |
Referenced by parent_collider_to_model().
Referenced by parent_collider_to_model().
void backup_map_collision_data | ( | void | ) |
Referenced by state_step_battle(), state_step_language_select(), and state_step_pause().
s32 collision_heap_create | ( | void | ) |
Referenced by initialize_collision().
void collision_heap_free | ( | void * | data | ) |
Referenced by parent_collider_to_model().
void * collision_heap_malloc | ( | s32 | size | ) |
Referenced by load_hit_data(), and parent_collider_to_model().
void func_8005AF84 | ( | void | ) |
Referenced by state_step_end_battle(), state_step_exit_language_select(), and state_step_unpause().
void func_8005AF8C | ( | void | ) |
void get_collider_center | ( | s32 | colliderID, |
f32 * | x, | ||
f32 * | y, | ||
f32 * | z ) |
s32 get_collider_flags | ( | s32 | colliderID | ) |
Referenced by action_update_hit_fire(), action_update_knockback(), action_update_sliding(), action_update_spin_jump(), action_update_step_down(), action_update_tornado_jump(), can_dismount(), check_input_jump(), func_80262130(), handle_floor_behavior(), partner_get_out(), partner_walking_follow_player(), phys_adjust_cam_on_landing(), phys_main_collision_below(), player_handle_floor_collider_type(), spawn_surface_effects(), try_player_footstep_sounds(), update_current_floor(), update_riding_physics(), and update_riding_physics().
void get_flat_collider_normal | ( | s32 | colliderID, |
f32 * | x, | ||
f32 * | y, | ||
f32 * | z ) |
void initialize_collision | ( | void | ) |
void load_battle_hit_asset | ( | const char * | hitName | ) |
Referenced by btl_state_update_normal_start().
void load_hit_data | ( | s32 | idx, |
HitFile * | hit ) |
Referenced by load_battle_hit_asset(), and load_map_hit_asset().
void load_map_hit_asset | ( | void | ) |
Referenced by load_map_by_IDs(), and restore_map_collision_data().
void parent_collider_to_model | ( | s16 | colliderID, |
s16 | modelIndex ) |
Referenced by restore_map_collision_data().
void restore_map_collision_data | ( | void | ) |
Referenced by state_step_end_battle(), state_step_exit_language_select(), and state_step_unpause().
f32 test_ray_collider_horizontal | ( | s32 | ignoreFlags, |
s32 | colliderID, | ||
f32 | x, | ||
f32 | y, | ||
f32 | z, | ||
f32 | length, | ||
f32 | yaw ) |
s32 test_ray_colliders | ( | s32 | ignoreFlags, |
f32 | startX, | ||
f32 | startY, | ||
f32 | startZ, | ||
f32 | dirX, | ||
f32 | dirY, | ||
f32 | dirZ, | ||
f32 * | hitX, | ||
f32 * | hitY, | ||
f32 * | hitZ, | ||
f32 * | hitDepth, | ||
f32 * | hitNx, | ||
f32 * | hitNy, | ||
f32 * | hitNz ) |
s32 test_ray_entities | ( | f32 | startX, |
f32 | startY, | ||
f32 | startZ, | ||
f32 | dirX, | ||
f32 | dirY, | ||
f32 | dirZ, | ||
f32 * | hitX, | ||
f32 * | hitY, | ||
f32 * | hitZ, | ||
f32 * | hitDepth, | ||
f32 * | hitNx, | ||
f32 * | hitNy, | ||
f32 * | hitNz ) |
Test a general ray from a given starting position and direction against all entities.
If one is hit, returns the position and normal of the hit and the length along the ray on the output params. All output params are invalid when a value of NO_COLLIDER
is returned.
startX | origin x position of the ray | |
startY | origin y position of the ray | |
startZ | origin z position of the ray | |
dirX | normalized x direction of the ray | |
dirY | normalized y direction of the ray | |
dirZ | normalized z direction of the ray | |
[out] | hitX | normalized x position of the hit |
[out] | hitY | normalized y position of the hit |
[out] | hitZ | normalized z position of the hit |
[in,out] | hitDepth | as input, maximum length of the ray; as output, distance along the ray of the hit |
[out] | hitNx | x normal direction of the hit |
[out] | hitNy | y normal direction of the hit |
[out] | hitNz | z normal direction of the hit |
NO_COLLIDER
is none is hit Referenced by entity_raycast_down(), npc_raycast_down(), npc_raycast_general(), npc_raycast_up(), npc_raycast_up_corner(), player_raycast_down(), player_raycast_general(), and player_raycast_up_corner().
s32 test_ray_triangle_down | ( | ColliderTriangle * | triangle, |
Vec3f * | vertices ) |
Referenced by test_ray_colliders(), and test_ray_zones().
s32 test_ray_triangle_general | ( | ColliderTriangle * | triangle, |
Vec3f * | vertices ) |
Referenced by test_ray_colliders(), and test_ray_entities().
s32 test_ray_triangle_horizontal | ( | ColliderTriangle * | triangle, |
Vec3f * | vertices ) |
Referenced by test_ray_collider_horizontal(), and test_ray_colliders().
s32 test_ray_zones | ( | f32 | startX, |
f32 | startY, | ||
f32 | startZ, | ||
f32 | dirX, | ||
f32 | dirY, | ||
f32 | dirZ, | ||
f32 * | hitX, | ||
f32 * | hitY, | ||
f32 * | hitZ, | ||
f32 * | hitDepth, | ||
f32 * | hitNx, | ||
f32 * | hitNy, | ||
f32 * | hitNz ) |
Referenced by test_ray_zone(), and test_ray_zone_aabb().
void update_collider_transform | ( | s16 | colliderID | ) |
Referenced by restore_map_collision_data().
CollisionData gCollisionData |
Referenced by backup_map_collision_data(), get_collider_center(), get_collider_flags(), get_flat_collider_normal(), initialize_collision(), load_battle_hit_asset(), load_hit_data(), modify_collider_family_flags(), parent_collider_to_model(), restore_map_collision_data(), test_ray_collider_horizontal(), test_ray_colliders(), and update_collider_transform().
BSS ColliderBackupEntry* gCollisionDataBackup |
Referenced by backup_map_collision_data(), and restore_map_collision_data().
BSS ColliderBackupEntry* gCollisionDataZoneBackup |
Referenced by backup_map_collision_data(), and restore_map_collision_data().
BSS f32 gCollisionNormalX |
BSS f32 gCollisionNormalY |
BSS f32 gCollisionNormalZ |
BSS f32 gCollisionPointX |
BSS f32 gCollisionPointY |
BSS f32 gCollisionPointZ |
BSS f32 gCollisionRayDirX |
BSS f32 gCollisionRayDirY |
BSS f32 gCollisionRayDirZ |
BSS f32 gCollisionRayLength |
BSS f32 gCollisionRayStartX |
BSS f32 gCollisionRayStartY |
BSS f32 gCollisionRayStartZ |
|
extern |
Referenced by test_ray_entities().
|
extern |
Referenced by test_ray_entities().
CollisionData gZoneCollisionData |