s&box docs

public sealed class Sandbox.ResourcePublishContext

Created by the editor when publishing a resource, passed into Resource.ConfigurePublishing. This allows the resource to configure how it wants to be published.

Constructors

Showing 1 constructors

Methods

Showing 1 methods

public void SetPublishingDisabled(string reason)

Allows you to disable publishing for this resource, with a reason that'll be shown to the user.

Properties

Showing 5 properties

public bool Sandbox.ResourcePublishContext.CanIncludeSourceFiles { get; set; }

If true then we'll offer an option to upload source files with this asset. This will make it easier for people who want to download and add it to their project, but make their own changes.

public System.Func`1<Sandbox.Bitmap> Sandbox.ResourcePublishContext.CreateThumbnailFunction { get; set; }

A function to create a thumbnail for this resource. If not null, this will be called to create the thumbnail.

public bool Sandbox.ResourcePublishContext.IncludeCode { get; set; }

If true we'll include the addon's code with this

public bool Sandbox.ResourcePublishContext.PublishingEnabled { get; set; }

Can be set to false using SetPublishingDisabled

public string Sandbox.ResourcePublishContext.ReasonForDisabling { get; set; }

If publishing is disabled this will be the message to display why.

Metadata

FieldValue
NamespaceSandbox
Typeclass
AssemblySandbox.Engine
Doc IDT:Sandbox.ResourcePublishContext

On this page