/* Base class for different type of vehicles they are supposed to move and be drawn you should be able to select them by clicking they can also be hit and have a key */ #ifndef _vehicle_hh_ #define _vehicle_hh_ #include #include #include "controller.hh" #include "../team.hh" class Controller; class Vehicle { //pure virtual protected: Controller * controller; Team * team; GLfloat posX, posY, posZ; GLfloat angX, angY, angZ; public: virtual void draw() = 0; virtual void drawBounding() = 0; virtual void key() = 0; virtual void action() = 0; virtual void orderForward( int i ) { } virtual void orderTurn( int i ) { } virtual void orderFire() { } Controller * getController(); GLfloat getPosX(); GLfloat getPosZ(); GLfloat getAngY(); GLfloat getAngZ(); Team * getTeam(); //make sure the angle is in reasonable limits and easy to calc for the controller //could be stupid void fixAng( float ); virtual void hit() { } virtual void collide() { } virtual bool tryCollision() { return false; } Vehicle( Controller *, GLfloat _posX, GLfloat _posY, GLfloat _posZ, GLfloat _angX, GLfloat _angY, GLfloat _angZ, Team * _team ); // virtual vector getPoints() = 0; virtual ~Vehicle() { } }; #endif