Added OTHER_RECT struct

Unifies the weird not-RECTs
This commit is contained in:
Clownacy 2020-07-08 19:30:11 +01:00
parent bfc255478c
commit f7a8a260a4
4 changed files with 19 additions and 42 deletions

View file

@ -2,6 +2,8 @@
#include "WindowsWrapper.h"
#include "CommonDefines.h"
#define BULLET_MAX 0x40
typedef struct BULLET
@ -31,13 +33,7 @@ typedef struct BULLET
int enemyYL;
int blockXL;
int blockYL;
struct
{
int front;
int top;
int back;
int bottom;
} view;
OTHER_RECT view;
} BULLET;
typedef struct BULLET_TABLE
@ -50,13 +46,7 @@ typedef struct BULLET_TABLE
int enemyYL;
int blockXL;
int blockYL;
struct
{
int front;
int top;
int back;
int bottom;
} view;
OTHER_RECT view;
} BULLET_TABLE;
extern BULLET gBul[BULLET_MAX];

View file

@ -20,3 +20,11 @@ enum Direction
DIR_DOWN = 3,
DIR_AUTO = 4
};
struct OTHER_RECT // The original name for this struct is unknown
{
int front;
int top;
int back;
int bottom;
};

View file

@ -2,6 +2,8 @@
#include "WindowsWrapper.h"
#include "CommonDefines.h"
// TODO - When I add bitmask constants for gMC.flags...
// 0x100 is a 'player is underwater' flag
@ -38,20 +40,8 @@ typedef struct MYCHAR
int ym;
int ani_wait;
int ani_no;
struct
{
int front;
int top;
int back;
int bottom;
} hit;
struct
{
int front;
int top;
int back;
int bottom;
} view;
OTHER_RECT hit;
OTHER_RECT view;
RECT rect;
RECT rect_arms;
int level;

View file

@ -2,6 +2,7 @@
#include "WindowsWrapper.h"
#include "CommonDefines.h"
#include "Draw.h"
#define NPC_MAX 0x200
@ -81,20 +82,8 @@ typedef struct NPCHAR
int count2;
int act_no;
int act_wait;
struct
{
int front;
int top;
int back;
int bottom;
} hit;
struct
{
int front;
int top;
int back;
int bottom;
} view;
OTHER_RECT hit;
OTHER_RECT view;
unsigned char shock;
int damage_view;
int damage;