atl/sm/item
import "atl/sm/item"sm.item: static information about item and shape uuids.
Functions
Section titled "Functions"func IsBlock(u sm.Uuid) boolfunc IsPart(u sm.Uuid) boolfunc IsTool(u sm.Uuid) boolfunc IsJoint(u sm.Uuid) boolfunc IsHarvestablePart(u sm.Uuid) boolWhat kind of item a uuid is.
func IsFlammable(u sm.Uuid) boolTrue if the item can burn.
func Title(u sm.Uuid) stringfunc Description(u sm.Uuid) stringThe item's display name and description.
func StackSize(u sm.Uuid) intHow many fit in one inventory slot.
func QualityLevel(u sm.Uuid) intThe item's quality level.
func Material(u sm.Uuid) stringfunc MaterialID(u sm.Uuid) intThe physics material name and id.
func Size(u sm.Uuid) sm.Vec3Size in blocks (the part's bounding box).
func Offset(u sm.Uuid) sm.Vec3Offset of the part's origin within its bounding box.
func DefaultColor(u sm.Uuid) sm.ColorThe color the item has when first placed.
func Rotation(u sm.Uuid, rotationIndex int) sm.QuatThe rotation for one of the part's rotation-set indices.
func FeatureData(u sm.Uuid) atl.Valuefunc Edible(u sm.Uuid) atl.Valuefunc Plantable(u sm.Uuid) atl.ValueRaw definition tables; nil when the item has no such feature.
func InteractablesOfType(typ string) []sm.UuidEvery interactable item of a type, e.g. "chest", "engine", "seat".
func Plantables() []sm.UuidEvery item that can be planted.
func IsMultiShape(u sm.Uuid) boolTrue for an item made of several shapes.
func AddTracked(u sm.Uuid, typ int)func RemoveTracked(u sm.Uuid, typ int)[client] Starts / stops tracking placement and use of an item (typ is sm.item's tracking type).
Ratings
Section titled "Ratings"type Ratings struct { Density, Durability, Friction, Buoyancy int}The 1 to 10 ratings shown in the inventory.
func RatingsOf(u sm.Uuid) RatingsReads all four ratings of an item.
CharacterShape
Section titled "CharacterShape"type CharacterShape struct { CharacterUuid sm.Uuid PlacementSphereRadius float64}The character a "character shape" item places.
func CharacterShapeOf(u sm.Uuid) CharacterShapeReads an item's character shape; empty if it has none.