Fixed the Logging system to actually be able to handle errors. Database is also fixed to use directories.
This commit is contained in:
@@ -60,7 +60,7 @@ namespace ehs
|
||||
const MdlCodec* codec = GetCodec(ext);
|
||||
if (!codec)
|
||||
{
|
||||
EHS_LOG_INT("Error", 0, "Codec not found for file extension, \"" + ext + "\".");
|
||||
EHS_LOG_INT(LogType::ERR, 0, "Codec not found for file extension, \"" + ext + "\".");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -203,7 +203,7 @@ namespace ehs
|
||||
const MdlCodec* codec = GetCodec(ext);
|
||||
if (!codec)
|
||||
{
|
||||
EHS_LOG_INT("Error", 0, "Codec not found for file extension, \"" + ext + "\".");
|
||||
EHS_LOG_INT(LogType::ERR, 0, "Codec not found for file extension, \"" + ext + "\".");
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -248,7 +248,7 @@ namespace ehs
|
||||
Version ver = data.ReadVersion();
|
||||
if (ver != Version(1, 0, 0))
|
||||
{
|
||||
EHS_LOG_INT("Error", 0, "Cannot decode EHM file version " + Str_8::FromNum(ver.major) + "." +
|
||||
EHS_LOG_INT(LogType::ERR, 0, "Cannot decode EHM file version " + Str_8::FromNum(ver.major) + "." +
|
||||
Str_8::FromNum(ver.minor) + "." + Str_8::FromNum(ver.patch) +
|
||||
", must be version 0.0.0.");
|
||||
return false;
|
||||
@@ -293,7 +293,7 @@ namespace ehs
|
||||
Bone* parent = skeleton.GetBone(parentId);
|
||||
if (!parent)
|
||||
{
|
||||
EHS_LOG_INT("Error", 0, "Invalid bone order.");
|
||||
EHS_LOG_INT(LogType::ERR, 0, "Invalid bone order.");
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@@ -88,7 +88,7 @@ namespace ehs
|
||||
{
|
||||
if (!encoder)
|
||||
{
|
||||
EHS_LOG_INT("Error", 0, "Encoding is not supported for the " + id + " format.");
|
||||
EHS_LOG_INT(LogType::ERR, 0, "Encoding is not supported for the " + id + " format.");
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -99,7 +99,7 @@ namespace ehs
|
||||
{
|
||||
if (!decoder)
|
||||
{
|
||||
EHS_LOG_INT("Error", 0, "Decoding is not supported for the " + id + " format.");
|
||||
EHS_LOG_INT(LogType::ERR, 0, "Decoding is not supported for the " + id + " format.");
|
||||
return false;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user