Skip to content

Commit

Permalink
API update v2.12.2
Browse files Browse the repository at this point in the history
  • Loading branch information
Cytraen committed Oct 16, 2021
1 parent 48fe930 commit 7bf83a3
Show file tree
Hide file tree
Showing 10 changed files with 110 additions and 94 deletions.
2 changes: 1 addition & 1 deletion BungieSharper.Benchmark/BungieSharper.Benchmark.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
<IsPackable>false</IsPackable>

<TargetFrameworks>net5.0;net6.0</TargetFrameworks>
<VersionPrefix>0.8.5</VersionPrefix>
<VersionPrefix>0.9.0</VersionPrefix>
</PropertyGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<IsPackable>false</IsPackable>

<TargetFramework>net6.0</TargetFramework>
<VersionPrefix>0.8.5</VersionPrefix>
<VersionPrefix>0.9.0</VersionPrefix>
</PropertyGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<IsPackable>true</IsPackable>

<TargetFramework>net6.0</TargetFramework>
<VersionPrefix>0.8.5</VersionPrefix>
<VersionPrefix>0.9.0</VersionPrefix>
</PropertyGroup>

<ItemGroup>
Expand Down
2 changes: 1 addition & 1 deletion BungieSharper.CodeGen/BungieSharper.CodeGen.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
<IsPackable>false</IsPackable>

<TargetFramework>net6.0</TargetFramework>
<VersionPrefix>0.8.5</VersionPrefix>
<VersionPrefix>0.9.0</VersionPrefix>
</PropertyGroup>

<ItemGroup>
Expand Down
2 changes: 1 addition & 1 deletion BungieSharper.Entities/BungieSharper.Entities.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<IsPackable>true</IsPackable>

<TargetFrameworks>net5.0;net6.0</TargetFrameworks>
<VersionPrefix>0.8.5</VersionPrefix>
<VersionPrefix>0.9.0</VersionPrefix>
</PropertyGroup>

<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,13 @@ public class DestinyCharacterProgressionComponent
[JsonPropertyName("uninstancedItemObjectives")]
public Dictionary<uint, IEnumerable<Destiny.Quests.DestinyObjectiveProgress>> UninstancedItemObjectives { get; set; }

/// <summary>
/// Sometimes, you have items in your inventory that don't have instances, but still have perks (for example: Trials passage cards). This gives you the perk information for uninstanced items.
/// This dictionary is keyed by item hash, which you can use to look up the corresponding item definition. The value is the list of perks states for the item.
/// </summary>
[JsonPropertyName("uninstancedItemPerks")]
public Dictionary<uint, Destiny.Entities.Items.DestinyItemPerksComponent> UninstancedItemPerks { get; set; }

/// <summary>
/// The set of checklists that can be examined for this specific character, keyed by the hash identifier of the Checklist (DestinyChecklistDefinition)
/// For each checklist returned, its value is itself a Dictionary keyed by the checklist's hash identifier with the value being a boolean indicating if it's been discovered yet.
Expand Down
36 changes: 18 additions & 18 deletions BungieSharper.Entities/Destiny/Entities.Destiny.Entities.Items.cs
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,24 @@ public class DestinyItemComponent
internal partial class DestinyItemComponentJsonContext : JsonSerializerContext { }
#endif

/// <summary>
/// Instanced items can have perks: benefits that the item bestows.
/// These are related to DestinySandboxPerkDefinition, and sometimes - but not always - have human readable info. When they do, they are the icons and text that you see in an item's tooltip.
/// Talent Grids, Sockets, and the item itself can apply Perks, which are then summarized here for your convenience.
/// </summary>
public class DestinyItemPerksComponent
{
/// <summary>The list of perks to display in an item tooltip - and whether or not they have been activated.</summary>
[JsonPropertyName("perks")]
public IEnumerable<Destiny.Perks.DestinyPerkReference> Perks { get; set; }
}

#if NET6_0_OR_GREATER
[JsonSerializable(typeof(DestinyItemPerksComponent))]
[JsonSourceGenerationOptions(PropertyNamingPolicy = JsonKnownNamingPolicy.CamelCase)]
internal partial class DestinyItemPerksComponentJsonContext : JsonSerializerContext { }
#endif

/// <summary>
/// Items can have objectives and progression. When you request this block, you will obtain information about any Objectives and progression tied to this item.
/// </summary>
Expand Down Expand Up @@ -224,24 +242,6 @@ public class DestinyItemInstanceEnergy
internal partial class DestinyItemInstanceEnergyJsonContext : JsonSerializerContext { }
#endif

