mirror of
https://github.com/ZDoom/Raze.git
synced 2024-11-15 08:51:24 +00:00
- restrict lookup of engine/engine.def to the main game files.
Mods should not use this to load their data.
This commit is contained in:
parent
9d36e61d3f
commit
1cea743536
3 changed files with 4 additions and 3 deletions
|
@ -2116,7 +2116,7 @@ static void defsparser(FScanner& sc)
|
|||
}
|
||||
}
|
||||
|
||||
void loaddefinitionsfile(const char* fn, bool cumulative)
|
||||
void loaddefinitionsfile(const char* fn, bool cumulative, bool maingame)
|
||||
{
|
||||
bool done = false;
|
||||
auto parseit = [&](int lump)
|
||||
|
@ -2154,6 +2154,7 @@ void loaddefinitionsfile(const char* fn, bool cumulative)
|
|||
int lump, lastlump = 0;
|
||||
while ((lump = fileSystem.FindLumpFullName(fn, &lastlump)) >= 0)
|
||||
{
|
||||
if (maingame && fileSystem.GetFileContainer(lump) > fileSystem.GetMaxIwadNum()) break;
|
||||
Printf(PRINT_NONOTIFY, "Loading \"%s\"\n", fileSystem.GetFileFullPath(lump).GetChars());
|
||||
deftimer.Clock();
|
||||
parseit(lump);
|
||||
|
|
|
@ -1411,7 +1411,7 @@ void LoadDefinitions()
|
|||
FString razedefsfile = defsfile;
|
||||
razedefsfile.Substitute(".def", "-raze.def");
|
||||
|
||||
loaddefinitionsfile("engine/engine.def"); // Internal stuff that is required.
|
||||
loaddefinitionsfile("engine/engine.def", true, true); // Internal stuff that is required.
|
||||
|
||||
// check what we have.
|
||||
// user .defs override the default ones and are not cumulative.
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
|
||||
extern int cameradist, cameraclock;
|
||||
|
||||
void loaddefinitionsfile(const char* fn, bool cumulative = false);
|
||||
void loaddefinitionsfile(const char* fn, bool cumulative = false, bool maingrp = false);
|
||||
|
||||
bool calcChaseCamPos(int* px, int* py, int* pz, spritetype* pspr, short *psectnum, binangle ang, fixedhoriz horiz, double const smoothratio);
|
||||
void PlanesAtPoint(const sectortype* sec, int dax, int day, float* ceilz, float* florz);
|
||||
|
|
Loading…
Reference in a new issue