Skip to content

Commit ea7c297

Browse files
committed
MessageBox on exit
1 parent 4e08f7e commit ea7c297

2 files changed

Lines changed: 8 additions & 5 deletions

File tree

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,5 +11,5 @@ Open Fodder Editor is a Map Editor for [OpenFodder](https://github.com/segrax/op
1111

1212
#####Requirements
1313

14-
* DOS CD version available at [Good Old Games] (http://www.gog.com/game/cannon_fodder)
14+
* Cannon Fodder DOS CD version available at [Good Old Games] (http://www.gog.com/game/cannon_fodder)
1515

Source/Resource_PC_CD.cpp

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
*/
2222

2323
#include "stdafx.hpp"
24-
24+
#include <wx/wx.h>
2525
#include <algorithm>
2626

2727
const uint8 cResource_PC_CD::byte_29921[0x100] = {
@@ -98,7 +98,7 @@ cResource_PC_CD::cResource_PC_CD( std::string pDataPath ) : cResources(pDataPath
9898

9999
mData = local_FileRead( "CF_ENG.DAT", pDataPath, mDataSize );
100100
if (!mData) {
101-
std::cout << "CF_ENG.DAT not found\n";
101+
wxMessageBox( "CF_ENG.DAT not found\n" );
102102
exit( 1 );
103103
}
104104

@@ -158,8 +158,11 @@ uint8* cResource_PC_CD::fileGet( std::string pFilename, size_t &pFileSize ) {
158158
}
159159
}
160160

161-
std::cout << "File " << pFilename << " Not Found!\n";
162-
exit( 1 );
161+
std::stringstream Error;
162+
Error << "File ";
163+
Error << pFilename << " Not Fond!";
164+
165+
wxMessageBox( Error.str() );
163166
return 0;
164167
}
165168

0 commit comments

Comments
 (0)