-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathAtaque.cpp
54 lines (46 loc) · 1.45 KB
/
Ataque.cpp
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
/*
* File: Ataque.cpp
* Author: danielnobusada
*
* Created on November 5, 2012, 8:05 PM
*/
#include "Ataque.h"
#include <iostream>
using namespace std;
Ataque::Ataque(int a, int d, int aMin, int aMax, char* n, bool f)
{
this->ataque = a;
this->dano = d;
this->alcanceMin = aMin;
this->alcanceMax = aMax;
this->nome = n;
this->fisico = f;
}
Ataque::Ataque(Ataque& at)
{
this->ataque = at.getAtaque();
this->dano = at.getDano();
this->alcanceMin = at.getAlcanceMin();
this->alcanceMax = at.getAlcanceMax();
this->nome = at.getNome();
this->fisico = at.getFisico();
}
void Ataque::setAlcanceMax(int aMax){this->alcanceMax = aMax;}
void Ataque::setAlcanceMin(int aMin){this->alcanceMin = aMin;}
void Ataque::setAtaque(int a){this->ataque = a;}
void Ataque::setDano(int d){this->dano = d;}
void Ataque::setNome(char* n){this->nome = n;}
void Ataque::setFisico(bool f){this->fisico = f;}
int Ataque::getAlcanceMax(){return this->alcanceMax;}
int Ataque::getAlcanceMin(){return this->alcanceMin;}
int Ataque::getAtaque(){return this->ataque;}
int Ataque::getDano(){return this->dano;}
bool Ataque::getFisico(){return this->fisico;}
char* Ataque::getNome(){return this->nome;}
void Ataque::printTudo()
{
cout<<"Nome: "<<this->getNome()<<endl;
cout<<"Ataque: "<<this->getAtaque()<<endl;
cout<<"Dano: "<<this->getDano()<<endl;
cout<<"Alcances: ("<<this->getAlcanceMin()<<","<<this->getAlcanceMax()<<")"<<endl;
}