Attempt to decompile ai001a

This commit is contained in:
Ryan Dwyer
2019-11-25 20:22:54 +10:00
parent 5a3fd51dae
commit 3d9fe3114f
4 changed files with 39 additions and 5 deletions
+35
View File
@@ -1031,6 +1031,41 @@ glabel ai001a
/* f04f050: 00001025 */ or $v0,$zero,$zero
);
//bool ai001a(void)
//{
// u8 *cmd = g_Vars.ailist + g_Vars.aioffset;
// struct chrdata *chr1 = chrFindById(g_Vars.chrdata, cmd[2]);
// struct chrdata *chr2 = chrFindById(g_Vars.chrdata, cmd[3]);
//
// if (chr1 && chr2 && chr1->pos && chr2->pos) {
// struct attachment *attachment = func0f028834(chr1, 0);
// struct coord coord;
// coord.x = var80068fec.x;
// coord.y = var80068fec.y;
// coord.z = var80068fec.z;
//
// if (!attachment) {
// attachment = func0f028834(chr1, 1);
// }
//
// if (attachment) {
// s32 weapon_id;
// s32 thing;
// coord.x = chr2->pos->coord.x - chr1->pos->coord.x;
// coord.y = chr2->pos->coord.y - chr1->pos->coord.y;
// coord.x = chr2->pos->coord.z - chr1->pos->coord.z;
// scaleTo1(&coord.x, &coord.y, &coord.z);
// weapon_id = attachment->weapon->weapon_id;
// thing = func0f0b1d28(weapon_id);
// func0f034330(chr2, thing, &coord, weapon_id);
// }
// }
//
// g_Vars.aioffset += 5;
//
// return false;
//}
/**
* @cmd 001b
*/
+2 -2
View File
@@ -530,7 +530,7 @@ u32 func0f028490(void);
u32 func0f028498(void);
u32 func0f028590(void);
u32 func0f028824(void);
u32 func0f028834(void);
struct attachment *func0f028834(struct chrdata *chr, s32 hand);
u32 func0f0288d0(void);
u32 func0f0289dc(void);
u32 func0f028a50(void);
@@ -623,7 +623,7 @@ u32 func0f034080(void);
u32 func0f034124(void);
u32 func0f03417c(void);
u32 func0f0341dc(void);
u32 func0f034330(void);
u32 func0f034330(struct chrdata *chr, s32 arg1, struct coord *coord, s32 arg3);
u32 func0f034410(void);
u32 func0f034480(void);
u32 func0f034524(void);
+1 -1
View File
@@ -40,7 +40,7 @@ u32 func0f0b1af0(void);
u32 func0f0b1c24(void);
u32 func0f0b1c78(void);
u32 func0f0b1ce8(void);
u32 func0f0b1d28(void);
u32 func0f0b1d28(s32 weapon_id);
u32 func0f0b1e28(void);
u32 func0f0b1e68(void);
u32 func0f0b1ea8(void);
+1 -2
View File
@@ -187,8 +187,7 @@ struct chrdata {
/*0x164*/ u32 aimendrshoulder;
/*0x168*/ u32 aimendback;
/*0x16c*/ u32 aimendsideback;
/*0x170*/ u32 unk170;
/*0x174*/ u32 unk174;
/*0x170*/ struct attachment *weapons_held[2];
/*0x178*/ u32 unk178;
/*0x17c*/ u16 fireslot;
/*0x17e*/ s16 target; // index into g_Vars.positions