mirror of
https://github.com/Facepunch/Facepunch.Steamworks.git
synced 2025-02-05 18:20:30 +03:00
SteamInventory.AddPromoItemAsync
This commit is contained in:
parent
8ea4231778
commit
9339477c89
@ -330,5 +330,20 @@ namespace Steamworks
|
|||||||
|
|
||||||
return await InventoryResult.GetAsync( sresult );
|
return await InventoryResult.GetAsync( sresult );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Trigger a promo item drop. You can call this at startup, it won't
|
||||||
|
/// give users multiple promo drops.
|
||||||
|
/// </summary>
|
||||||
|
public static async Task<InventoryResult?> AddPromoItemAsync( InventoryDefId id )
|
||||||
|
{
|
||||||
|
var sresult = default( SteamInventoryResult_t );
|
||||||
|
|
||||||
|
if ( !Internal.AddPromoItem( ref sresult, id ) )
|
||||||
|
return null;
|
||||||
|
|
||||||
|
return await InventoryResult.GetAsync( sresult );
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
x
Reference in New Issue
Block a user