1
0
Fork 0
mirror of https://git.coom.tech/drummyfish/raycastlib.git synced 2024-11-20 20:19:57 +01:00

Fix door roll

This commit is contained in:
Miloslav Číž 2018-09-25 08:06:49 +02:00
parent bca49edeb1
commit 300eceb005

View file

@ -1400,9 +1400,11 @@ void _RCL_columnFunctionSimple(RCL_HitResult *hits, uint16_t hitCount,
{
// normal hit, check the door roll
RCL_Unit texCoordMod = hit.textureCoord % RCL_UNITS_PER_SQUARE;
int8_t unrolled = hit.doorRoll >= 0 ?
hit.doorRoll > hit.textureCoord :
hit.textureCoord > RCL_UNITS_PER_SQUARE + hit.doorRoll;
hit.doorRoll > texCoordMod :
texCoordMod > RCL_UNITS_PER_SQUARE + hit.doorRoll;
if (unrolled)
{