Skip to content

Commit

Permalink
Added WIP support for hideout decorations
Browse files Browse the repository at this point in the history
  • Loading branch information
Stickymaddness committed Aug 22, 2014
1 parent a616a71 commit 4a1b635
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 0 deletions.
21 changes: 21 additions & 0 deletions POEApi.Model/Decoration.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace POEApi.Model
{
public class Decoration : Item
{
public Decoration(JSONProxy.Item item)
: base(item)
{

}

protected override int getConcreteHash()
{
return 0;
}
}
}
3 changes: 3 additions & 0 deletions POEApi.Model/ItemFactory.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@ public static Item Get(JSONProxy.Item item)
if (item.frameType == 4)
return new Gem(item);

if (item.DescrText != null && item.DescrText.ToLower() == "right click this item then left click a location on the ground to create the object.")
return new Decoration(item);

if (item.frameType == 5)
return new Currency(item);

Expand Down
1 change: 1 addition & 0 deletions POEApi.Model/POEApi.Model.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@
</ItemGroup>
<ItemGroup>
<Compile Include="CharacterStashBuilder.cs" />
<Compile Include="Decoration.cs" />
<Compile Include="GemHandler.cs" />
<Compile Include="ItemTradeInfo.cs" />
<Compile Include="Character.cs" />
Expand Down

0 comments on commit 4a1b635

Please sign in to comment.