public sealed class Sandbox.Clothing : Sandbox.GameResource
Describes an item of clothing and implicitly which other items it can be worn with
Related Guides
Broader workflow and conceptual references connected to this API.
You can define your own custom asset types as GameResources. They give you a nice inspector window and they're hotloaded in-game, which means you can whip things up pretty quickly if you're using them.
ResourceExtensions can be used to append additional data to existing GameResources without modifying the original class or assets. This is useful for adding additional properties to resources such as Clothing, Surfaces, Models, ect.
These quality guidelines will help you through the process of creating clothing that stands a better chance of being accepted for sale on the s&box store.
First, you'll need a fully set up .Clothing file. This is where we store our VMDLs and certain logic so your clothing works correctly.
Assets are the building blocks of your game — models, materials, sounds, textures, and custom resources. S&box provides tools for creating, importing, managing, and distributing assets.
This section needs to be rewritten with an explanation of all the code, libraries, etc.
Constructors
Showing 1 constructors
public Clothing()
No results match this filter.
Methods
Showing 5 methods
public bool CanBeWornWith(Sandbox.Clothing target)
Return true if this item of clothing can be worn with the target item, at the same time.
public static System.Collections.Generic.List`1<Sandbox.SceneModel> DressSceneObject(Sandbox.SceneModel citizen, System.Collections.Generic.IEnumerable`1<Sandbox.Clothing> Clothing)Obsolete
Obsolete: We should be using Scene/Components now
public bool HasPermissions()
Can we wear this item?
No results match this filter.
Properties
Showing 29 properties
public bool Sandbox.Clothing.AllowTintSelect { get; set; }
public Sandbox.Clothing.ClothingCategory Sandbox.Clothing.Category { get; set; }
What kind of clothing this is?
public System.Collections.Generic.Dictionary`2<string,string> Sandbox.Clothing.ConditionalModels { get; set; }
A list of conditional models. (key) = tag(s), (value) = model
public string Sandbox.Clothing.EyesMaterial { get; set; }
Replace the eyes with this material
public bool Sandbox.Clothing.HasHumanSkin { get; set; }
public float Sandbox.Clothing.HeelHeight { get; set; }
Do we need to lift the heel up?
public Sandbox.Clothing.BodyGroups Sandbox.Clothing.HideBody { get; set; }
Which body parts of the player model should not show when this clothing is equipped.
public string Sandbox.Clothing.HumanAltFemaleModel { get; set; }
The model to bonemerge to the human player when this clothing is equipped.
public string Sandbox.Clothing.HumanAltModel { get; set; }
The model to bonemerge to the human player when this clothing is equipped.
public string Sandbox.Clothing.HumanEyesMaterial { get; set; }
Replace skin with this
public ulong Sandbox.Clothing.HumanSkinBodyGroups { get; set; }
Bodygroup on the model to choose
public string Sandbox.Clothing.HumanSkinMaterial { get; set; }
Replace skin with this
public string Sandbox.Clothing.HumanSkinMaterialGroup { get; set; }
Bodygroup on the model to choose
public string Sandbox.Clothing.HumanSkinModel { get; set; }
Model to replace the human skin with
public Sandbox.TagSet Sandbox.Clothing.HumanSkinTags { get; set; }
Allows adding tags for this skin, ie "female". This affects which alternative clothing models are used with it.
public string Sandbox.Clothing.MaterialGroup { get; set; }
Which material group of the model to use.
public string Sandbox.Clothing.Model { get; set; }
The model to bonemerge to the player when this clothing is equipped.
public Sandbox.Clothing Sandbox.Clothing.Parent { get; set; }Obsolete
The clothing to parent this too. It will be displayed as a variation of its parent
Obsolete: This API member is obsolete.
public string Sandbox.Clothing.SkinMaterial { get; set; }
Replace the skin with this material
public Sandbox.Clothing.Slots Sandbox.Clothing.SlotsOver { get; set; }
Which slots this clothing takes on "outer" layer.
public Sandbox.Clothing.Slots Sandbox.Clothing.SlotsUnder { get; set; }
Which slots this clothing takes on "inner" layer.
public System.Nullable`1<int> Sandbox.Clothing.SteamItemDefinitionId { get; set; }
The Steam Item Definition ID for this clothing item, if it's an inventory item
public string Sandbox.Clothing.SubCategory { get; set; }Obsolete
This should be a single word to describe the subcategory, and should match any other items you want to categorize in the same bunch. The work will be tokenized so it can become localized.
Obsolete: This API member is obsolete.
public string Sandbox.Clothing.Tags { get; set; }
public float Sandbox.Clothing.TintDefault { get; set; }
No results match this filter.
Metadata
| Field | Value |
|---|---|
| Namespace | Sandbox |
| Type | class |
| Assembly | Sandbox.Engine |
| Doc ID | T:Sandbox.Clothing |