blob: 399943646288546a5b6225baec4248328bb47d6e (
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
|
#include "gameCommon.h"
#include "entity.h"
#include "PID.h"
#include <raylib.h>
#ifndef CAPORALE_H
#define CAPORALE_H
#define CAPORALE_COOLDOWN 0.5
#define CAPORALE_BULLET_DAMAGE 0.01
#define CAPORALE_TARGET_POINTER_DIS 10.0
typedef struct Caporale {
EntityFlyToPointInfo flyToPlayer;
double timeSinceLastShot;
bool initTarget;
Vector3 targetSetpoint;
Vector3 target;
Vector3 targetVelocity;
PID aimXPID;
PID aimYPID;
PID aimZPID;
Ray ray;
} Caporale;
void initCaporale(Entity * entity, Game * game);
void closeCaporale(Entity * entity);
void updateCaporale(Game * game, Entity * entity);
void drawCaporale(Game * game, Entity * entity);
#endif
|