Integrating latest 47acbe8
This commit is contained in:
@@ -45,7 +45,7 @@
|
||||
#undef CRY_ASSERT_DIALOG_ONLY_IN_DEBUG
|
||||
#endif
|
||||
|
||||
// Using AZ_Assert for all assert kinds (assert =, CRY_ASSERT, AZ_Assert). This is for Provo and Xenia
|
||||
// Using AZ_Assert for all assert kinds (assert =, CRY_ASSERT, AZ_Assert).
|
||||
// see Trace::Assert for implementation
|
||||
#if defined(USE_AZ_ASSERT)
|
||||
#undef assert
|
||||
|
||||
@@ -1,215 +0,0 @@
|
||||
/*
|
||||
* All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
|
||||
* its licensors.
|
||||
*
|
||||
* For complete copyright and license terms please see the LICENSE at the root of this
|
||||
* distribution (the "License"). All use of this software is governed by the License,
|
||||
* or, if provided, by the license below or the license accompanying this file. Do not
|
||||
* remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
*
|
||||
*/
|
||||
#ifndef CRYINCLUDE_CRYCOMMON_ICRYPTO_H
|
||||
#define CRYINCLUDE_CRYCOMMON_ICRYPTO_H
|
||||
#pragma once
|
||||
|
||||
#include "ISerialize.h"
|
||||
|
||||
typedef void* TCipher;
|
||||
|
||||
class IRijndael;
|
||||
class IStreamCipher;
|
||||
|
||||
struct StreamCipherState
|
||||
{
|
||||
uint8 m_StartS[256];
|
||||
uint8 m_S[256];
|
||||
int m_StartI;
|
||||
int m_I;
|
||||
int m_StartJ;
|
||||
int m_J;
|
||||
};
|
||||
|
||||
class ICrypto
|
||||
{
|
||||
public:
|
||||
//Need an empty virtual destructor to address a compiler error with GCC which doesn't allow delete to be called on incomplete types
|
||||
virtual ~ICrypto() {};
|
||||
|
||||
// Exposed block encryption
|
||||
virtual void EncryptBuffer(uint8* pOutput, const uint8* pInput, uint32 bufferLength, const uint8* pKey, uint32 keyLength) = 0;
|
||||
virtual void DecryptBuffer(uint8* pOutput, const uint8* pInput, uint32 bufferLength, const uint8* pKey, uint32 keyLength) = 0;
|
||||
|
||||
// Crypto implementations
|
||||
virtual IRijndael* GetRijndael() = 0;
|
||||
virtual IStreamCipher* GetStreamCipher() = 0;
|
||||
|
||||
virtual void InitWhirlpoolHash(uint8* hash) = 0;
|
||||
virtual void InitWhirlpoolHash(uint8* hash, const string& str) = 0;
|
||||
virtual void InitWhirlpoolHash(uint8* hash, const uint8* input, size_t length) = 0;
|
||||
};
|
||||
|
||||
#define _MAX_KEY_COLUMNS (256 / 32)
|
||||
#define _MAX_ROUNDS 14
|
||||
#define MAX_IV_SIZE 16
|
||||
|
||||
// Error codes
|
||||
#define RIJNDAEL_SUCCESS 0
|
||||
#define RIJNDAEL_UNSUPPORTED_MODE -1
|
||||
#define RIJNDAEL_UNSUPPORTED_DIRECTION -2
|
||||
#define RIJNDAEL_UNSUPPORTED_KEY_LENGTH -3
|
||||
#define RIJNDAEL_BAD_KEY -4
|
||||
#define RIJNDAEL_NOT_INITIALIZED -5
|
||||
#define RIJNDAEL_BAD_DIRECTION -6
|
||||
#define RIJNDAEL_CORRUPTED_DATA -7
|
||||
|
||||
enum class RijndaelDirection
|
||||
{
|
||||
Encrypt, Decrypt
|
||||
};
|
||||
enum class RijndaelMode
|
||||
{
|
||||
ECB, CBC, CFB1
|
||||
};
|
||||
enum class RijndaelKeyLength
|
||||
{
|
||||
Key16Bytes, Key24Bytes, Key32Bytes
|
||||
};
|
||||
|
||||
struct RijndaelState
|
||||
{
|
||||
enum State
|
||||
{
|
||||
Valid, Invalid
|
||||
};
|
||||
|
||||
State m_state;
|
||||
RijndaelMode m_mode;
|
||||
RijndaelDirection m_direction;
|
||||
uint8 m_initVector[MAX_IV_SIZE];
|
||||
uint32 m_uRounds;
|
||||
uint8 m_expandedKey[_MAX_ROUNDS + 1][4][4];
|
||||
};
|
||||
|
||||
class IRijndael
|
||||
{
|
||||
public:
|
||||
//////////////////////////////////////////////////////////////////////////////////////////
|
||||
// API
|
||||
//////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
// init(): Initializes the crypt session
|
||||
// Returns RIJNDAEL_SUCCESS or an error code
|
||||
// mode : Rijndael::ECB, Rijndael::CBC or Rijndael::CFB1
|
||||
// You have to use the same mode for encrypting and decrypting
|
||||
// dir : Rijndael::Encrypt or Rijndael::Decrypt
|
||||
// A cipher instance works only in one direction
|
||||
// (Well , it could be easily modified to work in both
|
||||
// directions with a single init() call, but it looks
|
||||
// useless to me...anyway , it is a matter of generating
|
||||
// two expanded keys)
|
||||
// key : array of unsigned octets , it can be 16 , 24 or 32 bytes long
|
||||
// this CAN be binary data (it is not expected to be null terminated)
|
||||
// keyLen : Rijndael::Key16Bytes , Rijndael::Key24Bytes or Rijndael::Key32Bytes
|
||||
// initVector: initialization vector, you will usually use 0 here
|
||||
virtual int init(RijndaelState& state, RijndaelMode mode, RijndaelDirection dir, const uint8* key, RijndaelKeyLength keyLen, uint8* initVector = 0) = 0;
|
||||
// Encrypts the input array (can be binary data)
|
||||
// The input array length must be a multiple of 16 bytes, the remaining part
|
||||
// is DISCARDED.
|
||||
// so it actually encrypts inputLen / 128 blocks of input and puts it in outBuffer
|
||||
// Input len is in BITS!
|
||||
// outBuffer must be at least inputLen / 8 bytes long.
|
||||
// Returns the encrypted buffer length in BITS or an error code < 0 in case of error
|
||||
virtual int blockEncrypt(RijndaelState& state, const uint8* input, int inputLen, uint8* outBuffer) = 0;
|
||||
// Encrypts the input array (can be binary data)
|
||||
// The input array can be any length , it is automatically padded on a 16 byte boundary.
|
||||
// Input len is in BYTES!
|
||||
// outBuffer must be at least (inputLen + 16) bytes long
|
||||
// Returns the encrypted buffer length in BYTES or an error code < 0 in case of error
|
||||
virtual int padEncrypt(RijndaelState& state, const uint8* input, int inputOctets, uint8* outBuffer) = 0;
|
||||
// Decrypts the input vector
|
||||
// Input len is in BITS!
|
||||
// outBuffer must be at least inputLen / 8 bytes long
|
||||
// Returns the decrypted buffer length in BITS and an error code < 0 in case of error
|
||||
virtual int blockDecrypt(RijndaelState& state, const uint8* input, int inputLen, uint8* outBuffer) = 0;
|
||||
// Decrypts the input vector
|
||||
// Input len is in BYTES!
|
||||
// outBuffer must be at least inputLen bytes long
|
||||
// Returns the decrypted buffer length in BYTES and an error code < 0 in case of error
|
||||
virtual int padDecrypt(RijndaelState& state, const uint8* input, int inputOctets, uint8* outBuffer) = 0;
|
||||
};
|
||||
|
||||
class IStreamCipher
|
||||
{
|
||||
public:
|
||||
virtual StreamCipherState BeginCipher(const uint8* pKey, uint32 keyLength) = 0;
|
||||
virtual void Init(StreamCipherState& state, const uint8* key, int keyLen) = 0;
|
||||
virtual void Encrypt(StreamCipherState& state, const uint8* input, int inputLen, uint8* output) = 0;
|
||||
virtual void Decrypt(StreamCipherState& state, const uint8* input, int inputLen, uint8* output) = 0;
|
||||
virtual void EncryptStream(StreamCipherState& state, const uint8* input, int inputLen, uint8* output) = 0;
|
||||
virtual void DecryptStream(StreamCipherState& state, const uint8* input, int inputLen, uint8* output) = 0;
|
||||
};
|
||||
|
||||
class CWhirlpoolHash
|
||||
{
|
||||
public:
|
||||
static const int DIGESTBYTES = 64;
|
||||
static const int STRING_SIZE = DIGESTBYTES * 2 + 1;
|
||||
|
||||
ILINE CWhirlpoolHash()
|
||||
{
|
||||
gEnv->pSystem->GetCrypto()->InitWhirlpoolHash(m_hash);
|
||||
}
|
||||
|
||||
ILINE CWhirlpoolHash(const string& str)
|
||||
{
|
||||
gEnv->pSystem->GetCrypto()->InitWhirlpoolHash(m_hash, str);
|
||||
}
|
||||
|
||||
ILINE CWhirlpoolHash(const uint8* input, size_t length)
|
||||
{
|
||||
gEnv->pSystem->GetCrypto()->InitWhirlpoolHash(m_hash, input, length);
|
||||
}
|
||||
|
||||
ILINE CryFixedStringT<STRING_SIZE> GetHumanReadable() const
|
||||
{
|
||||
static const char* hexchars = "0123456789ABCDEF";
|
||||
CRY_ASSERT(strlen(hexchars) == 16);
|
||||
|
||||
char buffer[DIGESTBYTES * 2 + 1];
|
||||
for (int i = 0; i < DIGESTBYTES; i++)
|
||||
{
|
||||
buffer[2 * i + 0] = hexchars[m_hash[i] >> 4];
|
||||
buffer[2 * i + 1] = hexchars[m_hash[i] & 15];
|
||||
}
|
||||
buffer[DIGESTBYTES * 2] = 0;
|
||||
return buffer;
|
||||
}
|
||||
|
||||
ILINE void SerializeWith(TSerialize ser)
|
||||
{
|
||||
for (int i = 0; i < DIGESTBYTES; i++)
|
||||
{
|
||||
char name[] = {'w', 'p', 0, 0, 0};
|
||||
sprintf_s(name + 2, sizeof(name), "%.2i", i);
|
||||
ser.Value(name, m_hash[i]);
|
||||
}
|
||||
}
|
||||
|
||||
ILINE bool operator==(const CWhirlpoolHash& rhs) const
|
||||
{
|
||||
return 0 == memcmp(m_hash, rhs.m_hash, DIGESTBYTES);
|
||||
}
|
||||
|
||||
ILINE bool operator!=(const CWhirlpoolHash& rhs) const
|
||||
{
|
||||
return !this->operator==(rhs);
|
||||
}
|
||||
|
||||
const uint8* operator()() const { return m_hash; }
|
||||
|
||||
private:
|
||||
uint8 m_hash[DIGESTBYTES];
|
||||
};
|
||||
|
||||
#endif // CRYINCLUDE_CRYCOMMON_ICRYPTO_H
|
||||
@@ -15,7 +15,8 @@
|
||||
#define CRYINCLUDE_CRYCOMMON_INAVIGATIONSYSTEM_H
|
||||
#pragma once
|
||||
|
||||
#include <functor.h>
|
||||
#include <AzCore/std/functional.h>
|
||||
|
||||
#include <IMNM.h>
|
||||
#include <physinterface.h>
|
||||
|
||||
@@ -49,8 +50,8 @@ private:
|
||||
typedef TNavigationID<MeshIDTag> NavigationMeshID;
|
||||
typedef TNavigationID<AgentTypeIDTag> NavigationAgentTypeID;
|
||||
typedef TNavigationID<VolumeIDTag> NavigationVolumeID;
|
||||
typedef Functor3<NavigationAgentTypeID, NavigationMeshID, uint32> NavigationMeshChangeCallback;
|
||||
typedef Functor2wRet<IPhysicalEntity&, uint32&, bool> NavigationMeshEntityCallback;
|
||||
typedef AZStd::function<void(NavigationAgentTypeID, NavigationMeshID, uint32)> NavigationMeshChangeCallback;
|
||||
typedef AZStd::function<bool(IPhysicalEntity&, uint32&)> NavigationMeshEntityCallback;
|
||||
|
||||
struct INavigationSystemUser
|
||||
{
|
||||
|
||||
@@ -1,515 +0,0 @@
|
||||
/*
|
||||
* All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
|
||||
* its licensors.
|
||||
*
|
||||
* For complete copyright and license terms please see the LICENSE at the root of this
|
||||
* distribution (the "License"). All use of this software is governed by the License,
|
||||
* or, if provided, by the license below or the license accompanying this file. Do not
|
||||
* remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
*
|
||||
*/
|
||||
// Original file Copyright Crytek GMBH or its affiliates, used under license.
|
||||
|
||||
// Description : Message definition to id management
|
||||
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <ISerialize.h>
|
||||
#include <smartptr.h>
|
||||
|
||||
#define NUM_ASPECTS 32 // Number of GameObject aspects supported.
|
||||
#define MAXIMUM_NUMBER_OF_CONNECTIONS 64 // Maximum number of connections supported.
|
||||
#if defined(AZ_RESTRICTED_PLATFORM)
|
||||
#include AZ_RESTRICTED_FILE(INetwork_h)
|
||||
#endif
|
||||
#if defined(AZ_RESTRICTED_SECTION_IMPLEMENTED)
|
||||
#undef AZ_RESTRICTED_SECTION_IMPLEMENTED
|
||||
#else
|
||||
#define LOBBY_DEFAULT_PORT 30090 // Default local UDP port.
|
||||
#endif
|
||||
#define SERVER_DEFAULT_PORT LOBBY_DEFAULT_PORT
|
||||
#define SERVER_DEFAULT_PORT_STRING #SERVER_DEFAULT_PORT
|
||||
static const int NumAspects = NUM_ASPECTS;
|
||||
#define _CRYNETWORK_CONCAT(x, y) x ## y
|
||||
#define CRYNETWORK_CONCAT(x, y) _CRYNETWORK_CONCAT(x, y)
|
||||
#define ASPECT_TYPE CRYNETWORK_CONCAT(uint, NUM_ASPECTS)
|
||||
typedef ASPECT_TYPE NetworkAspectType;
|
||||
typedef uint8 NetworkAspectID;
|
||||
#define NET_ASPECT_ALL (NetworkAspectType(0xFFFFFFFF))
|
||||
|
||||
typedef uint32 CryLobbyTaskID;
|
||||
typedef uint32 ECryLobbyError;
|
||||
|
||||
struct ISerializableInfo
|
||||
: public CMultiThreadRefCount
|
||||
, public ISerializable {};
|
||||
typedef _smart_ptr<ISerializableInfo> ISerializableInfoPtr;
|
||||
|
||||
typedef uint32 ChannelId; // Network channel id (derived from GridMember)
|
||||
static const ChannelId kInvalidChannelId = ChannelId(0);
|
||||
static const ChannelId kOfflineChannelId = ChannelId(1);
|
||||
|
||||
typedef unsigned int EntityId;
|
||||
static const EntityId kInvalidEntityId = (EntityId)0;
|
||||
|
||||
#define NET_PROFILE_COUNT_READ_BITS(count)
|
||||
#define NET_PROFILE_BEGIN(string, read)
|
||||
#define NET_PROFILE_BEGIN_BUDGET(string, read, budget)
|
||||
#define NET_PROFILE_BEGIN_RMI(string, read)
|
||||
#define NET_PROFILE_END()
|
||||
#define NET_PROFILE_SCOPE(string, read)
|
||||
#define NET_PROFILE_SCOPE_RMI(string, read)
|
||||
#define NET_PROFILE_SCOPE_BUDGET(string, read, budget)
|
||||
|
||||
enum ENetReliabilityType
|
||||
{
|
||||
eNRT_ReliableOrdered,
|
||||
eNRT_ReliableUnordered,
|
||||
eNRT_UnreliableOrdered,
|
||||
eNRT_UnreliableUnordered,
|
||||
// Must be last.
|
||||
eNRT_NumReliabilityTypes
|
||||
};
|
||||
|
||||
// Description:
|
||||
// Implementation of CContextView relies on the first two values being
|
||||
// as they are.
|
||||
enum ERMIAttachmentType
|
||||
{
|
||||
eRAT_PreAttach = 0,
|
||||
eRAT_PostAttach = 1,
|
||||
eRAT_NoAttach,
|
||||
|
||||
// Must be last.
|
||||
eRAT_NumAttachmentTypes
|
||||
};
|
||||
|
||||
struct SNetworkPerformance
|
||||
{
|
||||
uint64 m_nNetworkSync;
|
||||
float m_threadTime;
|
||||
};
|
||||
|
||||
enum ENetworkGameSync
|
||||
{
|
||||
eNGS_FrameStart = 0,
|
||||
eNGS_FrameEnd,
|
||||
eNGS_Shutdown_Clear,
|
||||
eNGS_Shutdown,
|
||||
eNGS_MinimalUpdateForLoading, // Internal use - workaround for sync loading problems
|
||||
eNGS_AllowMinimalUpdate,
|
||||
eNGS_DenyMinimalUpdate,
|
||||
// must be last
|
||||
eNGS_NUM_ITEMS
|
||||
};
|
||||
|
||||
#define STATS_MAX_MESSAGEQUEUE_ACCOUNTING_GROUPS (64)
|
||||
struct SAccountingGroupStats
|
||||
{
|
||||
SAccountingGroupStats()
|
||||
: m_sends(0)
|
||||
, m_bandwidthUsed(0.0f)
|
||||
, m_totalBandwidthUsed(0.0f)
|
||||
, m_priority(0)
|
||||
, m_maxLatency(0.0f)
|
||||
, m_discardLatency(0.0f)
|
||||
, m_inUse(false)
|
||||
{
|
||||
memset(m_name, 0, sizeof(m_name));
|
||||
}
|
||||
|
||||
char m_name[8];
|
||||
uint32 m_sends;
|
||||
float m_bandwidthUsed;
|
||||
float m_totalBandwidthUsed;
|
||||
uint32 m_priority;
|
||||
float m_maxLatency;
|
||||
float m_discardLatency;
|
||||
bool m_inUse;
|
||||
};
|
||||
|
||||
struct SMessageQueueStats
|
||||
{
|
||||
SMessageQueueStats()
|
||||
: m_usedPacketSize(0)
|
||||
, m_sentMessages(0)
|
||||
, m_unsentMessages(0)
|
||||
{
|
||||
}
|
||||
|
||||
SAccountingGroupStats m_accountingGroup[STATS_MAX_MESSAGEQUEUE_ACCOUNTING_GROUPS];
|
||||
uint32 m_usedPacketSize;
|
||||
uint16 m_sentMessages;
|
||||
uint16 m_unsentMessages;
|
||||
};
|
||||
|
||||
#define STATS_MAX_NUMBER_OF_CHANNELS (MAXIMUM_NUMBER_OF_CONNECTIONS + 1)
|
||||
#define STATS_MAX_NAME_SIZE (32)
|
||||
struct SNetChannelStats
|
||||
{
|
||||
SNetChannelStats()
|
||||
: m_ping(0)
|
||||
, m_pingSmoothed(0)
|
||||
, m_bandwidthInbound(0.0f)
|
||||
, m_bandwidthOutbound(0.0f)
|
||||
, m_bandwidthShares(0)
|
||||
, m_desiredPacketRate(0)
|
||||
, m_currentPacketRate(0.0f)
|
||||
, m_packetLossRate(0.0f)
|
||||
, m_maxPacketSize(0)
|
||||
, m_idealPacketSize(0)
|
||||
, m_sparePacketSize(0)
|
||||
, m_idle(false)
|
||||
, m_inUse(false)
|
||||
{
|
||||
memset(m_name, 0, sizeof(m_name));
|
||||
}
|
||||
|
||||
SMessageQueueStats m_messageQueue;
|
||||
|
||||
char m_name[STATS_MAX_NAME_SIZE];
|
||||
uint32 m_ping;
|
||||
uint32 m_pingSmoothed;
|
||||
float m_bandwidthInbound;
|
||||
float m_bandwidthOutbound;
|
||||
uint32 m_bandwidthShares;
|
||||
uint32 m_desiredPacketRate;
|
||||
float m_currentPacketRate;
|
||||
float m_packetLossRate;
|
||||
uint32 m_maxPacketSize;
|
||||
uint32 m_idealPacketSize;
|
||||
uint32 m_sparePacketSize;
|
||||
bool m_idle;
|
||||
bool m_inUse;
|
||||
};
|
||||
|
||||
struct SBandwidthStatsSubset
|
||||
{
|
||||
SBandwidthStatsSubset()
|
||||
: m_totalBandwidthSent(0)
|
||||
, m_lobbyBandwidthSent(0)
|
||||
, m_fragmentBandwidthSent(0)
|
||||
, m_aspectPayloadBitsSent(0)
|
||||
, m_rmiPayloadBitsSent(0)
|
||||
, m_totalBandwidthRecvd(0)
|
||||
, m_totalPacketsSent(0)
|
||||
, m_totalPacketsDropped(0)
|
||||
, m_lobbyPacketsSent(0)
|
||||
, m_fragmentPacketsSent(0)
|
||||
, m_totalPacketsRecvd(0)
|
||||
{
|
||||
}
|
||||
|
||||
uint64 m_totalBandwidthSent;
|
||||
uint64 m_lobbyBandwidthSent;
|
||||
uint64 m_fragmentBandwidthSent;
|
||||
uint64 m_aspectPayloadBitsSent;
|
||||
uint64 m_rmiPayloadBitsSent;
|
||||
uint64 m_totalBandwidthRecvd;
|
||||
int m_totalPacketsSent;
|
||||
uint64 m_totalPacketsDropped;
|
||||
int m_lobbyPacketsSent;
|
||||
int m_fragmentPacketsSent;
|
||||
int m_totalPacketsRecvd;
|
||||
};
|
||||
|
||||
struct SBandwidthStats
|
||||
{
|
||||
SBandwidthStats()
|
||||
: m_total()
|
||||
, m_prev()
|
||||
, m_1secAvg()
|
||||
, m_10secAvg()
|
||||
{
|
||||
}
|
||||
|
||||
SBandwidthStatsSubset TickDelta()
|
||||
{
|
||||
SBandwidthStatsSubset ret;
|
||||
ret.m_totalBandwidthSent = m_total.m_totalBandwidthSent - m_prev.m_totalBandwidthSent;
|
||||
ret.m_lobbyBandwidthSent = m_total.m_lobbyBandwidthSent - m_prev.m_lobbyBandwidthSent;
|
||||
ret.m_fragmentBandwidthSent = m_total.m_fragmentBandwidthSent - m_prev.m_fragmentBandwidthSent;
|
||||
ret.m_aspectPayloadBitsSent = m_total.m_aspectPayloadBitsSent - m_prev.m_aspectPayloadBitsSent;
|
||||
ret.m_rmiPayloadBitsSent = m_total.m_rmiPayloadBitsSent - m_prev.m_rmiPayloadBitsSent;
|
||||
|
||||
ret.m_totalBandwidthRecvd = m_total.m_totalBandwidthRecvd - m_prev.m_totalBandwidthRecvd;
|
||||
ret.m_totalPacketsSent = m_total.m_totalPacketsSent - m_prev.m_totalPacketsSent;
|
||||
ret.m_lobbyPacketsSent = m_total.m_lobbyPacketsSent - m_prev.m_lobbyPacketsSent;
|
||||
ret.m_fragmentPacketsSent = m_total.m_fragmentPacketsSent - m_prev.m_fragmentPacketsSent;
|
||||
ret.m_totalPacketsRecvd = m_total.m_totalPacketsRecvd - m_prev.m_totalPacketsRecvd;
|
||||
|
||||
ret.m_totalPacketsDropped = m_total.m_totalPacketsDropped - m_prev.m_totalPacketsDropped;
|
||||
return ret;
|
||||
}
|
||||
|
||||
SBandwidthStatsSubset m_total;
|
||||
SBandwidthStatsSubset m_prev;
|
||||
SBandwidthStatsSubset m_1secAvg;
|
||||
SBandwidthStatsSubset m_10secAvg;
|
||||
|
||||
SNetChannelStats m_channel[STATS_MAX_NUMBER_OF_CHANNELS];
|
||||
uint32 m_numChannels;
|
||||
};
|
||||
|
||||
struct SProfileInfoStat
|
||||
{
|
||||
SProfileInfoStat()
|
||||
: m_name("")
|
||||
, m_totalBits(0)
|
||||
, m_calls(0)
|
||||
, m_rmi(false)
|
||||
{
|
||||
}
|
||||
|
||||
string m_name;
|
||||
uint32 m_totalBits;
|
||||
uint32 m_calls;
|
||||
bool m_rmi;
|
||||
};
|
||||
|
||||
typedef DynArray<SProfileInfoStat> ProfileLeafList;
|
||||
|
||||
struct SNetworkProfilingStats
|
||||
{
|
||||
SNetworkProfilingStats()
|
||||
: m_ProfileInfoStats()
|
||||
, m_numBoundObjects(0)
|
||||
, m_maxBoundObjects(0)
|
||||
{
|
||||
}
|
||||
|
||||
ProfileLeafList m_ProfileInfoStats;
|
||||
uint m_numBoundObjects;
|
||||
uint m_maxBoundObjects;
|
||||
};
|
||||
|
||||
enum EDisconnectionCause
|
||||
{
|
||||
// This cause must be first! - timeout occurred.
|
||||
eDC_Timeout = 0,
|
||||
// Incompatible protocols.
|
||||
eDC_ProtocolError,
|
||||
// Failed to resolve an address.
|
||||
eDC_ResolveFailed,
|
||||
// Versions mismatch.
|
||||
eDC_VersionMismatch,
|
||||
// Server is full.
|
||||
eDC_ServerFull,
|
||||
// User initiated kick.
|
||||
eDC_Kicked,
|
||||
// Teamkill ban/ admin ban.
|
||||
eDC_Banned,
|
||||
// Context database mismatch.
|
||||
eDC_ContextCorruption,
|
||||
// Password mismatch, cdkey bad, etc.
|
||||
eDC_AuthenticationFailed,
|
||||
// Misc. game error.
|
||||
eDC_GameError,
|
||||
// DX11 not found.
|
||||
eDC_NotDX11Capable,
|
||||
// The nub has been destroyed.
|
||||
eDC_NubDestroyed,
|
||||
// Icmp reported error.
|
||||
eDC_ICMPError,
|
||||
// NAT negotiation error.
|
||||
eDC_NatNegError,
|
||||
// Demo playback finished.
|
||||
eDC_DemoPlaybackFinished,
|
||||
// Demo playback file not found.
|
||||
eDC_DemoPlaybackFileNotFound,
|
||||
// User decided to stop playing.
|
||||
eDC_UserRequested,
|
||||
// User should have controller connected.
|
||||
eDC_NoController,
|
||||
// Unable to connect to server.
|
||||
eDC_CantConnect,
|
||||
// Arbitration failed in a live arbitrated session.
|
||||
eDC_ArbitrationFailed,
|
||||
// Failed to successfully join migrated game
|
||||
eDC_FailedToMigrateToNewHost,
|
||||
// The session has just been deleted
|
||||
eDC_SessionDeleted,
|
||||
// Kicked due to having a high ping
|
||||
eDC_KickedHighPing,
|
||||
// Kicked due to reserved user joining
|
||||
eDC_KickedReservedUser,
|
||||
// Class registry mismatch
|
||||
eDC_ClassRegistryMismatch,
|
||||
// Global ban
|
||||
eDC_GloballyBanned,
|
||||
// Global ban stage 1 messaging
|
||||
eDC_Global_Ban1,
|
||||
// Global ban stage 2 messaging
|
||||
eDC_Global_Ban2,
|
||||
// This cause must be last! - unknown cause.
|
||||
eDC_Unknown
|
||||
};
|
||||
|
||||
enum EAspectFlags
|
||||
{
|
||||
// aspect will not be sent to clients that don't control the entity
|
||||
eAF_ServerControllerOnly = 0x04,
|
||||
// aspect is serialized without using compression manager (useful for data that is allready well quantised/compressed)
|
||||
eAF_NoCompression = 0x08,
|
||||
// aspect can be client controlled (delegated to the client)
|
||||
eAF_Delegatable = 0x10,
|
||||
// aspect has more than one profile (serialization format)
|
||||
eAF_ServerManagedProfile = 0x20,
|
||||
// client should periodically send a hash of what it thinks the current state of an aspect is
|
||||
// this hash is compared to the server hash and forces a server update if there's a mismatch
|
||||
eAF_HashState = 0x40,
|
||||
// aspect needs a timestamp to make sense (i.e. physics)
|
||||
eAF_TimestampState = 0x80,
|
||||
};
|
||||
|
||||
/*!
|
||||
* Crytek RMI representation. RMI declaration/impl macros subclass this, allowing
|
||||
* the network layer to callback for param serialization and invocation.
|
||||
* The derived classes are created statically by RMI impl macros, and assigned a
|
||||
* unique Id for lookup on the receiving end.
|
||||
*/
|
||||
class IRMIRep
|
||||
{
|
||||
public:
|
||||
|
||||
IRMIRep()
|
||||
: m_uniqueId(0) {}
|
||||
virtual ~IRMIRep() {}
|
||||
virtual const char* GetDebugName() const = 0;
|
||||
virtual void SerializeParamsToBuffer(TSerialize ser, void* params) = 0;
|
||||
virtual void* SerializeParamsFromBuffer(TSerialize ser) = 0;
|
||||
virtual bool IsServerRMI() const = 0;
|
||||
|
||||
void SetUniqueId(uint32 uniqueId) { m_uniqueId = uniqueId; }
|
||||
uint32 GetUniqueId() const { return m_uniqueId; }
|
||||
|
||||
bool operator == (const size_t compareId) const
|
||||
{
|
||||
return GetUniqueId() == compareId;
|
||||
}
|
||||
|
||||
private:
|
||||
|
||||
uint32 m_uniqueId;
|
||||
};
|
||||
|
||||
/*!
|
||||
* Actor (GameCore) RMI representation. RMI declaration/impl macros subclass this,
|
||||
* allowing the network layer to callback for param serialization and invocation.
|
||||
* A unique ID is also maintained to enable lookup on the receiving end. IDs are
|
||||
* assigned when the rep is 'registered' via RegisterActorRMI().
|
||||
*/
|
||||
class IActorRMIRep
|
||||
{
|
||||
public:
|
||||
|
||||
IActorRMIRep()
|
||||
: m_uniqueId(0) {}
|
||||
virtual ~IActorRMIRep() {}
|
||||
|
||||
virtual uint32 GetReliability() const = 0;
|
||||
virtual uint32 GetWhere() const = 0;
|
||||
virtual void SerializeParams(TSerialize ser) = 0;
|
||||
virtual void Invoke(EntityId entityId, uint8 actorExtensionId) = 0;
|
||||
virtual const char* GetDebugName() const = 0;
|
||||
|
||||
void SetUniqueId(uint32 uniqueId) { m_uniqueId = uniqueId; }
|
||||
uint32 GetUniqueId() const { return m_uniqueId; }
|
||||
|
||||
bool operator == (const size_t compareId) const
|
||||
{
|
||||
return GetUniqueId() == compareId;
|
||||
}
|
||||
|
||||
bool operator < (const size_t compareId) const
|
||||
{
|
||||
return GetUniqueId() <= compareId;
|
||||
}
|
||||
|
||||
private:
|
||||
|
||||
uint32 m_uniqueId;
|
||||
};
|
||||
|
||||
// GridMate forwards
|
||||
namespace GridMate
|
||||
{
|
||||
class IGridMate;
|
||||
class Replica;
|
||||
class GridSearch;
|
||||
class GridMember;
|
||||
class GridSession;
|
||||
struct SessionParams;
|
||||
struct SearchInfo;
|
||||
struct InviteInfo;
|
||||
struct SearchParams;
|
||||
struct CarrierDesc;
|
||||
} // namespace GridMate
|
||||
|
||||
struct INetwork
|
||||
{
|
||||
public:
|
||||
// Description:
|
||||
// Releases the interface (and delete the object that implements it).
|
||||
virtual void Release() = 0;
|
||||
|
||||
// Description:
|
||||
// Gathers memory statistics for the network module.
|
||||
virtual void GetMemoryStatistics(ICrySizer* pSizer) = 0;
|
||||
|
||||
// Description:
|
||||
// Gets the socket level bandwidth statistics
|
||||
virtual void GetBandwidthStatistics(SBandwidthStats* const pStats) = 0;
|
||||
|
||||
// Description:
|
||||
// Gathers performance statistics for the network module.
|
||||
virtual void GetPerformanceStatistics(SNetworkPerformance* pSizer) = 0;
|
||||
|
||||
// Description:
|
||||
// Gets debug and profiling statistics from network members
|
||||
virtual void GetProfilingStatistics(SNetworkProfilingStats* const pStats) = 0;
|
||||
|
||||
// Description:
|
||||
// Updates all nubs and contexts.
|
||||
// Arguments:
|
||||
// blocking - time to block for network input (zero to not block).
|
||||
virtual void SyncWithGame(ENetworkGameSync syncType) = 0;
|
||||
|
||||
// Description:
|
||||
// Gets the local host name.
|
||||
virtual const char* GetHostName() = 0;
|
||||
|
||||
|
||||
// New
|
||||
virtual GridMate::IGridMate* GetGridMate() = 0;
|
||||
|
||||
virtual ChannelId GetChannelIdForSessionMember(GridMate::GridMember* member) const = 0;
|
||||
virtual ChannelId GetServerChannelId() const = 0;
|
||||
virtual ChannelId GetLocalChannelId() const = 0;
|
||||
|
||||
//! Gets the synchronized network time as milliseconds since session creation time.
|
||||
virtual CTimeValue GetSessionTime() = 0;
|
||||
|
||||
virtual void ChangedAspects(EntityId id, NetworkAspectType aspectBits) = 0;
|
||||
|
||||
//////// Client-delegatable aspect shim.
|
||||
//! Sets mask describing which aspects are globally delegatable.
|
||||
virtual void SetDelegatableAspectMask(NetworkAspectType aspectBits) = 0;
|
||||
//! Sets mask on a given obejct describing which aspect that object has delegated to the controlling client.
|
||||
virtual void SetObjectDelegatedAspectMask(EntityId entityId, NetworkAspectType aspects, bool set) = 0;
|
||||
//! Request authority for entityId be delegated to client at clientChannelId.
|
||||
virtual void DelegateAuthorityToClient(EntityId entityId, ChannelId clientChannelId) = 0;
|
||||
////////
|
||||
|
||||
virtual void InvokeActorRMI(EntityId entityId, uint8 actorExtensionId, ChannelId targetChannelFilter, IActorRMIRep& rep) = 0;
|
||||
|
||||
virtual void InvokeScriptRMI(ISerializable* serializable, bool isServerRMI, ChannelId toChannelId = kInvalidChannelId, ChannelId avoidChannelId = kInvalidChannelId) = 0;
|
||||
|
||||
virtual void RegisterActorRMI(IActorRMIRep* rep) = 0;
|
||||
virtual void UnregisterActorRMI(IActorRMIRep* rep) = 0;
|
||||
|
||||
virtual EntityId LocalEntityIdToServerEntityId(EntityId localId) const = 0;
|
||||
virtual EntityId ServerEntityIdToLocalEntityId(EntityId serverId, bool allowForcedEstablishment = false) const = 0;
|
||||
};
|
||||
@@ -18,12 +18,12 @@
|
||||
struct IAIPathAgent;
|
||||
|
||||
#include <INavigationSystem.h>
|
||||
#include "functor.h"
|
||||
#include <IMNM.h>
|
||||
#include <ISerialize.h>
|
||||
#include <SerializeFwd.h>
|
||||
#include <Cry_Geo.h>
|
||||
|
||||
#include <AzCore/std/functional.h>
|
||||
#include <AzCore/std/smart_ptr/shared_ptr.h>
|
||||
#include <limits>
|
||||
|
||||
@@ -688,7 +688,7 @@ namespace MNM
|
||||
|
||||
struct MNMPathRequest
|
||||
{
|
||||
typedef Functor2<const MNM::QueuedPathID&, MNMPathRequestResult&> Callback;
|
||||
using Callback = AZStd::function<void(const MNM::QueuedPathID&, MNMPathRequestResult&)>;
|
||||
|
||||
MNMPathRequest()
|
||||
: resultCallback(0)
|
||||
|
||||
@@ -873,7 +873,6 @@ enum ERenderType
|
||||
eRT_Null,
|
||||
eRT_DX11,
|
||||
eRT_DX12,
|
||||
eRT_Xenia,
|
||||
eRT_Provo,
|
||||
eRT_OpenGL,
|
||||
eRT_Metal,
|
||||
|
||||
@@ -82,7 +82,7 @@ namespace RCPathUtil
|
||||
return filepathstr;
|
||||
case '.':
|
||||
// there's an extension in this file name
|
||||
filepathstr = filepathstr.substr(0, p - str);
|
||||
filepathstr.erase(p - str);
|
||||
return filepathstr;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2129,7 +2129,6 @@ struct SInputShaderResources
|
||||
#define SHGD_TEX_SUBSURFACE 0x80
|
||||
#define SHGD_HW_BILINEARFP16 0x100
|
||||
#define SHGD_HW_SEPARATEFP16 0x200
|
||||
#define SHGD_HW_DURANGO 0x400
|
||||
#define SHGD_HW_ORBIS 0x800
|
||||
#define SHGD_TEX_CUSTOM 0x1000
|
||||
#define SHGD_TEX_CUSTOM_SECONDARY 0x2000
|
||||
|
||||
@@ -165,8 +165,6 @@ struct IStreamEngineListener
|
||||
virtual void OnStreamEndIO(const void* pReq) = 0;
|
||||
virtual void OnStreamBeginInflate(const void* pReq) = 0;
|
||||
virtual void OnStreamEndInflate(const void* pReq) = 0;
|
||||
virtual void OnStreamBeginDecrypt(const void* pReq) = 0;
|
||||
virtual void OnStreamEndDecrypt(const void* pReq) = 0;
|
||||
virtual void OnStreamBeginAsyncCallback(const void* pReq) = 0;
|
||||
virtual void OnStreamEndAsyncCallback(const void* pReq) = 0;
|
||||
virtual void OnStreamDone(const void* pReq) = 0;
|
||||
|
||||
@@ -21,10 +21,6 @@
|
||||
#define STREAMENGINE_ENABLE_STATS
|
||||
#endif
|
||||
|
||||
#ifdef SUPPORT_RSA_AND_STREAMCIPHER_PAK_ENCRYPTION //Could check for INCLUDE_LIBTOMCRYPT here, but only decryption is implemented in the streaming engine, not signing
|
||||
#define STREAMENGINE_SUPPORT_DECRYPT
|
||||
#endif
|
||||
|
||||
enum : unsigned int
|
||||
{
|
||||
ERROR_UNKNOWN_ERROR = 0xF0000000,
|
||||
@@ -41,7 +37,6 @@ enum : unsigned int
|
||||
ERROR_OUT_OF_MEMORY_QUOTA = 0xF000000B,
|
||||
ERROR_ZIP_CACHE_FAILURE = 0xF000000C,
|
||||
ERROR_USER_ABORT = 0xF000000D,
|
||||
ERROR_DECRYPTION_FAIL = 0xF000000E,
|
||||
ERROR_MISSCHEDULED = 0xF000000F,
|
||||
ERROR_VERIFICATION_FAIL = 0xF0000010,
|
||||
ERROR_PREEMPTED = 0xF0000011,
|
||||
@@ -141,16 +136,13 @@ struct SStreamEngineStatistics
|
||||
uint32 nTotalRequestCount; // Number of request from reset to the streaming engine.
|
||||
uint32 nTotalStreamingRequestCount; // Number of request from reset which actually resulted in streaming data.
|
||||
|
||||
int nCurrentDecryptCount; // Number of requests currently waiting to be decrypted
|
||||
int nCurrentDecompressCount; // Number of requests currently waiting to be decompresses
|
||||
int nCurrentAsyncCount; // Number of requests currently waiting to be async callback
|
||||
int nCurrentFinishedCount; // Number of requests currently waiting to be finished by mainthread
|
||||
|
||||
uint32 nDecompressBandwidth; // Bytes/second for last second
|
||||
uint32 nDecryptBandwidth; // Bytes/second for last second
|
||||
uint32 nVerifyBandwidth; // Bytes/second for last second
|
||||
uint32 nDecompressBandwidthAverage; // Bytes/second in total.
|
||||
uint32 nDecryptBandwidthAverage; // Bytes/second in total.
|
||||
uint32 nVerifyBandwidthAverage; // Bytes/second in total.
|
||||
|
||||
bool bTempMemOutOfBudget; // Was the temporary streaming memory out of budget during the last second
|
||||
|
||||
@@ -68,11 +68,7 @@ struct IRenderer;
|
||||
struct IProcess;
|
||||
struct I3DEngine;
|
||||
struct ITimer;
|
||||
struct INetwork;
|
||||
struct IOnline;
|
||||
struct ICryLobby;
|
||||
struct ICryFont;
|
||||
class ICrypto;
|
||||
struct IMovieSystem;
|
||||
struct IMemoryManager;
|
||||
namespace Audio
|
||||
@@ -197,7 +193,6 @@ enum ESystemConfigPlatform
|
||||
CONFIG_OSX_METAL = 3,
|
||||
CONFIG_ANDROID = 4,
|
||||
CONFIG_IOS = 5,
|
||||
CONFIG_XENIA = 6,
|
||||
CONFIG_PROVO = 7,
|
||||
CONFIG_SALEM = 8,
|
||||
CONFIG_JASPER = 9,
|
||||
@@ -879,7 +874,6 @@ struct SSystemUpdateStats
|
||||
struct SSystemGlobalEnvironment
|
||||
{
|
||||
I3DEngine* p3DEngine;
|
||||
INetwork* pNetwork;
|
||||
AZ::IO::IArchive* pCryPak;
|
||||
AZ::IO::FileIOBase* pFileIO;
|
||||
IFileChangeMonitor* pFileChangeMonitor;
|
||||
@@ -1323,7 +1317,6 @@ struct ISystem
|
||||
virtual I3DEngine* GetI3DEngine() = 0;
|
||||
virtual ::IConsole* GetIConsole() = 0;
|
||||
virtual IRemoteConsole* GetIRemoteConsole() = 0;
|
||||
virtual ICrypto* GetCrypto() = 0;
|
||||
// Returns:
|
||||
// Can be NULL, because it only exists when running through the editor, not in pure game mode.
|
||||
virtual IResourceManager* GetIResourceManager() = 0;
|
||||
@@ -1341,9 +1334,6 @@ struct ISystem
|
||||
|
||||
//irtual IThreadManager* GetIThreadManager() = 0;
|
||||
|
||||
|
||||
virtual INetwork* GetINetwork() = 0;
|
||||
|
||||
virtual void SetLoadingProgressListener(ILoadingProgressListener* pListener) = 0;
|
||||
virtual ISystem::ILoadingProgressListener* GetLoadingProgressListener() const = 0;
|
||||
|
||||
|
||||
@@ -248,12 +248,6 @@ namespace CImageExtensionHelper
|
||||
const static uint32 EIF_Colormodel_YFF = 0x3000000; // info for the engine: colormodel is Y'FbFr (used for reflectance)
|
||||
const static uint32 EIF_Colormodel_IRB = 0x4000000; // info for the engine: colormodel is IRB (used for reflectance)
|
||||
|
||||
#if defined(AZ_PLATFORM_XENIA) || defined(TOOLS_SUPPORT_XENIA)
|
||||
#define AZ_RESTRICTED_SECTION IMAGEEXTENSIONHELPER_H_SECTION_CONSTS
|
||||
#include AZ_RESTRICTED_FILE_EXPLICIT(ImageExtensionHelper_h, xenia)
|
||||
#undef AZ_RESTRICTED_SECTION
|
||||
#endif
|
||||
|
||||
#if defined(AZ_PLATFORM_JASPER) || defined(TOOLS_SUPPORT_JASPER)
|
||||
#define AZ_RESTRICTED_SECTION IMAGEEXTENSIONHELPER_H_SECTION_CONSTS
|
||||
#include AZ_RESTRICTED_FILE_EXPLICIT(ImageExtensionHelper_h, jasper)
|
||||
@@ -331,10 +325,6 @@ namespace CImageExtensionHelper
|
||||
inline const bool IsImageNative(const uint32 nFlags)
|
||||
{
|
||||
return (nFlags & (0
|
||||
#if defined(AZ_PLATFORM_XENIA) || defined(TOOLS_SUPPORT_XENIA)
|
||||
#define AZ_RESTRICTED_SECTION IMAGEEXTENSIONHELPER_H_SECTION_ISNATIVE
|
||||
#include AZ_RESTRICTED_FILE_EXPLICIT(ImageExtensionHelper_h, xenia)
|
||||
#endif
|
||||
#if defined(AZ_PLATFORM_JASPER) || defined(TOOLS_SUPPORT_JASPER)
|
||||
#define AZ_RESTRICTED_SECTION IMAGEEXTENSIONHELPER_H_SECTION_ISNATIVE
|
||||
#include AZ_RESTRICTED_FILE_EXPLICIT(ImageExtensionHelper_h, jasper)
|
||||
|
||||
@@ -138,7 +138,7 @@ namespace AZ
|
||||
{
|
||||
};
|
||||
|
||||
#if defined(AZ_PLATFORM_PROVO) || defined(AZ_PLATFORM_XENIA) || defined(AZ_PLATFORM_JASPER)
|
||||
#if defined(AZ_PLATFORM_PROVO) || defined(AZ_PLATFORM_JASPER)
|
||||
struct GlobalAllocatorDescriptor
|
||||
: public AZ::HphaSchema::Descriptor
|
||||
{
|
||||
|
||||
@@ -9,8 +9,8 @@
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
*
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
#include <INetwork.h>
|
||||
|
||||
struct NetworkMock : public INetwork
|
||||
{
|
||||
|
||||
@@ -132,8 +132,6 @@ public:
|
||||
::IConsole * ());
|
||||
MOCK_METHOD0(GetIRemoteConsole,
|
||||
IRemoteConsole * ());
|
||||
MOCK_METHOD0(GetCrypto,
|
||||
ICrypto * ());
|
||||
MOCK_METHOD0(GetIResourceManager,
|
||||
IResourceManager * ());
|
||||
MOCK_METHOD0(GetIThreadTaskManager,
|
||||
@@ -154,8 +152,6 @@ public:
|
||||
ITimer * ());
|
||||
MOCK_METHOD0(GetIThreadManager,
|
||||
IThreadManager * ());
|
||||
MOCK_METHOD0(GetINetwork,
|
||||
INetwork * ());
|
||||
MOCK_METHOD1(SetLoadingProgressListener,
|
||||
void(ILoadingProgressListener * pListener));
|
||||
MOCK_CONST_METHOD0(GetLoadingProgressListener,
|
||||
|
||||
@@ -293,15 +293,13 @@ public:
|
||||
{
|
||||
return AZStd::string{ path.substr(0, path.size() - 1) } + AZ_CORRECT_DATABASE_SEPARATOR;
|
||||
}
|
||||
|
||||
return path.empty() ? AZStd::string(path) : AZStd::string(path) + AZ_CORRECT_DATABASE_SEPARATOR;
|
||||
};
|
||||
|
||||
AZStd::string dir;
|
||||
AZ::StringFunc::Path::Join(root.c_str(), pathIn.c_str(), dir);
|
||||
dir = AddSlash(dir);
|
||||
|
||||
ScanDirectoryFiles(pIPak, root, pathIn, fileSpec, files);
|
||||
ScanDirectoryFiles(pIPak, "", dir, fileSpec, files);
|
||||
|
||||
AZStd::string findFilter;
|
||||
AZ::StringFunc::Path::Join(dir.c_str(), "*", findFilter);
|
||||
@@ -353,9 +351,13 @@ private:
|
||||
{
|
||||
continue;
|
||||
}
|
||||
files.push_back(path + AZStd::string(pakFileIterator.m_filename));
|
||||
AZStd::string fullPath;
|
||||
AZ::StringFunc::Path::Join(path.c_str(), AZStd::string(pakFileIterator.m_filename).c_str(), fullPath);
|
||||
files.push_back(fullPath);
|
||||
} while (pakFileIterator = pIPak->FindNext(pakFileIterator));
|
||||
pIPak->FindClose(pakFileIterator);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
};
|
||||
|
||||
@@ -118,8 +118,6 @@ typedef uint32 vtx_idx;
|
||||
#define AZ_LEGACY_CRYCOMMON_TRAIT_USE_PTHREADS 1
|
||||
#define AZ_LEGACY_CRYCOMMON_TRAIT_USE_UNIX_PATHS 1
|
||||
#endif
|
||||
#define SUPPORT_RSA_AND_STREAMCIPHER_PAK_ENCRYPTION //C3/Warface Style - By Timur Davidenko and integrated by Rob Jessop
|
||||
#define SUPPORT_RSA_PAK_SIGNING //RSA signature verification
|
||||
#endif
|
||||
|
||||
#define USE_GLOBAL_BUCKET_ALLOCATOR
|
||||
@@ -302,46 +300,11 @@ typedef uint32 vtx_idx;
|
||||
#error "SoftCode currently relies on CryMemoryManager being enabled. Either build without SoftCode support, or enable CryMemoryManager."
|
||||
#endif
|
||||
|
||||
//Encryption & security defines
|
||||
|
||||
//Defines for various encryption methodologies that we support (or did support at some stage)
|
||||
#define SUPPORT_UNENCRYPTED_PAKS //Enable during dev and on consoles to support paks that aren't encrypted in any way
|
||||
#if defined(_RELEASE) // Require signing (at least)
|
||||
#define SUPPORT_UNSIGNED_PAKS //Enabled during dev to test release builds easier (remove this to enforce signed paks in release builds)
|
||||
#endif
|
||||
|
||||
//#define SUPPORT_XTEA_PAK_ENCRYPTION //C2 Style. Compromised - do not use
|
||||
//#define SUPPORT_STREAMCIPHER_PAK_ENCRYPTION //C2 DLC Style - by Mark Tully
|
||||
#if !defined(_RELEASE) || defined(PERFORMANCE_BUILD)
|
||||
#define SUPPORT_UNSIGNED_PAKS //Enable to load paks that aren't RSA signed
|
||||
#endif //!_RELEASE || PERFORMANCE_BUILD
|
||||
|
||||
#if PROJECTDEFINES_H_TRAIT_USE_GPU_PARTICLES && !defined(NULL_RENDERER)
|
||||
#define GPU_PARTICLES 1
|
||||
#else
|
||||
#define GPU_PARTICLES 0
|
||||
#endif
|
||||
|
||||
#if defined(SUPPORT_RSA_AND_STREAMCIPHER_PAK_ENCRYPTION) || defined(SUPPORT_RSA_PAK_SIGNING)
|
||||
//Use LibTomMath and LibTomCrypt for cryptography
|
||||
#define INCLUDE_LIBTOMCRYPT
|
||||
#endif
|
||||
|
||||
//This enables checking of CRCs on archived files when they are loaded fully and synchronously in CryPak.
|
||||
//Computes a CRC of the decompressed data and compares it to the CRC stored in the archive CDR for that file.
|
||||
//Files with CRC mismatches will return Z_ERROR_CORRUPT.
|
||||
#define VERIFY_PAK_ENTRY_CRC
|
||||
|
||||
//#define CHECK_CRC_ONLY_ONCE //Do NOT enable this if using SUPPORT_RSA_AND_STREAMCIPHER_PAK_ENCRYPTION - it will break subsequent decryption attempts for a file as it nulls the stored CRC32
|
||||
|
||||
#if 0 // Enable when clear on which platforms we want this check
|
||||
//On consoles we can trust files that have been loaded from optical drives
|
||||
#define SKIP_CHECKSUM_FROM_OPTICAL_MEDIA
|
||||
#endif // 0
|
||||
|
||||
//End of encryption & security defines
|
||||
|
||||
#define EXPOSE_D3DDEVICE
|
||||
|
||||
// The maximum number of joints in an animation
|
||||
#define MAX_JOINT_AMOUNT 1024
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
|
||||
#include <SmartPointersHelpers.h>
|
||||
#include <Serialization/IArchive.h>
|
||||
#include <functor.h>
|
||||
#include <AzCore/std/functional.h>
|
||||
|
||||
namespace Serialization
|
||||
{
|
||||
@@ -32,7 +32,7 @@ namespace Serialization
|
||||
virtual IActionButtonPtr Clone() const = 0;
|
||||
};
|
||||
|
||||
typedef Functor0 FunctorActionButtonCallback;
|
||||
typedef AZStd::function<void()> FunctorActionButtonCallback;
|
||||
|
||||
struct FunctorActionButton
|
||||
: public IActionButton
|
||||
|
||||
@@ -24,7 +24,6 @@ set(FILES
|
||||
IColorGradingController.h
|
||||
IConsole.h
|
||||
ICryMiniGUI.h
|
||||
ICrypto.h
|
||||
IDeferredCollisionEvent.h
|
||||
IDefragAllocator.h
|
||||
IEngineModule.h
|
||||
@@ -54,7 +53,6 @@ set(FILES
|
||||
IMeshBaking.h
|
||||
IMiniLog.h
|
||||
IMovieSystem.h
|
||||
INetwork.h
|
||||
INotificationNetwork.h
|
||||
IOverloadSceneManager.h
|
||||
IPerfHud.h
|
||||
@@ -171,7 +169,6 @@ set(FILES
|
||||
CryVersion.h
|
||||
CryZlib.h
|
||||
FrameProfiler.h
|
||||
functor.h
|
||||
GeomCacheFileFormat.h
|
||||
HashGrid.h
|
||||
HeapAllocator.h
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user