mirror of
https://github.com/Facepunch/Facepunch.Steamworks.git
synced 2024-12-25 06:05:46 +03:00
Complain if WorkshopUploadAppId not set
This commit is contained in:
parent
dc6b9fa5f7
commit
22dda179a3
@ -112,6 +112,9 @@ private void StartCreatingItem()
|
|||||||
if ( !Type.HasValue )
|
if ( !Type.HasValue )
|
||||||
throw new System.Exception( "Editor.Type must be set when creating a new item!" );
|
throw new System.Exception( "Editor.Type must be set when creating a new item!" );
|
||||||
|
|
||||||
|
if ( WorkshopUploadAppId == 0 )
|
||||||
|
throw new Exception( "WorkshopUploadAppId should not be 0" );
|
||||||
|
|
||||||
CreateItem = workshop.ugc.CreateItem( WorkshopUploadAppId, (SteamNative.WorkshopFileType)(uint)Type, OnItemCreated );
|
CreateItem = workshop.ugc.CreateItem( WorkshopUploadAppId, (SteamNative.WorkshopFileType)(uint)Type, OnItemCreated );
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -137,6 +140,9 @@ private void OnItemCreated( SteamNative.CreateItemResult_t obj, bool Failed )
|
|||||||
|
|
||||||
private void PublishChanges()
|
private void PublishChanges()
|
||||||
{
|
{
|
||||||
|
if ( WorkshopUploadAppId == 0 )
|
||||||
|
throw new Exception( "WorkshopUploadAppId should not be 0" );
|
||||||
|
|
||||||
UpdateHandle = workshop.ugc.StartItemUpdate(WorkshopUploadAppId, Id );
|
UpdateHandle = workshop.ugc.StartItemUpdate(WorkshopUploadAppId, Id );
|
||||||
|
|
||||||
if ( Title != null )
|
if ( Title != null )
|
||||||
|
Loading…
Reference in New Issue
Block a user