| 39 | } |
| 40 | |
| 41 | S32 zNPCGoalDuploLive::Process(en_trantype* trantype, F32 dt, void* updCtxt, xScene* xscn) |
| 42 | { |
| 43 | zNPCDuplotron* npc = (zNPCDuplotron*)psyche->clt_owner; |
| 44 | S32 nextgoal = 0; |
| 45 | |
| 46 | npc->VelStop(); |
| 47 | |
| 48 | switch (livestat) |
| 49 | { |
| 50 | case LIVESTAT_NORMAL: |
| 51 | { |
| 52 | if (tmr_chkPlyrDist < 0.0f) |
| 53 | { |
| 54 | CheckPlayer(); |
| 55 | } |
| 56 | |
| 57 | tmr_chkPlyrDist = MAX(-1.0f, tmr_chkPlyrDist - dt); |
| 58 | |
| 59 | if (!npc->SndChanIsBusy(0)) |
| 60 | { |
| 61 | npc->SndPlayRandom(NPC_STYP_CLANKING); |
| 62 | } |
| 63 | |
| 64 | break; |
| 65 | } |
| 66 | case LIVESTAT_COUNTDOWN: |
| 67 | { |
| 68 | if (SDS_Countdown(dt)) |
| 69 | { |
| 70 | *trantype = GOAL_TRAN_SET; |
| 71 | nextgoal = NPC_GOAL_DUPLODEAD; |
| 72 | } |
| 73 | |
| 74 | break; |
| 75 | } |
| 76 | } |
| 77 | |
| 78 | if (*trantype != GOAL_TRAN_NONE) |
| 79 | { |
| 80 | return nextgoal; |
| 81 | } |
| 82 | |
| 83 | npc->flg_xtrarend |= 0x1; |
| 84 | |
| 85 | npc->VFXCycleLights(dt, 0); |
| 86 | npc->VFXSmokeStack(dt); |
| 87 | |
| 88 | return xGoal::Process(trantype, dt, updCtxt, xscn); |
| 89 | } |
| 90 | |
| 91 | void zNPCGoalDuploLive::CheckPlayer() |
| 92 | { |
nothing calls this directly
no test coverage detected