MCPcopy Create free account
hub / github.com/bfbbdecomp/bfbb / NPC_entwrap_update

Function NPC_entwrap_update

src/SB/Core/x/xNPCBasic.cpp:289–319  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

287}
288
289void NPC_entwrap_update(xEnt* ent, xScene* scn, F32 dt_caller)
290{
291 F32 dt = dt_caller;
292 if (dt > 0.04f)
293 {
294 dt = 0.025000002f;
295 }
296
297 xNPCBasic* npc = (xNPCBasic*)ent;
298 xEntBeginUpdate(npc, scn, dt);
299 npc->flags1.inUpdate = 1;
300 npc->DBG_HaltOnMe(0, NULL);
301 npc->DBG_PStatOn(eNPCPerfEnable);
302
303 if (npc->isCulled)
304 {
305 npc->model->Flags &= 0xfffd;
306 }
307 else if ((npc->flags1.flg_upward & 0x1) == 0)
308 {
309 npc->model->Flags |= 0x2;
310 }
311
312 npc->Process(scn, dt);
313
314 npc->DBG_PStatCont(eNPCPerfEnable);
315 npc->flags1.inUpdate = 0;
316 xEntEndUpdate(npc, scn, dt);
317
318 npc->NewTime(scn, dt);
319}
320
321void NPC_entwrap_bupdate(xEnt* ent, xVec3* pos)
322{

Callers

nothing calls this directly

Calls 7

xEntBeginUpdateFunction · 0.85
DBG_HaltOnMeMethod · 0.80
DBG_PStatOnMethod · 0.80
DBG_PStatContMethod · 0.80
xEntEndUpdateFunction · 0.70
ProcessMethod · 0.45
NewTimeMethod · 0.45

Tested by

no test coverage detected