tx · EeFnu38kkvx7vDRVedP9mPM8Y9X3Xqj5qFi5YmNDqt1r
3NCukxG6cc7pqKoEwTZsr1CRrHMHfvGM7ok: -0.01000000 Waves
2023.11.16 09:17 [2845549] smart account 3NCukxG6cc7pqKoEwTZsr1CRrHMHfvGM7ok > SELF 0.00000000 Waves
{
"type": 13,
"id": "EeFnu38kkvx7vDRVedP9mPM8Y9X3Xqj5qFi5YmNDqt1r",
"fee": 1000000,
"feeAssetId": null,
"timestamp": 1700115443577,
"version": 2,
"chainId": 84,
"sender": "3NCukxG6cc7pqKoEwTZsr1CRrHMHfvGM7ok",
"senderPublicKey": "Ba1WX1ZypN1wFcFgVrXgam9NFbnD3XA1P62kc37wpxzA",
"proofs": [
"4En237p1fRXYtCqgnSubdgnSYp1LkL8KwBV86RR85qsvDgrmFV77asvLPRwEQnNdezSve5qorjh5kMZqkSkxCqzJ"
],
"script": "base64:BgImCAISABIDCgEIEgQKAggBEgQKAggEEgMKAQgSAwoBARIDCgEIEgADABR3eF9zdGFrZWRfYW1vdW50X2tleQIQd3hfc3Rha2VkX2Ftb3VudAAQd3hfbW9ja19hc3NldF9pZAEgem0CwypAHTesH/u7a8MttNFWRQzQ3dvWhSiS4BwdmuMBCWFzUGF5bWVudAEBdgQHJG1hdGNoMAUBdgMJAAECBQckbWF0Y2gwAg9BdHRhY2hlZFBheW1lbnQEAXAFByRtYXRjaDAFAXAJAAIBAiFmYWlsIHRvIGNhc3QgaW50byBBdHRhY2hlZFBheW1lbnQIAWkBF3VzZXJNYXhEdXJhdGlvblJFQURPTkxZAAkAlAoCBQNuaWwJAJQKAgIHc3Rha2VXWAD4CgFpARh1c2VyTWF4RHVyYXRpb25SRUFET05MWTIBB2FkZHJlc3MJAJQKAgUDbmlsAJADAWkBGHVzZXJNYXhEdXJhdGlvblJFQURPTkxZMwIHYWRkcmVzcwV2YWx1ZQkAlAoCBQNuaWwCBUhlbGxvAWkBGHVzZXJNYXhEdXJhdGlvblJFQURPTkxZNAIHYWRkcmVzcwV2YWx1ZQkAlAoCBQNuaWwGAWkBGHVzZXJNYXhEdXJhdGlvblJFQURPTkxZNQEHYWRkcmVzcwkAlAoCBQNuaWwJAMwIAgABCQDMCAIAAgkAzAgCAgNhc2QFA25pbAFpAQdzdGFrZVdYAQlkdXJhY3Rpb24EB3BheW1lbnQJAQlhc1BheW1lbnQBCQCRAwIIBQFpCHBheW1lbnRzAAAEBmFtb3VudAgFB3BheW1lbnQGYW1vdW50BA1jdXJyZW50QW1vdW50CQELdmFsdWVPckVsc2UCCQCfCAEFFHd4X3N0YWtlZF9hbW91bnRfa2V5AAAJAMwIAgkBDEludGVnZXJFbnRyeQIFFHd4X3N0YWtlZF9hbW91bnRfa2V5CQBkAgUNY3VycmVudEFtb3VudAUGYW1vdW50BQNuaWwBaQEHY2xhaW1XWAEFdG9rZW4EE2N1cnJlbnRTdGFrZWRBbW91bnQJARFAZXh0ck5hdGl2ZSgxMDU1KQEFFHd4X3N0YWtlZF9hbW91bnRfa2V5BAxyZXdhcmRBbW91bnQJAGsDBRNjdXJyZW50U3Rha2VkQW1vdW50AOgHAJBOCQDMCAIJAQ5TY3JpcHRUcmFuc2ZlcgMIBQFpBmNhbGxlcgUMcmV3YXJkQW1vdW50BRB3eF9tb2NrX2Fzc2V0X2lkBQNuaWwBaQELY2xhaW1SZXdhcmQABBNjdXJyZW50U3Rha2VkQW1vdW50CQERQGV4dHJOYXRpdmUoMTA1NSkBBRR3eF9zdGFrZWRfYW1vdW50X2tleQQMcmV3YXJkQW1vdW50CQBrAwUTY3VycmVudFN0YWtlZEFtb3VudADoBwCQTgkAzAgCCQEOU2NyaXB0VHJhbnNmZXIDCAUBaQZjYWxsZXIFDHJld2FyZEFtb3VudAUQd3hfbW9ja19hc3NldF9pZAUDbmlsAJglDGU=",
"height": 2845549,
"applicationStatus": "succeeded",
"spentComplexity": 0
}
View: original | compacted
Prev: 3meSTSRWJodaxZYQTh8AE5yU5x7DhhiQqgmJuGswLxn8
Next: 6BP8qpMGzBx7zCKEZJfG2dRiRzXGZk7o7FnqwQP3SsNw
Diff:
Old | New | | Differences |
---|
22 | 22 | | |
---|
23 | 23 | | |
---|
24 | 24 | | @Callable(g) |
---|
25 | | - | func stakeWX (h) = { |
---|
26 | | - | let i = c(g.payments[0]) |
---|
27 | | - | let j = i.amount |
---|
28 | | - | let k = valueOrElse(getInteger(a), 0) |
---|
29 | | - | [IntegerEntry(a, (k + j))] |
---|
| 25 | + | func userMaxDurationREADONLY2 (h) = $Tuple2(nil, 400) |
---|
| 26 | + | |
---|
| 27 | + | |
---|
| 28 | + | |
---|
| 29 | + | @Callable(g) |
---|
| 30 | + | func userMaxDurationREADONLY3 (h,i) = $Tuple2(nil, "Hello") |
---|
| 31 | + | |
---|
| 32 | + | |
---|
| 33 | + | |
---|
| 34 | + | @Callable(g) |
---|
| 35 | + | func userMaxDurationREADONLY4 (h,i) = $Tuple2(nil, true) |
---|
| 36 | + | |
---|
| 37 | + | |
---|
| 38 | + | |
---|
| 39 | + | @Callable(g) |
---|
| 40 | + | func userMaxDurationREADONLY5 (h) = $Tuple2(nil, [1, 2, "asd"]) |
---|
| 41 | + | |
---|
| 42 | + | |
---|
| 43 | + | |
---|
| 44 | + | @Callable(g) |
---|
| 45 | + | func stakeWX (j) = { |
---|
| 46 | + | let k = c(g.payments[0]) |
---|
| 47 | + | let l = k.amount |
---|
| 48 | + | let m = valueOrElse(getInteger(a), 0) |
---|
| 49 | + | [IntegerEntry(a, (m + l))] |
---|
30 | 50 | | } |
---|
31 | 51 | | |
---|
32 | 52 | | |
---|
33 | 53 | | |
---|
34 | 54 | | @Callable(g) |
---|
35 | | - | func claimWX (l) = { |
---|
36 | | - | let m = getIntegerValue(a) |
---|
37 | | - | let n = fraction(m, 1000, 10000) |
---|
38 | | - | [ScriptTransfer(g.caller, n, b)] |
---|
| 55 | + | func claimWX (n) = { |
---|
| 56 | + | let o = getIntegerValue(a) |
---|
| 57 | + | let p = fraction(o, 1000, 10000) |
---|
| 58 | + | [ScriptTransfer(g.caller, p, b)] |
---|
39 | 59 | | } |
---|
40 | 60 | | |
---|
41 | 61 | | |
---|
42 | 62 | | |
---|
43 | 63 | | @Callable(g) |
---|
44 | 64 | | func claimReward () = { |
---|
45 | | - | let m = getIntegerValue(a) |
---|
46 | | - | let n = fraction(m, 1000, 10000) |
---|
47 | | - | [ScriptTransfer(g.caller, n, b)] |
---|
| 65 | + | let o = getIntegerValue(a) |
---|
| 66 | + | let p = fraction(o, 1000, 10000) |
---|
| 67 | + | [ScriptTransfer(g.caller, p, b)] |
---|
48 | 68 | | } |
---|
49 | 69 | | |
---|
50 | 70 | | |
---|
Full:
Old | New | | Differences |
---|
1 | 1 | | {-# STDLIB_VERSION 6 #-} |
---|
2 | 2 | | {-# SCRIPT_TYPE ACCOUNT #-} |
---|
3 | 3 | | {-# CONTENT_TYPE DAPP #-} |
---|
4 | 4 | | let a = "wx_staked_amount" |
---|
5 | 5 | | |
---|
6 | 6 | | let b = base58'9Eu9de5GPPgLzY16bevCaxF4rFr4jA9wqyTfqcjksU82' |
---|
7 | 7 | | |
---|
8 | 8 | | func c (d) = { |
---|
9 | 9 | | let e = d |
---|
10 | 10 | | if ($isInstanceOf(e, "AttachedPayment")) |
---|
11 | 11 | | then { |
---|
12 | 12 | | let f = e |
---|
13 | 13 | | f |
---|
14 | 14 | | } |
---|
15 | 15 | | else throw("fail to cast into AttachedPayment") |
---|
16 | 16 | | } |
---|
17 | 17 | | |
---|
18 | 18 | | |
---|
19 | 19 | | @Callable(g) |
---|
20 | 20 | | func userMaxDurationREADONLY () = $Tuple2(nil, $Tuple2("stakeWX", 1400)) |
---|
21 | 21 | | |
---|
22 | 22 | | |
---|
23 | 23 | | |
---|
24 | 24 | | @Callable(g) |
---|
25 | | - | func stakeWX (h) = { |
---|
26 | | - | let i = c(g.payments[0]) |
---|
27 | | - | let j = i.amount |
---|
28 | | - | let k = valueOrElse(getInteger(a), 0) |
---|
29 | | - | [IntegerEntry(a, (k + j))] |
---|
| 25 | + | func userMaxDurationREADONLY2 (h) = $Tuple2(nil, 400) |
---|
| 26 | + | |
---|
| 27 | + | |
---|
| 28 | + | |
---|
| 29 | + | @Callable(g) |
---|
| 30 | + | func userMaxDurationREADONLY3 (h,i) = $Tuple2(nil, "Hello") |
---|
| 31 | + | |
---|
| 32 | + | |
---|
| 33 | + | |
---|
| 34 | + | @Callable(g) |
---|
| 35 | + | func userMaxDurationREADONLY4 (h,i) = $Tuple2(nil, true) |
---|
| 36 | + | |
---|
| 37 | + | |
---|
| 38 | + | |
---|
| 39 | + | @Callable(g) |
---|
| 40 | + | func userMaxDurationREADONLY5 (h) = $Tuple2(nil, [1, 2, "asd"]) |
---|
| 41 | + | |
---|
| 42 | + | |
---|
| 43 | + | |
---|
| 44 | + | @Callable(g) |
---|
| 45 | + | func stakeWX (j) = { |
---|
| 46 | + | let k = c(g.payments[0]) |
---|
| 47 | + | let l = k.amount |
---|
| 48 | + | let m = valueOrElse(getInteger(a), 0) |
---|
| 49 | + | [IntegerEntry(a, (m + l))] |
---|
30 | 50 | | } |
---|
31 | 51 | | |
---|
32 | 52 | | |
---|
33 | 53 | | |
---|
34 | 54 | | @Callable(g) |
---|
35 | | - | func claimWX (l) = { |
---|
36 | | - | let m = getIntegerValue(a) |
---|
37 | | - | let n = fraction(m, 1000, 10000) |
---|
38 | | - | [ScriptTransfer(g.caller, n, b)] |
---|
| 55 | + | func claimWX (n) = { |
---|
| 56 | + | let o = getIntegerValue(a) |
---|
| 57 | + | let p = fraction(o, 1000, 10000) |
---|
| 58 | + | [ScriptTransfer(g.caller, p, b)] |
---|
39 | 59 | | } |
---|
40 | 60 | | |
---|
41 | 61 | | |
---|
42 | 62 | | |
---|
43 | 63 | | @Callable(g) |
---|
44 | 64 | | func claimReward () = { |
---|
45 | | - | let m = getIntegerValue(a) |
---|
46 | | - | let n = fraction(m, 1000, 10000) |
---|
47 | | - | [ScriptTransfer(g.caller, n, b)] |
---|
| 65 | + | let o = getIntegerValue(a) |
---|
| 66 | + | let p = fraction(o, 1000, 10000) |
---|
| 67 | + | [ScriptTransfer(g.caller, p, b)] |
---|
48 | 68 | | } |
---|
49 | 69 | | |
---|
50 | 70 | | |
---|