Webclient: Fix error messages getting cutoff (Thanks Vuruz)

This commit is contained in:
UnknownShadow200 2021-10-25 08:18:17 +11:00
parent 1bcb0bfdab
commit 46b6679961
2 changed files with 2 additions and 3 deletions

View File

@ -428,8 +428,7 @@ cc_bool Platform_DescribeError(cc_result res, cc_string* dst) {
}
EMSCRIPTEN_KEEPALIVE void Platform_LogError(const char* msg) {
/* no point showing more than 128 characters in chat */
cc_string str = String_FromRaw(msg, 128);
cc_string str = String_FromReadonly(msg);
Logger_WarnFunc(&str);
}

View File

@ -72,7 +72,7 @@ static CC_INLINE BlockID World_GetBlock(int x, int y, int z) {
return (BlockID)((World.Blocks[i] | (World.Blocks2[i] << 8)) & World.IDMask);
}
#else
#define World_GetBlock(x, y, z) World_Blocks[World_Pack(x, y, z)]
#define World_GetBlock(x, y, z) World.Blocks[World_Pack(x, y, z)]
#endif
/* If Y is above the map, returns BLOCK_AIR. */