Add support for multiple portals

This commit is contained in:
Magnus Norddahl 2016-11-25 17:14:26 +01:00
commit 93af906a1d
5 changed files with 24 additions and 12 deletions

View file

@ -264,7 +264,7 @@ void RenderPolyPlane::Render(const TriMatrix &worldToClip, subsector_t *sub, uin
}
else
{
args.stencilwritevalue = 252;
args.stencilwritevalue = polyportal->StencilValue;
PolyTriangleDrawer::draw(args, TriDrawVariant::Stencil, TriBlendMode::Copy);
polyportal->Shape.push_back({ args.vinput, args.vcount, args.ccw, subsectorDepth });
}
@ -273,7 +273,7 @@ void RenderPolyPlane::Render(const TriMatrix &worldToClip, subsector_t *sub, uin
{
if (portal)
{
args.stencilwritevalue = 252;
args.stencilwritevalue = polyportal->StencilValue;
polyportal->Shape.push_back({ args.vinput, args.vcount, args.ccw, subsectorDepth });
}
else