- type: entity
abstract: true
+ parent: BasePaperLabelable # We use this instead of BasePaperLabelableVisualized because WrappedParcel needs its own GenericVisualizer component for the parcel itself, and WrappedParcelHumanoid currently doesn't have label sprites at all
id: BaseWrappedParcel
name: wrapped parcel
description: Something wrapped up in paper. I wonder what's inside...
params:
volume: -4
unwrapTrash: ParcelWrapTrash
- - type: ItemSlots
- - type: PaperLabel
- labelSlot:
- insertVerbText: comp-paper-label-insert
- ejectVerbText: comp-paper-label-eject
- whitelist:
- components:
- - Paper
- blacklist:
- tags:
- - Book
- type: Damageable
damageContainer: Inorganic
- type: Destructible
- Recyclable # Parcel entity is recyclable, and when it's destroyed, it'll drop its contents.
- type: entity
- parent: [BaseItem, BaseWrappedParcel]
+ parent: [ BaseItem, BaseWrappedParcel ]
id: WrappedParcel
components:
- type: Appearance
- type: entity
- parent: BaseItem
+ parent: [ BaseItem, BasePaperLabelable ] #TODO: Add sprites for different types of paper, replace BasePaperLabelable with BasePaperLabelableVisualized
id: SeedBase
abstract: true
components:
size: Tiny
- type: StaticPrice
price: 20
- - type: ItemSlots
- - type: ContainerContainer
- containers:
- paper_label: !type:ContainerSlot
- - type: PaperLabel
- labelSlot:
- insertVerbText: comp-paper-label-insert
- ejectVerbText: comp-paper-label-eject
- whitelist:
- components:
- - Paper
- blacklist:
- tags:
- - Book
- type: PhysicalComposition
- type: entity
- type: entity
id: BodyBag
- parent: BaseDeployFoldable
+ parent: [ BaseDeployFoldable, BasePaperLabelableVisualized ]
name: body bag
description: A plastic bag designed for the storage and transportation of cadavers to stop body decomposition.
components:
openSound:
path: /Audio/Misc/zip.ogg
- type: EntityStorageLayingDownOverride
- - type: PaperLabel
- labelSlot:
- insertVerbText: comp-paper-label-insert
- ejectVerbText: comp-paper-label-eject
- whitelist:
- components:
- - Paper
- blacklist:
- tags:
- - Book
- type: Appearance
- type: EntityStorageVisuals
stateDoorOpen: open_overlay
False: {visible: true}
- type: Pullable
- type: AntiRottingContainer
- - type: ItemSlots
- type: ContainerContainer
containers:
entity_storage: !type:Container
- type: entity
+ parent: [ BaseStructureDynamic, BasePaperLabelableVisualized ]
id: CrateArtifactContainer
- parent: BaseStructureDynamic
name: artifact container
description: Used to safely contain and move artifacts.
components:
behaviors:
- !type:DoActsBehavior
acts: ["Destruction"]
- - type: PaperLabel
- labelSlot:
- insertVerbText: comp-paper-label-insert
- ejectVerbText: comp-paper-label-eject
- whitelist:
- components:
- - Paper
- blacklist:
- tags:
- - Book
- type: Appearance
- type: EntityStorageVisuals
stateDoorOpen: artifact_container_open
True: { offset: "0.0,0.3125" }
False: { offset: "0.0,0.0" }
- type: LockVisuals
- - type: ItemSlots
- type: ContainerContainer
containers:
entity_storage: !type:Container
Open: { visible: true }
Closed: { visible: false }
+# Defines the behavior (but not the visuals!) for attaching paper labels to objects (e.g crates, parcels).
+# Use this (NOT BasePaperLabelableVisualized) if the child prototype allows paper labels but has no sprites for it.
+# Note that if an entity has its own ContainerContainer component then paper_label needs to be added to that too, or else there's bugs.
+- type: entity
+ id: BasePaperLabelable
+ abstract: true
+ components:
+ - type: ContainerContainer
+ containers:
+ paper_label: !type:ContainerSlot
+ - type: ItemSlots
+ - type: PaperLabel
+ labelSlot:
+ insertVerbText: comp-paper-label-insert
+ ejectVerbText: comp-paper-label-eject
+ whitelist:
+ components:
+ - Paper
+ blacklist:
+ tags:
+ - Book
+
+# Defines both the behavior (via parenting) and the visuals for attaching paper labels to objects (e.g crates, parcels).
+# Use this (NOT BasePaperLabelable) if the child prototype has sprites for paper labels.
+# The GenericVisualizer used here ONLY manages the paper label. If the child prototype has a unique GenericVisualizer for some reason or another,
+# then that will also need to handle the paper label too, since it'll completely overwrite the one here.
+# You should still parent from this instead of BasePaperLabelable since if that unique GenericVisualizer is missing for some reason this one works as a failsafe.
+# (Though it might not really matter in practice.)
+# In any case, the actual Sprite component for the label layer still needs to be defined on a per-item basis!
+# And again note that if an entity has its own ContainerContainer component then paper_label needs to be added to that too, or else there's bugs.
+- type: entity
+ parent: BasePaperLabelable
+ id: BasePaperLabelableVisualized
+ abstract: true
+ components:
+ - type: Appearance
+ - type: GenericVisualizer
+ visuals:
+ enum.PaperLabelVisuals.HasLabel:
+ enum.PaperLabelVisuals.Layer:
+ True: { visible: true }
+ False: { visible: false }
+ enum.PaperLabelVisuals.LabelType:
+ enum.PaperLabelVisuals.Layer:
+ Paper: { state: paper }
+ Bounty: { state: bounty }
+ CaptainsPaper: { state: captains_paper }
+ Invoice: { state: invoice }
+
# PowerCellSlot parents
- type: entity
id: PowerCellSlotSmallItem
- type: entity
abstract: true
- parent: BaseStructureDynamic
+ parent: [ BaseStructureDynamic, BasePaperLabelableVisualized ]
id: GasCanister
name: gas canister
description: A canister that can contain any type of gas. It can be attached to connector ports using a wrench.
nodeGroupID: Pipe
rotationsEnabled: false
volume: 1
- - type: ItemSlots
- type: GasPortable
- type: GasCanister
gasTankSlot:
- GasTank
- type: StaticPrice
price: 200
- - type: PaperLabel
- labelSlot:
- insertVerbText: comp-paper-label-insert
- ejectVerbText: comp-paper-label-eject
- whitelist:
- components:
- - Paper
- blacklist:
- tags:
- - Book
- type: AccessReader
access: [["Atmospherics"], ["Engineering"], ["Research"]]
- type: Lock
- type: entity
id: ClosetBase
- parent: BaseStructureDynamic
+ parent: [ BaseStructureDynamic, BasePaperLabelableVisualized ]
name: closet
description: A standard-issue Nanotrasen storage unit.
abstract: true
sprite: Structures/Storage/closet_labels.rsi
map: ["enum.PaperLabelVisuals.Layer"]
- type: MovedByPressure
- - type: PaperLabel
- labelSlot:
- insertVerbText: comp-paper-label-insert
- ejectVerbText: comp-paper-label-eject
- whitelist:
- components:
- - Paper
- blacklist:
- tags:
- - Book
- - type: ItemSlots
- type: DamageOnHighSpeedImpact
damage:
types:
- type: entity
- parent: BaseStructureDynamic
+ parent: [ BaseStructureDynamic, BasePaperLabelableVisualized ]
id: CrateGeneric
categories: [ HideSpawnMenu ]
name: crate
- !type:PlaySoundBehavior
sound:
collection: MetalBreak
- - type: Appearance
- type: EntityStorageVisuals
stateDoorOpen: open
stateDoorClosed: closed
- - type: GenericVisualizer
- visuals:
- enum.PaperLabelVisuals.HasLabel:
- enum.PaperLabelVisuals.Layer:
- True: { visible: true }
- False: { visible: false }
- enum.PaperLabelVisuals.LabelType:
- enum.PaperLabelVisuals.Layer:
- Paper: { state: paper }
- Bounty: { state: bounty }
- CaptainsPaper: { state: captains_paper }
- Invoice: { state: invoice }
- - type: PaperLabel
- labelSlot:
- insertVerbText: comp-paper-label-insert
- ejectVerbText: comp-paper-label-eject
- whitelist:
- components:
- - Paper
- blacklist:
- tags:
- - Book
- type: ContainerContainer
containers:
entity_storage: !type:Container
paper_label: !type:ContainerSlot
- - type: ItemSlots
- type: StaticPrice
price: 75
- type: Construction