documentation: core2/ba/physics

This commit is contained in:
Banjo Kazooie
2024-06-16 22:36:36 -05:00
parent 8fe5c3b4d1
commit 092de6aae3
208 changed files with 2342 additions and 2163 deletions

View File

@@ -4,6 +4,7 @@
#include "bsint.h"
#include "core2/statetimer.h"
#include "core2/ba/anim.h"
#include "core2/ba/physics.h"
/* .data */
const f32 D_80364AF0 = 30.0f;
@@ -14,9 +15,9 @@ const f32 D_80364AFC = 0.4f;
void func_802AAE80(void){
f32 sp1C = func_8029B30C();
if(func_8029B300() == 0)
func_80297970(0.0f);
baphysics_set_target_horizontal_velocity(0.0f);
else
func_80297970(ml_interpolate_f(sp1C, D_80364AF0, D_80364AF4));
baphysics_set_target_horizontal_velocity(ml_interpolate_f(sp1C, D_80364AF0, D_80364AF4));
}
void func_802AAEE0(void){
@@ -34,8 +35,8 @@ void bscarry_idle_init(void){
animctrl_setIndex(aCtrl, ASSET_72_ANIM_BSCARRY_IDLE);
animctrl_setDuration(aCtrl, 1.2f);
animctrl_start(aCtrl, "bscarry.c", 0x6f);
func_8029C7F4(1,1,1,2);
func_80297970(0.0f);
func_8029C7F4(1,1,1, BA_PHYSICS_NORMAL);
baphysics_set_target_horizontal_velocity(0.0f);
pitch_setAngVel(1000.0f, 12.0f);
roll_setAngularVelocity(1000.0f, 12.0f);
}
@@ -63,7 +64,7 @@ void bscarry_walk_init(void){
animctrl_setDuration(aCtrl, 0.8f);
animctrl_setPlaybackType(aCtrl, ANIMCTRL_LOOP);
animctrl_start(aCtrl, "bscarry.c", 0xac);
func_8029C7F4(2,1,1,2);
func_8029C7F4(2,1,1, BA_PHYSICS_NORMAL);
baanim_setVelocityMapRanges(D_80364AF0, D_80364AF4, D_80364AF8, D_80364AFC);
}
@@ -72,7 +73,7 @@ void bscarry_walk_update(void){
func_8029AD28(0.4f, 4);
func_8029AD28(0.9f, 3);
func_802AAE80();
if(func_8029B300() == 0 && func_80297C04(1.0f))
if(func_8029B300() == 0 && baphysics_is_slower_than(1.0f))
sp1C = BS_3A_CARRY_IDLE;
if(carriedobj_getMarker() == NULL)