mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2026-01-29 17:38:16 +03:00
Convert entity types to an enum (#1007)
In an effort to remove magic numbers, I've given every entity type a name. Hopefully I didn't miss anywhere. Also, add `createentity` case 100 for backwards compatibility. Co-authored-by: NyakoFox <nyakowofox@gmail.com> Co-authored-by: Dav999 <dav999.tolp@gmail.com>
This commit is contained in:
@@ -11,7 +11,7 @@ entclass::entclass(void)
|
||||
void entclass::clear(void)
|
||||
{
|
||||
invis = false;
|
||||
type = 0;
|
||||
type = EntityType_PLAYER;
|
||||
size = 0;
|
||||
tile = 0;
|
||||
rule = 0;
|
||||
@@ -650,8 +650,8 @@ void entclass::updatecolour(void)
|
||||
|
||||
bool entclass::ishumanoid(void)
|
||||
{
|
||||
return type == 0
|
||||
|| type == 12
|
||||
|| type == 14
|
||||
|| type == 55;
|
||||
return type == EntityType_PLAYER
|
||||
|| type == EntityType_CREWMATE
|
||||
|| type == EntityType_SUPERCREWMATE
|
||||
|| type == EntityType_COLLECTABLE_CREWMATE;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user