Types

Position

Info struct containing the position in a battle

struct Position {
    uint256 tokenId;
    address battleAddr;
    int24 tickLower;
    int24 tickUpper;
    uint128 liquidity;
    LiquidityType liquidityType;
    uint256 seed;
    GrowthX128 insideLast;
    Owed owed;
    PositionState state;
    uint256 spearObligation;
    uint256 shieldObligation;
}

Params:

Name

Type

Description

tokenId

uint256

The token ID of the position

battleAddr

address

The address of the battle

tickLower

int24

The lower tick of the position

tickUpper

int24

The upper tick of the position

liquidity

uint128

The liquidity of the position

liquidityType

LiquidityType

Specifies the type of liquidity seeded to the position is collateral, Spear, or Shield

seed

uint256

The token amount provided for the position, of the collateral, Spear or Shield liquidity type

insideLast

GrowthX128

The GrowthX128 info struct inside the position

owed

Owed

The Owed amounts accumulated by the position

state

PositionState

Record the state of the position liquidity or obligation

spearObligation

uint256

The obligatory reserve of collateral amount for settling Spear tokens sold by the position

shieldObligation

uint256

The obligatory reserve of collateral amount for settling Shield tokens sold by the position

Last updated