From 136557739372f8ecfd0cb9319535a00c858d6bb6 Mon Sep 17 00:00:00 2001 From: Issac332 <119879937+Issac8658@users.noreply.github.com> Date: Wed, 10 Jun 2026 20:27:57 +0300 Subject: [PATCH] time in shaders --- src/main.cpp | 2 +- src/plane.cpp | 1 + src/plane.h | 2 -- src/sprite.cpp | 1 + src/sprite.h | 2 -- src/sunshine.h | 2 +- src/tilemap.cpp | 3 +-- src/tilemap.h | 1 - 8 files changed, 5 insertions(+), 9 deletions(-) diff --git a/src/main.cpp b/src/main.cpp index 098bd00..aede6d7 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -216,7 +216,7 @@ static void setGamePathInRegistry() { } int main(int argc, char *argv[]){ SecurityManagerInit(); - starttime = boost::chrono::high_resolution_clock::now(); + startTime = boost::chrono::high_resolution_clock::now(); loadLanguageMetadata(); //there will be a segfault on fclose if I don't move it here SDL_SetHint(SDL_HINT_VIDEO_MINIMIZE_ON_FOCUS_LOSS, "0"); diff --git a/src/plane.cpp b/src/plane.cpp index 564f195..a151664 100644 --- a/src/plane.cpp +++ b/src/plane.cpp @@ -34,6 +34,7 @@ #include "etc-internal.h" #include "shader.h" #include "glstate.h" +#include "sunshine.h" #include diff --git a/src/plane.h b/src/plane.h index 62af3fa..4b1f951 100644 --- a/src/plane.h +++ b/src/plane.h @@ -36,8 +36,6 @@ struct PlanePrivate; class Plane : public ViewportElement, public Disposable{ public: - boost::chrono::high_resolution_clock::time_point startTime = boost::chrono::high_resolution_clock::now(); - Plane(Viewport *viewport = 0); ~Plane(); diff --git a/src/sprite.cpp b/src/sprite.cpp index 1c30673..672ab12 100644 --- a/src/sprite.cpp +++ b/src/sprite.cpp @@ -35,6 +35,7 @@ #include "quadarray.h" #include "config.h" #include "debugwriter.h" +#include "sunshine.h" #include diff --git a/src/sprite.h b/src/sprite.h index 57fabae..6409258 100644 --- a/src/sprite.h +++ b/src/sprite.h @@ -40,8 +40,6 @@ struct SpritePrivate; class Sprite : public ViewportElement, public Flashable, public Disposable{ public: - boost::chrono::high_resolution_clock::time_point startTime = boost::chrono::high_resolution_clock::now(); - Sprite(Viewport *viewport = 0); ~Sprite(); diff --git a/src/sunshine.h b/src/sunshine.h index 3761076..48c57df 100644 --- a/src/sunshine.h +++ b/src/sunshine.h @@ -1,4 +1,4 @@ #include //помойка ебаная -inline boost::chrono::high_resolution_clock::time_point starttime; +inline boost::chrono::high_resolution_clock::time_point startTime; diff --git a/src/tilemap.cpp b/src/tilemap.cpp index 011b8d7..081a957 100644 --- a/src/tilemap.cpp +++ b/src/tilemap.cpp @@ -38,6 +38,7 @@ #include "vertex.h" #include "tileatlas.h" #include "tilemap-common.h" +#include "sunshine.h" #include #include @@ -222,8 +223,6 @@ struct ZLayer : public ViewportElement { }; struct TilemapPrivate { - boost::chrono::high_resolution_clock::time_point startTime = boost::chrono::high_resolution_clock::now(); - Viewport *viewport; Bitmap *autotiles[autotileCount]; diff --git a/src/tilemap.h b/src/tilemap.h index 6172757..1c565de 100644 --- a/src/tilemap.h +++ b/src/tilemap.h @@ -25,7 +25,6 @@ #include "disposable.h" #include "util.h" -#include class Viewport; class Bitmap;