import type { ContextFloatProvider, FloatRef, } from 'sandstone/arguments/generated/data/number_provider/context_float.ts' import type { ContextIntProvider, IntRef } from 'sandstone/arguments/generated/data/number_provider/context_int.ts' import type { PredicateRef } from 'sandstone/arguments/generated/data/predicate.ts' import type { Registry } from 'sandstone/arguments/generated/registry.ts' import type { NonEmptyWeightedList } from 'sandstone/arguments/generated/util.ts' import type { NBTObject } from 'sandstone/arguments/nbt.ts' import type { DataPointClass, NamespacedString, NonEmptyString } from 'sandstone' export type AggregateProvider = { inputs: S, } export type BinaryProvider = { left: T, right: T, } export type ConditionalProvider = { condition: PredicateRef, on_true: T, /** * Defaults to constant 0. */ on_false?: T, } export type ConstantValue = { value: V, } export type DataStorageProvider = { storage: NamespacedString, path: NonEmptyString | DataPointClass, /** * Defaults to constant 0. */ fallback?: T, } export type DispatcherProvider = { /** * Each condition is tested in order, the first in the list that passes is used. */ cases: Array<{ condition: PredicateRef, value: T, }>, /** * Defaults to constant 0. */ default?: T, } export type DistributionProvider = { distribution: NonEmptyWeightedList, } export type EnvironmentAttributeProvider = { attribute: A, } export type FloatNumberProvider = ContextFloatProvider export type FloatNumberProviderRef = FloatRef export type IntNumberProvider = ContextIntProvider export type IntNumberProviderRef = IntRef export type PowerProvider = { base: T, exponent: T, } export type RandomProvider = { min: T, max: T, } export type SingleProvider = { input: T, }