/** * This code was AUTOGENERATED using the Codama library. * Please DO NOT EDIT THIS FILE, instead use visitors * to add features, then rerun Codama to update it. * * @see https://github.com/codama-idl/codama */ import { getAddressEncoder, getBytesEncoder, getProgramDerivedAddress, getU32Encoder, type Address, type ProgramDerivedAddress, } from '@solana/kit'; export type AtlasRewardConfigSeeds = { gameId: Address; configVersion: number; }; /** One immutable, fully authored reward configuration version. */ export async function findAtlasRewardConfigPda( seeds: AtlasRewardConfigSeeds, config: { programAddress?: Address | undefined } = {}, ): Promise { const { programAddress = 'C4SAgeKLgb3pTLWhVr6NRwWyYFuTR7ZeSXFrzoLwfMzF' as Address<'C4SAgeKLgb3pTLWhVr6NRwWyYFuTR7ZeSXFrzoLwfMzF'>, } = config; return await getProgramDerivedAddress({ programAddress, seeds: [ getBytesEncoder().encode( new Uint8Array([ 65, 116, 108, 97, 115, 82, 101, 119, 97, 114, 100, 67, 111, 110, 102, 105, 103, ]), ), getAddressEncoder().encode(seeds.gameId), getU32Encoder().encode(seeds.configVersion), ], }); }