summaryrefslogtreecommitdiffstats
path: root/src/References.cpp
blob: 187f4ffaa2bbf46c0d90728fef1db378d7811301 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#include "common.h"
#include "patcher.h"
#include "References.h"

CReference *CReferences::aRefs = (CReference*)0x70BBE0; //[NUMREFERENCES];
CReference *&CReferences::pEmptyList = *(CReference**)0x8F1AF8;

void
CReferences::Init(void)
{
	int i;
	pEmptyList = &aRefs[0];
	for(i = 0; i < NUMREFERENCES; i++){
		aRefs[i].pentity = nil;
		aRefs[i].next = &aRefs[i+1];
	}
	aRefs[NUMREFERENCES-1].next = nil;
}

STARTPATCHES
	InjectHook(0x4A7350, CReferences::Init, PATCH_JUMP);
ENDPATCHES