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

Deprecate .bmp format

This commit is contained in:
sfan5 2023-10-25 17:18:34 +02:00
parent 2f16227302
commit 03ba9370b9
2 changed files with 8 additions and 1 deletions

View file

@ -2557,6 +2557,13 @@ bool Server::addMediaFile(const std::string &filename,
return false;
}
const char *deprecated_ext[] = { ".bmp", nullptr };
if (!removeStringEnd(filename, deprecated_ext).empty())
{
warningstream << "Media file \"" << filename << "\" is using a"
" deprecated format and will stop working in the future." << std::endl;
}
SHA1 sha1;
sha1.addBytes(filedata.c_str(), filedata.length());