Move entityclass::setenemyroom() to entclass::setenemyroom()

This moves the setenemyroom() function onto the entity object itself, so
I can more easily change all 'entities[k].' to 'entity.' in
entityclass::createentity() later.

Additionally, I've had to move the rn() macro from Entity.h to Ent.h, or
else entclass::setenemyroom() won't know what it is.
This commit is contained in:
Misa authored and Ethan Lee committed 2020-04-03 23:28:47 -04:00
1 parent d4cffed176
commit f5a84d7972
4 files changed
+352 -352

No files matched your search

+4
View File
@@ -1,6 +1,8 @@
#ifndef ENT_H
#define ENT_H
#define rn( rx, ry) ((rx) + ((ry) * 100))
class entclass
{
public:
@@ -12,6 +14,8 @@ public:
void setenemy(int t);
void setenemyroom(int rx, int ry);
public:
//Fundamentals
bool active, invis;