Decompile liftGoToStop and discover lift_go_to_stop AI command

This commit is contained in:
Ryan Dwyer
2020-02-09 14:36:21 +10:00
parent b76d35c1b3
commit 4c883f8aaa
7 changed files with 67 additions and 189 deletions
+7 -2
View File
@@ -3150,10 +3150,15 @@
lift, \
label,
#define cmd0189(lift, u1) \
/**
* Makes the lift go to the given stop number.
*
* Lifts only support up to 4 stops, so stopnum must be 0-3.
*/
#define lift_go_to_stop(lift, stopnum) \
mkshort(0x0189), \
lift, \
u1,
stopnum,
/**
* Checks if the lift is stopped at the given stop number.
+1 -1
View File
@@ -370,7 +370,7 @@
/*0x0186*/ bool aiIfSoundTimer(void);
/*0x0187*/ bool ai0187(void);
/*0x0188*/ bool aiIfLiftStationary(void);
/*0x0189*/ bool ai0189(void);
/*0x0189*/ bool aiLiftGoToStop(void);
/*0x018a*/ bool aiIfLiftAtStop(void);
/*0x018b*/ bool aiConfigureRain(void);
/*0x018c*/ bool aiChrToggleProp(void);
+1 -1
View File
@@ -130,7 +130,7 @@ void liftActivate(struct prop *prop, u8 liftnum);
struct prop *liftFindByPad(s16 padnum);
u32 func0f070eac(void);
u32 func0f070f08(void);
void func0f0710ec(struct defaultobj *obj, u32 arg1);
void liftGoToStop(struct liftobj *lift, s32 stopnum);
u32 func0f071360(void);
u32 func0f0713e4(void);
u32 func0f0714b8(void);
+4 -8
View File
@@ -839,19 +839,15 @@ struct heliobj {
struct liftobj { // objtype 30
struct defaultobj base;
/*0x5c*/ u32 pad;
/*0x60*/ u32 unk60;
/*0x64*/ u32 unk64;
/*0x68*/ u32 unk68;
/*0x6c*/ u32 unk6c;
/*0x70*/ u32 unk70;
/*0x5c*/ s16 pads[4];
/*0x64*/ struct doorobj *doors[4];
/*0x74*/ f32 dist;
/*0x78*/ u32 speed;
/*0x78*/ f32 speed;
/*0x7c*/ u32 accel;
/*0x80*/ u32 maxspeed;
/*0x84*/ u8 soundtype;
/*0x85*/ s8 levelcur;
/*0x85*/ s8 levelaim;
/*0x86*/ s8 levelaim;
/*0x88*/ struct coord prevpos;
};