mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-23 12:32:34 +00:00
- fixed incomplete commit.
I have no idea where the rest of this stuff went...
This commit is contained in:
parent
de375ce187
commit
65b01bd16d
7 changed files with 14 additions and 11 deletions
|
@ -3134,7 +3134,7 @@ void MapLoader::LoadLevel(MapData *map, const char *lumpname, int position)
|
|||
for (auto & p : Level->bodyque)
|
||||
p = nullptr;
|
||||
|
||||
CreateSections(Level->sections);
|
||||
CreateSections(Level);
|
||||
|
||||
// [RH] Spawn slope creating things first.
|
||||
SpawnSlopeMakers(&MapThingsConverted[0], &MapThingsConverted[MapThingsConverted.Size()], oldvertextable);
|
||||
|
@ -3184,7 +3184,7 @@ void MapLoader::LoadLevel(MapData *map, const char *lumpname, int position)
|
|||
}
|
||||
|
||||
SWRenderer->SetColormap(); //The SW renderer needs to do some special setup for the level's default colormap.
|
||||
InitPortalGroups();
|
||||
InitPortalGroups(Level);
|
||||
P_InitHealthGroups();
|
||||
|
||||
if (reloop) LoopSidedefs(false);
|
||||
|
|
|
@ -1031,5 +1031,5 @@ void G_SerializeLevel(FSerializer &arc, bool hubload)
|
|||
}
|
||||
}
|
||||
AActor::RecreateAllAttachedLights();
|
||||
InitPortalGroups();
|
||||
InitPortalGroups(&level);
|
||||
}
|
||||
|
|
|
@ -282,7 +282,8 @@ void P_TranslatePortalVXVY(line_t* src, double &velx, double &vely);
|
|||
void P_TranslatePortalAngle(line_t* src, DAngle& angle);
|
||||
void P_TranslatePortalZ(line_t* src, double& vz);
|
||||
DVector2 P_GetOffsetPosition(double x, double y, double dx, double dy);
|
||||
void InitPortalGroups();
|
||||
struct FLevelLocals;
|
||||
void InitPortalGroups(FLevelLocals *Level);
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -373,7 +373,7 @@ static void GroupSectorPortals(FLevelLocals *Level)
|
|||
for (int k = 0; k < sec->subsectorcount; k++)
|
||||
{
|
||||
subsector_t *sub = sec->subsectors[k];
|
||||
BuildPortalCoverage(&sub->portalcoverage[plane], sub, pair->Key.mDisplacement);
|
||||
BuildPortalCoverage(Level, &sub->portalcoverage[plane], sub, pair->Key.mDisplacement);
|
||||
}
|
||||
sec->portals[plane] = portal;
|
||||
}
|
||||
|
|
|
@ -815,6 +815,7 @@ public:
|
|||
|
||||
void PrintSections(FSectionContainer &container)
|
||||
{
|
||||
auto Level = &level;
|
||||
for (unsigned i = 0; i < container.allSections.Size(); i++)
|
||||
{
|
||||
auto §ion = container.allSections[i];
|
||||
|
@ -861,21 +862,21 @@ void PrintSections(FSectionContainer &container)
|
|||
//
|
||||
//=============================================================================
|
||||
|
||||
void CreateSections(FSectionContainer &container)
|
||||
void CreateSections(FLevelLocals *Level)
|
||||
{
|
||||
FSectionCreator creat;
|
||||
FSectionCreator creat(Level);
|
||||
creat.GroupSubsectors();
|
||||
creat.MakeOutlines();
|
||||
creat.MergeLines();
|
||||
creat.FindOuterLoops();
|
||||
creat.GroupSections();
|
||||
creat.ConstructOutput(container);
|
||||
creat.ConstructOutput(Level->sections);
|
||||
creat.FixMissingReferences();
|
||||
}
|
||||
|
||||
CCMD(printsections)
|
||||
{
|
||||
PrintSections(Level->sections);
|
||||
PrintSections(level.sections);
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -160,7 +160,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
|
||||
struct FLevelLocals;
|
||||
void CreateSections(FLevelLocals *l);
|
||||
|
||||
#endif
|
||||
|
|
|
@ -52,6 +52,7 @@ struct seg_t;
|
|||
struct sector_t;
|
||||
class AActor;
|
||||
struct FSection;
|
||||
struct FLevelLocals;
|
||||
|
||||
#define MAXWIDTH 12000
|
||||
#define MAXHEIGHT 5000
|
||||
|
@ -1513,7 +1514,7 @@ struct FPortalCoverage
|
|||
int sscount;
|
||||
};
|
||||
|
||||
void BuildPortalCoverage(FPortalCoverage *coverage, subsector_t *subsector, const DVector2 &displacement);
|
||||
void BuildPortalCoverage(FLevelLocals *Level, FPortalCoverage *coverage, subsector_t *subsector, const DVector2 &displacement);
|
||||
|
||||
struct subsector_t
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue