mirror of
https://github.com/ZDoom/Raze.git
synced 2024-12-03 01:22:19 +00:00
5eee7b80b1
* controller handling improvements * use stb_sprintf. * various smaller fixes.
21 lines
497 B
C
21 lines
497 B
C
#define STB_SPRINTF_IMPLEMENTATION
|
|
#define STB_SPRINTF_UTF8_CHARS
|
|
#include "stb_sprintf.h"
|
|
|
|
// We still need our own wrappers because they use a size_t for count, not an int.
|
|
int mysnprintf(char* buf, size_t count, char const* fmt, ...)
|
|
{
|
|
int result;
|
|
va_list va;
|
|
va_start(va, fmt);
|
|
|
|
result = stbsp_vsnprintf(buf, (int)count, fmt, va);
|
|
va_end(va);
|
|
|
|
return result;
|
|
}
|
|
|
|
int myvsnprintf(char* buf, size_t count, const char* fmt, va_list va)
|
|
{
|
|
return stbsp_vsnprintf(buf, (int)count, fmt, va);
|
|
}
|