This commit is contained in:
TinyHerm committed 2026-11-24 23:40:08 +03:00
commit 1c7a8cf25f
579 files changed
+83196

No files matched your search

+35
View File
@@ -0,0 +1,35 @@
using System;
using System.Collections.Generic;
using System.Linq;
namespace VibranceHud.Games;
internal static class GameSetupOffer
{
internal static bool ShouldOffer(string gameId, bool profileExists, IEnumerable<string> declined, string alreadyPending)
{
if (string.IsNullOrEmpty(gameId))
{
return false;
}
if (GameLookJoin.LookGameFor(gameId) == null)
{
return false;
}
if (profileExists)
{
return false;
}
if (!string.IsNullOrEmpty(alreadyPending))
{
return false;
}
return !(declined ?? Enumerable.Empty<string>()).Any((string d) => string.Equals(d, gameId, StringComparison.OrdinalIgnoreCase));
}
internal static string Sentence(string gameId)
{
string value = GameLookJoin.LookGameFor(gameId) ?? gameId;
return $"Playing {value}? PlexusX can use the {value} look every time you launch it.";
}
}