/// <summary>
/// Instanced items can have perks: benefits that the item bestows.
/// These are related to DestinySandboxPerkDefinition, and sometimes - but not always - have human readable info. When they do, they are the icons and text that you see in an item's tooltip.
/// Talent Grids, Sockets, and the item itself can apply Perks, which are then summarized here for your convenience.
/// </summary>
public class DestinyItemPerksComponent
{
/// <summary>The list of perks to display in an item tooltip - and whether or not they have been activated.</summary>
[JsonPropertyName("perks")]
public IEnumerable<Destiny.Perks.DestinyPerkReference> Perks { get; set; }
}

#if NET6_0_OR_GREATER
[JsonSerializable(typeof(DestinyItemPerksComponent))]
[JsonSourceGenerationOptions(PropertyNamingPolicy = JsonKnownNamingPolicy.CamelCase)]
internal partial class DestinyItemPerksComponentJsonContext : JsonSerializerContext { }
#endif

/// <summary>
/// Many items can be rendered in 3D. When you request this block, you will obtain the custom data needed to render this specific instance of the item.
/// </summary>
Expand Down
147 changes: 78 additions & 69 deletions BungieSharper.Entities/Entities.cs
Original file line number Diff line number Diff line change
Expand Up @@ -709,6 +709,9 @@ public class DestinyBaseItemComponentSetOfuint32
{
[JsonPropertyName("objectives")]
public DictionaryComponentResponseOfuint32AndDestinyItemObjectivesComponent Objectives { get; set; }

[JsonPropertyName("perks")]
public DictionaryComponentResponseOfuint32AndDestinyItemPerksComponent Perks { get; set; }
}

#if NET6_0_OR_GREATER
Expand Down Expand Up @@ -737,6 +740,26 @@ public class DictionaryComponentResponseOfuint32AndDestinyItemObjectivesComponen
internal partial class DictionaryComponentResponseOfuint32AndDestinyItemObjectivesComponentJsonContext : JsonSerializerContext { }
#endif

