tx · 5Q4sY49apvAUgv1caA55zV47WLFUbUVcHmoAVNLppp8r

3NAfzeA3URU6oCV6HvtAiNwqGXsTs87ZpHh:  -0.02400000 Waves

2023.02.10 10:54 [2443255] smart account 3NAfzeA3URU6oCV6HvtAiNwqGXsTs87ZpHh > SELF 0.00000000 Waves

{ "type": 13, "id": "5Q4sY49apvAUgv1caA55zV47WLFUbUVcHmoAVNLppp8r", "fee": 2400000, "feeAssetId": null, "timestamp": 1676015664219, "version": 2, "chainId": 84, "sender": "3NAfzeA3URU6oCV6HvtAiNwqGXsTs87ZpHh", "senderPublicKey": "HiTi1JT7GQRqLNxg4yZhD1mV42y1Mv2AYvRx92JQRbwX", "proofs": [ "15QzAudUttPoiQacDAJmLJqGbgWm8MwFnrEdd9DdeKvgpmVEwwDhx3QpoKyjFx9QqfCgggNtNm9DhTRTPsNQtjp" ], "script": "base64:BgJWCAISBAoCAQQSBQoDCAEBEgUKAwgBARIDCgEIEgMKAQgSBAoCCAESBQoDCAEIEgUKAwgBCBIFCgMIAQgSAwoBARIDCgEBEgQKAgEBEgMKAQESBAoCAQFwAAZFVUxFUjgA1onPgQEABU1VTFQ2AMCEPQAGTVVMVFg2CQC2AgEAwIQ9AAVNVUxUOACAwtcvAAZNVUxUWDgJALYCAQCAwtcvAAdNVUxUWDEwCQC2AgEAgMivoCUABk1VTFQxMgCAoJSljR0AB01VTFRYMTYJALYCAQCAgIT+pt7hEQAGTVVMVDE4CQC2AgEAgICQu7rWrfANAANTRVACAl9fABFERUZBVUxUU1dBUEZFRU4yVwCIJwARREVGQVVMVFNXQVBGRUVXMk4AoJwBAAtCUlBST1RFQ1RFRACgjQYAB1dBVkVTSUQJANkEAQIFV0FWRVMACURBWU1JTExJUwCAuJkpARJrZXlOZXV0cmlub0Fzc2V0SWQAAhFuZXV0cmlub19hc3NldF9pZAEOa2V5TnNidEFzc2V0SWQAAg1ib25kX2Fzc2V0X2lkAQ5rZXlTdXJmQXNzZXRJZAACDXN1cmZfYXNzZX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Rm9yUGVyaW9kAgUTc3VyZlN0YWtpbmdDb250cmFjdAUHdG1wRGF5cwQDYXByCQEHY2FsY0FwcgQFE3N1cmZTdGFraW5nQ29udHJhY3QFB3RtcERheXMFD2luY29tZUZvclBlcmlvZAUPc3VyZlVzZG5QcmljZVg2CQCUCgIFA25pbAkArAICAgQlZF9fCQCkAwEFA2FwcgFpARZuc2J0U3Rha2luZ0FwclJFQURPTkxZAQRkYXlzBAd0bXBEYXlzAAMEEW5zYnRQcmljZVRvVXNkblg2AICk6AMED2luY29tZUZvclBlcmlvZAkBF2NhbGNVc2RuSW5jb21lRm9yUGVyaW9kAgUTbnNidFN0YWtpbmdDb250cmFjdAUHdG1wRGF5cwQDYXByCQEHY2FsY0FwcgQFE25zYnRTdGFraW5nQ29udHJhY3QFB3RtcERheXMFD2luY29tZUZvclBlcmlvZAURbnNidFByaWNlVG9Vc2RuWDYJAJQKAgUDbmlsCQCsAgICBCVkX18JAKQDAQUDYXByAWkBGG5zYnRTdGFraW5nQXByVjJSRUFET05MWQIEZGF5cw9uc2J0VXNkblByaWNlWDYEB3RtcERheXMAAwQPaW5jb21lRm9yUGVyaW9kCQEXY2FsY1VzZG5JbmNvbWVGb3JQZXJpb2QCBRNuc2J0U3Rha2luZ0NvbnRyYWN0BQd0bXBEYXlzBANhcHIJAQdjYWxjQXByBAUTbnNidFN0YWtpbmdDb250cmFjdAUHdG1wRGF5cwUPaW5jb21lRm9yUGVyaW9kBQ9uc2J0VXNkblByaWNlWDYJAJQKAgUDbmlsCQCsAgICBCVkX18JAKQDAQUDYXByAB2seFg=", "height": 2443255, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: C6B1me3ckcGDpGuc2g2E6HnqunrnMsdN8bCpepNqm1Di Next: 9WUGuchhMLgrzNpmgPDNhNTdtWcbxPwXKTnSg3MJ8nFh Diff:
OldNewDifferences
4040 func keySurfAssetId () = "surf_asset_id"
4141
4242
43-func keyBalanceLocked () = "balance_lock_"
44-
45-
46-func keyWavesLockedBalance () = (keyBalanceLocked() + "waves")
47-
48-
49-func keyNeutrinoLockedBalance () = (keyBalanceLocked() + "neutrino")
50-
51-
5243 func keyMinWavesSwapAmount () = "min_waves_swap_amount"
5344
5445
8374
8475
8576 func keyBalanceNeutrinoLockInterval () = "balance_neutrino_lock_interval"
77+
78+
79+func basketAssetsKey () = "%s%s__common__basketAssets"
8680
8781
8882 func keyPrice () = "price"
171165
172166
173167 func asWithdrawResultSTRUCT (val) = match val {
174- case struct: (Int, Unit, Int, Int, Int, Int, Int, Int)|(Int, ByteVector, Int, Int, Int, Int, Int, Int) =>
168+ case struct: (Int, Unit, Int, Int, Int, Int, Int, Int, String)|(Int, ByteVector, Int, Int, Int, Int, Int, Int, String) =>
175169 struct
176170 case _ =>
177171 throw("fail to cast into WithdrawResult")
510504 let limitMaxWaves = swapParamsTuple._6
511505 let limitMaxUsdn = swapParamsTuple._7
512506 let assetId = fromBase58String(assetIdStr)
513- let swapType = if ((assetId == WAVESID))
514- then "waves"
507+ let basketAssets = valueOrElse(getString(neutrinoContract, basketAssetsKey()), "WAVES")
508+ let swapType = if (contains(basketAssets, assetIdStr))
509+ then "outNeutrino"
515510 else if ((assetId == neutrinoAssetId))
516- then "neutrino"
511+ then "outMulti"
517512 else throw(("Can't swap assetId=" + assetIdStr))
518- let withdrawTuple = asWithdrawResultSTRUCT(invoke(neutrinoContract, "calcWithdrawResultSYSREADONLY", [swapType, amount, price], nil))
513+ let withdrawTuple = asWithdrawResultSTRUCT(invoke(neutrinoContract, "calcWithdrawResultSYSREADONLY", [swapType, amount, price, assetIdStr], nil))
519514 let outNetAmount = withdrawTuple._1
520515 let outAssetId = withdrawTuple._2
521516 let outSurfAmt = withdrawTuple._3
538533 let limitMaxWaves = swapParamsTuple._6
539534 let limitMaxUsdn = swapParamsTuple._7
540535 let assetId = fromBase58String(assetIdStr)
541- let swapType = if ((assetId == WAVESID))
542- then "waves"
536+ let basketAssets = valueOrElse(getString(neutrinoContract, basketAssetsKey()), "WAVES")
537+ let swapType = if (contains(basketAssets, assetIdStr))
538+ then "outNeutrino"
543539 else if ((assetId == neutrinoAssetId))
544- then "neutrino"
540+ then "outMulti"
545541 else throw(("Can't swap assetId=" + assetIdStr))
546- let withdrawTuple = asWithdrawResultSTRUCT(invoke(neutrinoContract, "calcWithdrawResultSYSREADONLY", [swapType, amount, price], nil))
542+ let withdrawTuple = asWithdrawResultSTRUCT(invoke(neutrinoContract, "calcWithdrawResultSYSREADONLY", [swapType, amount, price, assetIdStr], nil))
547543 let outNetAmount = withdrawTuple._1
548544 let outAssetId = withdrawTuple._2
549545 let outSurfAmt = withdrawTuple._3
552548 let outFeeAmount = withdrawTuple._6
553549 let outAmtGross = withdrawTuple._7
554550 let withdrawPrice = withdrawTuple._8
555- let basketStub = "WAVES:6500000:15590257:78343:318181_EMAMLxDnv3xiz8RXg8Btj33jcEw3wLczL3JKYYmuubpc:318700:35980614:179903:170454_52nvaZGa7ahqa21ER2PAMBVjMi7wC2nWYCNmLvj8QjHx:585395:19588520:97942:170454_9JXnfooQYnahr5L1dH7YksMmWPE8TZramFycXyYxv6Ef:49418611:232038:1160:170454_AMFteLfPzPhTsFc3NfvHG7fSRUnsp3tJXPH88G1PCisT:461400:248526696:1242633:170454"
556- $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d%s", toString(outNetAmount), toString(outSurfAmt), toString(outFeeAmount), toString(withdrawPrice), toString(blcks2LmtReset), toString(limitMaxWaves), toString(limitMaxUsdn), toString(inAmtToSurfPart), basketStub], SEP))
551+ let withdrawBasket = withdrawTuple._9
552+ $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d%s", toString(outNetAmount), toString(outSurfAmt), toString(outFeeAmount), toString(withdrawPrice), toString(blcks2LmtReset), toString(limitMaxWaves), toString(limitMaxUsdn), toString(inAmtToSurfPart), withdrawBasket], SEP))
557553 }
558554
559555
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let EULER8 = 271828182
55
66 let MULT6 = 1000000
77
88 let MULTX6 = toBigInt(1000000)
99
1010 let MULT8 = 100000000
1111
1212 let MULTX8 = toBigInt(100000000)
1313
1414 let MULTX10 = toBigInt(10000000000)
1515
1616 let MULT12 = 1000000000000
1717
1818 let MULTX16 = toBigInt(10000000000000000)
1919
2020 let MULT18 = toBigInt(1000000000000000000)
2121
2222 let SEP = "__"
2323
2424 let DEFAULTSWAPFEEN2W = 5000
2525
2626 let DEFAULTSWAPFEEW2N = 20000
2727
2828 let BRPROTECTED = 100000
2929
3030 let WAVESID = fromBase58String("WAVES")
3131
3232 let DAYMILLIS = 86400000
3333
3434 func keyNeutrinoAssetId () = "neutrino_asset_id"
3535
3636
3737 func keyNsbtAssetId () = "bond_asset_id"
3838
3939
4040 func keySurfAssetId () = "surf_asset_id"
4141
4242
43-func keyBalanceLocked () = "balance_lock_"
44-
45-
46-func keyWavesLockedBalance () = (keyBalanceLocked() + "waves")
47-
48-
49-func keyNeutrinoLockedBalance () = (keyBalanceLocked() + "neutrino")
50-
51-
5243 func keyMinWavesSwapAmount () = "min_waves_swap_amount"
5344
5445
5546 func keyMinNeutrinoSwapAmount () = "min_neutrino_swap_amount"
5647
5748
5849 func keyWavesOutFeePart () = "wavesOut_swap_feePart"
5950
6051
6152 func keyNeutrinoOutFeePart () = "neutrinoOut_swap_feePart"
6253
6354
6455 func keySwapAmountAParam () = "%s%s__config__swapAParam"
6556
6657
6758 func keySwapAmountBParam () = "%s%s__config__swapBParam"
6859
6960
7061 func keyUsdnSwapAmountAParam () = "%s%s__config__usdnSwapAParam"
7162
7263
7364 func keyUsdnSwapAmountBParam () = "%s%s__config__usdnSwapBParam"
7465
7566
7667 func keyNsbtLockContract () = "%s__nsbtLockContract"
7768
7869
7970 func keyMathContract () = "%s__mathContract"
8071
8172
8273 func keyBalanceWavesLockInterval () = "balance_waves_lock_interval"
8374
8475
8576 func keyBalanceNeutrinoLockInterval () = "balance_neutrino_lock_interval"
77+
78+
79+func basketAssetsKey () = "%s%s__common__basketAssets"
8680
8781
8882 func keyPrice () = "price"
8983
9084
9185 func keyLockParamStartBlock (userAddress) = makeString(["%s%s%s", "paramByUser", userAddress, "start"], SEP)
9286
9387
9488 func keyHalfLife () = "%s__halfLife"
9589
9690
9791 func keyMinLockAmount () = "%s__minLockAmount"
9892
9993
10094 func keyMinWavesForNsbtBuy () = "min_waves_nsbt_buy"
10195
10296
10397 func keyMinNsbtSell () = "min_nsbt_sell"
10498
10599
106100 func keyStatsDepositAmtByDay (timestamp) = makeString(["%s%s%d", "stats", "depositAmtByDay", toString(timestamp)], SEP)
107101
108102
109103 func toStartOfDay (timestamp) = ((timestamp / DAYMILLIS) * DAYMILLIS)
110104
111105
112106 func getStringOrFail (address,key) = valueOrErrorMessage(getString(address, key), makeString(["mandatory ", toString(address), ".", key, " is not defined"], ""))
113107
114108
115109 func getIntOrFail (address,key) = valueOrErrorMessage(getInteger(address, key), makeString(["mandatory ", toString(address), ".", key, " is not defined"], ""))
116110
117111
118112 func getBoolOrFail (address,key) = valueOrErrorMessage(getBoolean(address, key), makeString(["mandatory ", toString(address), ".", key, " is not defined"], ""))
119113
120114
121115 func getIntOrElse (address,key,defaultVal) = valueOrElse(getInteger(address, key), defaultVal)
122116
123117
124118 func getStrOrElse (address,key,defaultVal) = valueOrElse(getString(address, key), defaultVal)
125119
126120
127121 func convertNeutrinoToWaves (amount,price) = fraction(amount, MULT8, price)
128122
129123
130124 func convertWavesToNeutrino (amount,price) = fraction(amount, price, MULT8)
131125
132126
133127 func asAnyList (val) = match val {
134128 case valAnyList: List[Any] =>
135129 valAnyList
136130 case _ =>
137131 throw("fail to cast into List[Any]")
138132 }
139133
140134
141135 func asInt (val) = match val {
142136 case valInt: Int =>
143137 valInt
144138 case _ =>
145139 throw("fail to cast into Int")
146140 }
147141
148142
149143 func asString (val) = match val {
150144 case valStr: String =>
151145 valStr
152146 case _ =>
153147 throw("fail to cast into String")
154148 }
155149
156150
157151 func asTuple2Ints (val) = match val {
158152 case v: (Int, Int) =>
159153 v
160154 case _ =>
161155 throw("fail to cast into Tuple2 ints")
162156 }
163157
164158
165159 func asSwapParamsSTRUCT (val) = match val {
166160 case struct: (Int, Int, Int, Int, Int, Int, Int) =>
167161 struct
168162 case _ =>
169163 throw("fail to cast into SwapParamsSTRUCT")
170164 }
171165
172166
173167 func asWithdrawResultSTRUCT (val) = match val {
174- case struct: (Int, Unit, Int, Int, Int, Int, Int, Int)|(Int, ByteVector, Int, Int, Int, Int, Int, Int) =>
168+ case struct: (Int, Unit, Int, Int, Int, Int, Int, Int, String)|(Int, ByteVector, Int, Int, Int, Int, Int, Int, String) =>
175169 struct
176170 case _ =>
177171 throw("fail to cast into WithdrawResult")
178172 }
179173
180174
181175 func toTimestamp (start) = if ((0 > start))
182176 then -1
183177 else match blockInfoByHeight(start) {
184178 case block: BlockInfo =>
185179 block.timestamp
186180 case _ =>
187181 -1
188182 }
189183
190184
191185 func toX18 (origVal,origScaleMult) = fraction(toBigInt(origVal), MULT18, toBigInt(origScaleMult))
192186
193187
194188 func fromX18 (val,resultScaleMult) = toInt(fraction(val, toBigInt(resultScaleMult), MULT18))
195189
196190
197191 let nMetricIdxPrice = 0
198192
199193 let nMetricIdxUsdnLockedBalance = 1
200194
201195 let nMetricIdxWavesLockedBalance = 2
202196
203197 let nMetricIdxReserve = 3
204198
205199 let nMetricIdxReserveInUsdn = 4
206200
207201 let nMetricIdxUsdnSupply = 5
208202
209203 let nMetricIdxSurplus = 6
210204
211205 let nMetricIdxSurplusPercent = 7
212206
213207 let nMetricIdxBR = 8
214208
215209 let nMetricIdxNsbtSupply = 9
216210
217211 let nMetricIdxMaxNsbtSupply = 10
218212
219213 let nMetricIdxSurfSupply = 11
220214
221215 let IdxControlCfgNeutrinoDapp = 1
222216
223217 let IdxControlCfgAuctionDapp = 2
224218
225219 let IdxControlCfgRpdDapp = 3
226220
227221 let IdxControlCfgMathDapp = 4
228222
229223 let IdxControlCfgLiquidationDapp = 5
230224
231225 let IdxControlCfgRestDapp = 6
232226
233227 let IdxControlCfgNodeRegistryDapp = 7
234228
235229 let IdxControlCfgNsbtStakingDapp = 8
236230
237231 let IdxControlCfgMediatorDapp = 9
238232
239233 let IdxControlCfgSurfStakingDapp = 10
240234
241235 let IdxControlCfgGnsbtControllerDapp = 11
242236
243237 let bFuncIdxSurf = 0
244238
245239 let bFuncIdxWaves = 1
246240
247241 let bFuncIdxUsdn = 2
248242
249243 let bFuncIdxReserveStart = 3
250244
251245 let bFuncIdxSupplyStart = 4
252246
253247 let bFuncIdxBRStart = 5
254248
255249 let bFuncIdxReserveEnd = 6
256250
257251 let bFuncIdxSupplyEnd = 7
258252
259253 let bFuncIdxBREnd = 8
260254
261255 let bFuncIdxRest = 9
262256
263257 let bFuncIdxWavesPrice = 10
264258
265259 func keyControlAddress () = "%s%s__config__controlAddress"
266260
267261
268262 func keyControlCfg () = "%s__controlConfig"
269263
270264
271265 func readControlCfgOrFail (control) = split_4C(getStringOrFail(control, keyControlCfg()), SEP)
272266
273267
274268 func getContractAddressOrFail (controlCfg,idx) = valueOrErrorMessage(addressFromString(controlCfg[idx]), ("Control cfg doesn't contain address at index " + toString(idx)))
275269
276270
277271 let controlContract = addressFromStringValue(valueOrElse(getString(this, keyControlAddress()), "3N4NS7d4Jo9a6F14LiFUKKYVdUkkf2eP4Zx"))
278272
279273 let controlCfg = readControlCfgOrFail(controlContract)
280274
281275 let mathContract = getContractAddressOrFail(controlCfg, IdxControlCfgMathDapp)
282276
283277 let neutrinoContract = getContractAddressOrFail(controlCfg, IdxControlCfgNeutrinoDapp)
284278
285279 let auctionContract = getContractAddressOrFail(controlCfg, IdxControlCfgAuctionDapp)
286280
287281 let liquidationContract = getContractAddressOrFail(controlCfg, IdxControlCfgLiquidationDapp)
288282
289283 let rpdContract = getContractAddressOrFail(controlCfg, IdxControlCfgRpdDapp)
290284
291285 let nsbtStakingContract = getContractAddressOrFail(controlCfg, IdxControlCfgNsbtStakingDapp)
292286
293287 let surfStakingContract = getContractAddressOrFail(controlCfg, IdxControlCfgSurfStakingDapp)
294288
295289 let gnsbtControllerContract = getContractAddressOrFail(controlCfg, IdxControlCfgGnsbtControllerDapp)
296290
297291 let neutrinoAssetIdString = getStringOrFail(neutrinoContract, keyNeutrinoAssetId())
298292
299293 let neutrinoAssetId = fromBase58String(neutrinoAssetIdString)
300294
301295 let nsbtAssetIdStr = getStringValue(neutrinoContract, keyNsbtAssetId())
302296
303297 let nsbtAssetId = fromBase58String(nsbtAssetIdStr)
304298
305299 let surfAssetIdStr = getStringValue(auctionContract, keySurfAssetId())
306300
307301 let surfAssetId = fromBase58String(surfAssetIdStr)
308302
309303 func readUsdnIncomeForDay (stakingAcc,startOfDayTimestamp,neutrinoMetrics) = {
310304 let amtByDayKEY = keyStatsDepositAmtByDay(startOfDayTimestamp)
311305 let incomeStr = getStrOrElse(stakingAcc, amtByDayKEY, "%s%s__0__0")
312306 let incomeArray = split(incomeStr, SEP)
313307 let wavesAmt = parseIntValue(incomeArray[1])
314308 let usdnAmt = parseIntValue(incomeArray[2])
315309 let currentPrice = asInt(neutrinoMetrics[nMetricIdxPrice])
316310 let wavesAsUsdnAmt = fraction(wavesAmt, currentPrice, MULT8)
317311 (wavesAsUsdnAmt + usdnAmt)
318312 }
319313
320314
321315 func calcUsdnIncomeForPeriod (stakingAcc,days) = {
322316 let neutrinoMetrics = asAnyList(invoke(mathContract, "calcNeutinoMetricsREADONLY", nil, nil))
323317 let currStartOfDay = toStartOfDay(lastBlock.timestamp)
324318 let startTimestamp = (currStartOfDay - (DAYMILLIS * (days + 1)))
325319 let endTimestamp = (currStartOfDay - DAYMILLIS)
326320 let startUsdnAmtTMP = readUsdnIncomeForDay(stakingAcc, startTimestamp, neutrinoMetrics)
327321 let endUsdnAmt = readUsdnIncomeForDay(stakingAcc, endTimestamp, neutrinoMetrics)
328322 let startUsdnAmt = if ((startUsdnAmtTMP == 0))
329323 then endUsdnAmt
330324 else startUsdnAmtTMP
331325 (endUsdnAmt - startUsdnAmt)
332326 }
333327
334328
335329 func calcApr (stakingAcc,periodInDays,incomeForPeriod,stakingAssetPriceToUsdnX6) = {
336330 let totalStaked = getIntOrElse(stakingAcc, "%s%s__stats__activeTotalLocked", 1)
337331 let totalStakedInUsdn = fraction(totalStaked, stakingAssetPriceToUsdnX6, MULT6)
338332 if ((0 > incomeForPeriod))
339333 then 0
340334 else fraction((incomeForPeriod * MULT6), 365, (totalStakedInUsdn * periodInDays))
341335 }
342336
343337
344338 @Callable(i)
345339 func reverseSwapLimitREADONLY (lim,isWavesSwap) = {
346340 let BR = asInt(asAnyList(invoke(mathContract, "calcNeutinoMetricsREADONLY", nil, nil))[nMetricIdxBR])
347341 let gNsbt = if ((0 >= lim))
348342 then 0
349343 else {
350344 let aParamX8 = toBigInt(getIntOrFail(mathContract, if (isWavesSwap)
351345 then keySwapAmountAParam()
352346 else keyUsdnSwapAmountAParam()))
353347 let bParamX16 = toBigInt(getIntOrFail(mathContract, if (isWavesSwap)
354348 then keySwapAmountBParam()
355349 else keyUsdnSwapAmountBParam()))
356350 let limDivAX8 = if (isWavesSwap)
357351 then fraction(toBigInt(lim), MULTX10, aParamX8)
358352 else fraction(fraction(toBigInt(lim), MULTX10, aParamX8), MULTX6, toBigInt(BR))
359353 let revBX16 = fraction(MULTX16, MULTX16, bParamX16)
360354 toInt(pow(limDivAX8, 8, revBX16, 16, 6, CEILING))
361355 }
362356 $Tuple2(nil, gNsbt)
363357 }
364358
365359
366360
367361 @Callable(i)
368362 func gnsbtInfoINTERNAL (userAddressStrOrEmpty,additionalNsbtToStakeOrZero,additionalSurfToStakeOrZero) = {
369363 let userAddressOrThis = if ((userAddressStrOrEmpty != ""))
370364 then addressFromStringValue(userAddressStrOrEmpty)
371365 else this
372366 let currentPrice = getIntegerValue(controlContract, keyPrice())
373367 let gnsbtFromNsbtDiff = additionalNsbtToStakeOrZero
374368 let gnsbtFromSurfDiff = asInt(invoke(surfStakingContract, "gnsbtFromSurfSYSREADONLY", [additionalSurfToStakeOrZero], nil))
375369 let gNsbtDiff = (gnsbtFromNsbtDiff + gnsbtFromSurfDiff)
376370 let swapParamsTuple = asSwapParamsSTRUCT(invoke(neutrinoContract, "swapParamsByUserSYSREADONLY", [userAddressStrOrEmpty, 0], nil))
377371 let blcks2LmtReset = swapParamsTuple._3
378372 let gnsbtAmt = swapParamsTuple._4
379373 let gnsbtAmtTotal = swapParamsTuple._5
380374 let limitMaxWaves = swapParamsTuple._6
381375 let limitMaxUsdn = swapParamsTuple._7
382376 let swapParamsTupleNEW = asSwapParamsSTRUCT(invoke(neutrinoContract, "swapParamsByUserSYSREADONLY", [userAddressStrOrEmpty, gNsbtDiff], nil))
383377 let blcks2LmtResetNEW = swapParamsTupleNEW._3
384378 let gnsbtAmtNEW = swapParamsTupleNEW._4
385379 let gnsbtAmtTotalNEW = swapParamsTupleNEW._5
386380 let limitMaxWavesNEW = swapParamsTupleNEW._6
387381 let limitMaxUsdnNEW = swapParamsTupleNEW._7
388382 let nsbtBalance = if ((userAddressStrOrEmpty != ""))
389383 then assetBalance(userAddressOrThis, nsbtAssetId)
390384 else 0
391385 let surfBalance = if ((userAddressStrOrEmpty != ""))
392386 then assetBalance(userAddressOrThis, surfAssetId)
393387 else 0
394388 let nsbtBalanceDiff = if ((additionalNsbtToStakeOrZero >= 0))
395389 then additionalNsbtToStakeOrZero
396390 else {
397391 let nsbtUnstakingData = asAnyList(invoke(nsbtStakingContract, "nsbtUnstakingSYSREADONLY", [userAddressStrOrEmpty, (-1 * additionalNsbtToStakeOrZero)], nil))
398392 let nsbtReceiveAmount = asInt(nsbtUnstakingData[2])
399393 let result = -(nsbtReceiveAmount)
400394 result
401395 }
402396 let nsbtBalanceNew = (nsbtBalance - nsbtBalanceDiff)
403397 let surfBalanceNew = (surfBalance - additionalSurfToStakeOrZero)
404398 let gnsbtData = asAnyList(invoke(gnsbtControllerContract, "gnsbtInfoSYSREADONLY", [userAddressStrOrEmpty, additionalNsbtToStakeOrZero, additionalSurfToStakeOrZero], nil))
405399 let gnsbtUser = asInt(gnsbtData[0])
406400 let gnsbtTotal = asInt(gnsbtData[1])
407401 let nsbtData = asAnyList(gnsbtData[2])
408402 let surfData = asAnyList(gnsbtData[3])
409403 let vpEffectiveHeight = asInt(gnsbtData[4])
410404 let vpEffectiveHeightNEW = asInt(gnsbtData[5])
411405 let gnsbtAmtFromNsbt = asInt(nsbtData[2])
412406 let gnsbtAmtFromSurf = asInt(surfData[2])
413407 let gnsbtAmtFromNsbtNEW = (gnsbtAmtFromNsbt + gnsbtFromNsbtDiff)
414408 let gnsbtAmtFromSurfNEW = (gnsbtAmtFromSurf + gnsbtFromSurfDiff)
415409 let gnsbtFromNsbtTotal = asInt(nsbtData[3])
416410 let gnsbtFromSurfTotal = asInt(surfData[3])
417411 let gnsbtFromSurfActiveTotal = 0
418412 let gnsbtFromSurfFrozenTotal = gnsbtFromSurfTotal
419413 let gnsbtFromNsbtTotalNEW = (gnsbtFromNsbtTotal + gnsbtFromNsbtDiff)
420414 let gnsbtFromSurfTotalNEW = (gnsbtFromSurfTotal + gnsbtFromSurfDiff)
421415 let gnsbtFromSurfFrozenTotalNEW = gnsbtFromSurfTotalNEW
422416 let votingPower = fraction(gnsbtAmtFromNsbt, MULT8, (gnsbtFromNsbtTotal + gnsbtFromSurfActiveTotal))
423417 let votingPowerNew = fraction(gnsbtAmtFromNsbtNEW, MULT8, (gnsbtFromNsbtTotalNEW + gnsbtFromSurfActiveTotal))
424418 let votingPowerMax = fraction((gnsbtAmtFromNsbt + gnsbtAmtFromSurf), MULT8, ((gnsbtFromNsbtTotal + gnsbtFromSurfActiveTotal) + gnsbtFromSurfFrozenTotal))
425419 let votingPowerMaxNew = fraction((gnsbtAmtFromNsbtNEW + gnsbtAmtFromSurfNEW), MULT8, ((gnsbtFromNsbtTotalNEW + gnsbtFromSurfActiveTotal) + gnsbtFromSurfFrozenTotalNEW))
426420 let votingPowerEta = if ((vpEffectiveHeight == 0))
427421 then height
428422 else vpEffectiveHeight
429423 let votingPowerEtaNew = if ((vpEffectiveHeightNEW == 0))
430424 then height
431425 else vpEffectiveHeightNEW
432426 $Tuple2(nil, [0, nsbtBalance, surfBalance, nsbtBalanceNew, surfBalanceNew, gnsbtAmtFromNsbt, gnsbtAmtFromSurf, gnsbtAmtFromNsbtNEW, gnsbtAmtFromSurfNEW, gnsbtFromNsbtTotal, gnsbtFromSurfTotal, gnsbtFromNsbtTotalNEW, gnsbtFromSurfTotalNEW, limitMaxUsdn, limitMaxWaves, limitMaxUsdnNEW, limitMaxWavesNEW, blcks2LmtReset, blcks2LmtResetNEW, votingPower, votingPowerNew, votingPowerMax, votingPowerMaxNew, votingPowerEta, votingPowerEtaNew])
433427 }
434428
435429
436430
437431 @Callable(i)
438432 func gnsbtInfoREADONLY (userAddressStrOrEmpty,additionalNsbtToStakeOrZero,additionalSurfToStakeOrZero) = {
439433 let gnsbtInfoDATA = asAnyList(invoke(this, "gnsbtInfoINTERNAL", [userAddressStrOrEmpty, additionalNsbtToStakeOrZero, additionalSurfToStakeOrZero], nil))
440434 $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d", toString(asInt(gnsbtInfoDATA[1])), toString(asInt(gnsbtInfoDATA[2])), toString(asInt(gnsbtInfoDATA[3])), toString(asInt(gnsbtInfoDATA[4])), toString(asInt(gnsbtInfoDATA[5])), toString(asInt(gnsbtInfoDATA[6])), toString(asInt(gnsbtInfoDATA[7])), toString(asInt(gnsbtInfoDATA[8])), toString(asInt(gnsbtInfoDATA[9])), toString(asInt(gnsbtInfoDATA[10])), toString(asInt(gnsbtInfoDATA[11])), toString(asInt(gnsbtInfoDATA[12])), toString(asInt(gnsbtInfoDATA[13])), toString(asInt(gnsbtInfoDATA[14])), toString(asInt(gnsbtInfoDATA[15])), toString(asInt(gnsbtInfoDATA[16])), toString(asInt(gnsbtInfoDATA[17])), toString(asInt(gnsbtInfoDATA[18])), toString(asInt(gnsbtInfoDATA[19])), toString(asInt(gnsbtInfoDATA[20])), toString(asInt(gnsbtInfoDATA[21])), toString(asInt(gnsbtInfoDATA[22])), toString(asInt(gnsbtInfoDATA[23])), toString(asInt(gnsbtInfoDATA[24]))], SEP))
441435 }
442436
443437
444438
445439 @Callable(i)
446440 func gnsbtEffectiveREADONLY (userAddressStrOrEmpty) = {
447441 let gnsbtData = asAnyList(invoke(gnsbtControllerContract, "gnsbtInfoSYSREADONLY", [userAddressStrOrEmpty, 0, 0], nil))
448442 let nsbtData = asAnyList(gnsbtData[2])
449443 let userFromNsbt = asInt(nsbtData[2])
450444 let totalFromNsbt = asInt(nsbtData[3])
451445 let userMatureFromSurf = asInt(gnsbtData[9])
452446 let totalMatureFromSurf = asInt(gnsbtData[6])
453447 $Tuple2(nil, makeString(["%d%d", toString((totalFromNsbt + totalMatureFromSurf)), toString((userFromNsbt + userMatureFromSurf))], SEP))
454448 }
455449
456450
457451
458452 @Callable(i)
459453 func rewardInfoREADONLY (userAddressStrOrEmpty) = {
460454 let rewardsData = asAnyList(invoke(gnsbtControllerContract, "gnsbtRewardsSYSREADONLY", [userAddressStrOrEmpty], nil))
461455 let usdnRewards = asString(invoke(rpdContract, "unclaimedRewardsREADONLY", [userAddressStrOrEmpty], nil))
462456 $Tuple2(nil, makeString(["%s%s%s", asString(rewardsData[0]), asString(rewardsData[1]), usdnRewards], SEP))
463457 }
464458
465459
466460
467461 @Callable(i)
468462 func mergeNsbtREADONLY (userAddressMandatory,newAmount) = {
469463 let nsbtData = asAnyList(invoke(nsbtStakingContract, "nsbtStakingSYSREADONLY", [userAddressMandatory, newAmount], nil))
470464 let amount0 = asInt(nsbtData[0])
471465 let startHeight = if ((0 >= amount0))
472466 then -1
473467 else asInt(nsbtData[2])
474468 let startTimestamp = toTimestamp(startHeight)
475469 let startHeightNew = if ((0 >= newAmount))
476470 then startHeight
477471 else if ((0 >= amount0))
478472 then height
479473 else {
480474 let halfLife = getIntOrFail(nsbtStakingContract, keyHalfLife())
481475 asInt(invoke(mathContract, "mergeStakesREADONLY", [amount0, startHeight, newAmount, height, halfLife], nil))
482476 }
483477 let startTimestampNew = toTimestamp(startHeightNew)
484478 $Tuple2(nil, makeString(["%d%d%d%d", toString(startHeight), toString(startTimestamp), toString(startHeightNew), toString(startTimestampNew)], SEP))
485479 }
486480
487481
488482
489483 @Callable(i)
490484 func swapLimitCalculatorREADONLY (userAddressStrOpt,limitWanted,assetIdStr) = {
491485 let gNsbtCurrent = if ((userAddressStrOpt == ""))
492486 then 0
493487 else asInt(asSwapParamsSTRUCT(invoke(neutrinoContract, "swapParamsByUserSYSREADONLY", [userAddressStrOpt, 0], nil))._4)
494488 let limitWantedUsdn = if ((assetIdStr == "WAVES"))
495489 then convertWavesToNeutrino(limitWanted, getIntegerValue(controlContract, keyPrice()))
496490 else limitWanted
497491 let gNsbtNeeded = asInt(invoke(this, "reverseSwapLimitREADONLY", [limitWantedUsdn, (assetIdStr == "WAVES")], nil))
498492 let gNsbtDelta = (gNsbtNeeded - gNsbtCurrent)
499493 $Tuple2(nil, makeString(["%s%s", toString(gNsbtCurrent), toString(gNsbtDelta)], SEP))
500494 }
501495
502496
503497
504498 @Callable(i)
505499 func swapInfoREADONLY (userAddressStrOrEmpty,amount,assetIdStr) = {
506500 let neutrinoMetrics = asAnyList(invoke(mathContract, "calcNeutinoMetricsREADONLY", nil, nil))
507501 let price = asInt(neutrinoMetrics[nMetricIdxPrice])
508502 let swapParamsTuple = asSwapParamsSTRUCT(invoke(neutrinoContract, "swapParamsByUserSYSREADONLY", [userAddressStrOrEmpty, 0], nil))
509503 let blcks2LmtReset = swapParamsTuple._3
510504 let limitMaxWaves = swapParamsTuple._6
511505 let limitMaxUsdn = swapParamsTuple._7
512506 let assetId = fromBase58String(assetIdStr)
513- let swapType = if ((assetId == WAVESID))
514- then "waves"
507+ let basketAssets = valueOrElse(getString(neutrinoContract, basketAssetsKey()), "WAVES")
508+ let swapType = if (contains(basketAssets, assetIdStr))
509+ then "outNeutrino"
515510 else if ((assetId == neutrinoAssetId))
516- then "neutrino"
511+ then "outMulti"
517512 else throw(("Can't swap assetId=" + assetIdStr))
518- let withdrawTuple = asWithdrawResultSTRUCT(invoke(neutrinoContract, "calcWithdrawResultSYSREADONLY", [swapType, amount, price], nil))
513+ let withdrawTuple = asWithdrawResultSTRUCT(invoke(neutrinoContract, "calcWithdrawResultSYSREADONLY", [swapType, amount, price, assetIdStr], nil))
519514 let outNetAmount = withdrawTuple._1
520515 let outAssetId = withdrawTuple._2
521516 let outSurfAmt = withdrawTuple._3
522517 let inAmtToSurfPart = withdrawTuple._4
523518 let unleaseAmt = withdrawTuple._5
524519 let outFeeAmount = withdrawTuple._6
525520 let outAmtGross = withdrawTuple._7
526521 let withdrawPrice = withdrawTuple._8
527522 $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d", toString(outNetAmount), toString(outSurfAmt), toString(outFeeAmount), toString(withdrawPrice), toString(blcks2LmtReset), toString(limitMaxWaves), toString(limitMaxUsdn), toString(inAmtToSurfPart)], SEP))
528523 }
529524
530525
531526
532527 @Callable(i)
533528 func swapInfoV2READONLY (userAddressStrOrEmpty,amount,assetIdStr) = {
534529 let neutrinoMetrics = asAnyList(invoke(mathContract, "calcNeutinoMetricsREADONLY", nil, nil))
535530 let price = asInt(neutrinoMetrics[nMetricIdxPrice])
536531 let swapParamsTuple = asSwapParamsSTRUCT(invoke(neutrinoContract, "swapParamsByUserSYSREADONLY", [userAddressStrOrEmpty, 0], nil))
537532 let blcks2LmtReset = swapParamsTuple._3
538533 let limitMaxWaves = swapParamsTuple._6
539534 let limitMaxUsdn = swapParamsTuple._7
540535 let assetId = fromBase58String(assetIdStr)
541- let swapType = if ((assetId == WAVESID))
542- then "waves"
536+ let basketAssets = valueOrElse(getString(neutrinoContract, basketAssetsKey()), "WAVES")
537+ let swapType = if (contains(basketAssets, assetIdStr))
538+ then "outNeutrino"
543539 else if ((assetId == neutrinoAssetId))
544- then "neutrino"
540+ then "outMulti"
545541 else throw(("Can't swap assetId=" + assetIdStr))
546- let withdrawTuple = asWithdrawResultSTRUCT(invoke(neutrinoContract, "calcWithdrawResultSYSREADONLY", [swapType, amount, price], nil))
542+ let withdrawTuple = asWithdrawResultSTRUCT(invoke(neutrinoContract, "calcWithdrawResultSYSREADONLY", [swapType, amount, price, assetIdStr], nil))
547543 let outNetAmount = withdrawTuple._1
548544 let outAssetId = withdrawTuple._2
549545 let outSurfAmt = withdrawTuple._3
550546 let inAmtToSurfPart = withdrawTuple._4
551547 let unleaseAmt = withdrawTuple._5
552548 let outFeeAmount = withdrawTuple._6
553549 let outAmtGross = withdrawTuple._7
554550 let withdrawPrice = withdrawTuple._8
555- let basketStub = "WAVES:6500000:15590257:78343:318181_EMAMLxDnv3xiz8RXg8Btj33jcEw3wLczL3JKYYmuubpc:318700:35980614:179903:170454_52nvaZGa7ahqa21ER2PAMBVjMi7wC2nWYCNmLvj8QjHx:585395:19588520:97942:170454_9JXnfooQYnahr5L1dH7YksMmWPE8TZramFycXyYxv6Ef:49418611:232038:1160:170454_AMFteLfPzPhTsFc3NfvHG7fSRUnsp3tJXPH88G1PCisT:461400:248526696:1242633:170454"
556- $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d%s", toString(outNetAmount), toString(outSurfAmt), toString(outFeeAmount), toString(withdrawPrice), toString(blcks2LmtReset), toString(limitMaxWaves), toString(limitMaxUsdn), toString(inAmtToSurfPart), basketStub], SEP))
551+ let withdrawBasket = withdrawTuple._9
552+ $Tuple2(nil, makeString(["%d%d%d%d%d%d%d%d%s", toString(outNetAmount), toString(outSurfAmt), toString(outFeeAmount), toString(withdrawPrice), toString(blcks2LmtReset), toString(limitMaxWaves), toString(limitMaxUsdn), toString(inAmtToSurfPart), withdrawBasket], SEP))
557553 }
558554
559555
560556
561557 @Callable(i)
562558 func usdnStakingAprREADONLY (days) = {
563559 let tmpDays = 1
564560 let neutrinoMetrics = asAnyList(invoke(mathContract, "calcNeutinoMetricsREADONLY", nil, nil))
565561 let currentPrice = asInt(neutrinoMetrics[nMetricIdxPrice])
566562 let wavesIncome = (0 * MULT8)
567563 let incomeForPeriod = fraction(wavesIncome, currentPrice, MULT8)
568564 let apr = calcApr(rpdContract, tmpDays, incomeForPeriod, MULT6)
569565 $Tuple2(nil, ("%d__" + toString(apr)))
570566 }
571567
572568
573569
574570 @Callable(i)
575571 func surfStakingAprREADONLY (days) = {
576572 let tmpDays = 3
577573 let incomeForPeriod = calcUsdnIncomeForPeriod(surfStakingContract, tmpDays)
578574 let surfPriceToUsdnX6 = 86400
579575 let apr = calcApr(surfStakingContract, tmpDays, incomeForPeriod, surfPriceToUsdnX6)
580576 $Tuple2(nil, ("%d__" + toString(apr)))
581577 }
582578
583579
584580
585581 @Callable(i)
586582 func surfStakingAprV2READONLY (days,surfUsdnPriceX6) = {
587583 let tmpDays = 3
588584 let incomeForPeriod = calcUsdnIncomeForPeriod(surfStakingContract, tmpDays)
589585 let apr = calcApr(surfStakingContract, tmpDays, incomeForPeriod, surfUsdnPriceX6)
590586 $Tuple2(nil, ("%d__" + toString(apr)))
591587 }
592588
593589
594590
595591 @Callable(i)
596592 func nsbtStakingAprREADONLY (days) = {
597593 let tmpDays = 3
598594 let nsbtPriceToUsdnX6 = 8000000
599595 let incomeForPeriod = calcUsdnIncomeForPeriod(nsbtStakingContract, tmpDays)
600596 let apr = calcApr(nsbtStakingContract, tmpDays, incomeForPeriod, nsbtPriceToUsdnX6)
601597 $Tuple2(nil, ("%d__" + toString(apr)))
602598 }
603599
604600
605601
606602 @Callable(i)
607603 func nsbtStakingAprV2READONLY (days,nsbtUsdnPriceX6) = {
608604 let tmpDays = 3
609605 let incomeForPeriod = calcUsdnIncomeForPeriod(nsbtStakingContract, tmpDays)
610606 let apr = calcApr(nsbtStakingContract, tmpDays, incomeForPeriod, nsbtUsdnPriceX6)
611607 $Tuple2(nil, ("%d__" + toString(apr)))
612608 }
613609
614610

github/deemru/w8io/026f985 
84.09 ms