- changed secret message handling so that the debug output of the sector number is only printed to the console but not the centered message.

This commit is contained in:
Christoph Oelckers 2019-11-12 23:39:05 +01:00
parent 72bba914ce
commit 5cc75af295

View file

@ -592,12 +592,10 @@ void P_GiveSecret(FLevelLocals *Level, AActor *actor, bool printmessage, bool pl
{ {
if (printmessage) if (printmessage)
{ {
if (!showsecretsector || sectornum < 0) C_MidPrint(nullptr, GStrings["SECRETMESSAGE"]); C_MidPrint(nullptr, GStrings["SECRETMESSAGE"]);
else if (showsecretsector && sectornum >= 0)
{ {
FString s = GStrings["SECRETMESSAGE"]; Printf(PRINT_NONOTIFY, "Secret found in sector %d\n", sectornum);
s.AppendFormat(" (Sector %d)", sectornum);
C_MidPrint(nullptr, s);
} }
} }
if (playsound) S_Sound (CHAN_AUTO | CHAN_UI, "misc/secret", 1, ATTN_NORM); if (playsound) S_Sound (CHAN_AUTO | CHAN_UI, "misc/secret", 1, ATTN_NORM);