misc documentation
This commit is contained in:
@@ -306,7 +306,7 @@ void func_80389080(Actor *this){
|
||||
func_80335924(this->unk148, ASSET_12B_ANIM_TIPTUP_IDLE, 1.0f, 9.0f);
|
||||
unqPtr->unkC = randf2(5.0f, 15.0f);
|
||||
}
|
||||
if(func_8025773C(&unqPtr->unkC, sp3C)){
|
||||
if(ml_timer_update(&unqPtr->unkC, sp3C)){
|
||||
func_80335924(this->unk148, ASSET_12C_ANIM_TIPTUP_TAPPING, 1.0f, 4.0f);
|
||||
}
|
||||
func_80258A4C(this->position, this->yaw - 90.0f, player_position, &sp38, &sp34, &sp30);
|
||||
@@ -319,7 +319,7 @@ void func_80389080(Actor *this){
|
||||
}
|
||||
}
|
||||
else{
|
||||
if(ml_vec3f_distance(this->position, player_position) < 300.0f && player_getTransformation() == TRANSFORM_1_BANJO && !jiggyscore_isSpawned(JIGGY_27_BGS_TIPTUP)){
|
||||
if(ml_distance_vec3f(this->position, player_position) < 300.0f && player_getTransformation() == TRANSFORM_1_BANJO && !jiggyscore_isSpawned(JIGGY_27_BGS_TIPTUP)){
|
||||
BGS_func_803888E4(this, 2);
|
||||
}
|
||||
}
|
||||
@@ -333,12 +333,12 @@ void func_80389080(Actor *this){
|
||||
}
|
||||
} //L80389370
|
||||
else{
|
||||
if(ml_vec3f_distance(this->position, player_position) >= 300.0f)
|
||||
if(ml_distance_vec3f(this->position, player_position) >= 300.0f)
|
||||
BGS_func_803888E4(this, 1);
|
||||
}
|
||||
}//L803893A0
|
||||
if(this->state == 6){
|
||||
if(ml_vec3f_distance(this->position, player_position) < 300.0f && !unqPtr->unk8){
|
||||
if(ml_distance_vec3f(this->position, player_position) < 300.0f && !unqPtr->unk8){
|
||||
unqPtr->unk8 = 1;
|
||||
func_80311480(0xc7d, 4, 0, 0, 0, 0);
|
||||
}
|
||||
|
@@ -343,7 +343,7 @@ void chflibbit_update(Actor *this){
|
||||
spB0[2] = player_position[2] - this->position[2];
|
||||
player_distance = gu_sqrtf(spB0[0]*spB0[0] + spB0[1]*spB0[1] + spB0[2]*spB0[2]);
|
||||
|
||||
if(func_8025773C(&local->unk24, spA4)){
|
||||
if(ml_timer_update(&local->unk24, spA4)){
|
||||
func_8030E878(0x3f0, randf2(0.9f, 1.1f), randi2(12000, 19000), this->position, 500.0f, 2500.0f);
|
||||
local->unk24 = randf2(1.0f, 6.0f);
|
||||
}//L80387274
|
||||
@@ -375,7 +375,7 @@ void chflibbit_update(Actor *this){
|
||||
sp84[0] = (f32)local->unkE[0];
|
||||
sp84[1] = (f32)local->unkE[1];
|
||||
sp84[2] = (f32)local->unkE[2];
|
||||
if(ml_vec3f_distance(this->position, sp84) < 30.0f){
|
||||
if(ml_distance_vec3f(this->position, sp84) < 30.0f){
|
||||
func_80386AEC(this, 1);
|
||||
}
|
||||
else{
|
||||
@@ -421,7 +421,7 @@ void chflibbit_update(Actor *this){
|
||||
|
||||
|
||||
if(this->state == 4 || this->state == 5){
|
||||
if(func_8025773C(&local->unk18, spA4)){
|
||||
if(ml_timer_update(&local->unk18, spA4)){
|
||||
func_80386AEC(this, 3);
|
||||
}
|
||||
}
|
||||
|
@@ -156,7 +156,7 @@ void func_8038BDD4(Actor *this) {
|
||||
start_position[0] = this->position[0];
|
||||
start_position[1] = this->position[1];
|
||||
start_position[2] = this->position[2];
|
||||
func_8025773C(&local->unk14, sp5C);
|
||||
ml_timer_update(&local->unk14, sp5C);
|
||||
if ((local->unkC == 102) || (local->unkC == 103) || (local->unkC == 104)) {
|
||||
sp44[0] = 0.0f;
|
||||
sp44[1] = 0.0f;
|
||||
@@ -262,7 +262,7 @@ bool func_8038C2A8(ActorMarker *marker) {
|
||||
local = (ActorLocal_MrVile *)&this->local;
|
||||
player_getPosition(player_position);
|
||||
if (this->state == 6) {
|
||||
return ml_vec3f_distance(this->position, player_position) < 150.0f;
|
||||
return ml_distance_vec3f(this->position, player_position) < 150.0f;
|
||||
}
|
||||
return local->unk0 == 1;
|
||||
}
|
||||
@@ -353,7 +353,7 @@ void chvile_update(Actor *this) {
|
||||
local->game_marker = actorArray_findClosestActorFromActorId(this->position, 0x138, -1, &sp90)->marker;
|
||||
}
|
||||
player_getPosition(player_position);
|
||||
sp90 = ml_vec3f_distance(this->position, player_position);
|
||||
sp90 = ml_distance_vec3f(this->position, player_position);
|
||||
if (sp90 <= 300.0f) {
|
||||
local->unk0 = (local->unk0 == 0) ? 1 : 2;
|
||||
} else if (sp90 > 300.0f) {
|
||||
@@ -413,7 +413,7 @@ void chvile_update(Actor *this) {
|
||||
if (this->state == 4) {
|
||||
player_getPosition(local->target_position);
|
||||
local->unk10 = 500.0f;
|
||||
if ((local->unkC == 102) && (ml_vec3f_distance(this->position, local->target_position) < 200.0f)) {
|
||||
if ((local->unkC == 102) && (ml_distance_vec3f(this->position, local->target_position) < 200.0f)) {
|
||||
BGS_func_8038BBA0(this, 103);
|
||||
}
|
||||
if ((local->unkC == 103) && (func_80335794(this->unk148) >= 2)) {
|
||||
@@ -422,7 +422,7 @@ void chvile_update(Actor *this) {
|
||||
}
|
||||
if (this->state == 5) {
|
||||
local->unk10 = 200.0f;
|
||||
if (ml_vec3f_distance(this->position, local->target_position) < 100.0f) {
|
||||
if (ml_distance_vec3f(this->position, local->target_position) < 100.0f) {
|
||||
local->target_position[0] = randf2(-500.0f, 500.0f);
|
||||
local->target_position[1] = 0.0f;
|
||||
local->target_position[2] = randf2(-500.0f, 500.0f);
|
||||
@@ -430,12 +430,12 @@ void chvile_update(Actor *this) {
|
||||
}
|
||||
if ((this->state == 6)){
|
||||
local->unk10 = 400.0f;
|
||||
if((ml_vec3f_distance(this->position, local->target_position) < 100.0f) || (ml_vec3f_distance(player_position, local->target_position) < 300.0f)) {
|
||||
if((ml_distance_vec3f(this->position, local->target_position) < 100.0f) || (ml_distance_vec3f(player_position, local->target_position) < 300.0f)) {
|
||||
for(i = 0; i < 10; i++){
|
||||
random_position[0] = randf2(-500.0f, 500.0f);
|
||||
random_position[1] = 0.0f;
|
||||
random_position[2] = randf2(-500.0f, 500.0f);
|
||||
if ((i == 0) || (ml_vec3f_distance(player_position, random_position) > ml_vec3f_distance(player_position, local->target_position))) {
|
||||
if ((i == 0) || (ml_distance_vec3f(player_position, random_position) > ml_distance_vec3f(player_position, local->target_position))) {
|
||||
local->target_position[0] = random_position[0];
|
||||
local->target_position[1] = random_position[1];
|
||||
local->target_position[2] = random_position[2];
|
||||
|
@@ -79,11 +79,11 @@ void func_8038F610(Actor *this) {
|
||||
f32 sp24[3];
|
||||
|
||||
func_8034A174(this->marker->unk44, 8, sp24);
|
||||
if (func_80258368(sp24) != 0) {
|
||||
if (ml_isNonzero_vec3f(sp24) != 0) {
|
||||
func_8028E668(sp24, 200.0f, -600.0f, 300.0f);
|
||||
}
|
||||
func_8034A174(this->marker->unk44, 7, sp24);
|
||||
if (func_80258368(sp24) != 0) {
|
||||
if (ml_isNonzero_vec3f(sp24) != 0) {
|
||||
func_8028E668(sp24, 200.0f, -600.0f, 200.0f);
|
||||
}
|
||||
}
|
||||
@@ -140,7 +140,7 @@ void func_8038F6A4(Actor *this)
|
||||
player_getPosition(sp48);
|
||||
if (!this->unk138_24)
|
||||
{
|
||||
if ((((ml_vec3f_distance(local->unk18, sp48) < 250.0f) && (ml_vec3f_distance(local->unk18, sp48) > 80.0f)) && (!func_8028ECAC())) && (player_getTransformation() == TRANSFORM_1_BANJO))
|
||||
if ((((ml_distance_vec3f(local->unk18, sp48) < 250.0f) && (ml_distance_vec3f(local->unk18, sp48) > 80.0f)) && (!func_8028ECAC())) && (player_getTransformation() == TRANSFORM_1_BANJO))
|
||||
{
|
||||
func_80311480(0xC7E, 0, 0, 0, 0, 0);
|
||||
this->unk138_24 = 1;
|
||||
|
@@ -34,16 +34,16 @@ f32 BGS_D_80390B10[3] = {0.0f, 0.0f, 0.0f};
|
||||
void func_8038D1E0(Actor *this) {
|
||||
ParticleEmitter *temp_s0;
|
||||
|
||||
temp_s0 = partEmitList_pushNew(4U);
|
||||
temp_s0 = partEmitMgr_newEmitter(4U);
|
||||
particleEmitter_setSprite(temp_s0, ASSET_70E_SPRITE_SMOKE_2);
|
||||
func_802EFA5C(temp_s0, 0.01f, 0.7f);
|
||||
particleEmitter_setFade(temp_s0, 0.01f, 0.7f);
|
||||
particleEmitter_setStartingFrameRange(temp_s0, 0, 7);
|
||||
particleEmitter_setPosition(temp_s0, this->position);
|
||||
func_802EFFA8(temp_s0, D_80390B04);
|
||||
particleEmitter_setRGB(temp_s0, D_80390B04);
|
||||
func_802EFB70(temp_s0, 1.0f, 1.5f);
|
||||
func_802EFB84(temp_s0, 2.5f, 3.0f);
|
||||
particleEmitter_setParticleVelocityRange(temp_s0, -70.0f, 50.0f, -70.0f, 70.0f, 100.0f, 70.0f);
|
||||
func_802EFEC0(temp_s0, 3.0f, 4.0f);
|
||||
particleEmitter_setParticleLifeTimeRange(temp_s0, 3.0f, 4.0f);
|
||||
particleEmitter_emitN(temp_s0, 4);
|
||||
FUNC_8030E8B4(SFX_30_MAGIC_POOF, 1.0f, 25000, this->position, 500, 2500);
|
||||
}
|
||||
@@ -372,7 +372,7 @@ void BGS_func_8038E034(Actor *this) {
|
||||
spA8[1] = spB4[1] - this->position[1];
|
||||
spA8[2] = spB4[2] - this->position[2];
|
||||
spA4 = gu_sqrtf(spA8[0]*spA8[0] + spA8[1]*spA8[1] + spA8[2]*spA8[2]);
|
||||
if (func_8025773C(&local->unk28, sp9C) != 0) {
|
||||
if (ml_timer_update(&local->unk28, sp9C) != 0) {
|
||||
func_8030E878(0x3F0, randf2(0.9f, 1.1f), randi2(12000, 19000), this->position, 500.0f, 2500.0f);
|
||||
local->unk28 = randf2(1.0f, 6.0f);
|
||||
}
|
||||
@@ -395,7 +395,7 @@ void BGS_func_8038E034(Actor *this) {
|
||||
}
|
||||
|
||||
if(this->state == 2){
|
||||
if(func_8025773C(&local->unk1C, sp9C)){
|
||||
if(ml_timer_update(&local->unk1C, sp9C)){
|
||||
func_8038D9D0(this, 3);
|
||||
}
|
||||
}
|
||||
@@ -423,7 +423,7 @@ void BGS_func_8038E034(Actor *this) {
|
||||
sp7C[0] = (f32) local->unk10[0];
|
||||
sp7C[1] = (f32) local->unk10[1];
|
||||
sp7C[2] = (f32) local->unk10[2];
|
||||
if (ml_vec3f_distance(this->position, sp7C) < 30.0f) {
|
||||
if (ml_distance_vec3f(this->position, sp7C) < 30.0f) {
|
||||
func_8038D9D0(this, 1);
|
||||
} else {
|
||||
func_8038D9D0(this, 5);
|
||||
@@ -464,7 +464,7 @@ void BGS_func_8038E034(Actor *this) {
|
||||
}
|
||||
|
||||
if(this->state == 7 || this->state == 8){
|
||||
if(func_8025773C(&local->unk1C, sp9C)){
|
||||
if(ml_timer_update(&local->unk1C, sp9C)){
|
||||
func_8038D9D0(this, 6);
|
||||
}
|
||||
}
|
||||
|
@@ -162,7 +162,7 @@ void chyumblie_update(Actor *this){
|
||||
}
|
||||
sp50 = func_80335684(this->unk148);
|
||||
if(this->state == YUMBLIE_STATE_1_UNDER_GROUND){
|
||||
if(func_8025773C(&s0->unk8, sp4C)){
|
||||
if(ml_timer_update(&s0->unk8, sp4C)){
|
||||
if(mapSpecificFlags_get(6) && (12 > chvilegame_get_piece_count(s0->game_marker))){
|
||||
chyumblie_set_state(this, YUMBLIE_STATE_2_APPEAR);
|
||||
}
|
||||
@@ -194,7 +194,7 @@ void chyumblie_update(Actor *this){
|
||||
|
||||
}
|
||||
if(this->state == YUMBLIE_STATE_3_ABOVE_GROUND){
|
||||
if( func_8025773C(&s0->unk8,sp4C) || !mapSpecificFlags_get(6) ){
|
||||
if( ml_timer_update(&s0->unk8,sp4C) || !mapSpecificFlags_get(6) ){
|
||||
chyumblie_set_state(this,YUMBLIE_STATE_4_DISAPPEAR);
|
||||
}
|
||||
}
|
||||
@@ -210,7 +210,7 @@ void chyumblie_update(Actor *this){
|
||||
}
|
||||
|
||||
if(this->state == YUMBLIE_STATE_5_BEING_EATEN){
|
||||
if( func_8025773C(&s0->unk8,sp4C)){
|
||||
if( ml_timer_update(&s0->unk8,sp4C)){
|
||||
chyumblie_set_state(this,YUMBLIE_STATE_1_UNDER_GROUND);
|
||||
}
|
||||
}
|
||||
|
@@ -107,7 +107,7 @@ void BGS_func_80389850(Actor *this, s32 arg1) {
|
||||
sp7C[2] = 0.0f;
|
||||
sp7C[1] = sp94[1];
|
||||
sp7C[0] = 0.0f;
|
||||
if(ml_vec3f_distance(sp94, sp7C) <= 1000.0f){
|
||||
if(ml_distance_vec3f(sp94, sp7C) <= 1000.0f){
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -366,7 +366,7 @@ void chvilegame_player_consume_piece(Actor *this) {
|
||||
if ((end != begin) && BGS_func_80389810(sp44)){
|
||||
sp44[1] = 0.0f;
|
||||
for(i_ptr = begin; i_ptr < end; i_ptr++){
|
||||
if ((ml_vec3f_distance(i_ptr->position, sp44) < 65.25) && chyumblie_is_edible(i_ptr->marker)) {
|
||||
if ((ml_distance_vec3f(i_ptr->position, sp44) < 65.25) && chyumblie_is_edible(i_ptr->marker)) {
|
||||
is_correct_type = ((local->current_type != YUMBLIE) && (i_ptr->type != YUMBLIE)) || (((local->current_type == YUMBLIE) && i_ptr->type == YUMBLIE));
|
||||
if (is_correct_type) {
|
||||
local->player_score++;
|
||||
@@ -404,7 +404,7 @@ bool chvilegame_cpu_consume_piece(ActorMarker *marker, f32 position[3]) {
|
||||
begin = vector_getBegin(local->game_pieces);
|
||||
end = vector_getEnd(local->game_pieces);
|
||||
for(i_ptr = begin; i_ptr < end; i_ptr++){
|
||||
if ((ml_vec3f_distance(i_ptr->position, position) < 50.0f) && func_8038B684(i_ptr->marker)) {
|
||||
if ((ml_distance_vec3f(i_ptr->position, position) < 50.0f) && func_8038B684(i_ptr->marker)) {
|
||||
local->vile_score++;
|
||||
timedFunc_set_1(0.0f, (GenMethod_1)func_802FDCB8, ITEM_1B_VILE_VILE_SCORE);
|
||||
timedFunc_set_1(0.5f, (GenMethod_1)func_802FDCB8, ITEM_1B_VILE_VILE_SCORE);
|
||||
@@ -483,12 +483,12 @@ bool chvilegame_find_closest_piece(ActorMarker *marker, f32 position[0], f32 yaw
|
||||
piece_direction[0] = i_ptr->position[0] - position[0];
|
||||
piece_direction[1] = i_ptr->position[1] - position[1];
|
||||
piece_direction[2] = i_ptr->position[2] - position[2];
|
||||
distance = ml_vec3f_distance(i_ptr->position, position);
|
||||
distance = ml_distance_vec3f(i_ptr->position, position);
|
||||
angle_diff = func_80256AB4(target_direction[0], target_direction[2], piece_direction[0], piece_direction[2]);
|
||||
if( (distance > 300.0f)
|
||||
|| ((-0.8 < angle_diff) && (angle_diff < 0.8) && ((piece_direction[0]*target_direction[0] + piece_direction[1]*target_direction[1] + piece_direction[2]*target_direction[2]) >= 0.0f))
|
||||
) {
|
||||
if ((closest_piece == NULL) || (distance < ml_vec3f_distance(position, closest_piece->position))){
|
||||
if ((closest_piece == NULL) || (distance < ml_distance_vec3f(position, closest_piece->position))){
|
||||
closest_piece = i_ptr;
|
||||
}
|
||||
}
|
||||
@@ -601,7 +601,7 @@ void chvilegame_update(Actor *this) {
|
||||
} else {
|
||||
chvilegame_player_consume_piece(this);
|
||||
if ((local->unkC == 3) || (local->unkC == 6)) {
|
||||
if (func_8025773C(&local->type_change_timer, sp50)) {
|
||||
if (ml_timer_update(&local->type_change_timer, sp50)) {
|
||||
local->current_type = !local->current_type;
|
||||
if (func_803203FC(2)) {
|
||||
local->type_change_timer = 5.0f;
|
||||
|
Reference in New Issue
Block a user