LODE / Contracts

Contracts

Addresses

EVM

Solana · mainnet

floor_launch
8vfdPWfaA3b9GtJoFUwc36JKDaMfVCJ4oT9HrCrQ6Tdi
carpenter_amm
DdeiDx4ncHo9DXGZm1GrPe7mFKv7kNU3yx95uQEV2APA
floor_hook
9uXLyyZginMWdUeu22kp7XV7cpV8183xfsVqUxKi5Viy
floor_holders
2EUkJXSwCdRAuhesw2D9FXyGfbi6Kw2yZDyQUnCwc7te
floor_vesting
HHiwbXs3egRwtgEPEKx1PHpBU8gq5VSbhfrGrcCd4CSC

Launches

Every launch is registered in FloorRegistry. Page it with count() and page(start, n), or follow Launched. All pools share one hook per chain: FloorFactory.singletonHook().

Calls

function count() view returns (uint256)function page(uint256 start, uint256 n) view returns ((address launch, address token, address hook, address rewards, bytes32 poolId, uint8 mode, uint64 at, address registrar)[])function singletonHook() view returns (address)

Events

event Launched(address indexed launch, address indexed token, address indexed hook, address rewards, bytes32 poolId, uint8 mode, string name, string symbol, address registrar)event LaunchCreated(address indexed token, address indexed hook, address indexed launch, address rewards, bytes32 poolId, uint8 mode, address creator, uint256 graduationMcapUsd, uint256 ethUsd)

Bonding sale

Before graduation a launch trades only against its sale contract (FloorLaunch), at a fixed tranche price: p0 + (p1 − p0) · i / (tranches − 1), quote raw units per 1e18 tokens. No pool fee applies.

Buy: buy() with native value, or buy(amount) after approving the quote token. The tokens arrive in the same call. The LODE Platform fee (teamFeeBps) is charged on top.

Sell: FloorToken.sellBack(tokens), called by the holder. It pays the seller’s average cost for those tokens, less teamFeeBps. No approval.

Graduation: when sold == saleTokens, graduate() (permissionless) opens the v4 pool. The buy that sells out graduates in the same transaction.

Reads

function quoteToken() view returns (address)function saleTokens() view returns (uint256)function sold() view returns (uint256)function raised() view returns (uint256)function p0() view returns (uint256)function p1() view returns (uint256)function tranches() view returns (uint8)function teamFeeBps() view returns (uint16)function graduated() view returns (bool)function canGraduate() view returns (bool)

Buy

function buy() payablefunction buy(uint256 amount) payable

Sell

function sellBack(uint256)

Graduate

function graduate()

Events

event Bought(address indexed who, uint256 tokens, uint256 ethSpent, uint256 soldTotal, uint256 raisedTotal)event SoldBack(address indexed who, uint256 tokens, uint256 ethReturned, uint256 soldTotal, uint256 raisedTotal)event TeamFeeCharged(address indexed who, uint256 fee, bool sellBack)event Graduated(uint256 raised, uint256 floorEth, uint256 polEth, uint256 ladderTokens, int24 openTick)

Pool

After graduation the launch trades in a Uniswap v4 pool with LODE’s hook. poolForAccount(launch) gives the pool id; poolState(id).poolKey gives the key. Swap through any v4 router with that key. The hook takes its fees inside the swap, so the v4 Quoter’s answer is the net amount.

Pool state (hook)

function poolForAccount(address account) view returns (bytes32)function poolState(bytes32 id) view returns ((address poolInitializer, uint256 skimBuyFarBps, uint256 skimSellFarBps, (address currency0, address currency1, uint24 fee, int24 tickSpacing, address hooks) poolKey, bool poolBound, int24 tickSpacing, uint256 vaultEth, uint256 bidEthDeployed, uint256 inventoryTokens, int24 floorTick, int24 bidLower, uint128 bidLiquidity, uint256 cumulativeVolumeEth, uint256 unpaidSkim, bool needsRatchet, uint256 wallShape, uint128 seedLiq, int24 seedLower, int24 seedUpper, uint256 seedFeesSweptEth, uint256 seedFeesSweptTokens, int24 ladderUpper, uint256 ladderTokensRemaining, uint256 ladderProceedsEth, bool ladderSeeded, address token, address platformVault, uint256 platformPaidEth, uint256 creatorSlotCount, uint256 creatorBuyBps, uint256 creatorSellBps, uint256 creatorPendingMask, address recipientClaims, uint256 creatorFeesOwed, uint256 creatorFeesPaid, address holderRewards, uint256 holderBuyBps, uint256 holderSellBps, uint256 holderPaidEth, address quoteToken, bool quoteIsCurrency1, address custodyVault, uint256 skimBuyAtFloorBps, uint256 skimSellAtFloorBps, int24 bidWidth, address referrer, uint256 referralFeesPaid, uint256 quoteUnit, uint256 holderOwedEth, uint256 referralFeesOwed, uint256 teamFeesOwed, uint256 teamFeesPaid, uint256 teamFeeBps) state)

