- cleaned out all Doom dependencies from the DObject system.

This commit is contained in:
Christoph Oelckers 2020-04-07 00:35:53 +02:00
parent bb9a077424
commit 920f9a3f3f
4 changed files with 19 additions and 40 deletions

View file

@ -100,8 +100,6 @@
// EXTERNAL DATA DECLARATIONS ----------------------------------------------
//extern DThinker *NextToThink;
// PUBLIC DATA DEFINITIONS -------------------------------------------------
namespace GC
@ -262,9 +260,19 @@ void MarkArray(DObject **obj, size_t count)
//
//==========================================================================
TArray<GCMarkerFunc> markers;
void AddMarkerFunc(GCMarkerFunc func)
{
if (markers.Find(func) == markers.Size())
markers.Push(func);
}
static void MarkRoot()
{
Gray = NULL;
for (auto func : markers) func();
// Mark soft roots.
if (SoftRoots != NULL)
{