diff --git a/src/SB/Game/zNPCGoalAmbient.cpp b/src/SB/Game/zNPCGoalAmbient.cpp index 74c6ffd12..71bf8d427 100644 --- a/src/SB/Game/zNPCGoalAmbient.cpp +++ b/src/SB/Game/zNPCGoalAmbient.cpp @@ -2,8 +2,8 @@ #include "xMath3.h" #include "xVec3.h" - #include "zNPCGoalAmbient.h" +#include "zNPCSndTable.h" void xMat3x3RMulVec(xVec3* o, const xMat3x3* m, const xVec3* v) { @@ -15,3 +15,14 @@ void xMat3x3RMulVec(xVec3* o, const xMat3x3* m, const xVec3* v) o->y = y; o->z = z; } + +S32 zNPCGoalJellyAttack::Enter(F32 arg0, void* arg1) +{ + zNPCJelly* temp_r31 = (zNPCJelly*)psyche->clt_owner; + + temp_r31->SndPlayRandom(NPC_STYP_ENCOUNTER); + temp_r31->VelStop(); + lastAnimTime = 0; + zNPCGoalJellyAttack::ZapperStart(); + return zNPCGoalPushAnim::Enter(arg0, arg1); +} diff --git a/src/SB/Game/zNPCGoalAmbient.h b/src/SB/Game/zNPCGoalAmbient.h index 4c1cf7ce2..7c4ad3c4e 100644 --- a/src/SB/Game/zNPCGoalAmbient.h +++ b/src/SB/Game/zNPCGoalAmbient.h @@ -1,7 +1,12 @@ #ifndef ZNPCGOALAMBIENT_H #define ZNPCGOALAMBIENT_H +#include "zNPCGoalAmbient.h" #include "zNPCGoalCommon.h" +#include "zNPCGoalStd.h" +#include "zNPCSndTable.h" +#include "zNPCTypeAmbient.h" + xFactoryInst* GOALCreate_Ambient(S32 who, RyzMemGrow* grow, void*); @@ -15,4 +20,11 @@ struct zNPCGoalJellyBirth : zNPCGoalCommon S32 Enter(F32 dt, void* updCtxt); }; +struct zNPCGoalJellyAttack : zNPCGoalPushAnim +{ + U32 lastAnimTime; + S32 Enter(F32 dt, void* updCtxt); + S32 ZapperStart(); +}; + #endif