2016-03-01 15:47:10 +00:00
|
|
|
#ifndef COMPATIBILITY_H
|
|
|
|
#define COMPATIBILITY_H
|
|
|
|
|
|
|
|
#include "doomtype.h"
|
|
|
|
#include "tarray.h"
|
|
|
|
#include "p_setup.h"
|
|
|
|
|
|
|
|
union FMD5Holder
|
|
|
|
{
|
2017-03-09 18:54:41 +00:00
|
|
|
uint8_t Bytes[16];
|
2017-03-08 17:50:37 +00:00
|
|
|
uint32_t DWords[4];
|
2016-03-01 15:47:10 +00:00
|
|
|
hash_t Hash;
|
|
|
|
};
|
|
|
|
|
|
|
|
struct FCompatValues
|
|
|
|
{
|
|
|
|
int CompatFlags[3];
|
|
|
|
unsigned int ExtCommandIndex;
|
|
|
|
};
|
|
|
|
|
|
|
|
struct FMD5HashTraits
|
|
|
|
{
|
|
|
|
hash_t Hash(const FMD5Holder key)
|
|
|
|
{
|
|
|
|
return key.Hash;
|
|
|
|
}
|
|
|
|
int Compare(const FMD5Holder left, const FMD5Holder right)
|
|
|
|
{
|
|
|
|
return left.DWords[0] != right.DWords[0] ||
|
|
|
|
left.DWords[1] != right.DWords[1] ||
|
|
|
|
left.DWords[2] != right.DWords[2] ||
|
|
|
|
left.DWords[3] != right.DWords[3];
|
|
|
|
}
|
|
|
|
};
|
|
|
|
|
|
|
|
extern TMap<FMD5Holder, FCompatValues, FMD5HashTraits> BCompatMap;
|
|
|
|
|
|
|
|
void ParseCompatibility();
|
2018-04-09 20:09:28 +00:00
|
|
|
FName CheckCompatibility(MapData *map);
|
|
|
|
void SetCompatibilityParams(FName);
|
2016-03-01 15:47:10 +00:00
|
|
|
|
|
|
|
#endif
|