Notifier: Disable flash notification when off is selected to prevent

stuck flash state
This commit is contained in:
Derek Lopes
2020-07-21 17:55:37 -07:00
committed by Adam
parent 24cfac14fa
commit ef86486a82

View File

@@ -208,14 +208,15 @@ public class Notifier
public void processFlash(final Graphics2D graphics)
{
if (flashStart == null || client.getGameState() != GameState.LOGGED_IN)
FlashNotification flashNotification = runeLiteConfig.flashNotification();
if (flashStart == null || client.getGameState() != GameState.LOGGED_IN
|| flashNotification == FlashNotification.DISABLED)
{
flashStart = null;
return;
}
FlashNotification flashNotification = runeLiteConfig.flashNotification();
if (Instant.now().minusMillis(MINIMUM_FLASH_DURATION_MILLIS).isAfter(flashStart))
{
switch (flashNotification)