|
|
@ -46,8 +46,8 @@ You can contact Cyan Worlds, Inc. by email legal@cyan.com |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/************************** Other Includes *****************************/ |
|
|
|
/************************** Other Includes *****************************/ |
|
|
|
#include <stdlib.h> |
|
|
|
#include <cstdlib> |
|
|
|
#include <stdio.h> |
|
|
|
#include <cstdio> |
|
|
|
|
|
|
|
|
|
|
|
#if HS_CAN_USE_FLOAT |
|
|
|
#if HS_CAN_USE_FLOAT |
|
|
|
#include <math.h> |
|
|
|
#include <math.h> |
|
|
@ -64,16 +64,24 @@ You can contact Cyan Worlds, Inc. by email legal@cyan.com |
|
|
|
|
|
|
|
|
|
|
|
/************************** Basic Types *****************************/ |
|
|
|
/************************** Basic Types *****************************/ |
|
|
|
|
|
|
|
|
|
|
|
typedef unsigned char byte; |
|
|
|
|
|
|
|
typedef unsigned short word; |
|
|
|
|
|
|
|
typedef unsigned long dword; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#ifdef _MSC_VER |
|
|
|
#ifdef _MSC_VER |
|
|
|
typedef unsigned __int64 qword; |
|
|
|
typedef signed __int8 int8_t; |
|
|
|
|
|
|
|
typedef unsigned __int8 uint8_t; |
|
|
|
|
|
|
|
typedef signed __int16 int16_t; |
|
|
|
|
|
|
|
typedef unsigned __int16 uint16_t; |
|
|
|
|
|
|
|
typedef signed __int32 int32_t; |
|
|
|
|
|
|
|
typedef unsigned __int32 uint32_t; |
|
|
|
|
|
|
|
typedef signed __int64 int64_t; |
|
|
|
|
|
|
|
typedef unsigned __int64 uint64_t; |
|
|
|
#else |
|
|
|
#else |
|
|
|
typedef unsigned long long qword; |
|
|
|
#include <cstdint> |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
typedef uint8_t byte; |
|
|
|
|
|
|
|
typedef uint16_t word; |
|
|
|
|
|
|
|
typedef uint32_t dword; |
|
|
|
|
|
|
|
typedef uint64_t qword; |
|
|
|
|
|
|
|
|
|
|
|
typedef size_t unsigned_ptr; |
|
|
|
typedef size_t unsigned_ptr; |
|
|
|
|
|
|
|
|
|
|
|
typedef wchar_t wchar; |
|
|
|
typedef wchar_t wchar; |
|
|
@ -84,26 +92,18 @@ typedef wchar_t wchar; |
|
|
|
#define kPosInfinity32 (0x7fffffff) |
|
|
|
#define kPosInfinity32 (0x7fffffff) |
|
|
|
#define kNegInfinity32 (0x80000000) |
|
|
|
#define kNegInfinity32 (0x80000000) |
|
|
|
|
|
|
|
|
|
|
|
#if HS_BUILD_FOR_PS2 |
|
|
|
typedef int8_t Int8; |
|
|
|
typedef int Int32; |
|
|
|
typedef int16_t Int16; |
|
|
|
#else |
|
|
|
typedef int32_t Int32; |
|
|
|
typedef long Int32; |
|
|
|
typedef int64_t Int64; |
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
typedef short Int16; |
|
|
|
|
|
|
|
typedef signed char Int8; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#if !(HS_BUILD_FOR_MAC) |
|
|
|
typedef uint8_t UInt8; |
|
|
|
typedef unsigned char UInt8; |
|
|
|
typedef uint16_t UInt16; |
|
|
|
typedef unsigned short UInt16; |
|
|
|
typedef uint32_t UInt32; |
|
|
|
#if HS_BUILD_FOR_PS2 |
|
|
|
typedef uint64_t UInt64; |
|
|
|
typedef unsigned int UInt32; |
|
|
|
|
|
|
|
#else |
|
|
|
|
|
|
|
typedef unsigned long UInt32; |
|
|
|
|
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#ifndef Byte |
|
|
|
#ifndef Byte |
|
|
|
typedef UInt8 Byte; |
|
|
|
typedef uint8_t Byte; |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
#ifndef false |
|
|
|
#ifndef false |
|
|
@ -113,21 +113,9 @@ typedef signed char Int8; |
|
|
|
#define true 1 |
|
|
|
#define true 1 |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
#ifndef Boolean |
|
|
|
#ifndef Boolean |
|
|
|
#if HS_BUILD_FOR_UNIX |
|
|
|
typedef uint8_t Boolean; |
|
|
|
typedef char Boolean; |
|
|
|
|
|
|
|
#else |
|
|
|
|
|
|
|
typedef UInt8 Boolean; |
|
|
|
|
|
|
|
#endif |
|
|
|
|
|
|
|
#endif |
|
|
|
|
|
|
|
#endif |
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
#if HS_BUILD_FOR_WIN32 |
|
|
|
|
|
|
|
typedef __int64 Int64; |
|
|
|
|
|
|
|
typedef unsigned __int64 UInt64; |
|
|
|
|
|
|
|
#else |
|
|
|
|
|
|
|
typedef long long Int64; |
|
|
|
|
|
|
|
typedef unsigned long long UInt64; |
|
|
|
|
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
typedef Int32 hsFixed; |
|
|
|
typedef Int32 hsFixed; |
|
|
|
typedef Int32 hsFract; |
|
|
|
typedef Int32 hsFract; |
|
|
|