tx · 9JyGvi2cajgrAiCdvb3QXZUuLy6BFWFozeTSyjm4oswr

3N1HdGqmcf4nVsUgmWiwB8p6p8ErWBmvQua:  -0.01000000 Waves

2023.11.02 16:01 [2825745] smart account 3N1HdGqmcf4nVsUgmWiwB8p6p8ErWBmvQua > SELF 0.00000000 Waves

{ "type": 13, "id": "9JyGvi2cajgrAiCdvb3QXZUuLy6BFWFozeTSyjm4oswr", "fee": 1000000, "feeAssetId": null, "timestamp": 1698930093463, "version": 2, "chainId": 84, "sender": "3N1HdGqmcf4nVsUgmWiwB8p6p8ErWBmvQua", "senderPublicKey": "JAEVvs5E9kGyXWx3YQaivUpUP3vb3pgr2eS6UrYr1A8P", "proofs": [ "3iL8bg3oFZJxP14csyuY1Qti2NfAYcwWa5hLgaBYBjphZEzxD6AJpgwzK3RigubQVyKHXtTwA2pzSsmp1PueawGR" ], "script": "base64:BgIXCAISAwoBAhIICgYICAEBAQESBAoCCAgJAANTRVACAl9fAQZuZnRLZXkBBW5mdElkCQC5CQIJAMwIAgIDbmZ0CQDMCAIJANgEAQUFbmZ0SWQFA25pbAUDU0VQARVuZnRUeXBlRGVzY3JpcHRpb25LZXkBCW5mdFR5cGVJZAkAuQkCCQDMCAICCG5mdF90eXBlCQDMCAIFCW5mdFR5cGVJZAUDbmlsBQNTRVABBnNldE5mdAQFbmZ0SWQJbmZ0VHlwZUlkBmhlYWx0aAZkYW1hZ2UJAQtTdHJpbmdFbnRyeQIJAQZuZnRLZXkBBQVuZnRJZAkAuQkCCQDMCAIFCW5mdFR5cGVJZAkAzAgCCQCkAwEFBmhlYWx0aAkAzAgCCQCkAwEFBmRhbWFnZQUDbmlsBQNTRVABFWdldE5mdFR5cGVEZXNjcmlwdGlvbgEJbmZ0VHlwZUlkBAtzYXZlZFN0cmluZwkAtQkCBAckbWF0Y2gwCQCdCAIFBHRoaXMJARVuZnRUeXBlRGVzY3JpcHRpb25LZXkBBQluZnRUeXBlSWQDCQABAgUHJG1hdGNoMAIGU3Rya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aXB0aW9uAl8zCQBkAggFD3R5cGVEZXNjcmlwdGlvbgJfMwkAagIJALEJAQgFB2hlYWx0aFQCXzEJAGUCCAUPdHlwZURlc2NyaXB0aW9uAl8zCAUPdHlwZURlc2NyaXB0aW9uAl8yBAZkYW1hZ2UDCQAAAgkAZQIIBQ90eXBlRGVzY3JpcHRpb24CXzUIBQ90eXBlRGVzY3JpcHRpb24CXzQAAAgFD3R5cGVEZXNjcmlwdGlvbgJfNQkAZAIIBQ90eXBlRGVzY3JpcHRpb24CXzQJAGoCCQCxCQEIBQdkYW1hZ2VUAl8xCQBlAggFD3R5cGVEZXNjcmlwdGlvbgJfNQgFD3R5cGVEZXNjcmlwdGlvbgJfNAQLZGVzY3JpcHRpb24JAKwCAgkArAICCQCsAgIJAKwCAgIQeyJpbml0SGVhbHRoIjogIgkApAMBBQZoZWFsdGgCESIsICJpbml0RGFtYWdlIjogCQCkAwEFBmRhbWFnZQIBfQQFYXNzZXQJAMIIBQUJbmZ0VHlwZUlkBQtkZXNjcmlwdGlvbgABAAAHBAdhc3NldElkCQC4CAEFBWFzc2V0CQCUCgIJAMwIAgkBBnNldE5mdAQFB2Fzc2V0SWQFCW5mdFR5cGVJZAUGaGVhbHRoBQZkYW1hZ2UJAMwIAgUFYXNzZXQJAMwIAgkBDlNjcmlwdFRyYW5zZmVyAwkBBXZhbHVlAQkApggBBQJ0bwABBQdhc3NldElkBQNuaWwJANgEAQUHYXNzZXRJZAECdHgBBnZlcmlmeQAJAPQDAwgFAnR4CWJvZHlCeXRlcwkAkQMCCAUCdHgGcHJvb2ZzAAAIBQJ0eA9zZW5kZXJQdWJsaWNLZXlcYqGi", "height": 2825745, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: ERheEv3VCmgDW2FywKcbF7xZjJvKgSz39EBTrn6psFMK Next: H2m5cDoMv9HCDafSmPedST3RQ7U4e1WF9ZachcXzSZyo Diff:
OldNewDifferences
8686 let L = i(e)
8787 let M = m(E, base58'')
8888 let N = m(E, M._2)
89- let g = (L._3 + (toInt(M._1) % (L._3 - L._2)))
90- let h = (L._4 + (toInt(N._1) % (L._5 - L._4)))
89+ let g = if (((L._3 - L._2) == 0))
90+ then L._3
91+ else (L._3 + (toInt(M._1) % (L._3 - L._2)))
92+ let h = if (((L._5 - L._4) == 0))
93+ then L._5
94+ else (L._4 + (toInt(N._1) % (L._5 - L._4)))
9195 let O = (((("{\"initHealth\": \"" + toString(g)) + "\", \"initDamage\": ") + toString(h)) + "}")
9296 let P = Issue(e, O, 1, 0, false)
9397 let Q = calculateAssetId(P)
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let a = "__"
55
66 func b (c) = makeString(["nft", toBase58String(c)], a)
77
88
99 func d (e) = makeString(["nft_type", e], a)
1010
1111
1212 func f (c,e,g,h) = StringEntry(b(c), makeString([e, toString(g), toString(h)], a))
1313
1414
1515 func i (e) = {
1616 let j = split({
1717 let k = getString(this, d(e))
1818 if ($isInstanceOf(k, "String"))
1919 then {
2020 let l = k
2121 l
2222 }
2323 else throw("nft type not found")
2424 }, a)
2525 $Tuple5(j[0], parseIntValue(j[1]), parseIntValue(j[2]), parseIntValue(j[3]), parseIntValue(j[4]))
2626 }
2727
2828
2929 func m (n,o) = {
3030 let p = (((((o + n.transactionId) + n.callerPublicKey) + lastBlock.generationSignature) + toBytes(lastBlock.timestamp)) + toBytes(lastBlock.height))
3131 $Tuple2(sha256(p), p)
3232 }
3333
3434
3535 func q (r) = {
3636 let k = getString(this, b(r))
3737 if ($isInstanceOf(k, "String"))
3838 then {
3939 let l = k
4040 let s = split(l, a)
4141 $Tuple3(s[0], parseIntValue(s[1]), parseIntValue(s[2]))
4242 }
4343 else nil
4444 }
4545
4646
4747 func t (u,v) = {
4848 let k = q(v)
4949 if ($isInstanceOf(k, "(String, Int, Int)"))
5050 then {
5151 let l = k
5252 l :: u
5353 }
5454 else u
5555 }
5656
5757
5858 func w (r) = $Tuple2(nil, {
5959 let x = r
6060 let y = size(x)
6161 let z = nil
6262 func A (B,C) = if ((C >= y))
6363 then B
6464 else t(B, x[C])
6565
6666 func D (B,C) = if ((C >= y))
6767 then B
6868 else throw("List size exceeds 5")
6969
7070 D(A(A(A(A(A(z, 0), 1), 2), 3), 4), 5)
7171 })
7272
7373
7474 @Callable(E)
7575 func getNft (r) = $Tuple2(nil, q(r))
7676
7777
7878
7979 @Callable(E)
8080 func setNftTypeDescription (e,F,G,H,I,J) = [StringEntry(d(e), makeString([F, toString(G), toString(H), toString(I), toString(J)], a))]
8181
8282
8383
8484 @Callable(E)
8585 func mint (e,K) = {
8686 let L = i(e)
8787 let M = m(E, base58'')
8888 let N = m(E, M._2)
89- let g = (L._3 + (toInt(M._1) % (L._3 - L._2)))
90- let h = (L._4 + (toInt(N._1) % (L._5 - L._4)))
89+ let g = if (((L._3 - L._2) == 0))
90+ then L._3
91+ else (L._3 + (toInt(M._1) % (L._3 - L._2)))
92+ let h = if (((L._5 - L._4) == 0))
93+ then L._5
94+ else (L._4 + (toInt(N._1) % (L._5 - L._4)))
9195 let O = (((("{\"initHealth\": \"" + toString(g)) + "\", \"initDamage\": ") + toString(h)) + "}")
9296 let P = Issue(e, O, 1, 0, false)
9397 let Q = calculateAssetId(P)
9498 $Tuple2([f(Q, e, g, h), P, ScriptTransfer(value(addressFromString(K)), 1, Q)], toBase58String(Q))
9599 }
96100
97101
98102 @Verifier(R)
99103 func S () = sigVerify(R.bodyBytes, R.proofs[0], R.senderPublicKey)
100104

github/deemru/w8io/026f985 
23.12 ms