Move CRC32 definition to separate file.

Signed-off-by: aixxe <me@aixxe.net>
This commit is contained in:
aixxe 2016-12-20 13:13:38 +00:00
parent 33f3672867
commit 3b12e00ad1
3 changed files with 22 additions and 6 deletions

View File

@ -1,7 +1,5 @@
#pragma once
typedef unsigned long CRC32_t;
typedef struct player_info_s {
char name[MAX_PLAYER_NAME_LENGTH];
int userID;

View File

@ -0,0 +1,18 @@
#pragma once
#define CRC32_INIT_VALUE 0xFFFFFFFFUL
#define CRC32_XOR_VALUE 0xFFFFFFFFUL
typedef unsigned int CRC32_t;
typedef void (*CRC32_ProcessBufferFn) (CRC32_t*, const void*, int);
extern CRC32_ProcessBufferFn CRC32_ProcessBuffer;
static void CRC32_Init(CRC32_t* crc) {
*crc = CRC32_INIT_VALUE;
}
static void CRC32_Final(CRC32_t* crc) {
*crc ^= CRC32_XOR_VALUE;
}

View File

@ -5,16 +5,16 @@
#include "Definitions/Buttons.h"
#include "Definitions/Const.h"
#include "Utilities/Virtuals.h"
#include "Utilities/CRC32.h"
#include "Structures/Color.h"
#include "Structures/Matrix.h"
#include "Structures/Vector.h"
#include "Structures/PlayerInfo.h"
#include "Utilities/Virtuals.h"
#include "Classes/Interface.h"
#include "Classes/CInput.h"
#include "Classes/CUserCmd.h"
#include "Classes/CInput.h"
#include "Classes/CBaseHandle.h"
#include "Classes/CGlobalVarsBase.h"
#include "Classes/ClientClass.h"