Jamie Slowgrove - AI Assignment 1
Line of Sight & A* path-finding
|
Creates a BotB object that inherits BotAI. Creates a BotB object that inherits BotAI and contains the details for the BotA. More...
#include <botB.h>
Public Member Functions | |
BotB (Texture *, Vec2, int, int, Map *) | |
~BotB () | |
void | playerLineOfSight (Player *, BotA *, Map *) |
void | updateMovement (Player *, Map *, float) |
bool | getFollowing () |
Public Member Functions inherited from BotAI | |
BotAI (Texture *, Vec2, Vec2, int, int, int, int, Map *) | |
~BotAI () | |
void | playerLineOfSight (Player *, Map *) |
void | drawPath (SDL_Renderer *, Vec2 target) |
Vec2 | getLastNodePosition () |
bool | getRunning () |
Public Member Functions inherited from Creature | |
Creature (Texture *, Vec2, Vec2, int, int, int, int) | |
~Creature () | |
void | updatePosition (float) |
void | setVelocities (Vec2) |
Vec2 | getVelocities () |
void | displayTiles (SDL_Renderer *, Map *) |
void | collisionUpdate (Map *, float) |
void | collisionUpdate (Entity *, float) |
Public Member Functions inherited from Entity | |
Entity (Texture *, Vec2, Vec2, int, int, int, int) | |
~Entity () | |
void | display (SDL_Renderer *) |
void | setPosition (Vec2) |
Vec2 | getPosition () |
int | getWidth () |
int | getHeight () |
Private Member Functions | |
void | updateMoveFollow (Creature *, Map *, float) |
Private Attributes | |
bool | following |
BotA * | botA |
Additional Inherited Members | |
Protected Member Functions inherited from BotAI | |
void | updateMovementVelocities (float, bool) |
Protected Member Functions inherited from Creature | |
float | collision (Map *, float, float, float, int, int, int, int, char) |
void | displayCollisionTest (SDL_Renderer *, Map *, int, int, int, int) |
Protected Attributes inherited from BotAI | |
AStar * | aStar |
Vec2 | moveTarget |
Vec2 | nextPosition |
Vec2 | lastNode |
bool | running |
Protected Attributes inherited from Creature | |
Vec2 | velocities |
int | minX |
int | maxX |
int | minY |
int | maxY |
Protected Attributes inherited from Entity | |
Vec2 | position |
Vec2 | source |
int | spriteWidth |
int | spriteHeight |
int | width |
int | height |
Texture * | texture |
Creates a BotB object that inherits BotAI. Creates a BotB object that inherits BotAI and contains the details for the BotA.
BotB::~BotB | ( | ) |
Destructs an BotA object
bool BotB::getFollowing | ( | ) |
Getter # Get the value of following
|
private |
If the bot is following