tx · J4Jf4gZR4uP67JtLGLaEAEAsskbowD5dR5FdhPdEGfXm

3N9R7u449Z1b76QpJp9u3gzPjMYQYnp3V7r:  -0.04000000 Waves

2022.01.15 04:44 [1879427] smart account 3N9R7u449Z1b76QpJp9u3gzPjMYQYnp3V7r > SELF 0.00000000 Waves

{ "type": 13, "id": "J4Jf4gZR4uP67JtLGLaEAEAsskbowD5dR5FdhPdEGfXm", "fee": 4000000, "feeAssetId": null, "timestamp": 1642211092099, "version": 2, "chainId": 84, "sender": "3N9R7u449Z1b76QpJp9u3gzPjMYQYnp3V7r", "senderPublicKey": "GUHw1jkstNWTs9SX1KM3pMtq9HXjupvxiTd1urNhNoyY", "proofs": [ "5pZwupw4DYLsWP2xcNrBXTWnbmEgfz72CYyR2v7bbfRMUi7XcduYF8GobPsRotvy7VZhi8x1PTsVgzZNTv7wHVWd" ], "script": "base64:AAIFAAAAAAAAAV4IAhIFCgMICAgSAwoBCBoQCgFhEgtkYXBwQWRkcmVzcxoXCgFiEhJob2xkaW5nc0FkZHJlc3NTdHIaFgoBYxIRaG9sZGluZ3NQdWJsaWNLZXkaFAoBZBIPaG9sZGluZ3NBZGRyZXNzGhQKAWUSD3RyYW5zZmVyQ29zdFBjdBoGCgFmEgFpGgwKAWcSB293bmVySWQaDAoBaBIHYXNzZXRJZBoLCgFpEgZhbW91bnQaDAoBahIHJG1hdGNoMBoGCgFrEgF4GhIKAWwSDXBheW1lbnRBbW91bnQaDwoBbRIKZEFwcFVwZGF0ZRoMCgFuEgdkYXRhS2V5GgYKAW8SAWEaDQoBcBIIdHJhbnNmZXIaHQoBcRIYYW1vdW50VG9SZW1haW5JbkhvbGRpbmdzGhwKAXISF2Ftb3VudFRvVHJhbnNmZXJUb093bmVyGhEKAXMSDG93bmVyQWRkcmVzcwAAAAUAAAAAAWECAAAAIzNONHZxVVhXdzh0ZjIzTERXRGJTRXBKWkg2ZGVudDNFVEZ1AAAAAAFiAgAAACMzTjlSN3U0NDlaMWI3NlFwSnA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gAAAAIFAAAAAXAJAARMAAAAAgkBAAAADlNjcmlwdFRyYW5zZmVyAAAAAwUAAAABcwUAAAABcgUAAAAEdW5pdAUAAAADbmlsBQAAAAFwCQAAAgAAAAECAAAAJFN0cmljdCB2YWx1ZSBpcyBub3QgZXF1YWwgdG8gaXRzZWxmLgAAAACTFj+e", "height": 1879427, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 4QzDetcMM3TWoDSczY5Foq3ZdoJNuK1yYf6jWVNFyw2z Next: 61zba1DFGcCSqhAZPKUUZRjm8wwBogJmdm1Txj9svZL2 Diff:
OldNewDifferences
7575 }
7676
7777
78-@Verifier(t)
79-func u () = sigVerify(t.bodyBytes, t.proofs[0], t.senderPublicKey)
80-
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let a = "3N4vqUXWw8tf23LDWDbSEpJZH6dent3ETFu"
55
66 let b = "3N9R7u449Z1b76QpJp9u3gzPjMYQYnp3V7r"
77
88 let c = base58'GUHw1jkstNWTs9SX1KM3pMtq9HXjupvxiTd1urNhNoyY'
99
1010 let d = Address(fromBase58String(b))
1111
1212 let e = 25
1313
1414 @Callable(f)
1515 func addOwnerAndAmount (g,h,i) = [StringEntry((("sale_" + h) + "_originalOwner"), g), StringEntry((("sale_" + h) + "_amount"), i)]
1616
1717
1818
1919 @Callable(f)
2020 func buyFromHoldings (h) = {
2121 let g = {
2222 let j = getString(this, (("sale_" + h) + "_originalOwner"))
2323 if ($isInstanceOf(j, "Unit"))
2424 then "unset"
2525 else if ($isInstanceOf(j, "String"))
2626 then {
2727 let k = j
2828 k
2929 }
3030 else throw("Match error")
3131 }
3232 let l = valueOrElse(f.payments[0].amount, 0)
3333 let i = {
3434 let j = getString(this, (("sale_" + h) + "_amount"))
3535 if ($isInstanceOf(j, "Unit"))
3636 then 0
3737 else if ($isInstanceOf(j, "String"))
3838 then {
3939 let k = j
4040 (valueOrElse(parseInt(k), 0) * 100000000)
4141 }
4242 else throw("Match error")
4343 }
4444 if ((g == "unset"))
4545 then throw("Original owner not found ")
4646 else if (if ((i == 0))
4747 then true
4848 else (i > l))
4949 then throw(((("Payment and amount do not match. This assets costs " + toString(i)) + "but you sent ") + toString(l)))
5050 else {
5151 let m = invoke(Address(fromBase58String(a)), "finalizeSale", [h, g], [AttachedPayment(unit, 0)])
5252 if ((m == m))
5353 then {
5454 let n = {
5555 let j = m
5656 if ($isInstanceOf(j, "String"))
5757 then {
5858 let o = j
5959 o
6060 }
6161 else throw("Unexpected result from finalizing purcahse")
6262 }
6363 let p = [ScriptTransfer(f.caller, 1, fromBase58String(h))]
6464 if ((g != b))
6565 then {
6666 let q = (l * (e / 1000))
6767 let r = (l - q)
6868 let s = Address(fromBase58String(g))
6969 (p ++ [ScriptTransfer(s, r, unit)])
7070 }
7171 else p
7272 }
7373 else throw("Strict value is not equal to itself.")
7474 }
7575 }
7676
7777
78-@Verifier(t)
79-func u () = sigVerify(t.bodyBytes, t.proofs[0], t.senderPublicKey)
80-

github/deemru/w8io/169f3d6 
31.73 ms