mirror of
https://github.com/Facepunch/Facepunch.Steamworks.git
synced 2024-12-25 14:15:47 +03:00
Workshop.GetItem
This commit is contained in:
parent
a66f84c0d5
commit
c3ca4673d1
@ -26,12 +26,16 @@ public class Item
|
|||||||
public DateTime Modified { get; private set; }
|
public DateTime Modified { get; private set; }
|
||||||
public DateTime Created { get; private set; }
|
public DateTime Created { get; private set; }
|
||||||
|
|
||||||
|
public Item( ulong Id, Workshop workshop )
|
||||||
|
{
|
||||||
|
this.Id = Id;
|
||||||
|
this.workshop = workshop;
|
||||||
|
}
|
||||||
|
|
||||||
internal static Item From( SteamNative.SteamUGCDetails_t details, Workshop workshop )
|
internal static Item From( SteamNative.SteamUGCDetails_t details, Workshop workshop )
|
||||||
{
|
{
|
||||||
var item = new Item();
|
var item = new Item( details.m_nPublishedFileId, workshop);
|
||||||
|
|
||||||
item.workshop = workshop;
|
|
||||||
item.Id = details.m_nPublishedFileId;
|
|
||||||
item.Title = details.m_rgchTitle;
|
item.Title = details.m_rgchTitle;
|
||||||
item.Description = details.m_rgchDescription;
|
item.Description = details.m_rgchDescription;
|
||||||
item.OwnerId = details.m_ulSteamIDOwner;
|
item.OwnerId = details.m_ulSteamIDOwner;
|
||||||
@ -202,6 +206,8 @@ public Editor Edit()
|
|||||||
|
|
||||||
string _ownerName = null;
|
string _ownerName = null;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
public string OwnerName
|
public string OwnerName
|
||||||
{
|
{
|
||||||
get
|
get
|
||||||
|
@ -69,6 +69,11 @@ public Editor EditItem( ulong itemId )
|
|||||||
return new Editor() { workshop = this, Id = itemId };
|
return new Editor() { workshop = this, Id = itemId };
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public Item GetItem( ulong itemid )
|
||||||
|
{
|
||||||
|
return new Item( itemid, this );
|
||||||
|
}
|
||||||
|
|
||||||
public enum Order
|
public enum Order
|
||||||
{
|
{
|
||||||
RankedByVote = 0,
|
RankedByVote = 0,
|
||||||
|
Loading…
Reference in New Issue
Block a user