mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-11-11 07:12:16 +00:00
- fixed: Old portal data must be deleted before loading a new level.
This commit is contained in:
parent
cb0e7c6ca5
commit
dc37f78566
4 changed files with 16 additions and 2 deletions
|
@ -4178,7 +4178,6 @@ bool DLevelScript::DoCheckActorTexture(int tid, AActor *activator, int string, b
|
|||
// they're obviously not the same.
|
||||
return 0;
|
||||
}
|
||||
int i, numff;
|
||||
FTextureID secpic;
|
||||
sector_t *resultsec;
|
||||
F3DFloor *resffloor;
|
||||
|
|
|
@ -3392,12 +3392,12 @@ void P_FreeLevelData ()
|
|||
FPolyObj::ClearAllSubsectorLinks(); // can't be done as part of the polyobj deletion process.
|
||||
SN_StopAllSequences ();
|
||||
DThinker::DestroyAllThinkers ();
|
||||
P_ClearPortals();
|
||||
tagManager.Clear();
|
||||
level.total_monsters = level.total_items = level.total_secrets =
|
||||
level.killed_monsters = level.found_items = level.found_secrets =
|
||||
wminfo.maxfrags = 0;
|
||||
|
||||
linePortals.Clear();
|
||||
FBehavior::StaticUnloadModules ();
|
||||
if (vertexes != NULL)
|
||||
{
|
||||
|
|
|
@ -359,6 +359,20 @@ bool P_ChangePortal(line_t *ln, int thisid, int destid)
|
|||
return res;
|
||||
}
|
||||
|
||||
//============================================================================
|
||||
//
|
||||
// clears all portal dat for a new level start
|
||||
//
|
||||
//============================================================================
|
||||
|
||||
void P_ClearPortals()
|
||||
{
|
||||
Displacements.Create(1);
|
||||
linePortals.Clear();
|
||||
linkedPortals.Clear();
|
||||
}
|
||||
|
||||
|
||||
//============================================================================
|
||||
//
|
||||
// Calculate the intersection between two lines.
|
||||
|
|
|
@ -123,6 +123,7 @@ struct FLinePortal
|
|||
|
||||
extern TArray<FLinePortal> linePortals;
|
||||
|
||||
void P_ClearPortals();
|
||||
void P_SpawnLinePortal(line_t* line);
|
||||
void P_FinalizePortals();
|
||||
bool P_ChangePortal(line_t *ln, int thisid, int destid);
|
||||
|
|
Loading…
Reference in a new issue