- added forced automap style to linedef, UDMF only

https://forum.zdoom.org/viewtopic.php?t=59808
This commit is contained in:
alexey.lysiuk 2018-05-19 10:49:04 +03:00 committed by Christoph Oelckers
commit c6f7d92c76
4 changed files with 57 additions and 0 deletions

View file

@ -324,6 +324,30 @@ struct AMColorset
}
};
//=============================================================================
//
// automap colors forced by linedef
//
//=============================================================================
static const int AUTOMAP_LINE_COLORS[AMLS_COUNT] =
{
-1, // AMLS_Default (unused)
AMColorset::WallColor, // AMLS_OneSided,
AMColorset::TSWallColor, // AMLS_TwoSided
AMColorset::FDWallColor, // AMLS_FloorDiff
AMColorset::CDWallColor, // AMLS_CeilingDiff
AMColorset::EFWallColor, // AMLS_ExtraFloor
AMColorset::SpecialWallColor, // AMLS_Special
AMColorset::SecretWallColor, // AMLS_Secret
AMColorset::NotSeenColor, // AMLS_NotSeen
AMColorset::LockedColor, // AMLS_Locked
AMColorset::IntraTeleportColor, // AMLS_IntraTeleport
AMColorset::InterTeleportColor, // AMLS_InterTeleport
AMColorset::UnexploredSecretColor, // AMLS_UnexploredSecret
AMColorset::PortalColor, // AMLS_Portal
};
//=============================================================================
//
// predefined colorsets
@ -2583,6 +2607,13 @@ void AM_drawWalls (bool allmap)
}
}
if (line.automapstyle > AMLS_Default && line.automapstyle < AMLS_COUNT
&& (am_cheat == 0 || am_cheat >= 4))
{
AM_drawMline(&l, AUTOMAP_LINE_COLORS[line.automapstyle]);
continue;
}
if (portalmode)
{
AM_drawMline(&l, AMColors.PortalColor);