tx · 6xctEujtSLfCNQALaaFT3bXnPmTUaqCzagwrCzX73QAf

3N51W4fn1aAAdypU26EGUwNZPr3zikN3vwh:  -0.01000000 Waves

2021.07.15 20:30 [1615019] smart account 3N51W4fn1aAAdypU26EGUwNZPr3zikN3vwh > SELF 0.00000000 Waves

{ "type": 13, "id": "6xctEujtSLfCNQALaaFT3bXnPmTUaqCzagwrCzX73QAf", "fee": 1000000, "feeAssetId": null, "timestamp": 1626370263255, "version": 2, "chainId": 84, "sender": "3N51W4fn1aAAdypU26EGUwNZPr3zikN3vwh", "senderPublicKey": "D7edN6TZzQ6PbyWHGFdGMPJkkRNjR1Y32g7MmU7AXR73", "proofs": [ "5XSEYqWPXYzpZeNzKu4CJxAA8pYS3RsvaGM86zM38oXZv6UxPDnCuNdxTE1gTwuQp8JK4AjoJZMSmDPsjfYFL4LM" ], "script": "base64:AAIFAAAAAAAAAAYIAhIAEgAAAAAEAAAAAAlCTE9DS1NURVAAAAAAAAAAAAoAAAAACUlOR09UQ09TVAAAAAAAAAAACgAAAAADUkVTAQAAACD3MI5LvZDW9hdsE5mwaJiKnQDcPy9bxLj3SQ9cNYQcswEAAAAKcmFuZG9taXplcgAAAAEAAAADaW52BAAAAAhsYXN0UGxheQQAAAAHJG1hdGNoMAkABBwAAAACBQAAAAR0aGlzAgAAAAhsYXN0UGxheQMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAAKQnl0ZVZlY3RvcgQAAAABcwUAAAAHJG1hdGNoMAUAAAABcwMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAAEVW5pdAEAAAAOR29sZE1pbmVyczIwMjEJAAACAAAAAQIAAAALTWF0Y2ggZXJyb3IEAAAABHJhbmQJAADLAAAAAgkAAMsAAAACCQAAywAAAAIJAADLAAAAAgkAAMsAAAACBQAAAAhsYXN0UGxheQgFAAAAA2ludgAAAA10cmFuc2FjdGlvbklkCAUAAAADaW52AAAAD2NhbGxlclB1YmxpY0tleQgFAAAACWxhc3RCbG9jawAAAB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TkdPVAkAAaQAAAABBQAAAAluZXdJbmdvdHMJAAEsAAAAAgIAAAAFSU5HT1QJAAGkAAAAAQUAAAAJbmV3SW5nb3RzAAAAAAAAAAABAAAAAAAAAAAABwkABEwAAAACCQEAAAAOU2NyaXB0VHJhbnNmZXIAAAADCAUAAAABaQAAAAZjYWxsZXIAAAAAAAAAAAEFAAAAA25mdAkABEwAAAACCQEAAAAMSW50ZWdlckVudHJ5AAAAAgIAAAAMaW5nb3RzX2NvdW50BQAAAAluZXdJbmdvdHMJAARMAAAAAgkBAAAAC1N0cmluZ0VudHJ5AAAAAgkAASwAAAACAgAAAAZpbmdvdF8JAAGkAAAAAQUAAAAJbmV3SW5nb3RzCQACWAAAAAEFAAAAA25mdAUAAAADbmlsAAAAAOWf0gQ=", "height": 1615019, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: FwZQ6ea5UhPUtCnr3doyWupnW42F2tgFR4UATXKjPm3d Next: GSNYATbMQHiuL8haQzBnZ6rdzSDovVvmCJ44RNq5XfuW Diff:
OldNewDifferences
4040 let o = d(j)
4141 let p = (toInt(o) % 1000)
4242 if ((l > lastBlock.height))
43- then throw((("Still wait block " + toString(lastBlock.height)) + " for mining"))
43+ then throw((("Still wait block " + toString(n)) + " for mining"))
4444 else [IntegerEntry(("wait_" + k), n), ScriptTransfer(j.caller, p, c)]
4545 }
4646
7979 else {
8080 let u = Issue(("INGOT" + toString(s)), ("INGOT" + toString(s)), 1, 0, false)
8181 let v = calculateAssetId(u)
82-[Issue(("INGOT" + toString(s)), ("INGOT" + toString(s)), 1, 0, false), Burn(c, 10), ScriptTransfer(j.caller, 1, v), IntegerEntry("ingots_count", s), StringEntry(("ingot_" + toString(s)), toBase58String(v))]
82+[Burn(c, 10), Issue(("INGOT" + toString(s)), ("INGOT" + toString(s)), 1, 0, false), ScriptTransfer(j.caller, 1, v), IntegerEntry("ingots_count", s), StringEntry(("ingot_" + toString(s)), toBase58String(v))]
8383 }
8484 }
8585 }
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let a = 10
55
66 let b = 10
77
88 let c = base58'HdveNhSzDRiEib9RfQ5EAxmpFVica4EqvBFd2S4pdbD4'
99
1010 func d (e) = {
1111 let f = {
1212 let g = getBinary(this, "lastPlay")
1313 if ($isInstanceOf(g, "ByteVector"))
1414 then {
1515 let h = g
1616 h
1717 }
1818 else if ($isInstanceOf(g, "Unit"))
1919 then base58'TGCTLFoHxJ8U7rcUofN'
2020 else throw("Match error")
2121 }
2222 let i = (((((f + e.transactionId) + e.callerPublicKey) + lastBlock.generationSignature) + toBytes(lastBlock.timestamp)) + toBytes(lastBlock.height))
2323 sha256(i)
2424 }
2525
2626
2727 @Callable(j)
2828 func goToMine () = {
2929 let k = toBase58String(j.caller.bytes)
3030 let l = {
3131 let g = getInteger(this, ("wait_" + k))
3232 if ($isInstanceOf(g, "Int"))
3333 then {
3434 let m = g
3535 m
3636 }
3737 else 0
3838 }
3939 let n = (lastBlock.height + a)
4040 let o = d(j)
4141 let p = (toInt(o) % 1000)
4242 if ((l > lastBlock.height))
43- then throw((("Still wait block " + toString(lastBlock.height)) + " for mining"))
43+ then throw((("Still wait block " + toString(n)) + " for mining"))
4444 else [IntegerEntry(("wait_" + k), n), ScriptTransfer(j.caller, p, c)]
4545 }
4646
4747
4848
4949 @Callable(j)
5050 func craftIngot () = {
5151 let k = toBase58String(j.caller.bytes)
5252 let q = {
5353 let g = getInteger(this, ("craft_" + k))
5454 if ($isInstanceOf(g, "Int"))
5555 then {
5656 let m = g
5757 m
5858 }
5959 else 0
6060 }
6161 let r = {
6262 let g = getInteger(this, "ingots_count")
6363 if ($isInstanceOf(g, "Int"))
6464 then {
6565 let m = g
6666 m
6767 }
6868 else 0
6969 }
7070 let s = (r + 1)
7171 if ((size(j.payments) == 0))
7272 then throw("Payment not attached")
7373 else {
7474 let t = j.payments[0]
7575 if ((t.assetId != c))
7676 then throw("PAY IN RES TOKEN ONLY")
7777 else if ((t.amount != b))
7878 then throw((("PAY " + toString(b)) + " RES TOKEN ONLY"))
7979 else {
8080 let u = Issue(("INGOT" + toString(s)), ("INGOT" + toString(s)), 1, 0, false)
8181 let v = calculateAssetId(u)
82-[Issue(("INGOT" + toString(s)), ("INGOT" + toString(s)), 1, 0, false), Burn(c, 10), ScriptTransfer(j.caller, 1, v), IntegerEntry("ingots_count", s), StringEntry(("ingot_" + toString(s)), toBase58String(v))]
82+[Burn(c, 10), Issue(("INGOT" + toString(s)), ("INGOT" + toString(s)), 1, 0, false), ScriptTransfer(j.caller, 1, v), IntegerEntry("ingots_count", s), StringEntry(("ingot_" + toString(s)), toBase58String(v))]
8383 }
8484 }
8585 }
8686
8787

github/deemru/w8io/026f985 
27.52 ms