More refactoring. The code is ALMOST able to compile now – all three programs together give a mere 25 errors.
git-svn-id: http://openexile.googlecode.com/svn/trunk@31 4ebdad44-0ea0-11de-aab3-ff745001d230
This commit is contained in:
64
osx/regtown.h
Normal file
64
osx/regtown.h
Normal file
@@ -0,0 +1,64 @@
|
||||
/*
|
||||
* regtown.h
|
||||
* BoE
|
||||
*
|
||||
* Created by Celtic Minstrel on 24/04/09.
|
||||
*
|
||||
*/
|
||||
|
||||
namespace legacy {
|
||||
struct big_tr_type;
|
||||
struct ave_tr_type;
|
||||
struct tiny_tr_type;
|
||||
};
|
||||
|
||||
class cBigTown : public cTown { // formerly big_tr_type
|
||||
unsigned char _terrain[64][64];
|
||||
rectangle _room_rect[16];
|
||||
cCreature _creatures[60];
|
||||
unsigned char _lighting[8][64];
|
||||
public:
|
||||
void append(legacy::big_tr_type& old);
|
||||
unsigned char& terrain(size_t x, size_t y);
|
||||
rectangle& room_rect(size_t i);
|
||||
cCreature& creatures(size_t i);
|
||||
unsigned char& lighting(size_t i, size_t r);
|
||||
short max_dim();
|
||||
short max_monst();
|
||||
|
||||
cBigTown();
|
||||
};
|
||||
|
||||
class cMedTown : public cTown { // formerly ave_tr_type
|
||||
unsigned char _terrain[48][48];
|
||||
rectangle _room_rect[16];
|
||||
cCreature _creatures[40];
|
||||
unsigned char _lighting[6][48];
|
||||
public:
|
||||
void append(legacy::ave_tr_type& old);
|
||||
unsigned char& terrain(size_t x, size_t y);
|
||||
rectangle& room_rect(size_t i);
|
||||
cCreature& creatures(size_t i);
|
||||
unsigned char& lighting(size_t i, size_t r);
|
||||
short max_dim();
|
||||
short max_monst();
|
||||
|
||||
cMedTown();
|
||||
};
|
||||
|
||||
class cTinyTown : public cTown { // formerly tiny_tr_type
|
||||
unsigned char _terrain[32][32];
|
||||
rectangle _room_rect[16];
|
||||
cCreature _creatures[30];
|
||||
unsigned char _lighting[4][32];
|
||||
public:
|
||||
void append(legacy::tiny_tr_type& old);
|
||||
unsigned char& terrain(size_t x, size_t y);
|
||||
rectangle& room_rect(size_t i);
|
||||
cCreature& creatures(size_t i);
|
||||
unsigned char& lighting(size_t i, size_t r);
|
||||
short max_dim();
|
||||
short max_monst();
|
||||
|
||||
cTinyTown();
|
||||
};
|
||||
Reference in New Issue
Block a user