Merge branch 'master' of git@github.com:andreferreira/Projeto-PCG
[Projeto-PCG.git] / shooter.h
blob3ecf045f5508400ac5bd665044480537c31021cb
1 #ifndef SHOOTER_H
2 #define SHOOTER_H
4 #include "game.h"
5 #include "geometry.h"
6 #include "thing.h"
7 #include "weapon.h"
9 class Game;
10 class Player;
12 class Shooter: public Thing {
13 protected:
14 Ponto leftArm(bool w);
15 Ponto rightArm(bool w);
16 Ponto aim;
17 Ponto realRightfeet;
18 Ponto realLeftfeet;
19 Ponto imaginaryRightfeet();
20 Ponto imaginaryLeftfeet();
21 double imaginaryBodyAngle();
22 Weapon* weapon;
23 double bodyAngle;
24 double tamanhoAntebraco();
25 double tamanhoBraco();
26 double tamanhoCoxa();
27 double tamanhoPerna();
28 double getAngle();
29 Ponto getJunta(Ponto superior, Ponto inferior,
30 double tamanhoSuperior, double tamanhoInferior);
31 bool canfire;
32 unsigned int feetTime;
33 unsigned int angleTime;
34 void updateFeetTime();
35 void updateAngleTime();
36 int direction;
37 double addToAngle;
38 public:
39 bool crawl;
40 Ponto leftFeet();
41 Ponto rightFeet();
42 Ponto cabeca();
43 Ponto pescoco();
44 Ponto cintura();
45 Game* game;
46 Shooter(Game* agame, Ponto pos, Ponto speed);
47 void desenha();
48 void setAim(double x, double y);
49 void equip(Weapon* aweapon);
50 void fire();
51 void allowFire();
52 void animate();
53 virtual Linha getBaseLine();
54 virtual Polygon getCollision();
57 #endif