aboutsummaryrefslogtreecommitdiff
path: root/cpp04/ex01/Enemy.hpp
blob: 954e147d27648411a92cfbb9b116d5306a346185 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
/* ************************************************************************** */
/*                                                                            */
/*                                                        :::      ::::::::   */
/*   Enemy.hpp                                          :+:      :+:    :+:   */
/*                                                    +:+ +:+         +:+     */
/*   By: charles <charles.cabergs@gmail.com>        +#+  +:+       +#+        */
/*                                                +#+#+#+#+#+   +#+           */
/*   Created: 2020/04/14 13:23:40 by charles           #+#    #+#             */
/*   Updated: 2020/11/17 09:01:14 by cacharle         ###   ########.fr       */
/*                                                                            */
/* ************************************************************************** */

#ifndef ENEMY_HPP
# define ENEMY_HPP

# include <string>

class Enemy
{
public:
    Enemy(Enemy const& other);
    Enemy& operator=(Enemy const& other);

    Enemy(int hp, std::string const& type);
    virtual ~Enemy();
    std::string const& getType() const;
    int getHP() const;

    virtual void takeDamage(int amount);

protected:
    int         m_hp;
    std::string m_type;

private:
    Enemy();
};

#endif