tx · BCWLXp3PAQ4g573T45cG3q28k7YpxpLHfXW9gowMu6LF

3N51W4fn1aAAdypU26EGUwNZPr3zikN3vwh:  -0.01400000 Waves

2021.08.01 08:57 [1638871] smart account 3N51W4fn1aAAdypU26EGUwNZPr3zikN3vwh > SELF 0.00000000 Waves

{ "type": 13, "id": "BCWLXp3PAQ4g573T45cG3q28k7YpxpLHfXW9gowMu6LF", "fee": 1400000, "feeAssetId": null, "timestamp": 1627797508273, "version": 2, "chainId": 84, "sender": "3N51W4fn1aAAdypU26EGUwNZPr3zikN3vwh", "senderPublicKey": "D7edN6TZzQ6PbyWHGFdGMPJkkRNjR1Y32g7MmU7AXR73", "proofs": [ "59qNB3QV8f33NzE84mJ6eFWCBNBzP9hFRdFNy2DG2QTxyg8efBPRHGRVTtA8BG3CtBEnwzxae7kmicAPBNJgd8Gz" ], "script": "base64:AAIFAAAAAAAAABcIAhIAEgMKAQESAwoBARIAEgMKAQESAAAAAAcAAAAACUJMT0NLU1RFUAAAAAAAAAAACgAAAAAJSU5HT1RDT1NUAAAAAAAAAAPoAAAAAAhQTE9UQ09TVAAAAAAAAAGGoAAAAAAFZ0x1bXABAAAAIPcwjku9kNb2F2wTmbBomIqdANw/L1vEuPdJD1w1hByzAAAAAAREQVBQAQAAABoBVKWQPedm0Te8uocEZojnPgCB9mXBVVoIGAAAAAAJRVBPQ0hTVEVQAAAAAAAAAABkAQAAAApyYW5kb21pemVyAAAAAQAAAANpbnYEAAAACGxhc3RQbGF5BAAAAAckbWF0Y2gwCQAEHAAAAAIFAAAABHRoaXMCAAAACGxhc3RNaW5lAwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAAApCeXRlVmVjdG9yBAAAAAFzBQAAAAckbWF0Y2gwBQAAAAFzAwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAAARVbml0AQAAAA5Hb2xkTWluZXJzMjAyMQkAAAIAAAABAgAAAAtNYXRjaCBlcnJvcgQAAAAEcmFuZAkAAMsAAAACCQAAywAAAAIJ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AAEsAAAAAgIAAAAIeyJraW5nIjoFAAAACG1heE93bmVyAgAAAAksImVwb2NoIjoJAAGkAAAAAQUAAAAFZXBvY2gCAAAAAX0EAAAABWlzc3VlCQAEQgAAAAUFAAAACWlzc3VlTmFtZQUAAAAJaXNzdWVEZXNjAAAAAAAAAAABAAAAAAAAAAAABwQAAAADbmZ0CQAEOAAAAAEFAAAABWlzc3VlCQAETAAAAAIJAARCAAAABQUAAAAJaXNzdWVOYW1lBQAAAAlpc3N1ZURlc2MAAAAAAAAAAAEAAAAAAAAAAAAHCQAETAAAAAIJAQAAAA5TY3JpcHRUcmFuc2ZlcgAAAAMJAQAAABFAZXh0ck5hdGl2ZSgxMDYyKQAAAAEFAAAACG1heE93bmVyAAAAAAAAAAABBQAAAANuZnQJAARMAAAAAgkBAAAADEludGVnZXJFbnRyeQAAAAICAAAABWVwb2NoBQAAAAhuZXdFcG9jaAkABEwAAAACCQEAAAAMSW50ZWdlckVudHJ5AAAAAgIAAAALZXBvY2hIZWlnaHQFAAAAD25leHRFcG9jaEhlaWdodAUAAAADbmlsAAAAAQAAAAJ0eAEAAAAGdmVyaWZ5AAAAAAkAAfQAAAADCAUAAAACdHgAAAAJYm9keUJ5dGVzCQABkQAAAAIIBQAAAAJ0eAAAAAZwcm9vZnMAAAAAAAAAAAAIBQAAAAJ0eAAAAA9zZW5kZXJQdWJsaWNLZXl7jlGr", "height": 1638871, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 8rxS4isKvEvZCexVipBn3ZK3euVjVfaE5G2zZ4QmtfJZ Next: 6pqtYvAgfBqySs6X3DJ3iRmxzq42qr8QGPFFuSCY4WV8 Diff:
OldNewDifferences
219219 let issueDesc = (((("{\"king\":" + maxOwner) + ",\"epoch\":") + toString(epoch)) + "}")
220220 let issue = Issue(issueName, issueDesc, 1, 0, false)
221221 let nft = calculateAssetId(issue)
222-[ScriptTransfer(addressFromStringValue(maxOwner), 1, nft), IntegerEntry("epoch", newEpoch), IntegerEntry("epochHeight", nextEpochHeight)]
222+[Issue(issueName, issueDesc, 1, 0, false), ScriptTransfer(addressFromStringValue(maxOwner), 1, nft), IntegerEntry("epoch", newEpoch), IntegerEntry("epochHeight", nextEpochHeight)]
223223 }
224224 }
225225 }
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let BLOCKSTEP = 10
55
66 let INGOTCOST = 1000
77
88 let PLOTCOST = 100000
99
1010 let gLump = base58'HdveNhSzDRiEib9RfQ5EAxmpFVica4EqvBFd2S4pdbD4'
1111
1212 let DAPP = base58'3N51W4fn1aAAdypU26EGUwNZPr3zikN3vwh'
1313
1414 let EPOCHSTEP = 100
1515
1616 func randomizer (inv) = {
1717 let lastPlay = match getBinary(this, "lastMine") {
1818 case s: ByteVector =>
1919 s
2020 case _: Unit =>
2121 base58'TGCTLFoHxJ8U7rcUofN'
2222 case _ =>
2323 throw("Match error")
2424 }
2525 let rand = (((((lastPlay + inv.transactionId) + inv.callerPublicKey) + lastBlock.generationSignature) + toBytes(lastBlock.timestamp)) + toBytes(lastBlock.height))
2626 sha256(rand)
2727 }
2828
2929
3030 @Callable(i)
3131 func goToMine () = {
3232 let caller = toBase58String(i.caller.bytes)
3333 let wait = match getInteger(this, ("wait_" + caller)) {
3434 case a: Int =>
3535 a
3636 case _ =>
3737 0
3838 }
3939 let newWait = (lastBlock.height + BLOCKSTEP)
4040 let randhash = randomizer(i)
4141 let count = (toInt(randhash) % 1000)
4242 if ((wait > lastBlock.height))
4343 then throw((("Wait block " + toString(wait)) + " for mining again"))
4444 else [IntegerEntry(("wait_" + caller), newWait), ScriptTransfer(i.caller, count, gLump), BinaryEntry("lastMine", randhash)]
4545 }
4646
4747
4848
4949 @Callable(i)
5050 func craftIngot (count) = {
5151 let caller = toBase58String(i.caller.bytes)
5252 let craft = match getInteger(this, ("craft_" + caller)) {
5353 case a: Int =>
5454 a
5555 case _ =>
5656 0
5757 }
5858 let ingots = match getInteger(this, "ingots_count") {
5959 case a: Int =>
6060 a
6161 case _ =>
6262 0
6363 }
6464 let newIngots = (ingots + 1)
6565 let newCraft = (lastBlock.height + BLOCKSTEP)
6666 if ((size(i.payments) == 0))
6767 then throw("Payment wasn't attached")
6868 else if ((craft > lastBlock.height))
6969 then throw((("Wait block " + toString(craft)) + " for crafting again"))
7070 else if (if (if ((count != 1))
7171 then (count != 10)
7272 else false)
7373 then (count != 50)
7474 else false)
7575 then throw("Wrong ingot's weight!")
7676 else {
7777 let payment = i.payments[0]
7878 if ((payment.assetId != gLump))
7979 then throw("Payment only in gLump")
8080 else if ((payment.amount != (INGOTCOST * count)))
8181 then throw((("Payment expected " + toString((INGOTCOST * count))) + " gLump"))
8282 else {
8383 let issueName = ("INGOT" + toString(newIngots))
8484 let issueDesc = (((((("{\"weight\":" + toString(count)) + ",\"uid\":") + toString(newIngots)) + ",\"made_by\":\"") + caller) + "\"}")
8585 let issue = Issue(issueName, issueDesc, 1, 0, false)
8686 let nft = calculateAssetId(issue)
8787 [Burn(gLump, (INGOTCOST * count)), Issue(issueName, issueDesc, 1, 0, false), ScriptTransfer(i.caller, 1, nft), IntegerEntry("ingots_count", newIngots), StringEntry(("ingot_" + toString(newIngots)), toBase58String(nft)), IntegerEntry(("craft_" + caller), newCraft), IntegerEntry(("weight_" + toBase58String(nft)), count)]
8888 }
8989 }
9090 }
9191
9292
9393
9494 @Callable(i)
9595 func buyPlot (pSize) = {
9696 let caller = toBase58String(i.caller.bytes)
9797 let plotSize = match getInteger(this, ("plot_" + caller)) {
9898 case a: Int =>
9999 a
100100 case _ =>
101101 0
102102 }
103103 if ((plotSize > 0))
104104 then throw("You already have a plot!")
105105 else if (if ((0 > plotSize))
106106 then true
107107 else (plotSize > 1000))
108108 then throw("Correct size value from 1 to 1000")
109109 else {
110110 let payment = i.payments[0]
111111 if (isDefined(payment.assetId))
112112 then throw("Payment only in WAVES")
113113 else if ((payment.amount != (pSize * PLOTCOST)))
114114 then throw((("Payment expected " + toString((pSize * PLOTCOST))) + " WAVELET"))
115115 else [IntegerEntry(("plot_" + caller), pSize)]
116116 }
117117 }
118118
119119
120120
121121 @Callable(i)
122122 func goToPlot () = {
123123 let caller = toBase58String(i.caller.bytes)
124124 let plotSize = match getInteger(this, ("plot_" + caller)) {
125125 case a: Int =>
126126 a
127127 case _ =>
128128 0
129129 }
130130 let wait = match getInteger(this, ("wait_" + caller)) {
131131 case a: Int =>
132132 a
133133 case _ =>
134134 0
135135 }
136136 let newWait = (lastBlock.height + BLOCKSTEP)
137137 let newPlotSize = (plotSize - 1)
138138 if ((0 >= plotSize))
139139 then throw("Plot is empty, buy new!")
140140 else if ((wait > lastBlock.height))
141141 then throw((("Wait block " + toString(wait)) + " for mining again"))
142142 else [IntegerEntry(("wait_" + caller), newWait), ScriptTransfer(i.caller, 1000, gLump), IntegerEntry(("plot_" + caller), newPlotSize)]
143143 }
144144
145145
146146
147147 @Callable(i)
148148 func giveIngot (uid) = {
149149 let caller = toBase58String(i.caller.bytes)
150150 let assetId = match getString(this, ("ingot_" + toString(uid))) {
151151 case a: String =>
152152 a
153153 case _ =>
154154 ""
155155 }
156156 let given = match getInteger(this, ("from_by_" + caller)) {
157157 case a: Int =>
158158 a
159159 case _ =>
160160 0
161161 }
162162 let weight = match getInteger(this, ("weight_" + assetId)) {
163163 case a: Int =>
164164 a
165165 case _ =>
166166 0
167167 }
168168 let maxq = match getInteger(this, "max_q") {
169169 case a: Int =>
170170 a
171171 case _ =>
172172 0
173173 }
174174 let newGiven = (given + weight)
175175 let newMaxQ = newGiven
176176 if ((size(i.payments) == 0))
177177 then throw("NFT Payment wasn't attached")
178178 else if ((assetId == ""))
179179 then throw(("Can't find INGOT" + toString(uid)))
180180 else {
181181 let payment = i.payments[0]
182182 if ((isDefined(payment.assetId) == false))
183183 then throw("???")
184184 else if ((payment.assetId != fromBase58String(assetId)))
185185 then throw(("Wrong Ingot in Payment " + assetId))
186186 else if ((payment.amount != 1))
187187 then throw("Wrong ingot's count")
188188 else if ((newMaxQ > maxq))
189189 then [IntegerEntry("max_q", newMaxQ), StringEntry("max_owner", caller), IntegerEntry(("from_by_" + caller), newGiven)]
190190 else [IntegerEntry(("from_by_" + caller), newGiven)]
191191 }
192192 }
193193
194194
195195
196196 @Callable(i)
197197 func startNewEpoch () = {
198198 let epoch = match getInteger(this, "epoch") {
199199 case a: Int =>
200200 a
201201 case _ =>
202202 -1
203203 }
204204 let maxOwner = match getString(this, "max_owner") {
205205 case a: String =>
206206 a
207207 case _ =>
208208 ""
209209 }
210210 if ((i.caller.bytes != DAPP))
211211 then throw("Only Creator of the world can start new Epoch")
212212 else {
213213 let newEpoch = (epoch + 1)
214214 let nextEpochHeight = (lastBlock.height + BLOCKSTEP)
215215 if ((maxOwner == ""))
216216 then [IntegerEntry("epoch", newEpoch), IntegerEntry("epochHeight", nextEpochHeight)]
217217 else {
218218 let issueName = ("CROWN" + toString(epoch))
219219 let issueDesc = (((("{\"king\":" + maxOwner) + ",\"epoch\":") + toString(epoch)) + "}")
220220 let issue = Issue(issueName, issueDesc, 1, 0, false)
221221 let nft = calculateAssetId(issue)
222-[ScriptTransfer(addressFromStringValue(maxOwner), 1, nft), IntegerEntry("epoch", newEpoch), IntegerEntry("epochHeight", nextEpochHeight)]
222+[Issue(issueName, issueDesc, 1, 0, false), ScriptTransfer(addressFromStringValue(maxOwner), 1, nft), IntegerEntry("epoch", newEpoch), IntegerEntry("epochHeight", nextEpochHeight)]
223223 }
224224 }
225225 }
226226
227227
228228 @Verifier(tx)
229229 func verify () = sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)
230230

github/deemru/w8io/169f3d6 
87.87 ms