16
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-07-21 22:59:19 +02:00

stars object, interrior lighting level as accessible parameter for dynamic object

This commit is contained in:
tmj-fstate
2017-02-24 01:22:06 +01:00
parent 3e68e4921b
commit 4dcb87906f
14 changed files with 268 additions and 97 deletions

23
World.h
View File

@@ -14,9 +14,25 @@ http://mozilla.org/MPL/2.0/.
#include "Ground.h"
#include "sky.h"
#include "sun.h"
#include "stars.h"
#include "skydome.h"
#include "mczapkie/mover.h"
// wrapper for environment elements -- sky, sun, stars, clouds etc
class world_environment {
public:
void init();
void update();
void render();
private:
CSkyDome m_skydome;
cStars m_stars;
cSun m_sun;
TSky m_clouds;
};
class TWorld
{
void InOutKey();
@@ -42,21 +58,19 @@ class TWorld
std::string OutText2;
std::string OutText3;
std::string OutText4;
void Update_Lights();
void Update_Environment();
void Update_Camera( const double Deltatime );
bool Render();
void Render_Cab();
void Render_UI();
TCamera Camera;
TGround Ground;
world_environment Environment;
TTrain *Train;
TDynamicObject *pDynamicNearest;
bool Paused;
GLuint base; // numer DL dla znaków w napisach
texture_manager::size_type light; // numer tekstury dla smugi
TSky Clouds;
CSkyDome SkyDome;
cSun Sun;
TEvent *KeyEvents[10]; // eventy wyzwalane z klawiaury
TMoverParameters *mvControlled; // wskaźnik na człon silnikowy, do wyświetlania jego parametrów
int iCheckFPS; // kiedy znów sprawdzić FPS, żeby wyłączać optymalizacji od razu do zera
@@ -72,5 +86,6 @@ class TWorld
void CreateE3D(std::string const &dir = "", bool dyn = false);
void CabChange(TDynamicObject *old, TDynamicObject *now);
};
//---------------------------------------------------------------------------