RGSSAD: Add RGSS2 archive reader
Exactly the same as RGSS1 but different file extension. Also remove some redundant strings.
This commit is contained in:
		
							parent
							
								
									1ecdd9f980
								
							
						
					
					
						commit
						6726493ee7
					
				
					 3 changed files with 29 additions and 5 deletions
				
			
		| 
						 | 
				
			
			@ -337,7 +337,9 @@ FileSystem::FileSystem(const char *argv0,
 | 
			
		|||
	p->extensions[Font].push_back("otf");
 | 
			
		||||
 | 
			
		||||
	PHYSFS_init(argv0);
 | 
			
		||||
	PHYSFS_registerArchiver(&RGSS_Archiver);
 | 
			
		||||
 | 
			
		||||
	PHYSFS_registerArchiver(&RGSS1_Archiver);
 | 
			
		||||
	PHYSFS_registerArchiver(&RGSS2_Archiver);
 | 
			
		||||
 | 
			
		||||
	if (allowSymlinks)
 | 
			
		||||
		PHYSFS_permitSymbolicLinks(1);
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -466,14 +466,35 @@ RGSS_noop2(void*, const char*)
 | 
			
		|||
	return 0;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
const PHYSFS_Archiver RGSS_Archiver =
 | 
			
		||||
const PHYSFS_Archiver RGSS1_Archiver =
 | 
			
		||||
{
 | 
			
		||||
	0,
 | 
			
		||||
	{
 | 
			
		||||
		"RGSSAD",
 | 
			
		||||
		"RGSS encrypted archive format",
 | 
			
		||||
		"Jonas Kulla <Nyocurio@gmail.com>",
 | 
			
		||||
		"http://k-du.de/rgss/rgss.html",
 | 
			
		||||
		"", /* Author */
 | 
			
		||||
		"", /* Website */
 | 
			
		||||
		0 /* symlinks not supported */
 | 
			
		||||
	},
 | 
			
		||||
	RGSS_openArchive,
 | 
			
		||||
	RGSS_enumerateFiles,
 | 
			
		||||
	RGSS_openRead,
 | 
			
		||||
	RGSS_noop1, /* openWrite */
 | 
			
		||||
	RGSS_noop1, /* openAppend */
 | 
			
		||||
	RGSS_noop2, /* remove */
 | 
			
		||||
	RGSS_noop2, /* mkdir */
 | 
			
		||||
	RGSS_stat,
 | 
			
		||||
	RGSS_closeArchive
 | 
			
		||||
};
 | 
			
		||||
 | 
			
		||||
const PHYSFS_Archiver RGSS2_Archiver =
 | 
			
		||||
{
 | 
			
		||||
	0,
 | 
			
		||||
	{
 | 
			
		||||
		"RGSS2A",
 | 
			
		||||
		"RGSS2 encrypted archive format",
 | 
			
		||||
		"", /* Author */
 | 
			
		||||
		"", /* Website */
 | 
			
		||||
		0 /* symlinks not supported */
 | 
			
		||||
	},
 | 
			
		||||
	RGSS_openArchive,
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -24,6 +24,7 @@
 | 
			
		|||
 | 
			
		||||
#include <physfs.h>
 | 
			
		||||
 | 
			
		||||
extern const PHYSFS_Archiver RGSS_Archiver;
 | 
			
		||||
extern const PHYSFS_Archiver RGSS1_Archiver;
 | 
			
		||||
extern const PHYSFS_Archiver RGSS2_Archiver;
 | 
			
		||||
 | 
			
		||||
#endif // RGSSAD_H
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue