Merge commit '3849cb8623' into scripting

Conflicts:
	src/g_hexen/a_clericstaff.cpp
	src/g_hexen/a_hexenspecialdecs.cpp
	src/p_acs.cpp
	src/p_enemy.cpp
	src/p_interaction.cpp
	src/thingdef/thingdef_codeptr.cpp
	src/thingdef/thingdef_expression.cpp

(Scripting branch update part 4)
This commit is contained in:
Christoph Oelckers 2015-04-28 11:59:33 +02:00
commit 792cad89b3
184 changed files with 12699 additions and 18900 deletions

View file

@ -214,6 +214,7 @@ bool autostart;
FString StoredWarp;
bool advancedemo;
FILE *debugfile;
FILE *hashfile;
event_t events[MAXEVENTS];
int eventhead;
int eventtail;
@ -2009,7 +2010,7 @@ static void D_DoomInit()
//
//==========================================================================
static void AddAutoloadFiles(const char *gamesection)
static void AddAutoloadFiles(const char *group, const char *autoname)
{
if (!(gameinfo.flags & GI_SHAREWARE) && !Args->CheckParm("-noautoload"))
{
@ -2046,10 +2047,18 @@ static void AddAutoloadFiles(const char *gamesection)
file += ".Autoload";
D_AddConfigWads (allwads, file);
// Add group-specific wads
if (group != NULL)
{
file = group;
file += ".Autoload";
D_AddConfigWads(allwads, file);
}
// Add IWAD-specific wads
if (gamesection != NULL)
if (autoname != NULL)
{
file = gamesection;
file = autoname;
file += ".Autoload";
D_AddConfigWads(allwads, file);
}
@ -2217,6 +2226,26 @@ void D_DoomMain (void)
execLogfile(logfile);
}
if (Args->CheckParm("-hashfiles"))
{
const char *filename = "fileinfo.txt";
Printf("Hashing loaded content to: %s\n", filename);
hashfile = fopen(filename, "w");
if (hashfile)
{
fprintf(hashfile, "%s version %s (%s)\n", GAMENAME, GetVersionString(), GetGitHash());
#ifdef __VERSION__
fprintf(hashfile, "Compiler version: %s\n", __VERSION__);
#endif
fprintf(hashfile, "Command line:");
for (int i = 0; i < Args->NumArgs(); ++i)
{
fprintf(hashfile, " %s", Args->GetArg(i));
}
fprintf(hashfile, "\n");
}
}
D_DoomInit();
// [RH] Make sure zdoom.pk3 is always loaded,
@ -2264,7 +2293,7 @@ void D_DoomMain (void)
FBaseCVar::DisableCallbacks();
GameConfig->DoGameSetup (gameinfo.ConfigName);
AddAutoloadFiles(iwad_info->Autoname);
AddAutoloadFiles(iwad_info->Group, iwad_info->Autoname);
// Run automatically executed files
execFiles = new DArgs;
@ -2283,6 +2312,11 @@ void D_DoomMain (void)
pwads.Clear();
pwads.ShrinkToFit();
if (hashfile)
{
Printf("Notice: File hashing is incredibly verbose. Expect loading files to take much longer then usual.\n");
}
Printf ("W_Init: Init WADfiles.\n");
Wads.InitMultipleFiles (allwads);
allwads.Clear();