Skip to content

Commit

Permalink
Added fight awards to Discord report
Browse files Browse the repository at this point in the history
  • Loading branch information
bear-on-the-job committed Apr 6, 2024
1 parent 53e4e09 commit ee25c79
Show file tree
Hide file tree
Showing 15 changed files with 221,646 additions and 14 deletions.
3 changes: 3 additions & 0 deletions DiscordApi/DiscordWebhookData.cs
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,9 @@ internal sealed class DiscordWebhookData
//BEAR
[JsonProperty("showOpponentIcons")]
internal bool ShowClassIcons { get; set; } = true;
//BEAR
[JsonProperty("showFightAwards")]
internal bool ShowFightAwards { get; set; } = true;

/// <summary>
/// A selected webhook team, with which the webhook should evaluate itself
Expand Down
15 changes: 15 additions & 0 deletions DpsReport/ExtraJSON/BuffData.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
using Newtonsoft.Json;
using Newtonsoft.Json.Linq;

namespace PlenBotLogUploader.DpsReport.ExtraJson
{
internal sealed class BuffData
{
[JsonProperty("uptime")]
internal float Uptime { get; set; }

[JsonProperty("generated")]
// Needs to be a JObject, because the members are dynamically named, based on player names...
internal JObject Generated { get; set; }
}
}
13 changes: 13 additions & 0 deletions DpsReport/ExtraJSON/BuffUptimes.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
using Newtonsoft.Json;

namespace PlenBotLogUploader.DpsReport.ExtraJson
{
internal sealed class BuffUptimes
{
[JsonProperty("id")]
internal int Id{ get; set; }

[JsonProperty("buffData")]
internal BuffData[] BuffData { get; set; }
}
}
13 changes: 13 additions & 0 deletions DpsReport/ExtraJSON/Buffs.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
using Newtonsoft.Json;

namespace PlenBotLogUploader.DpsReport.ExtraJson
{
internal sealed class Buffs
{
[JsonProperty("id")]
internal int Id { get; set; }

[JsonProperty("buffData")]
internal BuffData[] BuffData { get; set; }
}
}
21 changes: 21 additions & 0 deletions DpsReport/ExtraJSON/Defenses.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,26 @@ internal sealed class Defenses

[JsonProperty("damageBarrier")]
internal int DamageBarrier { get; set; }

[JsonProperty("downDuration")]
internal float DownDuration { get; set; }

[JsonProperty("blockedCount")]
internal float BlockedCount { get; set; }

[JsonProperty("evadedCount")]
internal float EvadedCount { get; set; }

[JsonProperty("missedCount")]
internal float MissedCount { get; set; }

[JsonProperty("dodgeCount")]
internal float DodgeCount { get; set; }

[JsonProperty("interruptedCount")]
internal float InterruptedCount { get; set; }

[JsonProperty("boonStrips")]
internal float BoonStrips { get; set; }
}
}
6 changes: 6 additions & 0 deletions DpsReport/ExtraJSON/Player.cs
Original file line number Diff line number Diff line change
Expand Up @@ -111,5 +111,11 @@ internal string ProfessionShort

[JsonProperty("totalDamageDist")]
internal TotalDamageDist[][] TotalDamageDist { get; set; }

[JsonProperty("buffUptimes")]
internal BuffUptimes[] BuffUptimes { get; set; }

[JsonProperty("targetDamageDist")]
internal TargetDamageDist[][][] TargetDamageDist { get; set; }
}
}
3 changes: 3 additions & 0 deletions DpsReport/ExtraJSON/PlayerSupport.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,8 @@ internal sealed class PlayerSupport

[JsonProperty("boonStrips")]
internal int BoonStrips { get; set; }

[JsonProperty("resurrectTime")]
internal float ResurrectTime { get; set; }
}
}
21 changes: 21 additions & 0 deletions DpsReport/ExtraJSON/StatsAll.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,26 @@ internal sealed class StatsAll

[JsonProperty("downed")]
internal int Downed { get; set; }

[JsonProperty("flankingRate")]
internal float FlankingRate { get; set; }

[JsonProperty("criticalRate")]
internal float CriticalRate { get; set; }

[JsonProperty("distToCom")]
internal float DistToCom { get; set; }

[JsonProperty("swapCount")]
internal float SwapCount { get; set; }

[JsonProperty("interrupts")]
internal float Interrupts { get; set; }

[JsonProperty("connectedDirectDamageCount")]
internal float ConnectedDirectDamageCount { get; set; }

[JsonProperty("glanceRate")]
internal float GlanceRate { get; set; }
}
}
3 changes: 3 additions & 0 deletions DpsReport/ExtraJSON/Target.cs
Original file line number Diff line number Diff line change
Expand Up @@ -33,5 +33,8 @@ internal sealed class Target

[JsonProperty("teamId")]
internal int TeamId { get; set; }

[JsonProperty("buffs")]
internal Buffs[] Buffs { get; set; }
}
}
5 changes: 4 additions & 1 deletion DpsReport/ExtraJSON/TargetDamageDist.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

namespace PlenBotLogUploader.DpsReport.ExtraJson
{
internal sealed class TotalDamageDist
internal sealed class TargetDamageDist
{
[JsonProperty("id")]
internal int Id { get; set; }
Expand All @@ -15,5 +15,8 @@ internal sealed class TotalDamageDist

[JsonProperty("flank")]
internal int Flank { get; set; }

[JsonProperty("totalDamage")]
internal int TotalDamage { get; set; }
}
}
19 changes: 19 additions & 0 deletions DpsReport/ExtraJSON/TotalDamageDist.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
using Newtonsoft.Json;

namespace PlenBotLogUploader.DpsReport.ExtraJson
{
internal sealed class TotalDamageDist
{
[JsonProperty("id")]
internal int Id { get; set; }

[JsonProperty("hits")]
internal int Hits { get; set; }

[JsonProperty("connectedHits")]
internal int ConnectedHits { get; set; }

[JsonProperty("flank")]
internal int Flank { get; set; }
}
}
Loading

0 comments on commit ee25c79

Please sign in to comment.