runs on Xbox

This commit is contained in:
Chris Danford
2003-07-22 07:47:27 +00:00
parent 20b4af87b1
commit 278cb4c3f1
53 changed files with 631 additions and 318 deletions
+35
View File
@@ -0,0 +1,35 @@
#ifndef RageFile_H
#define RageFile_H
/*
-----------------------------------------------------------------------------
Class: RageFile
Desc: Encapsulates C and C++ file classes to deal with arch-specific oddities.
Copyright (c) 2001-2002 by the person(s) listed below. All rights reserved.
Chris Danford
-----------------------------------------------------------------------------
*/
#include <fstream>
using namespace std; // using "std::ifstream" causes problems below in VC6. Why?!?
void FixSlashesInPlace( CString &sPath );
CString FixSlashes( CString sPath );
void CollapsePath( CString &sPath );
FILE* Ragefopen( const char *szPath, const char *szMode );
// replacement for ifstream
class Rageifstream : public std::ifstream
{
public:
Rageifstream() {};
Rageifstream( const char *szPath ) : ifstream(FixSlashes(szPath)) {}
void open( const char *szPath ) { ifstream::open(FixSlashes(szPath)); }
};
#endif