Quote (V4Quoter)

function quoteExactInputSingle(((address currency0, address currency1, uint24 fee, int24 tickSpacing, address hooks) poolKey, bool zeroForOne, uint128 exactAmount, bytes hookData) params) returns (uint256 amountOut, uint256 gasEstimate)function quoteExactOutputSingle(((address currency0, address currency1, uint24 fee, int24 tickSpacing, address hooks) poolKey, bool zeroForOne, uint128 exactAmount, bytes hookData) params) returns (uint256 amountIn, uint256 gasEstimate)

Events

event Swap(bytes32 indexed id, address indexed sender, int128 amount0, int128 amount1, uint160 sqrtPriceX96, uint128 liquidity, int24 tick, uint24 fee)event Ratcheted(bytes32 indexed poolId, int24 floorTick, int24 askTick, uint256 vaultEth, uint256 inventoryTokens, uint256 bounty)

Token

ERC-20, 18 decimals, fixed supply of 1B. Transfers revert with Locked until graduation, except the sale’s own and sellBack.

Calls

function name() view returns (string)function symbol() view returns (string)function decimals() view returns (uint8)function totalSupply() view returns (uint256)function balanceOf(address) view returns (uint256)function approve(address, uint256) returns (bool)function transfer(address to, uint256 value) returns (bool)function burn(uint256)

Solana

Anchor programs. Sale: floor_launch (buy, sell_back, graduate). Pool: carpenter_amm (swap) with floor_hook. Events are Anchor CPI events signed by each program’s event authority.

carpenter_amm events

ConfigInitializedConfigAuthorityChangedHookApprovedHookPausedHookReapprovedQuoteMintListedQuoteMintRetiredQuoteMintRelistedQuoteMintDelistedQuoteCapsAdmittedSetHookQuotesSetQuoteMintHookListedPoolPauseSetPauseGuardianSetGuardianPoolPausedGuardianHookPausedPoolInitializedLiquidityModifiedFeesTruncatedPositionClosedPositionTransferredSwappedDonatedHookDepositedHookWithdrewMintExclusivityRegisteredMintExclusivityRevokedLpFeeUpdatedBaseTransferHookSetTickArrayClosedProtocolTreasuryGovernanceChangedProtocolFeesSweptProtocolFeesWithdrawnProtocolFeeSet

floor_hook events

HookConfigInitializedSkimmedCreatorFeePlatformCutPolRaisedBidReplacedFloorUnbackedRatchetedStairRentReimbursedStairArrayReclaimedStairRatchetedStairFeesSweptStairOwnersPlacedStairOwnerBookedStairPayeeSweptStairTokensWithdrawnStairPayeeResolvedVaultTokensFedCreatorClaimedPlatformSweptRecipientResolvedPoolRegisteredReferralFundedQuoteListedAllowAllQuotesSetQuoteAdmittedQuoteEconomicsSetQuoteRetiredQuoteObservedPoolRewardsTermsHolderPaidReferralPaidPoolReferralTiersReferralTierPaidPlatformWithdrawnTreasuryGovernanceChangedHookGovernanceChangedTeamSweptFloorPoolDesignatedPlatformPoolCreditTeamWithdrawnInventoryDonatedTraderReferralBookedTraderReferralSweptTraderReferralClaimed

floor_launch events

LaunchConfigInitializedLaunchCreatedPayeeSlotsSetBoughtSoldBackGraduatedRecipientClaimedTeamBoughtTeamVestedClaimedTeamBuySoldBackStairRentFundedStairPayeeClaimedGraduationRentReservedGraduationRentClosedGraduationPreparedMetadataBaseSetMetadataUriFilledLaunchEconomicsUpdatedGovernanceChangedAttestorChangedTeamFeesSetGenesisInitializedScheduleUpdatedFloorShareUpdatedGenesisAuthorityTransferStartedGenesisAuthorityTransferredContributedOpeningTickGenesisStairTopUpdatedGenesisWhitelistUpdatedFloorFeesAppliedGenesisGraduatedVestingCreatedGenesisClaimedAllocationDustRoutedGenesisRefundedQuoteChainPricedPresetAddedPresetEnabledPresetAuthorityTransferStartedPresetAuthorityTransferredTraderLinkedSaleTraderReferralBookedSaleTraderReferralSwept

floor_holders events

LaunchHookedClaimsTableRotatedClaimsTableExtendedRecordOpenedHolderClaimedRecordClosed

floor_vesting events

ScheduleCreatedClaimedScheduleClosedAbsoluteSchedule