Remove Eggs::Eggs and rearrange Entity members a bit

This commit is contained in:
2021-03-22 17:53:46 +01:00
parent 22678fcfc2
commit 3325397d17
8 changed files with 68 additions and 58 deletions

View File

@@ -499,7 +499,7 @@ static void eggCommand(std::string full, std::vector<std::string>& args, CNSocke
}
char* tmp;
int eggType = std::strtol(args[1].c_str(), &tmp, 10);
int eggType = std::strtol(args[1].c_str(), &tmp, 10);
if (*tmp)
return;
@@ -520,7 +520,6 @@ static void eggCommand(std::string full, std::vector<std::string>& args, CNSocke
Egg* egg = new Egg(plr->x + addX, plr->y + addY, plr->z, plr->instanceID, eggType, id, false); // change last arg to true after gruntwork
NPCManager::NPCs[id] = egg;
Eggs::Eggs[id] = egg;
NPCManager::updateNPCPosition(id, plr->x + addX, plr->y + addY, plr->z, plr->instanceID, plr->angle);
// add to template