| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
#ifndef __smokestack__ |
| 18 |
#define __smokestack__ |
| 19 |
|
| 20 |
#include "mobref.h" |
| 21 |
|
| 22 |
class SRAMSTREAM; |
| 23 |
|
| 24 |
|
| 25 |
|
| 26 |
|
| 27 |
class SMOKEITEM |
| 28 |
{ |
| 29 |
public: |
| 30 |
SMOKEITEM(); |
| 31 |
~SMOKEITEM(); |
| 32 |
|
| 33 |
|
| 34 |
SMOKEITEM(const SMOKEITEM &smoke); |
| 35 |
SMOKEITEM &operator=(const SMOKEITEM &smoke); |
| 36 |
|
| 37 |
|
| 38 |
void setPosition(int x, int y); |
| 39 |
void setData(SMOKE_NAMES smoke, MOB *owner); |
| 40 |
|
| 41 |
bool isPosition(int x, int y) const; |
| 42 |
void getPosition(int &x, int &y) const; |
| 43 |
void getData(SMOKE_NAMES &smoke, MOB **owner = 0) const; |
| 44 |
|
| 45 |
void save(SRAMSTREAM &os) const; |
| 46 |
void load(SRAMSTREAM &is); |
| 47 |
|
| 48 |
private: |
| 49 |
u16 myPosSmoke; |
| 50 |
MOBREF myOwner; |
| 51 |
}; |
| 52 |
|
| 53 |
class SMOKESTACK |
| 54 |
{ |
| 55 |
public: |
| 56 |
SMOKESTACK(); |
| 57 |
~SMOKESTACK(); |
| 58 |
|
| 59 |
|
| 60 |
|
| 61 |
|
| 62 |
void set(int x, int y, SMOKE_NAMES smoke, MOB *owner); |
| 63 |
|
| 64 |
|
| 65 |
SMOKE_NAMES get(int x, int y, MOB **owner = 0) const; |
| 66 |
|
| 67 |
|
| 68 |
|
| 69 |
int entries() const { return myEntries; } |
| 70 |
|
| 71 |
|
| 72 |
|
| 73 |
void collapse(); |
| 74 |
|
| 75 |
|
| 76 |
void getEntry(int idx, SMOKE_NAMES &smoke, MOB **owner = 0); |
| 77 |
|
| 78 |
void save(SRAMSTREAM &os); |
| 79 |
void load(SRAMSTREAM &is); |
| 80 |
|
| 81 |
private: |
| 82 |
u16 myEntries; |
| 83 |
u16 mySize; |
| 84 |
|
| 85 |
SMOKEITEM *mySmoke; |
| 86 |
}; |
| 87 |
|
| 88 |
#endif |
| 89 |
|