Built-in formspecs: Force version 1
authorSmallJoker <mk939@ymail.com>
Sat, 14 Sep 2019 18:31:07 +0000 (20:31 +0200)
committerSmallJoker <mk939@ymail.com>
Sat, 14 Sep 2019 18:42:54 +0000 (20:42 +0200)
src/client/game.cpp
src/network/networkprotocol.h

index bc35ade855714ebda9080fe689e199ac1791fc9e..2b0976649ea348c6c3f7821a17cd569f8c0b36a0 100644 (file)
@@ -3981,7 +3981,7 @@ void Game::extendedResourceCleanup()
 void Game::showDeathFormspec()
 {
        static std::string formspec_str =
-               std::string(FORMSPEC_VERSION_STRING) +
+               std::string("formspec_version[1]") +
                SIZE_TAG
                "bgcolor[#320000b4;true]"
                "label[4.85,1.35;" + gettext("You died") + "]"
@@ -4055,7 +4055,7 @@ void Game::showPauseMenu()
        float ypos = simple_singleplayer_mode ? 0.7f : 0.1f;
        std::ostringstream os;
 
-       os << FORMSPEC_VERSION_STRING << SIZE_TAG
+       os << "formspec_version[1]" << SIZE_TAG
                << "button_exit[4," << (ypos++) << ";3,0.5;btn_continue;"
                << strgettext("Continue") << "]";
 
index f603ed6c5d43fb70ab1086b237ac67bfb5dd85a0..52cdf489cebbcd4ea5ec7728c46f41e91c311c65 100644 (file)
@@ -230,7 +230,6 @@ with this program; if not, write to the Free Software Foundation, Inc.,
                background[]: 9-slice scaling parameters
 */
 #define FORMSPEC_API_VERSION 2
-#define FORMSPEC_VERSION_STRING "formspec_version[" TOSTRING(FORMSPEC_API_VERSION) "]"
 
 #define TEXTURENAME_ALLOWED_CHARS "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789_.-"