mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Add dummy and LevelDB database backends
This commit is contained in:
parent
71a8769bb5
commit
58841ef12f
148 changed files with 26766 additions and 242 deletions
|
@ -163,6 +163,12 @@ inline s32 mystoi(const std::string &s, s32 min, s32 max)
|
|||
return i;
|
||||
}
|
||||
|
||||
inline s64 stoi64(const std::string &s) {
|
||||
std::stringstream tmp(s);
|
||||
long long t;
|
||||
tmp >> t;
|
||||
return t;
|
||||
}
|
||||
|
||||
// MSVC2010 includes it's own versions of these
|
||||
//#if !defined(_MSC_VER) || _MSC_VER < 1600
|
||||
|
@ -200,6 +206,12 @@ inline std::string itos(s32 i)
|
|||
return o.str();
|
||||
}
|
||||
|
||||
inline std::string i64tos(s64 i) {
|
||||
std::ostringstream o;
|
||||
o<<i;
|
||||
return o.str();
|
||||
}
|
||||
|
||||
inline std::string ftos(float f)
|
||||
{
|
||||
std::ostringstream o;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue