tx · 4xCcxGjaYtWg3EmAqk3nwAauWjoGEEK9i5rG4XE4uPNC

3MuVEuhXaTvF3ELakZksUP77a4bT8gPJtm6:  -0.01000000 Waves

2021.12.04 18:30 [1819717] smart account 3MuVEuhXaTvF3ELakZksUP77a4bT8gPJtm6 > SELF 0.00000000 Waves

{ "type": 13, "id": "4xCcxGjaYtWg3EmAqk3nwAauWjoGEEK9i5rG4XE4uPNC", "fee": 1000000, "feeAssetId": null, "timestamp": 1638631891889, "version": 2, "chainId": 84, "sender": "3MuVEuhXaTvF3ELakZksUP77a4bT8gPJtm6", "senderPublicKey": "2LizaCNygFYwGFKe34vvFHgJc4ckK7MpzRzziRNn56Cu", "proofs": [ "gxkiqkeCzjLePUWXvQAbhTq6B9i8DZgrFXeyxnAJukCZDD9mLSK1zpxTMUE4Taxxqjx87RUQsB1B3pcmtheLLuJ" ], "script": "base64:AAIFAAAAAAAAAAcIAhIDCgEIAAAABAAAAAAGbWFzdGVyCQEAAAAHQWRkcmVzcwAAAAEBAAAAGgFUPUYGSQjhSwi99Mcha5hyYJjHFzCelkk9AAAAAAVzZXBhcgIAAAAFfHx8fHwAAAAACWluaXRwcmljZQIAAAAGMTAwMDAwAQAAAAd0b3dhdmVzAAAAAQAAAAFhAwkAAGYAAAACAAAAAAAAAAAJCQABMQAAAAEFAAAAAWEJAAEsAAAAAgkAASwAAAACAgAAAAEwAgAAAAEuBQAAAAFhCQABLAAAAAIJAAEsAAAAAgkAAS8AAAACBQAAAAFhCQAAZQAAAAIJAAExAAAAAQUAAAABYQAAAAAAAAAACAIAAAABLgkBAAAACXRha2VSaWdodAAAAAIFAAAAAWEAAAAAAAAAAAgAAAABAAAAAWkBAAAABXBhaW50AAAAAQAAAAVpZGF0YQQAAAAMY2FsbGVyQWRyZXNzCQACWAAAAAEICAUAAAABaQAAAAZjYWxsZXIAAAAFYnl0ZXMEAAAABXBpeHh5CQAEtQAAAAIFAAAABWlkYXRhBQAAAAVzZXBhcgQAAAAGbnVtYmVy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AGRAAAAAgUAAAADYWxsAAAAAAAAAAADAAAAAAAAAAAACQABkQAAAAIJAAGRAAAAAgUAAAADYWxsAAAAAAAAAAADAAAAAAAAAAABCQAETAAAAAIJAQAAAA5TY3JpcHRUcmFuc2ZlcgAAAAMFAAAABm1hc3RlcgkBAAAADXBhcnNlSW50VmFsdWUAAAABCQABkQAAAAIJAAGRAAAAAgUAAAADYWxsAAAAAAAAAAADAAAAAAAAAAADBQAAAAR1bml0CQAETAAAAAIJAQAAAAtTdHJpbmdFbnRyeQAAAAIJAAGRAAAAAgkAAZEAAAACBQAAAANhbGwAAAAAAAAAAAQAAAAAAAAAAAAJAAGRAAAAAgkAAZEAAAACBQAAAANhbGwAAAAAAAAAAAQAAAAAAAAAAAEJAARMAAAAAgkBAAAADlNjcmlwdFRyYW5zZmVyAAAAAwUAAAAGbWFzdGVyCQEAAAANcGFyc2VJbnRWYWx1ZQAAAAEJAAGRAAAAAgkAAZEAAAACBQAAAANhbGwAAAAAAAAAAAQAAAAAAAAAAAMFAAAABHVuaXQFAAAAA25pbAUAAAAEdW5pdAAAAABb6T0p", "height": 1819717, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 5a1d92LuVrxUERLnykqnzdY7nV1B6zgtUUBEkRHoj6zA Next: 26zP5zXr8RpakXF2rEJX2XSNdW12myzJJu8Tw7cKS1pb Diff:
OldNewDifferences
6565 if (isDefined(pmt.assetId))
6666 then throw("works with waves only")
6767 else if ((payment > pmt.amount))
68- then throw(((("you give: " + toString(pmt.amount)) + ", but deal needs: ") + towaves(toString(payment))))
68+ then throw(((("you give: " + towaves(toString(pmt.amount))) + ", but deal needs: ") + towaves(toString(payment))))
6969 else {
7070 let all = [makerecord(0), makerecord(1), makerecord(2), makerecord(3), makerecord(4)]
7171 $Tuple2([StringEntry(all[0][0], all[0][1]), ScriptTransfer(master, parseIntValue(all[0][3]), unit), StringEntry(all[1][0], all[1][1]), ScriptTransfer(master, parseIntValue(all[1][3]), unit), StringEntry(all[2][0], all[2][1]), ScriptTransfer(master, parseIntValue(all[2][3]), unit), StringEntry(all[3][0], all[3][1]), ScriptTransfer(master, parseIntValue(all[3][3]), unit), StringEntry(all[4][0], all[4][1]), ScriptTransfer(master, parseIntValue(all[4][3]), unit)], unit)
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let master = Address(base58'3MuW4t1jCXHt8WRsHVLUar32EnvJxZaQWAx')
55
66 let separ = "|||||"
77
88 let initprice = "100000"
99
1010 func towaves (a) = if ((9 > size(a)))
1111 then (("0" + ".") + a)
1212 else ((take(a, (size(a) - 8)) + ".") + takeRight(a, 8))
1313
1414
1515 @Callable(i)
1616 func paint (idata) = {
1717 let callerAdress = toBase58String(i.caller.bytes)
1818 let pixxy = split(idata, separ)
1919 let number = min([5, size(pixxy)])
2020 let records = nil
2121 func validxy (x) = match parseInt(pixxy[x]) {
2222 case a: Int =>
2323 if (if ((parseIntValue(pixxy[x]) > -1))
2424 then (1000 > parseIntValue(pixxy[x]))
2525 else false)
2626 then parseInt(pixxy[x])
2727 else false
2828 case _ =>
2929 false
3030 }
3131
3232 func getrecord (x) = match getString(pixxy[x]) {
3333 case a: String =>
3434 a
3535 case _ =>
3636 false
3737 }
3838
3939 func makerecord (x) = if ((x > (number - 1)))
4040 then ["--", "--", "--", "0"]
4141 else if ((validxy(x) == false))
4242 then ["--", "--", "--", "0"]
4343 else if ((getrecord(x) == false))
4444 then [pixxy[x], makeString([callerAdress, initprice, "color", "url"], separ), "", initprice]
4545 else {
4646 let price = parseIntValue(split(getStringValue(pixxy[x]), separ)[1])
4747 [pixxy[x], makeString([callerAdress, toString((price + parseIntValue(initprice))), "color", "url"], separ), "", toString(price)]
4848 }
4949
5050 func paymentforpix (x) = if (if ((number > x))
5151 then (getrecord(x) != false)
5252 else false)
5353 then match parseInt(split(getStringValue(pixxy[x]), separ)[1]) {
5454 case a: Int =>
5555 parseIntValue(split(getStringValue(pixxy[x]), separ)[1])
5656 case _ =>
5757 0
5858 }
5959 else 0
6060
6161 let payment = ((((paymentforpix(0) + paymentforpix(1)) + paymentforpix(2)) + paymentforpix(3)) + paymentforpix(4))
6262 let pmt = if ((size(i.payments) == 1))
6363 then i.payments[0]
6464 else throw(("Attached payment is required: " + towaves(toString(payment))))
6565 if (isDefined(pmt.assetId))
6666 then throw("works with waves only")
6767 else if ((payment > pmt.amount))
68- then throw(((("you give: " + toString(pmt.amount)) + ", but deal needs: ") + towaves(toString(payment))))
68+ then throw(((("you give: " + towaves(toString(pmt.amount))) + ", but deal needs: ") + towaves(toString(payment))))
6969 else {
7070 let all = [makerecord(0), makerecord(1), makerecord(2), makerecord(3), makerecord(4)]
7171 $Tuple2([StringEntry(all[0][0], all[0][1]), ScriptTransfer(master, parseIntValue(all[0][3]), unit), StringEntry(all[1][0], all[1][1]), ScriptTransfer(master, parseIntValue(all[1][3]), unit), StringEntry(all[2][0], all[2][1]), ScriptTransfer(master, parseIntValue(all[2][3]), unit), StringEntry(all[3][0], all[3][1]), ScriptTransfer(master, parseIntValue(all[3][3]), unit), StringEntry(all[4][0], all[4][1]), ScriptTransfer(master, parseIntValue(all[4][3]), unit)], unit)
7272 }
7373 }
7474
7575

github/deemru/w8io/169f3d6 
31.96 ms