Skip to content

Combat

Combat is a capability-only entry: it is not composed into the root client, so you import it directly.

import {
getFleetCombatStatus,
getCombatConfiguration,
} from '@aephia/atlas-kit/combat';
const status = await getFleetCombatStatus(ctx, fleetAddress);

Configuration and status are different reads

Section titled “Configuration and status are different reads”

Configuration comes from the Game account: the rules combat runs by, shared by everyone and stable.

Status is one fleet’s current combat state, which changes.

Reading configuration once and status often is the right pattern — the SDK’s cache makes that cheap, since configuration is part of the Game definitions it already holds.

Loot accounts are what combat leaves behind. They have no derivable address, so finding loot you have no reference to needs discovery:

const loot = await getLootByProfile(ctx, profileAddress);
const flag = await getOutlawFlag(ctx, profileAddress, againstFaction);

Outlaw state is derived rather than stored as a simple boolean, and it may not exist for a given profile at all. Treat its absence as “not an outlaw” rather than as a failed read.

Not composed into the root client. sage.combat does not exist. Import from @aephia/atlas-kit/combat and pass the context, as shown above. The same is true of scanning, rewards, factions, and loyalty.

Combat status can be absent. A fleet that has never fought has nothing to report.

This combat capability remains read-only. It can tell you a fleet’s combat state, but it cannot start, resolve, or influence a fight. The existence of action entries elsewhere does not imply that combat has a curated planner.

  • combat — every export in this entry
  • fleets — the fleet a status belongs to