public class DictionaryComponentResponseOfuint32AndDestinyItemPerksComponent
{
[JsonPropertyName("data")]
public Dictionary<uint, Destiny.Entities.Items.DestinyItemPerksComponent> Data { get; set; }

[JsonPropertyName("privacy")]
public Components.ComponentPrivacySetting Privacy { get; set; }

/// <summary>If true, this component is disabled.</summary>
[JsonPropertyName("disabled")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public bool? Disabled { get; set; }
}

#if NET6_0_OR_GREATER
[JsonSerializable(typeof(DictionaryComponentResponseOfuint32AndDestinyItemPerksComponent))]
[JsonSourceGenerationOptions(PropertyNamingPolicy = JsonKnownNamingPolicy.CamelCase)]
internal partial class DictionaryComponentResponseOfuint32AndDestinyItemPerksComponentJsonContext : JsonSerializerContext { }
#endif

public class DictionaryComponentResponseOfint64AndDestinyPresentationNodesComponent
{
[JsonPropertyName("data")]
Expand Down Expand Up @@ -821,6 +844,9 @@ public class DestinyBaseItemComponentSetOfint64
{
[JsonPropertyName("objectives")]
public DictionaryComponentResponseOfint64AndDestinyItemObjectivesComponent Objectives { get; set; }

[JsonPropertyName("perks")]
public DictionaryComponentResponseOfint64AndDestinyItemPerksComponent Perks { get; set; }
}

#if NET6_0_OR_GREATER
Expand Down Expand Up @@ -849,14 +875,31 @@ public class DictionaryComponentResponseOfint64AndDestinyItemObjectivesComponent
internal partial class DictionaryComponentResponseOfint64AndDestinyItemObjectivesComponentJsonContext : JsonSerializerContext { }
#endif

public class DictionaryComponentResponseOfint64AndDestinyItemPerksComponent
{
[JsonPropertyName("data")]
public Dictionary<long, Destiny.Entities.Items.DestinyItemPerksComponent> Data { get; set; }

[JsonPropertyName("privacy")]
public Components.ComponentPrivacySetting Privacy { get; set; }

/// <summary>If true, this component is disabled.</summary>
[JsonPropertyName("disabled")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public bool? Disabled { get; set; }
}

#if NET6_0_OR_GREATER
[JsonSerializable(typeof(DictionaryComponentResponseOfint64AndDestinyItemPerksComponent))]
[JsonSourceGenerationOptions(PropertyNamingPolicy = JsonKnownNamingPolicy.CamelCase)]
internal partial class DictionaryComponentResponseOfint64AndDestinyItemPerksComponentJsonContext : JsonSerializerContext { }
#endif

public class DestinyItemComponentSetOfint64
{
[JsonPropertyName("instances")]
public DictionaryComponentResponseOfint64AndDestinyItemInstanceComponent Instances { get; set; }

[JsonPropertyName("perks")]
public DictionaryComponentResponseOfint64AndDestinyItemPerksComponent Perks { get; set; }

[JsonPropertyName("renderData")]
public DictionaryComponentResponseOfint64AndDestinyItemRenderComponent RenderData { get; set; }

Expand All @@ -880,6 +923,9 @@ public class DestinyItemComponentSetOfint64

[JsonPropertyName("objectives")]
public DictionaryComponentResponseOfint64AndDestinyItemObjectivesComponent Objectives { get; set; }

[JsonPropertyName("perks")]
public DictionaryComponentResponseOfint64AndDestinyItemPerksComponent Perks { get; set; }
}

#if NET6_0_OR_GREATER
Expand Down Expand Up @@ -908,26 +954,6 @@ public class DictionaryComponentResponseOfint64AndDestinyItemInstanceComponent
internal partial class DictionaryComponentResponseOfint64AndDestinyItemInstanceComponentJsonContext : JsonSerializerContext { }
#endif

public class DictionaryComponentResponseOfint64AndDestinyItemPerksComponent
{
[JsonPropertyName("data")]
public Dictionary<long, Destiny.Entities.Items.DestinyItemPerksComponent> Data { get; set; }

[JsonPropertyName("privacy")]
public Components.ComponentPrivacySetting Privacy { get; set; }

/// <summary>If true, this component is disabled.</summary>
[JsonPropertyName("disabled")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public bool? Disabled { get; set; }
}

#if NET6_0_OR_GREATER
[JsonSerializable(typeof(DictionaryComponentResponseOfint64AndDestinyItemPerksComponent))]
[JsonSourceGenerationOptions(PropertyNamingPolicy = JsonKnownNamingPolicy.CamelCase)]
internal partial class DictionaryComponentResponseOfint64AndDestinyItemPerksComponentJsonContext : JsonSerializerContext { }
#endif

public class DictionaryComponentResponseOfint64AndDestinyItemRenderComponent
{
[JsonPropertyName("data")]
Expand Down Expand Up @@ -1524,6 +1550,9 @@ public class DestinyBaseItemComponentSetOfint32
{
[JsonPropertyName("objectives")]
public DictionaryComponentResponseOfint32AndDestinyItemObjectivesComponent Objectives { get; set; }

[JsonPropertyName("perks")]
public DictionaryComponentResponseOfint32AndDestinyItemPerksComponent Perks { get; set; }
}

#if NET6_0_OR_GREATER
Expand Down Expand Up @@ -1552,14 +1581,31 @@ public class DictionaryComponentResponseOfint32AndDestinyItemObjectivesComponent
internal partial class DictionaryComponentResponseOfint32AndDestinyItemObjectivesComponentJsonContext : JsonSerializerContext { }
#endif

public class DictionaryComponentResponseOfint32AndDestinyItemPerksComponent
{
[JsonPropertyName("data")]
public Dictionary<int, Destiny.Entities.Items.DestinyItemPerksComponent> Data { get; set; }

[JsonPropertyName("privacy")]
public Components.ComponentPrivacySetting Privacy { get; set; }

/// <summary>If true, this component is disabled.</summary>
[JsonPropertyName("disabled")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public bool? Disabled { get; set; }
}

#if NET6_0_OR_GREATER
[JsonSerializable(typeof(DictionaryComponentResponseOfint32AndDestinyItemPerksComponent))]
[JsonSourceGenerationOptions(PropertyNamingPolicy = JsonKnownNamingPolicy.CamelCase)]
internal partial class DictionaryComponentResponseOfint32AndDestinyItemPerksComponentJsonContext : JsonSerializerContext { }
#endif

public class DestinyItemComponentSetOfint32
{
[JsonPropertyName("instances")]
public DictionaryComponentResponseOfint32AndDestinyItemInstanceComponent Instances { get; set; }

[JsonPropertyName("perks")]
public DictionaryComponentResponseOfint32AndDestinyItemPerksComponent Perks { get; set; }

[JsonPropertyName("renderData")]
public DictionaryComponentResponseOfint32AndDestinyItemRenderComponent RenderData { get; set; }

Expand All @@ -1583,6 +1629,9 @@ public class DestinyItemComponentSetOfint32

[JsonPropertyName("objectives")]
public DictionaryComponentResponseOfint32AndDestinyItemObjectivesComponent Objectives { get; set; }

[JsonPropertyName("perks")]
public DictionaryComponentResponseOfint32AndDestinyItemPerksComponent Perks { get; set; }
}

#if NET6_0_OR_GREATER
Expand Down Expand Up @@ -1611,26 +1660,6 @@ public class DictionaryComponentResponseOfint32AndDestinyItemInstanceComponent
internal partial class DictionaryComponentResponseOfint32AndDestinyItemInstanceComponentJsonContext : JsonSerializerContext { }
#endif

public class DictionaryComponentResponseOfint32AndDestinyItemPerksComponent
{
[JsonPropertyName("data")]
public Dictionary<int, Destiny.Entities.Items.DestinyItemPerksComponent> Data { get; set; }

[JsonPropertyName("privacy")]
public Components.ComponentPrivacySetting Privacy { get; set; }

/// <summary>If true, this component is disabled.</summary>
[JsonPropertyName("disabled")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public bool? Disabled { get; set; }
}

#if NET6_0_OR_GREATER
[JsonSerializable(typeof(DictionaryComponentResponseOfint32AndDestinyItemPerksComponent))]
[JsonSourceGenerationOptions(PropertyNamingPolicy = JsonKnownNamingPolicy.CamelCase)]
internal partial class DictionaryComponentResponseOfint32AndDestinyItemPerksComponentJsonContext : JsonSerializerContext { }
#endif

public class DictionaryComponentResponseOfint32AndDestinyItemRenderComponent
{
[JsonPropertyName("data")]
Expand Down Expand Up @@ -1868,9 +1897,6 @@ public class DestinyItemComponentSetOfuint32
[JsonPropertyName("instances")]
public DictionaryComponentResponseOfuint32AndDestinyItemInstanceComponent Instances { get; set; }

[JsonPropertyName("perks")]
public DictionaryComponentResponseOfuint32AndDestinyItemPerksComponent Perks { get; set; }

[JsonPropertyName("renderData")]
public DictionaryComponentResponseOfuint32AndDestinyItemRenderComponent RenderData { get; set; }

Expand All @@ -1894,6 +1920,9 @@ public class DestinyItemComponentSetOfuint32

[JsonPropertyName("objectives")]
public DictionaryComponentResponseOfuint32AndDestinyItemObjectivesComponent Objectives { get; set; }

[JsonPropertyName("perks")]
public DictionaryComponentResponseOfuint32AndDestinyItemPerksComponent Perks { get; set; }
}

#if NET6_0_OR_GREATER
Expand Down Expand Up @@ -1922,26 +1951,6 @@ public class DictionaryComponentResponseOfuint32AndDestinyItemInstanceComponent
internal partial class DictionaryComponentResponseOfuint32AndDestinyItemInstanceComponentJsonContext : JsonSerializerContext { }
#endif

public class DictionaryComponentResponseOfuint32AndDestinyItemPerksComponent
{
[JsonPropertyName("data")]
public Dictionary<uint, Destiny.Entities.Items.DestinyItemPerksComponent> Data { get; set; }

[JsonPropertyName("privacy")]
public Components.ComponentPrivacySetting Privacy { get; set; }

/// <summary>If true, this component is disabled.</summary>
[JsonPropertyName("disabled")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public bool? Disabled { get; set; }
}

#if NET6_0_OR_GREATER
[JsonSerializable(typeof(DictionaryComponentResponseOfuint32AndDestinyItemPerksComponent))]
[JsonSourceGenerationOptions(PropertyNamingPolicy = JsonKnownNamingPolicy.CamelCase)]
internal partial class DictionaryComponentResponseOfuint32AndDestinyItemPerksComponentJsonContext : JsonSerializerContext { }
#endif

public class DictionaryComponentResponseOfuint32AndDestinyItemRenderComponent
{
[JsonPropertyName("data")]
Expand Down
2 changes: 1 addition & 1 deletion BungieSharper.Tests/BungieSharper.Tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<IsPackable>false</IsPackable>

<TargetFrameworks>net5.0;net6.0</TargetFrameworks>
<VersionPrefix>0.8.5</VersionPrefix>
<VersionPrefix>0.9.0</VersionPrefix>
</PropertyGroup>

<ItemGroup>
Expand Down
2 changes: 1 addition & 1 deletion BungieSharper/BungieSharper.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<IsPackable>true</IsPackable>

<TargetFrameworks>net5.0;net6.0</TargetFrameworks>
<VersionPrefix>0.8.5</VersionPrefix>
<VersionPrefix>0.9.0</VersionPrefix>
</PropertyGroup>

<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
Expand Down

0 comments on commit 7bf83a3

Please sign in to comment.