Studio Yotsuba
Back to Node List

Variant Value Get

variant_value_get

Gets one typed value by key from a variant record, snapshot, or map

Reviewed
Guide available

Input Ports

NameTypeDescription
Source
source
Any
Required
VariantRecord, VariantSnapshot, or Map to read

Output Ports

NameTypeDescription
Value
value
Number
Typed value stored at Key

Parameters

NameTypeDefaultRangeDescription / Options
Key
key
Text
value—

Snapshot or map key to read

Value Type
value_type
Enum
Number—

Expected type and output port type

  • NumberNumber
    Pass Number values through this node
  • FloatFloat
    Pass Float values through this node
  • IntInt
    Pass Int values through this node
  • BoolBool
    Pass Bool values through this node
  • ColorColor
    Pass Color values through this node
  • TextText
    Pass Text values through this node
  • ImageImage
    Pass Image values through this node
  • PathPath
    Pass Path values through this node
  • PixelLinePixelLine
    Pass PixelLine values through this node
  • Vec2Vec2
    Pass Vec2 values through this node
  • Vec3Vec3
    Pass Vec3 values through this node
  • OklchAdjustOklchAdjust
    Pass OklchAdjust values through this node
  • PalettePalette
    Pass Palette values through this node
  • ListList
    Pass List values through this node
  • MapMap
    Pass Map values through this node
  • TextLayoutTextLayout
    Pass TextLayout values through this node
  • PixelPatchPixelPatch
    Pass PixelPatch values through this node
  • RecordedLayerRecordedLayer
    Pass RecordedLayer values through this node
  • AnimationClipAnimationClip
    Pass AnimationClip values through this node
  • AsepriteFileAsepriteFile
    Pass AsepriteFile values through this node
  • RuleGridSpecRuleGridSpec
    Pass RuleGridSpec values through this node
  • RuleTileSetRuleTileSet
    Pass RuleTileSet values through this node
  • RuleTileAssetRuleTileAsset
    Pass RuleTileAsset values through this node
  • RuleSetRuleSet
    Pass RuleSet values through this node
  • RuleCanvasRuleCanvas
    Pass RuleCanvas values through this node
  • RuleResolvedRuleResolved
    Pass RuleResolved values through this node
  • RuleTileAtlasRuleTileAtlas
    Pass RuleTileAtlas values through this node
  • NineSliceNineSlice
    Pass NineSlice values through this node
  • FxState2DFxState2D
    Pass FxState2D values through this node
  • SpriteSheetSpriteSheet
    Pass SpriteSheet values through this node
  • VariantSnapshotVariantSnapshot
    Pass VariantSnapshot values through this node
  • VariantRecipeVariantRecipe
    Pass VariantRecipe values through this node
  • VariantRecordVariantRecord
    Pass VariantRecord values through this node
  • IsoItemIsoItem
    Pass IsoItem values through this node
  • IsoSceneIsoScene
    Pass IsoScene values through this node
  • IsoWorldIsoWorld
    Pass IsoWorld values through this node
  • TileAssetTileAsset
    Pass TileAsset values through this node
  • TilePaletteTilePalette
    Pass TilePalette values through this node
  • TileCanvasTileCanvas
    Pass TileCanvas values through this node
  • TileResolvedTileResolved
    Pass TileResolved values through this node
  • AnyAny
    Advanced: allow any value type. Downstream nodes may fail if the value type does not match what they expect.

Overview

Extracts one snapshot or Map entry as a normal typed output. It bridges a candidate chosen by Variant Select back into a parameter input on an image or processing node.

Basic workflow

  1. Set VariantRange.key to the value name you want to apply, such as amount.
  2. Connect VariantRange.variants to VariantSelect.variants.
  3. Connect VariantSelect.snapshot to VariantValueGet.source.
  4. Set VariantValueGet.key = amount.
  5. Choose the value_type required downstream and connect value to that parameter.

You can also connect VariantSelect.values and read the same key from its Map.

Notes

  • The source wire is typed as Any, but runtime input is restricted to VariantRecord, VariantSnapshot, or Map.
  • A missing key or a value that does not match value_type is an explicit error.
  • Number preserves either Float or Int. Selecting Float converts an Int value to Float.
  • Changing value_type synchronizes the concrete type of the value output port.

Related nodes

  • variant_select — choose one candidate and expose the source data
  • variant_range / seed_range — generate candidates
  • batch_render — evaluate all candidates in a batch
Back to Node List