diff --git a/Personnage/Kenny.cpp b/Personnage/Kenny.cpp index 3beb83a..76f2655 100644 --- a/Personnage/Kenny.cpp +++ b/Personnage/Kenny.cpp @@ -11,3 +11,11 @@ void Kenny::parler(const string &message) const { cout << "MMmmmhhmmmm" << endl; } + +Kenny::Kenny() : Kenny("Kenny", "huh?") +{} + +Kenny::Kenny(const std::string &name, + const std::string &pv) + : Personnage(name, pv) +{} diff --git a/Personnage/Kenny.h b/Personnage/Kenny.h index 8d1f236..8f2731d 100644 --- a/Personnage/Kenny.h +++ b/Personnage/Kenny.h @@ -12,6 +12,11 @@ class Kenny : public Personnage { public: void parler(const std::string &message) const override; + + Kenny(); + + Kenny(const std::string &name, + const std::string &pv); }; diff --git a/Personnage/Personnage.cpp b/Personnage/Personnage.cpp index 740bbf0..a5501ab 100644 --- a/Personnage/Personnage.cpp +++ b/Personnage/Personnage.cpp @@ -10,3 +10,12 @@ void Personnage::parler(const string &message) const { cout << message << endl; } + +Personnage::Personnage() + : Personnage("FNU", "wat") +{} + +Personnage::Personnage(const std::string &name, + const std::string &pv) + : name(name), pv(pv) +{} diff --git a/Personnage/Personnage.h b/Personnage/Personnage.h index 9c68414..234bb7b 100644 --- a/Personnage/Personnage.h +++ b/Personnage/Personnage.h @@ -14,6 +14,11 @@ private: std::string pv; public: virtual void parler(const std::string &message) const; + + Personnage(); + + Personnage(const std::string &name, + const std::string &pv); };