import { KeyedAccountInfo, PublicKey } from '@solana/web3.js'; import { Account, AsyncSigner, DecodedAccountData, InstructionReturn } from '@staratlas/data-source'; import { CloseDisbandedFleetInput, DisbandedFleetAccount, DisbandedFleetToEscrowInput, SageIDL, SageIDLProgram } from './constants'; /** * Check if two `DisbandedFleetAccount` instances are equal * @param data1 - first DisbandedFleetAccount * @param data2 - second DisbandedFleetAccount * @returns boolean */ export declare function disbandedFleetDataEquals(data1: DisbandedFleetAccount, data2: DisbandedFleetAccount): boolean; export declare const SHIP_COUNTS_SIZE: number; export declare class DisbandedFleet implements Account { private _data; private _key; static readonly ACCOUNT_NAME: NonNullable[number]['name']; static readonly MIN_DATA_SIZE: number; constructor(_data: DisbandedFleetAccount, _key: PublicKey); get data(): Readonly; get key(): PublicKey; /** * Find the DisbandedFleet account address * @param program - SAGE program * @param game - the SAGE game id * @param playerProfile - the profile that owns the fleet * @param fleetLabel - the label/name of the fleet * @returns - The PDA and bump respectively */ static findAddress(program: SageIDLProgram, game: PublicKey, playerProfile: PublicKey, fleetLabel: number[]): [PublicKey, number]; /** * Moves ships from a `DisbandedFleet` to `StarbasePlayer` ship escrow * @param program - SAGE program * @param key - the key authorized to run this instruction * @param playerProfile - the profile with the required permissions for the instruction * @param profileFaction - the profile's faction * @param disbandedFleet - the disbanded fleet * @param fleetShips - the fleet's ships account public key * @param ship - the ship account * @param starbasePlayer - the Starbase player account tied to the Starbase * @param starbase - the Starbase in which the ship is currently in * @param gameId - the SAGE game id * @param gameState - the game state account * @param input - input params * @returns InstructionReturn */ static disbandedFleetToEscrow(program: SageIDLProgram, key: AsyncSigner, playerProfile: PublicKey, profileFaction: PublicKey, disbandedFleet: PublicKey, fleetShips: PublicKey, ship: PublicKey, starbasePlayer: PublicKey, starbase: PublicKey, gameId: PublicKey, gameState: PublicKey, input: DisbandedFleetToEscrowInput): InstructionReturn; /** * Closes am empty `DisbandedFleet` account * @param program - SAGE program * @param key - the key authorized to run this instruction * @param playerProfile - the profile with the required permissions for the instruction * @param fundsTo - the entity that should receive rent refunds * @param disbandedFleet - the disbanded fleet * @param fleetShips - the fleet's ships account public key * @param input - input params * @returns InstructionReturn */ static closeDisbandedFleet(program: SageIDLProgram, key: AsyncSigner, playerProfile: PublicKey, fundsTo: PublicKey | 'funder', disbandedFleet: PublicKey, fleetShips: PublicKey, input: CloseDisbandedFleetInput): InstructionReturn; static decodeData(account: KeyedAccountInfo, program: SageIDLProgram): DecodedAccountData; } //# sourceMappingURL=disbandedFleet.d.ts.map