Merge branch 'ziplantil/custom-sxx' into master
This commit is contained in:
commit
0d66e531a0
|
@ -165,6 +165,7 @@ extern void remove_char( char * s, char c ); // in piggy.c
|
|||
#define REMOVE_COMMENTS(s) remove_char((s),';')
|
||||
#define REMOVE_DOTS(s) remove_char((s),'.')
|
||||
|
||||
extern int Piggy_hamfile_version;
|
||||
extern unsigned Num_bitmap_files;
|
||||
extern int Num_sound_files;
|
||||
extern ubyte bogus_bitmap_initialized;
|
||||
|
@ -183,6 +184,7 @@ extern array<BitmapFile, MAX_BITMAP_FILES> AllBitmaps;
|
|||
#endif
|
||||
void piggy_init_pigfile(const char *filename);
|
||||
int read_hamfile();
|
||||
int read_sndfile();
|
||||
void swap_0_255(grs_bitmap &bmp);
|
||||
|
||||
#endif
|
||||
|
|
|
@ -753,7 +753,16 @@ static mission_list_type build_mission_list(int anarchy_mode)
|
|||
|
||||
int load_mission_ham()
|
||||
{
|
||||
read_hamfile();
|
||||
read_hamfile(); // intentionally can also read from the HOG
|
||||
|
||||
if (Piggy_hamfile_version >= 3)
|
||||
{
|
||||
// re-read sounds in case mission has custom .sXX
|
||||
Num_sound_files = 0;
|
||||
read_sndfile();
|
||||
piggy_read_sounds();
|
||||
}
|
||||
|
||||
if (Current_mission->descent_version == Mission::descent_version_type::descent2a &&
|
||||
Current_mission->alternate_ham_file)
|
||||
{
|
||||
|
|
|
@ -1045,7 +1045,7 @@ int read_hamfile()
|
|||
return 1;
|
||||
}
|
||||
|
||||
static int read_sndfile()
|
||||
int read_sndfile()
|
||||
{
|
||||
int snd_id,snd_version;
|
||||
int N_sounds;
|
||||
|
|
Loading…
Reference in a new issue