1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

Add flag string settings, flat map option

This commit is contained in:
kwolekr 2013-02-05 15:01:33 -05:00
parent f148ae58c3
commit 97260d09a8
9 changed files with 118 additions and 32 deletions

View file

@ -28,6 +28,11 @@ with this program; if not, write to the Free Software Foundation, Inc.,
#include <vector>
#include <sstream>
struct FlagDesc {
const char *name;
u32 flag;
};
static inline std::string padStringRight(std::string s, size_t len)
{
if(len > s.size())
@ -283,6 +288,8 @@ inline std::string wrap_rows(const std::string &from, u32 rowlen)
std::string translatePassword(std::string playername, std::wstring password);
size_t curl_write_data(char *ptr, size_t size, size_t nmemb, void *userdata);
u32 readFlagString(std::string str, FlagDesc *flagdesc);
std::string writeFlagString(u32 flags, FlagDesc *flagdesc);
char *mystrtok_r(char *s, const char *sep, char **lasts);
#endif