tx · 8aTGCBmPmzECJBBbTE2yWwLtWy1c37UyGKnsiS5vu9nd

3N356YfN19XTJNfZ1sE9kssQwTxvyMLq7MT:  -0.01000000 Waves

2022.05.31 14:09 [2075760] smart account 3N356YfN19XTJNfZ1sE9kssQwTxvyMLq7MT > SELF 0.00000000 Waves

{ "type": 13, "id": "8aTGCBmPmzECJBBbTE2yWwLtWy1c37UyGKnsiS5vu9nd", "fee": 1000000, "feeAssetId": null, "timestamp": 1653995402444, "version": 2, "chainId": 84, "sender": "3N356YfN19XTJNfZ1sE9kssQwTxvyMLq7MT", "senderPublicKey": "5FCKdCQ3s4naiaoX3iSwKqTAHzcVkGi6M48BnWuHjJ5u", "proofs": [ "SL6wGQ1pTLsB2Zuhf1qqQjDSC1SqHtgUFh9yKgFdq4pLMS8iv7XMtQSJAX1429XTuoL5o68NrDyM96J9pyn9HXm" ], "script": "base64:AAIFAAAAAAAAAAcIAhIDCgEBAAAAAgAAAAANUEFZTUVOVF9BU1NFVAEAAAAgrZ1IFoWReWfvw0p6hpnR3VDpBUk85P5AREeM4YPEwvQBAAAAC2lzUGF5bWVudE9rAAAAAQAAAAFpBAAAABFhY2NlcHRhYmxlQXNzZXRJZAUAAAANUEFZTUVOVF9BU1NFVAMJAAAAAAAAAgkAAZAAAAABCAUAAAABaQAAAAhwYXltZW50cwAAAAAAAAAAAAkAAAIAAAABAgAAABRQYXltZW50IG5vdCBhdHRhY2hlZAQAAAABcAkAAZEAAAACCAUAAAABaQAAAAhwYXltZW50cwAAAAAAAAAAAAQAAAAIcHJpY2VLZXkCAAAACmxhc3RfcHJpY2UEAAAACmludGVnZXJWYWwJAQAAAAt2YWx1ZU9yRWxzZQAAAAIJAQAAABFAZXh0ck5hdGl2ZSgxMDUwKQAAAAIFAAAABHRoaXMFAAAACHByaWNlS2V5AAAAAAAC+vCABAAAAAckbWF0Y2gwCAUAAAABcAAAAAdhc3NldElkAwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAAApCeXRlVmVjdG9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AAAAAAAAmJaABAAAAANpZGEJAAQ4AAAAAQUAAAAGaXNzdWVyCQAETAAAAAIFAAAABmlzc3VlcgkABEwAAAACCQEAAAALU3RyaW5nRW50cnkAAAACCQABLAAAAAIJAAEsAAAAAgkAAaQAAAABBQAAAAJpZAIAAAABXwUAAAAMd2FsbGV0U3RyaW5nCQACWAAAAAEFAAAAA2lkYQkABEwAAAACCQEAAAAOU2NyaXB0VHJhbnNmZXIAAAADCAUAAAABaQAAAAZjYWxsZXIAAAAAAAAAAAEFAAAAA2lkYQkABEwAAAACCQEAAAAMSW50ZWdlckVudHJ5AAAAAgUAAAAIcHJpY2VLZXkFAAAACG5ld1ByaWNlBQAAAANuaWwJAAACAAAAAQIAAAAeYWxyZWFkeSBtaW50ZWQgYnkgc29tZW9uZSBlbHNlCQAAAgAAAAECAAAAHldyb25nIHBheW1lbnQgYW1vdW50IG9yIGFzc2V0LgkAAAIAAAABAgAAAAxvdXQgb2YgcmFuZ2UAAAAAmMkacA==", "height": 2075760, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 4sAGBHEq69F3Rh4hh2EoaHJ5tuN7pUDGLVF8noauAmLV Next: 5KtjavABwZBTHtYHrYzWyezVasZgtHzkNY2hNB5S2Jft Diff:
OldNewDifferences
1010 else {
1111 let e = c.payments[0]
1212 let f = "last_price"
13- let g = 50000000
13+ let g = valueOrElse(getIntegerValue(this, f), 50000000)
1414 let h = e.assetId
1515 if ($isInstanceOf(h, "ByteVector"))
1616 then {
4343 let p = Issue(o, ("POKEMON_NFT_" + toString(j)), 1, 0, false)
4444 let q = (g + 10000000)
4545 let r = calculateAssetId(p)
46- valueOrErrorMessage([p, StringEntry(((toString(j) + "_") + k), toBase58String(r)), ScriptTransfer(c.caller, 1, r), IntegerEntry(f, q)], "an error occured")
46+[p, StringEntry(((toString(j) + "_") + k), toBase58String(r)), ScriptTransfer(c.caller, 1, r), IntegerEntry(f, q)]
4747 }
4848 else throw("already minted by someone else")
4949 }
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let a = base58'CgidgEMbCKXXErgJXVyZCFRaK8SBNA73Jg8mNXALtVKh'
55
66 func b (c) = {
77 let d = a
88 if ((size(c.payments) == 0))
99 then throw("Payment not attached")
1010 else {
1111 let e = c.payments[0]
1212 let f = "last_price"
13- let g = 50000000
13+ let g = valueOrElse(getIntegerValue(this, f), 50000000)
1414 let h = e.assetId
1515 if ($isInstanceOf(h, "ByteVector"))
1616 then {
1717 let i = h
1818 if ((i == a))
1919 then (e.amount == g)
2020 else false
2121 }
2222 else throw("Wrong payment asset or min amount 50 USDN")
2323 }
2424 }
2525
2626
2727 @Callable(c)
2828 func mintPokemon (j) = {
2929 let k = toBase58String(c.caller.bytes)
3030 let f = "last_price"
3131 let g = valueOrElse(getIntegerValue(this, f), 0)
3232 if (if ((j > 0))
3333 then true
3434 else (151 >= j))
3535 then if (b(c))
3636 then {
3737 let l = toString(j)
3838 let m = valueOrElse(getString(this, l), "none")
3939 let n = ((toString(j) + "_w_") + k)
4040 let o = ("POKEMON_NFT" + toString(j))
4141 if ((m == "none"))
4242 then {
4343 let p = Issue(o, ("POKEMON_NFT_" + toString(j)), 1, 0, false)
4444 let q = (g + 10000000)
4545 let r = calculateAssetId(p)
46- valueOrErrorMessage([p, StringEntry(((toString(j) + "_") + k), toBase58String(r)), ScriptTransfer(c.caller, 1, r), IntegerEntry(f, q)], "an error occured")
46+[p, StringEntry(((toString(j) + "_") + k), toBase58String(r)), ScriptTransfer(c.caller, 1, r), IntegerEntry(f, q)]
4747 }
4848 else throw("already minted by someone else")
4949 }
5050 else throw("Wrong payment amount or asset.")
5151 else throw("out of range")
5252 }
5353
5454

github/deemru/w8io/169f3d6 
37.93 ms