#include "scripting_mainmenu.h"
#include "config.h"
+#include "version.h"
#include "porting.h"
#include "filesys.h"
#include "main.h"
//create topleft header
core::rect<s32> rect(0, 0, 500, 40);
rect += v2s32(4, 0);
- std::string t = "Minetest " VERSION_STRING;
+ std::string t = std::string("Minetest ") + minetest_version_hash;
m_irr_toplefttext =
m_device->getGUIEnvironment()->addStaticText(narrow_to_wide(t).c_str(),
}
/* Draw background texture */
- v2u32 sourcesize = texture->getSize();
+ v2u32 sourcesize = texture->getOriginalSize();
driver->draw2DImage(texture,
core::rect<s32>(0, 0, screensize.X, screensize.Y),
core::rect<s32>(0, 0, sourcesize.X, sourcesize.Y),
return;
/* Draw background texture */
- v2u32 sourcesize = texture->getSize();
+ v2u32 sourcesize = texture->getOriginalSize();
driver->draw2DImage(texture,
core::rect<s32>(0, 0, screensize.X, screensize.Y),
core::rect<s32>(0, 0, sourcesize.X, sourcesize.Y),
if(!texture)
return;
- f32 mult = (((f32)screensize.Width / 2)) /
+ f32 mult = (((f32)screensize.Width / 2.0)) /
((f32)texture->getOriginalSize().Width);
v2s32 splashsize(((f32)texture->getOriginalSize().Width) * mult,
driver->draw2DImage(texture, splashrect,
core::rect<s32>(core::position2d<s32>(0,0),
- core::dimension2di(texture->getSize())),
+ core::dimension2di(texture->getOriginalSize())),
NULL, NULL, true);
}
}
driver->draw2DImage(texture, rect,
core::rect<s32>(core::position2d<s32>(0,0),
- core::dimension2di(texture->getSize())),
+ core::dimension2di(texture->getOriginalSize())),
NULL, NULL, true);
}
}
/******************************************************************************/
void GUIEngine::setTopleftText(std::string append) {
- std::string toset = "Minetest " VERSION_STRING;
+ std::string toset = std::string("Minetest ") + minetest_version_hash;
if (append != "") {
toset += " / ";