mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-12-11 13:11:48 +00:00
- fixed conditions for PortalBlocksView. Created a new function PortalBlocksSight that's relevant for playsim-related sight checks.
This commit is contained in:
parent
7da9a0463b
commit
0ecfc68205
2 changed files with 8 additions and 0 deletions
|
@ -205,6 +205,13 @@ inline int line_t::getPortalAlignment() const
|
||||||
}
|
}
|
||||||
|
|
||||||
inline bool sector_t::PortalBlocksView(int plane)
|
inline bool sector_t::PortalBlocksView(int plane)
|
||||||
|
{
|
||||||
|
if (SkyBoxes[plane] == NULL) return true;
|
||||||
|
if (SkyBoxes[plane]->special1 != SKYBOX_LINKEDPORTAL) return false;
|
||||||
|
return !!(planes[plane].Flags & (PLANEF_NORENDER | PLANEF_DISABLED | PLANEF_OBSTRUCTED));
|
||||||
|
}
|
||||||
|
|
||||||
|
inline bool sector_t::PortalBlocksSight(int plane)
|
||||||
{
|
{
|
||||||
if (SkyBoxes[plane] == NULL || SkyBoxes[plane]->special1 != SKYBOX_LINKEDPORTAL) return true;
|
if (SkyBoxes[plane] == NULL || SkyBoxes[plane]->special1 != SKYBOX_LINKEDPORTAL) return true;
|
||||||
return !!(planes[plane].Flags & (PLANEF_NORENDER | PLANEF_DISABLED | PLANEF_OBSTRUCTED));
|
return !!(planes[plane].Flags & (PLANEF_NORENDER | PLANEF_DISABLED | PLANEF_OBSTRUCTED));
|
||||||
|
|
|
@ -793,6 +793,7 @@ struct sector_t
|
||||||
}
|
}
|
||||||
|
|
||||||
bool PortalBlocksView(int plane);
|
bool PortalBlocksView(int plane);
|
||||||
|
bool PortalBlocksSight(int plane);
|
||||||
bool PortalBlocksMovement(int plane);
|
bool PortalBlocksMovement(int plane);
|
||||||
bool PortalBlocksSound(int plane);
|
bool PortalBlocksSound(int plane);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue