Effect 6 flag allows cutting of cyan pixels on FOF and PolyObject planes (even if they're translucent)

This commit is contained in:
MascaraSnake 2020-06-03 19:41:47 +02:00
parent 04c7eeb6ae
commit 33ed36cf4b
4 changed files with 31 additions and 8 deletions

View file

@ -760,6 +760,7 @@ linedeftypes
flags128text = "[7] Intangible";
flags256text = "[8] Stopped by pushables";
flags512text = "[9] Render flats";
flags8192text = "[13] Cut cyan flat pixels";
}
30
@ -914,6 +915,7 @@ linedeftypes
flags32text = "[5] Only block player";
flags64text = "[6] Render insides";
flags128text = "[7] Only block non-players";
flags8192text = "[13] Cut cyan flat pixels";
3dfloor = true;
3dfloorflags = "195F";
flags643dfloorflagsadd = "7C80";
@ -973,6 +975,7 @@ linedeftypes
flags32text = "[5] Only block player";
flags64text = "[6] Don't cast shadow";
flags128text = "[7] Render insides/block non-plr";
flags8192text = "[13] Cut cyan flat pixels";
3dfloor = true;
3dfloorflags = "200191F";
flags1283dfloorflagsadd = "7C80";
@ -986,6 +989,7 @@ linedeftypes
flags32text = "[5] Only block player";
flags64text = "[6] Don't cast shadow";
flags128text = "[7] Render insides/block non-plr";
flags8192text = "[13] Cut cyan flat pixels";
3dfloor = true;
3dfloorflags = "2001917";
flags1283dfloorflagsadd = "7C80";
@ -1013,6 +1017,7 @@ linedeftypes
flags32text = "[5] Only block player";
flags64text = "[6] Don't cast shadow";
flags128text = "[7] Render insides/block non-plr";
flags8192text = "[13] Cut cyan flat pixels";
3dfloor = true;
3dfloorflags = "400191F";
flags1283dfloorflagsadd = "7C80";
@ -1026,6 +1031,7 @@ linedeftypes
flags32text = "[5] Only block player";
flags64text = "[6] Don't cast shadow";
flags128text = "[7] Render insides/block non-plr";
flags8192text = "[13] Cut cyan flat pixels";
3dfloor = true;
3dfloorflags = "4001917";
flags1283dfloorflagsadd = "7C80";
@ -1071,6 +1077,7 @@ linedeftypes
flags64text = "[6] Use two light levels";
flags512text = "[9] Use target light level";
flags1024text = "[10] Ripple effect";
flags8192text = "[13] Cut cyan flat pixels";
3dfloor = true;
3dfloorflags = "9F39";
flags643dfloorflagsadd = "20000";
@ -1099,6 +1106,7 @@ linedeftypes
flags64text = "[6] Use two light levels";
flags512text = "[9] Use target light level";
flags1024text = "[10] Ripple effect";
flags8192text = "[13] Cut cyan flat pixels";
3dfloor = true;
3dfloorflags = "1F31";
flags643dfloorflagsadd = "20000";
@ -1114,6 +1122,7 @@ linedeftypes
flags64text = "[6] Use two light levels";
flags512text = "[9] Use target light level";
flags1024text = "[10] Ripple effect";
flags8192text = "[13] Cut cyan flat pixels";
3dfloor = true;
3dfloorflags = "209F39";
flags643dfloorflagsadd = "20000";
@ -1128,6 +1137,7 @@ linedeftypes
flags64text = "[6] Use two light levels";
flags512text = "[9] Use target light level";
flags1024text = "[10] Ripple effect";
flags8192text = "[13] Cut cyan flat pixels";
3dfloor = true;
3dfloorflags = "201F31";
flags643dfloorflagsadd = "20000";
@ -1150,6 +1160,7 @@ linedeftypes
prefix = "(221)";
flags8text = "[3] Slope skew sides";
flags64text = "[6] Cast shadow";
flags8192text = "[13] Cut cyan flat pixels";
3dfloor = true;
3dfloorflags = "1B59";
flags643dfloorflagsremove = "40";
@ -1273,6 +1284,7 @@ linedeftypes
flags32text = "[5] Only block player";
flags64text = "[6] Spindash to move";
flags128text = "[7] Only block non-players";
flags8192text = "[13] Cut cyan flat pixels";
3dfloor = true;
3dfloorflags = "195F";
}
@ -1312,6 +1324,7 @@ linedeftypes
flags32text = "[5] Only block player";
flags64text = "[6] Spindash, no shadow";
flags128text = "[7] Only block non-players";
flags8192text = "[13] Cut cyan flat pixels";
3dfloor = true;
3dfloorflags = "2009D1F";
flags643dfloorflagsadd = "40";
@ -1378,6 +1391,7 @@ linedeftypes
flags32text = "[5] Only block player";
flags64text = "[6] Don't cast shadow";
flags128text = "[7] Only block non-players";
flags8192text = "[13] Cut cyan flat pixels";
3dfloor = true;
3dfloorflags = "210959F";
flags643dfloorflagsadd = "40";
@ -1391,6 +1405,7 @@ linedeftypes
flags32text = "[5] Only block player";
flags64text = "[6] Don't cast shadow";
flags128text = "[7] Only block non-players";
flags8192text = "[13] Cut cyan flat pixels";
3dfloor = true;
3dfloorflags = "218959F";
flags643dfloorflagsadd = "40";
@ -1529,6 +1544,7 @@ linedeftypes
flags8text = "[3] Slope skew sides";
flags512text = "[9] Shattered by pushables";
flags1024text = "[10] Trigger linedef executor";
flags8192text = "[13] Cut cyan flat pixels";
3dfloor = true;
3dfloorflags = "880101D";
}
@ -1570,6 +1586,7 @@ linedeftypes
flags128text = "[7] Only block non-players";
flags512text = "[9] Shattered by pushables";
flags1024text = "[10] Trigger linedef executor";
flags8192text = "[13] Cut cyan flat pixels";
3dfloor = true;
3dfloorflags = "1080101F";
}
@ -1591,6 +1608,7 @@ linedeftypes
prefix = "(258)";
flags8text = "[3] Slope skew sides";
flags32text = "[5] Don't damage bosses";
flags8192text = "[13] Cut cyan flat pixels";
3dfloor = true;
3dfloorflags = "959";
}
@ -1604,6 +1622,7 @@ linedeftypes
flags128text = "[7] Only block non-players";
flags512text = "[9] Shattered by pushables";
flags1024text = "[10] Trigger linedef executor";
flags8192text = "[13] Cut cyan flat pixels";
3dfloor = true;
3dfloorcustom = true;
}

View file

@ -240,6 +240,9 @@ static void Polyobj_GetInfo(polyobj_t *po)
/*if (lines[i].flags & ML_EFFECT5)
po->flags &= ~POF_CLIPPLANES;*/
if (lines[i].flags & ML_EFFECT6)
po->flags |= POF_SPLAT;
if (lines[i].flags & ML_NOCLIMB) // Has a linedef executor
po->flags |= POF_LDEXEC;
}

View file

@ -38,7 +38,7 @@ typedef enum
POF_SOLID = 0x3, ///< Clips things.
POF_TESTHEIGHT = 0x4, ///< Test line collision with heights
POF_RENDERSIDES = 0x8, ///< Renders the sides.
POF_RENDERTOP = 0x10, ///< Renders the top..
POF_RENDERTOP = 0x10, ///< Renders the top.
POF_RENDERBOTTOM = 0x20, ///< Renders the bottom.
POF_RENDERPLANES = 0x30, ///< Renders top and bottom.
POF_RENDERALL = 0x38, ///< Renders everything.
@ -49,6 +49,7 @@ typedef enum
POF_LDEXEC = 0x400, ///< This PO triggers a linedef executor.
POF_ONESIDE = 0x800, ///< Only use the first side of the linedef.
POF_NOSPECIALS = 0x1000, ///< Don't apply sector specials.
POF_SPLAT = 0x2000, ///< Use splat flat renderer (treat cyan pixels as invisible).
} polyobjflags_e;
//

View file

@ -943,23 +943,23 @@ void R_DrawSinglePlane(visplane_t *pl)
#endif
spanfunc = spanfuncs[BASEDRAWFUNC];
if (pl->polyobj && pl->polyobj->translucency != 0)
if (pl->polyobj)
{
spanfunctype = SPANDRAWFUNC_TRANS;
// Hacked up support for alpha value in software mode Tails 09-24-2002 (sidenote: ported to polys 10-15-2014, there was no time travel involved -Red)
if (pl->polyobj->translucency >= 10)
return; // Don't even draw it
else if (pl->polyobj->translucency > 0)
{
spanfunctype = (pl->polyobj->flags & POF_SPLAT) ? SPANDRAWFUNC_TRANSSPLAT : SPANDRAWFUNC_TRANS;
ds_transmap = transtables + ((pl->polyobj->translucency-1)<<FF_TRANSSHIFT);
else // Opaque, but allow transparent flat pixels
}
else if (pl->polyobj->flags & POF_SPLAT) // Opaque, but allow transparent flat pixels
spanfunctype = SPANDRAWFUNC_SPLAT;
if ((spanfunctype == SPANDRAWFUNC_SPLAT) || (pl->extra_colormap && (pl->extra_colormap->flags & CMF_FOG)))
if (pl->polyobj->translucency == 0 || (pl->extra_colormap && (pl->extra_colormap->flags & CMF_FOG)))
light = (pl->lightlevel >> LIGHTSEGSHIFT);
else
light = LIGHTLEVELS-1;
}
else
{
@ -984,7 +984,7 @@ void R_DrawSinglePlane(visplane_t *pl)
if (pl->ffloor->flags & FF_TRANSLUCENT)
{
spanfunctype = SPANDRAWFUNC_TRANS;
spanfunctype = (pl->ffloor->master->flags & ML_EFFECT6) ? SPANDRAWFUNC_TRANSSPLAT : SPANDRAWFUNC_TRANS;
// Hacked up support for alpha value in software mode Tails 09-24-2002
if (pl->ffloor->alpha < 12)