tx · 5oyBF9QvfL9Qmmas5YCoo2gNEEzYEazRzZGVXkwunZeS

3NBbFNBed9tcU5AmsJAuExWvgJyNmJxqjWq:  -0.01000000 Waves

2023.06.23 01:29 [2634448] smart account 3NBbFNBed9tcU5AmsJAuExWvgJyNmJxqjWq > SELF 0.00000000 Waves

{ "type": 13, "id": "5oyBF9QvfL9Qmmas5YCoo2gNEEzYEazRzZGVXkwunZeS", "fee": 1000000, "feeAssetId": null, "timestamp": 1687472993661, "version": 2, "chainId": 84, "sender": "3NBbFNBed9tcU5AmsJAuExWvgJyNmJxqjWq", "senderPublicKey": "ERewvWFUFQfR1eCnipNAv9n7SdQhof2ESP6PGVjTueLd", "proofs": [ "2UfKmcYx4RzbBcAHCvxsrmfPpAYNL5R3BiEaJaK6GZb62Jr8TFTcdHX9ZC6YfkgJWqSyYGKCsc6iUsjCQ9esuCAQ" ], "script": "base64:BgIbCAISAwoBARIECgIIARIECgIIARIAEgQKAggBAwADYXJyCQDMCAIAAQkAzAgCAAIJAMwIAgADCQDMCAIABAkAzAgCAAUFA25pbAAEYXJyMgkAzAgCAAEJAMwIAgACBQNuaWwBA3N1bQIBYQFiCQD8BwQJARFAZXh0ck5hdGl2ZSgxMDYyKQECIzNOM0RuVmZmblV5WnR6Mk1SYms1VTdnaU4xMTJXZW1wTU5kAgZib3Jyb3cJAMwIAgIsMjVGRXFFalJrcUs2eUNraVQ3THo2U0FZejdnVUZDdHhmQ0NobnJWRkQ1QVQJAMwIAgDAhD0FA25pbAUDbmlsBQFpAQZib3Jyb3cBC2Fzc2V0QW1vdW50BAdhZGRyZXNzCQClCAEIBQFpBmNhbGxlcgQDcmVzCQD8BwQJARFAZXh0ck5hdGl2ZSgxMDYyKQECIzNOM0RuVmZmblV5WnR6Mk1SYms1VTdnaU4xMTJXZW1wTU5kAgZib3Jyb3cJAMwIAgIsMjVGRXFFalJrcUs2eUNraVQ3THo2U0FZejdnVUZDdHhmQ0NobnJWRkQ1QVQJAMwIAgULYXNzZXR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jNEblZmZm5VeVp0ejJNUmJrNVU3Z2lOMTEyV2VtcE1OZAIId2l0aGRyYXcJAMwIAgUKYXNzZXRJZFN0cgkAzAgCBQthc3NldEFtb3VudAUDbmlsBQNuaWwDCQAAAgUDcmVzBQNyZXMJAMwIAgkBDEludGVnZXJFbnRyeQIJAKwCAgkArAICBQdhZGRyZXNzAgpfd2l0aGRyZXdfBQphc3NldElkU3RyBQthc3NldEFtb3VudAUDbmlsCQACAQIkU3RyaWN0IHZhbHVlIGlzIG5vdCBlcXVhbCB0byBpdHNlbGYuAQJ0eAEGdmVyaWZ5AAkA9AMDCAUCdHgJYm9keUJ5dGVzCQCRAwIIBQJ0eAZwcm9vZnMAAAgFAnR4D3NlbmRlclB1YmxpY0tleXDwupw=", "height": 2634448, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: ALL9tGSZ92CfYMp8KVuDP6VVF685EKz89sdoEqJAWS5 Next: 5xZxCaFtXQbtTv8XGgcysaQfzGjQ5BiNP5DK97dG2vDS Diff:
OldNewDifferences
99
1010
1111 @Callable(i)
12-func borrow (assetIdStr,assetAmount) = {
12+func borrow (assetAmount) = {
1313 let address = toString(i.caller)
14- let res = invoke(addressFromStringValue("3N3DnVffnUyZtz2MRbk5U7giN112WempMNd"), "borrow", [assetIdStr, assetAmount], nil)
14+ let res = invoke(addressFromStringValue("3N3DnVffnUyZtz2MRbk5U7giN112WempMNd"), "borrow", ["25FEqEjRkqK6yCkiT7Lz6SAYz7gUFCtxfCChnrVFD5AT", assetAmount], nil)
1515 if ((res == res))
16- then [ScriptTransfer(i.caller, assetAmount, base58'25FEqEjRkqK6yCkiT7Lz6SAYz7gUFCtxfCChnrVFD5AT'), IntegerEntry(((address + "_borrowed_") + assetIdStr), assetAmount)]
16+ then [ScriptTransfer(i.caller, assetAmount, base58'25FEqEjRkqK6yCkiT7Lz6SAYz7gUFCtxfCChnrVFD5AT'), IntegerEntry(((address + "_borrowed_") + "25FEqEjRkqK6yCkiT7Lz6SAYz7gUFCtxfCChnrVFD5AT"), assetAmount)]
1717 else throw("Strict value is not equal to itself.")
1818 }
1919
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let arr = [1, 2, 3, 4, 5]
55
66 let arr2 = [1, 2]
77
88 func sum (a,b) = invoke(addressFromStringValue("3N3DnVffnUyZtz2MRbk5U7giN112WempMNd"), "borrow", ["25FEqEjRkqK6yCkiT7Lz6SAYz7gUFCtxfCChnrVFD5AT", 1000000], nil)
99
1010
1111 @Callable(i)
12-func borrow (assetIdStr,assetAmount) = {
12+func borrow (assetAmount) = {
1313 let address = toString(i.caller)
14- let res = invoke(addressFromStringValue("3N3DnVffnUyZtz2MRbk5U7giN112WempMNd"), "borrow", [assetIdStr, assetAmount], nil)
14+ let res = invoke(addressFromStringValue("3N3DnVffnUyZtz2MRbk5U7giN112WempMNd"), "borrow", ["25FEqEjRkqK6yCkiT7Lz6SAYz7gUFCtxfCChnrVFD5AT", assetAmount], nil)
1515 if ((res == res))
16- then [ScriptTransfer(i.caller, assetAmount, base58'25FEqEjRkqK6yCkiT7Lz6SAYz7gUFCtxfCChnrVFD5AT'), IntegerEntry(((address + "_borrowed_") + assetIdStr), assetAmount)]
16+ then [ScriptTransfer(i.caller, assetAmount, base58'25FEqEjRkqK6yCkiT7Lz6SAYz7gUFCtxfCChnrVFD5AT'), IntegerEntry(((address + "_borrowed_") + "25FEqEjRkqK6yCkiT7Lz6SAYz7gUFCtxfCChnrVFD5AT"), assetAmount)]
1717 else throw("Strict value is not equal to itself.")
1818 }
1919
2020
2121
2222 @Callable(i)
2323 func borrow2 (assetIdStr,assetAmount) = {
2424 let address = toString(i.caller)
2525 func repeatFunc (a,b) = invoke(addressFromStringValue("3N3DnVffnUyZtz2MRbk5U7giN112WempMNd"), "borrow", [assetIdStr, assetAmount], nil)
2626
2727 let res = {
2828 let $l = arr2
2929 let $s = size($l)
3030 let $acc0 = 0
3131 func $f0_1 ($a,$i) = if (($i >= $s))
3232 then $a
3333 else repeatFunc($a, $l[$i])
3434
3535 func $f0_2 ($a,$i) = if (($i >= $s))
3636 then $a
3737 else throw("List size exceeds 2")
3838
3939 $f0_2($f0_1($f0_1($acc0, 0), 1), 2)
4040 }
4141 if ((res == res))
4242 then [IntegerEntry(((address + "_borrowed_") + assetIdStr), assetAmount)]
4343 else throw("Strict value is not equal to itself.")
4444 }
4545
4646
4747
4848 @Callable(i)
4949 func borrow5 (assetIdStr,assetAmount) = {
5050 let address = toString(i.caller)
5151 let res = {
5252 let $l = arr
5353 let $s = size($l)
5454 let $acc0 = 0
5555 func $f0_1 ($a,$i) = if (($i >= $s))
5656 then $a
5757 else sum($a, $l[$i])
5858
5959 func $f0_2 ($a,$i) = if (($i >= $s))
6060 then $a
6161 else throw("List size exceeds 5")
6262
6363 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5)
6464 }
6565 if ((res == res))
6666 then [IntegerEntry(((address + "_borrowed_") + assetIdStr), assetAmount)]
6767 else throw("Strict value is not equal to itself.")
6868 }
6969
7070
7171
7272 @Callable(i)
7373 func deposit () = {
7474 let address = toString(i.caller)
7575 let res = invoke(addressFromStringValue("3N3DnVffnUyZtz2MRbk5U7giN112WempMNd"), "supply", nil, [AttachedPayment(unit, 1000000)])
7676 if ((res == res))
7777 then [IntegerEntry((address + "supply_waves"), 1000000)]
7878 else throw("Strict value is not equal to itself.")
7979 }
8080
8181
8282
8383 @Callable(i)
8484 func withdraw (assetIdStr,assetAmount) = {
8585 let address = toString(i.caller)
8686 let res = invoke(addressFromStringValue("3N3DnVffnUyZtz2MRbk5U7giN112WempMNd"), "withdraw", [assetIdStr, assetAmount], nil)
8787 if ((res == res))
8888 then [IntegerEntry(((address + "_withdrew_") + assetIdStr), assetAmount)]
8989 else throw("Strict value is not equal to itself.")
9090 }
9191
9292
9393 @Verifier(tx)
9494 func verify () = sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)
9595

github/deemru/w8io/026f985 
42.23 ms