Decompile func0f190260

This commit is contained in:
Ryan Dwyer 2020-02-20 19:21:34 +10:00
parent 7de45b85ce
commit d123af877c
5 changed files with 25 additions and 24 deletions

View File

@ -12315,14 +12315,14 @@ u16 var80087ce4[] = {
u8 g_NumMpSimulantChrs = 0;
u32 var80087d14[] = {
0x5a000000, 0x3e86051b, 0x3f06051b, 0x02580000, 0x41200000, 0x3f32b179, 0x3eb2b179, 0x000003e8,
0x3c000000, 0x3dfa2baa, 0x3e7a2baa, 0x01680000, 0x41200000, 0x3efea34d, 0x3e0ef461, 0x000003e8,
0x1e000000, 0x3d8ef461, 0x3e0ef461, 0x00b40000, 0x40800000, 0x3eb2b179, 0x3db2b179, 0x000005dc,
0x0f000000, 0x3cd66e92, 0x3d8ef461, 0x005a0000, 0x40000000, 0x3e7a2baa, 0x3d0ef461, 0x000009c4,
0x00000000, 0x00000000, 0x3d0ef461, 0x002d0000, 0x3f800000, 0x3e32b179, 0x00000000, 0x00000fa0,
0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x3e0ef461, 0x00000000, 0x00000fa0,
0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000,
struct var80087d14 var80087d14[] = {
{ 90, 0.26175770163536, 0.52351540327072, 600, 10, 0.69802051782608, 0.34901025891304, 1000 },
{ 60, 0.12215359508991, 0.24430719017982, 360, 10, 0.49733963608742, 0.13960410654545, 1000 },
{ 30, 0.069802053272724, 0.13960410654545, 180, 4, 0.34901025891304, 0.08725256472826, 1500 },
{ 15, 0.026175770908594, 0.069802053272724, 90, 2, 0.24430719017982, 0.034901026636362, 2500 },
{ 0, 0, 0.034901026636362, 45, 1, 0.17450512945652, 0, 4000 },
{ 0, 0, 0, 0, 0, 0.13960410654545, 0, 4000 },
{ 0, 0, 0, 0, 0, 0, 0, 0 },
};
// 2de14

View File

@ -33,20 +33,10 @@
#include "library/library_233c0.h"
#include "types.h"
GLOBAL_ASM(
glabel func0f190260
/* f190260: 8c8f02d4 */ lw $t7,0x2d4($a0)
/* f190264: 3c098008 */ lui $t1,0x8008
/* f190268: 848e02d8 */ lh $t6,0x2d8($a0)
/* f19026c: 8df80004 */ lw $t8,0x4($t7)
/* f190270: 93190048 */ lbu $t9,0x48($t8)
/* f190274: 00194140 */ sll $t0,$t9,0x5
/* f190278: 01284821 */ addu $t1,$t1,$t0
/* f19027c: 8d297d30 */ lw $t1,0x7d30($t1)
/* f190280: 01c9102a */ slt $v0,$t6,$t1
/* f190284: 03e00008 */ jr $ra
/* f190288: 38420001 */ xori $v0,$v0,0x1
);
bool func0f190260(struct chrdata *chr)
{
return chr->blurdrugamount >= var80087d14[chr->unk2d4->simulant->unk48].blurdrugamount;
}
GLOBAL_ASM(
glabel mpChrReset

View File

@ -308,7 +308,7 @@ extern struct mptrack g_MpTracks[NUM_MPTRACKS];
extern struct mppreset g_MpPresets[NUM_MPPRESETS];
extern u32 g_TeamColours[MAX_TEAMS];
extern u8 g_NumMpSimulantChrs;
extern u32 var80087d14[];
extern struct var80087d14 var80087d14[];
extern u32 g_MpBotCommands[NUM_MPBOTCOMMANDS];
extern u32 var80087e2c;
extern u32 var80087e50;

View File

@ -3,7 +3,7 @@
#include <ultra64.h>
#include "types.h"
u32 func0f190260(void);
bool func0f190260(struct chrdata *chr);
void mpChrReset(struct chrdata *chr, u8 full);
void mpInitSimulant(struct chrdata *chr, u8 full);
void mpInitSimulants(void);

View File

@ -5109,4 +5109,15 @@ struct propdefinition {
u16 scale;
};
struct var80087d14 {
u8 unk00;
f32 unk04;
f32 unk08;
u16 unk0c;
f32 unk10;
f32 unk14;
f32 unk18;
s32 blurdrugamount;
};
#endif