diff options
Diffstat (limited to 'src/being/being.h')
-rw-r--r-- | src/being/being.h | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/src/being/being.h b/src/being/being.h index 634c26d23..a93d0e3db 100644 --- a/src/being/being.h +++ b/src/being/being.h @@ -877,21 +877,27 @@ class Being : public ActorSprite, public ConfigListener void addPet(const int id); - void removePet(); + void removePet(const int id); void updatePets(); void fixPetSpawnPos(int &dstX, int &dstY) const; - Being *getPet() - { return mPet; } + const std::vector<Being*> &getPets() const + { return mPets; } - void setPet(Being *const pet) - { mPet = pet; } + Being *getFirstPet() + { return mPets.empty() ? nullptr : mPets[0]; } void setOwner(Being *const owner) { mOwner = owner; } + void unassignPet(Being *const pet); + + void removeAllPets(); + + Being *findChildPet(const int id); + void playSfx(const SoundInfo &sound, Being *const being, const bool main, const int x, const int y) const; @@ -1029,7 +1035,7 @@ class Being : public ActorSprite, public ConfigListener int *mSpriteHide; int *mSpriteDraw; std::string mComment; - Being *mPet; + std::vector<Being*> mPets; Being *mOwner; Particle *mSpecialParticle; |