fix(Core/Commands): debug send opcode (#2344)

This commit is contained in:
Stoabrogga
2019-10-22 08:20:00 +02:00
committed by GitHub
parent 6b395e9b70
commit d4cf4c1fd9
3 changed files with 14 additions and 2 deletions

View File

@@ -250,8 +250,12 @@ public:
unit = player;
std::ifstream ifs("opcode.txt");
if (ifs.bad())
if (!ifs.is_open())
{
handler->SendSysMessage(LANG_DEBUG_OPCODE_FILE_MISSING);
handler->SetSentErrorMessage(true);
return false;
}
// remove comments from file
std::stringstream parsedStream;