diff --git a/desktop_version/src/Graphics.cpp b/desktop_version/src/Graphics.cpp index 6a2773aa..db9bc54b 100644 --- a/desktop_version/src/Graphics.cpp +++ b/desktop_version/src/Graphics.cpp @@ -1282,8 +1282,15 @@ void Graphics::textboxadjust(void) } -void Graphics::createtextbox( std::string t, int xp, int yp, int r, int g, int b) -{ +void Graphics::createtextboxreal( + std::string t, + int xp, + int yp, + int r, + int g, + int b, + bool flipme +) { m = textbox.size(); if(m<20) @@ -1295,11 +1302,34 @@ void Graphics::createtextbox( std::string t, int xp, int yp, int r, int g, int b if (xp == -1) text.xp = 160 - (((length / 2) + 1) * 8); text.yp = yp; text.initcol(r, g, b); + text.flipme = flipme; text.resize(); textbox.push_back(text); } } +void Graphics::createtextbox( + std::string t, + int xp, + int yp, + int r, + int g, + int b +) { + createtextboxreal(t, xp, yp, r, g, b, false); +} + +void Graphics::createtextboxflipme( + std::string t, + int xp, + int yp, + int r, + int g, + int b +) { + createtextboxreal(t, xp, yp, r, g, b, true); +} + void Graphics::drawfade(void) { int usethisamount = lerp(oldfadeamount, fadeamount); diff --git a/desktop_version/src/Graphics.h b/desktop_version/src/Graphics.h index 1f98ad7a..ee901c3f 100644 --- a/desktop_version/src/Graphics.h +++ b/desktop_version/src/Graphics.h @@ -51,7 +51,31 @@ public: void setwarprect(int a, int b, int c, int d); - void createtextbox(std::string t, int xp, int yp, int r, int g, int b); + void createtextboxreal( + std::string t, + int xp, + int yp, + int r, + int g, + int b, + bool flipme + ); + void createtextbox( + std::string t, + int xp, + int yp, + int r, + int g, + int b + ); + void createtextboxflipme( + std::string t, + int xp, + int yp, + int r, + int g, + int b + ); void textboxcenterx(void);