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

Function NPCPS_CltPoolReset

src/SB/Game/zNPCMessenger.cpp:198–211  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

196}
197
198static void NPCPS_CltPoolReset(NPCPSData* npc)
199{
200 S32 max_clts = npc->cltlist.max;
201 memset(npc->cltblob, 0, max_clts * sizeof(NPCPSClt));
202 npc->cltfree = NULL;
203 for (S32 i = 0; i < max_clts; i++)
204 {
205 NPCPSClt* current_clt = &npc->cltblob[i];
206
207 current_clt->next = npc->cltfree;
208 npc->cltfree = current_clt;
209 }
210 npc->cltlist.cnt = 0;
211}
212
213static NPCPSData* NPCPS_postOffice()
214{

Callers 2

zNPCMsg_SceneResetFunction · 0.85
NPCPS_CltPoolInitFunction · 0.85

Calls 1

memsetFunction · 0.85

Tested by

no test coverage detected