Move CRC32 definition to separate file.
Signed-off-by: aixxe <me@aixxe.net>
This commit is contained in:
parent
33f3672867
commit
3b12e00ad1
|
@ -1,7 +1,5 @@
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
typedef unsigned long CRC32_t;
|
|
||||||
|
|
||||||
typedef struct player_info_s {
|
typedef struct player_info_s {
|
||||||
char name[MAX_PLAYER_NAME_LENGTH];
|
char name[MAX_PLAYER_NAME_LENGTH];
|
||||||
int userID;
|
int userID;
|
||||||
|
|
|
@ -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;
|
||||||
|
}
|
|
@ -5,16 +5,16 @@
|
||||||
#include "Definitions/Buttons.h"
|
#include "Definitions/Buttons.h"
|
||||||
#include "Definitions/Const.h"
|
#include "Definitions/Const.h"
|
||||||
|
|
||||||
|
#include "Utilities/Virtuals.h"
|
||||||
|
#include "Utilities/CRC32.h"
|
||||||
|
|
||||||
#include "Structures/Color.h"
|
#include "Structures/Color.h"
|
||||||
#include "Structures/Matrix.h"
|
#include "Structures/Matrix.h"
|
||||||
#include "Structures/Vector.h"
|
#include "Structures/Vector.h"
|
||||||
#include "Structures/PlayerInfo.h"
|
#include "Structures/PlayerInfo.h"
|
||||||
|
|
||||||
#include "Utilities/Virtuals.h"
|
|
||||||
|
|
||||||
#include "Classes/Interface.h"
|
|
||||||
#include "Classes/CInput.h"
|
|
||||||
#include "Classes/CUserCmd.h"
|
#include "Classes/CUserCmd.h"
|
||||||
|
#include "Classes/CInput.h"
|
||||||
#include "Classes/CBaseHandle.h"
|
#include "Classes/CBaseHandle.h"
|
||||||
#include "Classes/CGlobalVarsBase.h"
|
#include "Classes/CGlobalVarsBase.h"
|
||||||
#include "Classes/ClientClass.h"
|
#include "Classes/ClientClass.h"
|
||||||
|
|
Loading…
Reference in New Issue