Skip to content

Commit

Permalink
Conditionally show the titan icon
Browse files Browse the repository at this point in the history
  • Loading branch information
IncPlusPlus committed Sep 7, 2021
1 parent 4f26cd9 commit dafa412
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions titanfall2-rp/GameDetailsProvider.cs
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,13 @@ public static (string, string, Timestamps?, Assets? assets) GetMultiplayerDetail
string gameDetails = tf2Api.GetGameMode().ToFriendlyString();
string gameState = "";
var timestamps = new Timestamps(gameOpenTimestamp);
var playerInTitan = tf2Api.IsPlayerInTitan();
var assets = new Assets
{
LargeImageKey = tf2Api.GetMultiplayerMapName(),
LargeImageText = tf2Api.GetFriendlyMapName(),
SmallImageKey = tf2Api.GetMultiPlayerGameStats().GetCurrentFaction().GetAssetName(),
SmallImageText = tf2Api.GetMultiPlayerGameStats().GetCurrentFaction().ToFriendlyString(),
SmallImageKey = playerInTitan ? tf2Api.GetTitan().GetAssetName() : tf2Api.GetMultiPlayerGameStats().GetCurrentFaction().GetAssetName(),
SmallImageText = playerInTitan ? tf2Api.GetTitan().ToFriendlyString():tf2Api.GetMultiPlayerGameStats().GetCurrentFaction().ToFriendlyString(),
};
switch (currentGameMode)
{
Expand Down

0 comments on commit dafa412

Please sign in to comment.