summaryrefslogtreecommitdiff
path: root/ex03/main.cpp
diff options
context:
space:
mode:
authorDominik Kaiser2025-02-10 12:53:16 +0100
committerDominik Kaiser2025-02-10 12:53:16 +0100
commit57e945f03e37e741a527f07fdcd84307733635e7 (patch)
treef6f1b67a329d1547217e421cc58ff6b867a45b2e /ex03/main.cpp
parent4b7e380d5f718fe557ef6ae068d7896620bc24f2 (diff)
downloadcpp01-57e945f03e37e741a527f07fdcd84307733635e7.tar.gz
cpp01-57e945f03e37e741a527f07fdcd84307733635e7.zip
Implement HumanA class
Diffstat (limited to 'ex03/main.cpp')
-rw-r--r--ex03/main.cpp26
1 files changed, 23 insertions, 3 deletions
diff --git a/ex03/main.cpp b/ex03/main.cpp
index b2ae001..e53d3a0 100644
--- a/ex03/main.cpp
+++ b/ex03/main.cpp
@@ -6,9 +6,29 @@
/* By: dkaiser <dkaiser@student.42heilbronn.de +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2025/02/10 11:58:15 by dkaiser #+# #+# */
-/* Updated: 2025/02/10 11:58:24 by dkaiser ### ########.fr */
+/* Updated: 2025/02/10 12:48:13 by dkaiser ### ########.fr */
/* */
/* ************************************************************************** */
-int main(void)
-{}
+#include "Weapon.hpp"
+#include "HumanA.hpp"
+
+int main()
+{
+ {
+ Weapon club = Weapon("crude spiked club");
+ HumanA bob("Bob", club);
+ bob.attack();
+ club.setType("some other type of club");
+ bob.attack();
+ }
+ // {
+ // Weapon club = Weapon("crude spiked club");
+ // HumanB jim("Jim");
+ // jim.setWeapon(club);
+ // jim.attack();
+ // club.setType("some other type of club");
+ // jim.attack();
+ // }
+ // return 0;
+}