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

Function xGridUpdate

src/SB/Core/x/xGrid.cpp:245–258  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

243}
244
245void xGridUpdate(xGrid* grid, xEnt* ent)
246{
247 S32 dx;
248 S32 dz;
249 xGridGetCell(grid, ent, dx, dz);
250
251 if (dx != ent->gridb.gx || dz != ent->gridb.gz)
252 {
253 if (xGridRemove(&ent->gridb))
254 {
255 xGridAdd(grid, &ent->gridb, dx, dz);
256 }
257 }
258}
259
260xGridBound** xGridGetCell(xGrid* grid, const xEnt* ent, S32& grx, S32& grz)
261{

Callers 1

zGridUpdateEntFunction · 0.50

Calls 3

xGridGetCellFunction · 0.70
xGridRemoveFunction · 0.70
xGridAddFunction · 0.70

Tested by

no test coverage detected