Compare commits

..

No commits in common. "4c837eff0a1c3677e5b0af88a43e5a73d8a5be9d" and "8f9a18d960ce7034e7d48e5ff2bf9b9a304d0306" have entirely different histories.

6 changed files with 397 additions and 586 deletions

View File

@ -8,7 +8,7 @@ namespace ZL {
int Environment::windowHeaderHeight = 0;
int Environment::width = 0;
int Environment::height = 0;
float Environment::zoom = 14.f;
float Environment::zoom = 6.f;
bool Environment::leftPressed = false;
bool Environment::rightPressed = false;

940
Game.cpp

File diff suppressed because it is too large Load Diff

32
Game.h
View File

@ -25,7 +25,6 @@ namespace ZL {
void update();
void render();
bool shouldExit() const { return Environment::exitGameLoop; }
private:
@ -34,7 +33,6 @@ namespace ZL {
void drawCubemap();
void drawShip();
void drawBoxes();
void drawUI();
SDL_Window* window;
SDL_GLContext glContext;
@ -43,32 +41,6 @@ namespace ZL {
size_t newTickCount;
size_t lastTickCount;
std::vector<BoxCoords> boxCoordsArr;
std::vector<VertexRenderStruct> boxRenderArr;
std::shared_ptr<Texture> buttonTexture;
VertexRenderStruct button;
std::shared_ptr<Texture> musicVolumeBarTexture;
VertexRenderStruct musicVolumeBar;
std::shared_ptr<Texture> musicVolumeBarButtonTexture;
VertexRenderStruct musicVolumeBarButton;
bool isDraggingVolume = false;
float musicVolume = 0.0f;
float volumeBarMinX = 1190.0f;
float volumeBarMaxX = 1200.0f;
float volumeBarMinY = 100.0f;
float volumeBarMaxY = 600.0f;
float musicVolumeBarButtonButtonCenterX = 1195.0f;
float musicVolumeBarButtonButtonRadius = 25.0f;
void UpdateVolumeFromMouse(int mouseX, int mouseY);
void UpdateVolumeKnob();
static const size_t CONST_TIMER_INTERVAL = 10;
static const size_t CONST_MAX_TIME_INTERVAL = 1000;
@ -83,8 +55,10 @@ namespace ZL {
std::shared_ptr<Texture> boxTexture;
VertexDataStruct boxBase;
std::vector<BoxCoords> boxCoordsArr;
std::vector<VertexRenderStruct> boxRenderArr;
SparkEmitter sparkEmitter;
};
} // namespace ZL

BIN
resources/button.png (Stored with Git LFS)

Binary file not shown.

BIN
resources/musicVolumeBarButton.png (Stored with Git LFS)

Binary file not shown.

BIN
resources/musicVolumeBarTexture.png (Stored with Git LFS)

Binary file not shown.