From c7dd48fd3a063eba8ea50b2568c8c0094120e1d0 Mon Sep 17 00:00:00 2001 From: gamemasterplc Date: Sun, 28 Apr 2024 21:29:31 -0500 Subject: [PATCH] Match fn_2_A940 --- src/REL/m401Dll/main.c | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/src/REL/m401Dll/main.c b/src/REL/m401Dll/main.c index 3e2c2b5c..56aeda14 100644 --- a/src/REL/m401Dll/main.c +++ b/src/REL/m401Dll/main.c @@ -2590,6 +2590,28 @@ void fn_2_A914(s32 player) void fn_2_A940(omObjData *object) { + Vec spC; + omObjData *sp8; + M401WorkPlayer *temp_r28; + s32 temp_r23; + temp_r28 = object->data; + if(temp_r28->unk78 != 0) { + return; + } + spC.x = object->trans.x; + spC.y = object->trans.y; + spC.z = object->trans.z; + if((temp_r23 = fn_2_AC2C(&spC, 90, &sp8)) != 0) { + if(temp_r23 == 1) { + omVibrate(temp_r28->unk4, 12, 4, 2); + } else if(temp_r23 == 3) { + omVibrate(temp_r28->unk4, 12, 4, 2); + } else { + omVibrate(temp_r28->unk4, 12, 12, 0); + } + fn_2_7C3C(object); + fn_2_1858(temp_r28->unk4, sp8->work[3]); + } }