import type { FactionRelation } from "./factions.js"; export interface ReputationTier { id: string; min: number; relation: FactionRelation; } export declare const DEFAULT_REPUTATION_TIERS: readonly ReputationTier[]; /** * Map a faction standing value to its named reputation tier. * * @capability reputation faction standing that crosses named reputation tiers */ export declare function tierForStanding(tiers: readonly ReputationTier[], standing: number): ReputationTier; export interface ReputationLedgerConfig { tiers?: readonly ReputationTier[]; initial?: Readonly>; min?: number; max?: number; } /** Plain JSON standings of a {@link ReputationLedger}: stored values only, `initial` stays config. */ export interface ReputationLedgerState { records: Record>; } export interface ReputationLedger { standing(actorId: string, factionId: string): number; hasStanding(actorId: string, factionId: string): boolean; gain(actorId: string, factionId: string, amount: number): number; set(actorId: string, factionId: string, standing: number): number; tier(actorId: string, factionId: string): ReputationTier; relation(actorId: string, factionId: string): FactionRelation; standings(actorId: string): Record; reset(actorId: string, factionId?: string): void; snapshot(): ReputationLedgerState; restore(next: ReputationLedgerState): void; } export declare function createReputationLedger(config?: ReputationLedgerConfig): ReputationLedger; export interface EffectiveRelationInput { base: FactionRelation; ledger: ReputationLedger; actorId: string; factionId: string; } export declare function effectiveRelation(input: EffectiveRelationInput): FactionRelation;