# Editor.ProjectPublisher

- Kind: class
- Namespace: `Editor`
- Assembly: `Sandbox.Tools`

## Fields

- [`AddonTypesMetaKey`](/api/Editor.ProjectPublisher/AddonTypesMetaKey): The meta key of a game's addon types ([Sandbox.PackageInfo.AddonTypes](/api/Sandbox.PackageInfo/AddonTypes))
- [`MaxPickedWorkshopTags`](/api/Editor.ProjectPublisher/MaxPickedWorkshopTags): The most tags that can be picked for an item - enough to say what it is, and it keeps room for the ones a game gets from its player settings (Steam takes 32 at most)
- [`WorkshopTagsMetaKey`](/api/Editor.ProjectPublisher/WorkshopTagsMetaKey): The project meta key the tags picked for its workshop item are kept under

## Properties

- [`Files`](/api/Editor.ProjectPublisher/Files): Get access to the files within the manifest
- [`HasWorkshopUpload`](/api/Editor.ProjectPublisher/HasWorkshopUpload): Does this publish put its files in a Steam Workshop item?
- [`IsWorkshopUploaded`](/api/Editor.ProjectPublisher/IsWorkshopUploaded): Have the files gone up to the workshop? A retried publish doesn't upload them again.
- [`Manifest`](/api/Editor.ProjectPublisher/Manifest)
- [`MissingFileCount`](/api/Editor.ProjectPublisher/MissingFileCount)
- [`MissingFileSize`](/api/Editor.ProjectPublisher/MissingFileSize)
- [`OnProgressChanged`](/api/Editor.ProjectPublisher/OnProgressChanged)
- [`TargetPackageIdent`](/api/Editor.ProjectPublisher/TargetPackageIdent)
- [`TotalFileCount`](/api/Editor.ProjectPublisher/TotalFileCount)
- [`WorkshopBytesDone`](/api/Editor.ProjectPublisher/WorkshopBytesDone): How far through the current stage of the workshop upload we are, in bytes
- [`WorkshopBytesTotal`](/api/Editor.ProjectPublisher/WorkshopBytesTotal): The size of the current stage of the workshop upload, in bytes. Steam doesn't know until it's started.
- [`WorkshopFileCount`](/api/Editor.ProjectPublisher/WorkshopFileCount): How many files go in the workshop item
- [`WorkshopTargetItemId`](/api/Editor.ProjectPublisher/WorkshopTargetItemId): The workshop item this publishes to, or 0 if it'll create a new one
- [`WorkshopUploadSize`](/api/Editor.ProjectPublisher/WorkshopUploadSize): The size of the files that go in the workshop item, in bytes
- [`WorkshopUploadStatus`](/api/Editor.ProjectPublisher/WorkshopUploadStatus): What the workshop upload is doing right now, or null if it hasn't started
- [`WorkshopUrl`](/api/Editor.ProjectPublisher/WorkshopUrl): The workshop item's page on Steam, once there is one
- [`WorkshopWarning`](/api/Editor.ProjectPublisher/WorkshopWarning): Something whoever's publishing should know about the workshop item first, like that it isn't theirs. Null if there's nothing to say.

## Methods

- [`AddCodePackageReference`](/api/Editor.ProjectPublisher/AddCodePackageReference): If the code is referencing a package - we can add it to the manifest using this.
- [`AddFile`](/api/Editor.ProjectPublisher/AddFile): Manually add a file to the manifest
- [`CanPublishFile`](/api/Editor.ProjectPublisher/CanPublishFile): Return true if we're not opposed to publishing this asset
- [`CropToSquare`](/api/Editor.ProjectPublisher/CropToSquare): The middle of this image, cut square - Steam shows workshop items' main thumbnails square. A new bitmap.
- [`FromAsset`](/api/Editor.ProjectPublisher/FromAsset)
- [`FromProject`](/api/Editor.ProjectPublisher/FromProject)
- [`GetGameSettings`](/api/Editor.ProjectPublisher/GetGameSettings): Fetch a list of game settings to be added to the project's metadata
- [`GetPublishedWorkshopItemsAsync`](/api/Editor.ProjectPublisher/GetPublishedWorkshopItemsAsync): The workshop items we've published of this type (e.g. "map" or "game"), newest first. Empty if Steam couldn't be asked.
- [`GetWorkshopItemIdAsync`](/api/Editor.ProjectPublisher/GetWorkshopItemIdAsync): The workshop item a publish of this project goes to unless it's told otherwise - 0 if it isn't a map, game or addon, or it'll make a new item
- [`GetWorkshopItemInfoAsync`](/api/Editor.ProjectPublisher/GetWorkshopItemInfoAsync): Ask Steam about a workshop item - not from its cache, it might have just been published
- [`PlayerTags`](/api/Editor.ProjectPublisher/PlayerTags): The tags a game's workshop item gets for how it's played - singleplayer, multiplayer, co-op and versus - made from its player settings rather than picked
- [`PrePublish`](/api/Editor.ProjectPublisher/PrePublish): Prepare the Workshop files and, for projects with a backend package, check which backend files need uploading.
- [`Publish`](/api/Editor.ProjectPublisher/Publish): Publish a new revision
- [`PublishesOnlyToWorkshop`](/api/Editor.ProjectPublisher/PublishesOnlyToWorkshop): Addons are identified and published entirely through Steam Workshop, without a backend package.
- [`PublishesToWorkshop`](/api/Editor.ProjectPublisher/PublishesToWorkshop): Would publishing this project put its files in a Steam Workshop item?
- [`SetChangeDetails`](/api/Editor.ProjectPublisher/SetChangeDetails): Allows to set information on the revision - for future reference
- [`SetMeta`](/api/Editor.ProjectPublisher/SetMeta)
- [`SetThumbnail`](/api/Editor.ProjectPublisher/SetThumbnail): Use this image as the package's thumb instead of the one rendered from its asset - the middle of it, cut square ([Editor.ProjectPublisher.CropToSquare](/api/Editor.ProjectPublisher/CropToSquare)). Any image a [Sandbox.Bitmap](/api/Sandbox.Bitmap) can read - it goes up as a png. Before [Editor.ProjectPublisher.PrePublish](/api/Editor.ProjectPublisher/PrePublish), so it's uploaded.
- [`SetWorkshopItem`](/api/Editor.ProjectPublisher/SetWorkshopItem): Put the files in this workshop item, or a new one with 0, rather than the one the package says. Before [Editor.ProjectPublisher.PrePublish](/api/Editor.ProjectPublisher/PrePublish).
- [`SetWorkshopVisibility`](/api/Editor.ProjectPublisher/SetWorkshopVisibility): Who can see the workshop item once it's published. Before [Editor.ProjectPublisher.Publish](/api/Editor.ProjectPublisher/Publish).
- [`UploadFiles`](/api/Editor.ProjectPublisher/UploadFiles)
- [`WorkshopTagChoices`](/api/Editor.ProjectPublisher/WorkshopTagChoices): The tags that can be picked for a workshop item of this type ("map" or "game"). Keep them the same as the Workshop tags on Steamworks, so Steam's own filters match.
