MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / Osiris_TimerExists

Function Osiris_TimerExists

Descent3/OsirisLoadandBind.cpp:2538–2551  ·  view source on GitHub ↗

Osiris_TimerExists Purpose: Returns true if the timer is valid

Source from the content-addressed store, hash-verified

2536// Purpose:
2537// Returns true if the timer is valid
2538uint8_t Osiris_TimerExists(int handle) {
2539 int id = GET_SLOT(handle);
2540
2541 if (id < 0 || id >= MAX_OSIRIS_TIMERS)
2542 return false;
2543
2544 if (!(OsirisTimers[id].flags & OITF_USED))
2545 return false;
2546
2547 if (OsirisTimers[id].handle != handle) // not the same timer
2548 return false;
2549
2550 return true;
2551}
2552
2553// Osiris_TimerTimeRemaining
2554// Purpose:

Callers

nothing calls this directly

Calls 1

GET_SLOTFunction · 0.70

Tested by

no test coverage detected