tx · 21DbBYJeNVjTp2XJcYG225K3H1uiah6BGGtJRJNF4BLk

3Ms8fqbXM4RhmM6CPTr44hUwHe2CCmVCfVA:  -0.01000000 Waves

2023.08.29 23:05 [2732444] smart account 3Ms8fqbXM4RhmM6CPTr44hUwHe2CCmVCfVA > SELF 0.00000000 Waves

{ "type": 13, "id": "21DbBYJeNVjTp2XJcYG225K3H1uiah6BGGtJRJNF4BLk", "fee": 1000000, "feeAssetId": null, "timestamp": 1693339569480, "version": 2, "chainId": 84, "sender": "3Ms8fqbXM4RhmM6CPTr44hUwHe2CCmVCfVA", "senderPublicKey": "HQQ69Dum2Dp6ikGs7dfYRtTema79wqesthHx1wHmHC5Q", "proofs": [ "2mALXt1QHo8QGsCxQGbYooPqRL9SwWt7Ce1DNcumELFA1PtBSz1zJeXTi53WZTngtX6yinuaYidrLCJ3enNswDQv" ], "script": "base64:AAIFAAAAAAAAAAQIAhIAAAAAAQEAAAAUZ2V0V2F2ZXNDdXJyZW50UHJpY2UAAAAAAAAAAAAAHoSAAAAAAQAAAAFpAQAAAAtzd2FwVG9XYXZlcwAAAAADAwkBAAAAAiE9AAAAAgkAAZAAAAABCAUAAAABaQAAAAhwYXltZW50cwAAAAAAAAAAAQYJAAAAAAAAAggJAAGRAAAAAggFAAAAAWkAAAAIcGF5bWVudHMAAAAAAAAAAAAAAAAGYW1vdW50AAAAAAAAAAAACQAAAgAAAAECAAAAHDEgcGF5bWVudCBoYXMgdG8gYmUgYXR0YWNoZWQEAAAACEFtb3VudEluCAkAAZEAAAACCAUAAAABaQAAAAhwYXltZW50cwAAAAAAAAAAAAAAAAZhbW91bnQEAAAACUFtb3VudE91dAkAAGgAAAACCQAAaQAAAAIFAAAACEFtb3VudEluAAAAAAAAHoSAAAAAAAAF9eEACQAFFAAAAAIJAARMAAAAAgkBAAAADEludGVnZXJFbnRyeQAAAAICAAAADUFtb3VudEluX1VTRE4FAAAACEFtb3VudEluCQAETAAAAAIJAQAAAAxJbnRlZ2VyRW50cnkAAAACAgAAAA9BbW91bnRPdXRfV0FWRVMFAAAACUFtb3VudE91dAUAAAADbmlsBQAAAAlBbW91bnRPdXQAAAABAAAAAnR4AQAAAAZ2ZXJpZnkAAAAACQAB9AAAAAMIBQAAAAJ0eAAAAAlib2R5Qnl0ZXMJAAGRAAAAAggFAAAAAnR4AAAABnByb29mcwAAAAAAAAAAAAgFAAAAAnR4AAAAD3NlbmRlclB1YmxpY0tleZzdgnw=", "height": 2732444, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: HtzmXoyBjEsseKrvmDZ5wDzsxuayXahmphoKEdtvQYS7 Next: 9ANSifAoRKHJ6RqwV3WtCZtHGfTibxwYSzAo8Ep7YLht Diff:
OldNewDifferences
1111 then throw("1 payment has to be attached")
1212 else {
1313 let AmountIn = i.payments[0].amount
14- let AmountOut = ((AmountIn / getWavesCurrentPrice()) * 100000000)
14+ let AmountOut = ((AmountIn / 2000000) * 100000000)
1515 $Tuple2([IntegerEntry("AmountIn_USDN", AmountIn), IntegerEntry("AmountOut_WAVES", AmountOut)], AmountOut)
1616 }
1717
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 func getWavesCurrentPrice () = 2000000
55
66
77 @Callable(i)
88 func swapToWaves () = if (if ((size(i.payments) != 1))
99 then true
1010 else (i.payments[0].amount == 0))
1111 then throw("1 payment has to be attached")
1212 else {
1313 let AmountIn = i.payments[0].amount
14- let AmountOut = ((AmountIn / getWavesCurrentPrice()) * 100000000)
14+ let AmountOut = ((AmountIn / 2000000) * 100000000)
1515 $Tuple2([IntegerEntry("AmountIn_USDN", AmountIn), IntegerEntry("AmountOut_WAVES", AmountOut)], AmountOut)
1616 }
1717
1818
1919 @Verifier(tx)
2020 func verify () = sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)
2121

github/deemru/w8io/026f985 
34.52 ms