Skip to content

Commit

Permalink
Update Aurora message to use settings
Browse files Browse the repository at this point in the history
  • Loading branch information
Arkhorse committed Jun 7, 2023
1 parent 50078de commit e3e24ba
Show file tree
Hide file tree
Showing 7 changed files with 6 additions and 12 deletions.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified .vs/AuroraMonitor/v17/.suo
Binary file not shown.
2 changes: 1 addition & 1 deletion VisualStudio/Patches/GameManager_Update.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ private static void Postfix()
{
if (GameManager.GetAuroraManager().GetNormalizedAlpha() > 0f)
{
Utilities.AuroraMonitorMessage("Active");
Utilities.AuroraMonitorMessage("Aurora Active", Settings.Instance.AuroraNotificationTime);
}
if (GameManager.GetAuroraManager().GetNormalizedAlpha() == 0f && AuroraMonitor.AuroraActive)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ internal class WeatherTransition_ChooseNextWeatherSet
{
private static void Postfix()
{
GearMessage.AddMessage("ico_journal", "Aurora Monitor", $"Next Weather Set: {GameManager.GetWeatherComponent().GetWeatherStage()}", 15f, false, true);
Utilities.AuroraMonitorMessage($"Next Weather: {GameManager.GetWeatherComponent().GetWeatherStage()}", Settings.Instance.WeatherStageNotificationTime);
}
}
}
14 changes: 4 additions & 10 deletions VisualStudio/Utilities/Utilities.cs
Original file line number Diff line number Diff line change
Expand Up @@ -36,25 +36,19 @@ internal class Utilities

// Aurora Monitor Utils

public static void AuroraMonitorMessage(string message, bool log = false)
public static void AuroraMonitorMessage(string message, float messageTime, bool log = false)
{
if (message == null) return;
if (AuroraMonitor.AuroraActive) return;
AuroraMonitor.AuroraActive = true;
if (log) Log($"Aurora {message}");
GearMessage.AddMessage("ico_journal", "Aurora Monitor", $"Aurora {message}", 15f, false, true);
GearMessage.AddMessage("ico_journal", "Aurora Monitor", $"{message}", messageTime, false, true);
}

public static void UpdateAuroraColor()
{
if (Settings.Instance.AuroraColour == Settings.AuroraColourSettings.Cinematic)
{
GameManager.GetAuroraManager().SetCinematicColours(true);
}
else
{
GameManager.GetAuroraManager().SetCinematicColours(false);
}
if (Settings.Instance.AuroraColour == Settings.AuroraColourSettings.Cinematic) GameManager.GetAuroraManager().SetCinematicColours(true);
else GameManager.GetAuroraManager().SetCinematicColours(false);
}
}
}

0 comments on commit e3e24ba

Please sign in to comment.