File tree Expand file tree Collapse file tree 3 files changed +8
-0
lines changed Expand file tree Collapse file tree 3 files changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -84,6 +84,8 @@ export function decodeUser(buffer: Buffer): UserAccount {
8484 const quoteAssetAmount = readSignedBigInt64LE ( buffer , offset + 16 ) ;
8585 const lpShares = readUnsignedBigInt64LE ( buffer , offset + 64 ) ;
8686 const openOrders = buffer . readUInt8 ( offset + 94 ) ;
87+ const positionFlag = buffer . readUInt8 ( offset + 95 ) ;
88+ const isolatedPositionScaledBalance = readUnsignedBigInt64LE ( buffer , offset + 96 ) ;
8789
8890 if (
8991 baseAssetAmount . eq ( ZERO ) &&
@@ -135,6 +137,8 @@ export function decodeUser(buffer: Buffer): UserAccount {
135137 openOrders,
136138 perLpBase,
137139 maxMarginRatio,
140+ isolatedPositionScaledBalance,
141+ positionFlag,
138142 } ) ;
139143 }
140144
Original file line number Diff line number Diff line change @@ -1135,6 +1135,8 @@ export type PerpPosition = {
11351135 lastBaseAssetAmountPerLp : BN ;
11361136 lastQuoteAssetAmountPerLp : BN ;
11371137 perLpBase : number ;
1138+ isolatedPositionScaledBalance : BN ;
1139+ positionFlag : number ;
11381140} ;
11391141
11401142export type UserStatsAccount = {
Original file line number Diff line number Diff line change @@ -338,6 +338,8 @@ export class User {
338338 lastQuoteAssetAmountPerLp : ZERO ,
339339 perLpBase : 0 ,
340340 maxMarginRatio : 0 ,
341+ isolatedPositionScaledBalance : ZERO ,
342+ positionFlag : 0 ,
341343 } ;
342344 }
343345
You can’t perform that action at this time.
0 commit comments