27 lines
621 B
C++
27 lines
621 B
C++
#pragma once
|
|
#include "body.h"
|
|
#include "star_system.h"
|
|
|
|
class Frame;
|
|
class Planet : public Body {
|
|
public:
|
|
Planet(StarSystem::SBody*);
|
|
virtual ~Planet(void);
|
|
virtual void SetPosition(vector3d p);
|
|
virtual vector3d GetPosition(void);
|
|
void SetRadius(double radius);
|
|
double GetRadius(void) { return sbody.radius; }
|
|
virtual void Render(const Frame* camFrame);
|
|
virtual void SetFrame(Frame* f);
|
|
virtual bool OnCollision(Body* b, Uint32 flags) { return true; }
|
|
private:
|
|
void DrawRockyPlanet(void);
|
|
void DrawGasGiant(void);
|
|
|
|
vector3d pos;
|
|
dGeomID geom;
|
|
StarSystem::SBody sbody;
|
|
GLuint crudDList;
|
|
};
|
|
|