tx · FDAMNwPMzBuVvi3QhTRwJWztDnCeuhCVPTjNB1zUL31k

3Mp5JgVSHA9iziujC9Kmnf2rCN5SYFE97yC:  -0.01400000 Waves

2021.11.30 19:10 [1813997] smart account 3Mp5JgVSHA9iziujC9Kmnf2rCN5SYFE97yC > SELF 0.00000000 Waves

{ "type": 13, "id": "FDAMNwPMzBuVvi3QhTRwJWztDnCeuhCVPTjNB1zUL31k", "fee": 1400000, "feeAssetId": null, "timestamp": 1638288605913, "version": 2, "chainId": 84, "sender": "3Mp5JgVSHA9iziujC9Kmnf2rCN5SYFE97yC", "senderPublicKey": "CSx1y2ADZAi6KvFZT2LoqQmX5qBxDVVGGZ6heDAGngHM", "proofs": [ "6Kfcw7n8BPX821acJKXMXAmzxtDqCBkaV85MfCbS1RdEBVxizwcEg5hzPWMZ37D4Sgn4q54Rt7KWVdjxGZvaeCW", "hyBDSbtwGqyEmSsW8JNyZjfTFAFqwmBR44Pu7Rk23QeXR7dcmqUkwmx6DaRnzwFD7CcnY95k5QyrVeqgTPTbvDq" ], "script": "base64:AAIFAAAAAAAAABwIAhIHCgUBERgRGBIAEgMKAQgSBAoCAQgSABIAAAAAHQAAAAAJa2V5QWN0aXZlAgAAAAZhY3RpdmUAAAAADGtleUVuZEhlaWdodAIAAAAKZW5kX2hlaWdodAAAAAAPa2V5UHJpemVzUHJpY2VzAgAAAA1wcml6ZXNfcHJpY2VzAAAAAA1rZXlQcml6ZXNBSWRzAgAAABdwcml6ZXNfYWNoaWV2ZW1lbnRzX2lkcwAAAAAQa2V5UHJpemVzQW1vdW50cwIAAAANcHJpemVzX2Ftb3VudAAAAAAOa2V5TGV2ZWxQcmljZXMCAAAADGxldmVsX3ByaWNlcwAAAAAWa2V5TGV2ZWxBY2hpZXZlbW50c0lkcwIAAAAWbGV2ZWxfYWNoaWV2ZW1lbnRzX2lkcwAAAAAJa2V5U1dPUGlkAgAAAAdTV09QX2lkAAAAAA5rZXlUb3RhbEJ1cm5lZAIAAAAMdG90YW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AAAAAAAAAAAAkAAGcAAAACCQAAZAAAAAIJAABkAAAAAgUAAAASYWRtaW5QdWJLZXkxU2lnbmVkBQAAABJhZG1pblB1YktleTJTaWduZWQFAAAAEmFkbWluUHViS2V5M1NpZ25lZAAAAAAAAAAAAgQAAAANc2lnbmVkQnlBZG1pbgMDAwkAAfQAAAADCAUAAAACdHgAAAAJYm9keUJ5dGVzCQABkQAAAAIIBQAAAAJ0eAAAAAZwcm9vZnMAAAAAAAAAAAAFAAAADGFkbWluUHViS2V5MQYJAAH0AAAAAwgFAAAAAnR4AAAACWJvZHlCeXRlcwkAAZEAAAACCAUAAAACdHgAAAAGcHJvb2ZzAAAAAAAAAAAABQAAAAxhZG1pblB1YktleTIGCQAB9AAAAAMIBQAAAAJ0eAAAAAlib2R5Qnl0ZXMJAAGRAAAAAggFAAAAAnR4AAAABnByb29mcwAAAAAAAAAAAAUAAAAMYWRtaW5QdWJLZXkzBgkAAfQAAAADCAUAAAACdHgAAAAJYm9keUJ5dGVzCQABkQAAAAIIBQAAAAJ0eAAAAAZwcm9vZnMAAAAAAAAAAAAFAAAAEmFkbWluUHViS2V5U3Rha2luZwQAAAAHJG1hdGNoMAUAAAACdHgFAAAAE211bHRpU2lnbmVkQnlBZG1pbnOj+bta", "height": 1813997, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: FsJSMEA8njEumeQMn9cuRNK7dKX9fBrC8ZHdGH1Scaud Next: 5EPJnNx2cbQgkC2DJrXD9R4HsXZbvJwPoP8MRGKZybmv Diff:
OldNewDifferences
8888
8989 2(1(1(1(1(1($acc0, 0), 1), 2), 3), 4), 5)
9090 }
91- if ((burned >= levelPrices[3]))
91+ let lvlthree = levelPrices[3]
92+ let lvltwo = levelPrices[2]
93+ let lvlone = levelPrices[1]
94+ let lvlzero = levelPrices[0]
95+ if ((burned >= lvlthree))
9296 then 4
93- else if ((burned >= levelPrices[2]))
97+ else if ((burned >= lvlthree))
9498 then 3
95- else if ((burned >= levelPrices[1]))
99+ else if ((burned >= lvltwo))
96100 then 2
97- else if ((burned >= levelPrices[0]))
101+ else if ((burned >= lvlone))
98102 then 1
99103 else 0
100104 }
154158
155159 @Callable(i)
156160 func add () = {
157- let $t035253600 = $Tuple2(i.payments[0].amount, i.payments[0].assetId)
158- let pmtAmount = $t035253600._1
159- let pmtAssetId = $t035253600._2
161+ let $t036213696 = $Tuple2(i.payments[0].amount, i.payments[0].assetId)
162+ let pmtAmount = $t036213696._1
163+ let pmtAssetId = $t036213696._2
160164 let endHeight = valueOrElse(getInteger(this, keyEndHeight), 0)
161165 if (!(isActive))
162166 then throw("DApp is inactive at this moment")
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let keyActive = "active"
55
66 let keyEndHeight = "end_height"
77
88 let keyPrizesPrices = "prizes_prices"
99
1010 let keyPrizesAIds = "prizes_achievements_ids"
1111
1212 let keyPrizesAmounts = "prizes_amount"
1313
1414 let keyLevelPrices = "level_prices"
1515
1616 let keyLevelAchievemntsIds = "level_achievements_ids"
1717
1818 let keySWOPid = "SWOP_id"
1919
2020 let keyTotalBurned = "total_burned"
2121
2222 let keyVerifyHash = "verify_hash"
2323
2424 let keyFinalizeHeight = "finalize_height"
2525
2626 let keyUserTotalBurned = "_total_burned"
2727
2828 let oracle = Address(base58'3NBBWfzZtZtszaXbitTKnrB2xXwv26Bn7H9')
2929
3030 let farming = Address(base58'3MsxHxruYWoddB4HRiPBYAWtMXMtCF1V9XT')
3131
3232 let achievements = Address(base58'3N3HtdnBkqSSc16DaydiwtrMBUv3DfqKjSW')
3333
3434 let keyAdminPubKey1 = "admin_pub_1"
3535
3636 let keyAdminPubKey2 = "admin_pub_2"
3737
3838 let keyAdminPubKey3 = "admin_pub_3"
3939
4040 func getAdminPub (keyAdminPub) = match getString(oracle, keyAdminPub) {
4141 case string: String =>
4242 fromBase58String(string)
4343 case nothing =>
4444 throw("Admin public key is empty")
4545 }
4646
4747
4848 let adminPubKey1 = getAdminPub(keyAdminPubKey1)
4949
5050 let adminPubKey2 = getAdminPub(keyAdminPubKey2)
5151
5252 let adminPubKey3 = getAdminPub(keyAdminPubKey3)
5353
5454 let adminPubKeyStaking = base58'Kn7NpzaG12dLZgcHf2ipUftU6hbJygmrhFqQYE4B7ZK'
5555
5656 let swopId = fromBase58String(getStringValue(farming, keySWOPid))
5757
5858 let isActive = valueOrElse(getBoolean(this, keyActive), true)
5959
6060 func inListToStr (acc,next) = if ((acc == ""))
6161 then (acc + toString(next))
6262 else ((acc + ",") + toString(next))
6363
6464
6565 func inListToInt (acc,next) = (acc :+ parseIntValue(next))
6666
6767
6868 func calcPrizesAmounts (acc,next) = {
6969 let $t016511676 = acc
7070 let total = $t016511676._1
7171 let result = $t016511676._2
7272 $Tuple2(total, (result :+ (total / next)))
7373 }
7474
7575
7676 func calcLevel (burned) = {
7777 let levelPrices = {
7878 let $l = split(getStringValue(this, keyLevelPrices), ",")
7979 let $s = size($l)
8080 let $acc0 = nil
8181 func 1 ($a,$i) = if (($i >= $s))
8282 then $a
8383 else inListToInt($a, $l[$i])
8484
8585 func 2 ($a,$i) = if (($i >= $s))
8686 then $a
8787 else throw("List size exceeds 5")
8888
8989 2(1(1(1(1(1($acc0, 0), 1), 2), 3), 4), 5)
9090 }
91- if ((burned >= levelPrices[3]))
91+ let lvlthree = levelPrices[3]
92+ let lvltwo = levelPrices[2]
93+ let lvlone = levelPrices[1]
94+ let lvlzero = levelPrices[0]
95+ if ((burned >= lvlthree))
9296 then 4
93- else if ((burned >= levelPrices[2]))
97+ else if ((burned >= lvlthree))
9498 then 3
95- else if ((burned >= levelPrices[1]))
99+ else if ((burned >= lvltwo))
96100 then 2
97- else if ((burned >= levelPrices[0]))
101+ else if ((burned >= lvlone))
98102 then 1
99103 else 0
100104 }
101105
102106
103107 @Callable(i)
104108 func init (endHeight,prizePrices,prizeAchievmentsIds,levelPrices,levelAchievmentsIds) = if (!(containsElement([adminPubKey1, adminPubKey2, adminPubKey3], i.callerPublicKey)))
105109 then throw("Only admin can call this function")
106110 else if (isDefined(getInteger(this, keyEndHeight)))
107111 then throw("DApp is already inited")
108112 else if ((height > endHeight))
109113 then throw("Burning ending must be greater than current height")
110114 else if (if ((size(prizePrices) != 5))
111115 then true
112116 else (size(prizeAchievmentsIds) != 5))
113117 then throw("Amount of prizes achievemts lists must equal to 5")
114118 else if (if ((size(levelPrices) != 4))
115119 then true
116120 else (size(levelAchievmentsIds) != 4))
117121 then throw("Amount of levels lists must equal to 4")
118122 else {
119123 let prizePricesStr = {
120124 let $l = prizePrices
121125 let $s = size($l)
122126 let $acc0 = ""
123127 func 1 ($a,$i) = if (($i >= $s))
124128 then $a
125129 else inListToStr($a, $l[$i])
126130
127131 func 2 ($a,$i) = if (($i >= $s))
128132 then $a
129133 else throw("List size exceeds 5")
130134
131135 2(1(1(1(1(1($acc0, 0), 1), 2), 3), 4), 5)
132136 }
133137 let prizeAchievmentsIdsStr = makeString(prizeAchievmentsIds, ",")
134138 let levelPricesStr = {
135139 let $l = levelPrices
136140 let $s = size($l)
137141 let $acc0 = ""
138142 func 1 ($a,$i) = if (($i >= $s))
139143 then $a
140144 else inListToStr($a, $l[$i])
141145
142146 func 2 ($a,$i) = if (($i >= $s))
143147 then $a
144148 else throw("List size exceeds 5")
145149
146150 2(1(1(1(1(1($acc0, 0), 1), 2), 3), 4), 5)
147151 }
148152 let levelAchievmentsIdsStr = makeString(levelAchievmentsIds, ",")
149153 let prizesAmountStr = "0,0,0,0,0"
150154 [IntegerEntry(keyEndHeight, endHeight), StringEntry(keyPrizesPrices, prizePricesStr), StringEntry(keyPrizesAIds, prizeAchievmentsIdsStr), StringEntry(keyLevelPrices, levelPricesStr), StringEntry(keyLevelAchievemntsIds, levelAchievmentsIdsStr), StringEntry(keyPrizesAmounts, prizesAmountStr)]
151155 }
152156
153157
154158
155159 @Callable(i)
156160 func add () = {
157- let $t035253600 = $Tuple2(i.payments[0].amount, i.payments[0].assetId)
158- let pmtAmount = $t035253600._1
159- let pmtAssetId = $t035253600._2
161+ let $t036213696 = $Tuple2(i.payments[0].amount, i.payments[0].assetId)
162+ let pmtAmount = $t036213696._1
163+ let pmtAssetId = $t036213696._2
160164 let endHeight = valueOrElse(getInteger(this, keyEndHeight), 0)
161165 if (!(isActive))
162166 then throw("DApp is inactive at this moment")
163167 else if (if ((height > endHeight))
164168 then true
165169 else (endHeight == 0))
166170 then throw("Swop burning are ended or not started yet")
167171 else if ((pmtAssetId != swopId))
168172 then throw("You can add only SWOP token")
169173 else {
170174 let newTotalBurned = (valueOrElse(getInteger(this, keyTotalBurned), 0) + pmtAmount)
171175 let userTotalBurned = valueOrElse(getInteger(this, (toString(i.caller) + keyUserTotalBurned)), 0)
172176 let prizesAmounts = {
173177 let $l = split(getStringValue(this, keyPrizesAmounts), ",")
174178 let $s = size($l)
175179 let $acc0 = nil
176180 func 1 ($a,$i) = if (($i >= $s))
177181 then $a
178182 else inListToInt($a, $l[$i])
179183
180184 func 2 ($a,$i) = if (($i >= $s))
181185 then $a
182186 else throw("List size exceeds 5")
183187
184188 2(1(1(1(1(1($acc0, 0), 1), 2), 3), 4), 5)
185189 }
186190 let prizesPrices = {
187191 let $l = split(getStringValue(this, keyPrizesPrices), ",")
188192 let $s = size($l)
189193 let $acc0 = nil
190194 func 1 ($a,$i) = if (($i >= $s))
191195 then $a
192196 else inListToInt($a, $l[$i])
193197
194198 func 2 ($a,$i) = if (($i >= $s))
195199 then $a
196200 else throw("List size exceeds 5")
197201
198202 2(1(1(1(1(1($acc0, 0), 1), 2), 3), 4), 5)
199203 }
200204 let prizesAchievementsIds = split(getStringValue(this, keyPrizesAIds), ",")
201205 let levelAchievementsIds = split(getStringValue(this, keyLevelAchievemntsIds), ",")
202206 let res = {
203207 let $l = prizesPrices
204208 let $s = size($l)
205209 let $acc0 = $Tuple2(newTotalBurned, nil)
206210 func 1 ($a,$i) = if (($i >= $s))
207211 then $a
208212 else calcPrizesAmounts($a, $l[$i])
209213
210214 func 2 ($a,$i) = if (($i >= $s))
211215 then $a
212216 else throw("List size exceeds 5")
213217
214218 2(1(1(1(1(1($acc0, 0), 1), 2), 3), 4), 5)
215219 }
216220 let newPrizesAmounts = res._2
217221 let newPrizesAmountsStr = {
218222 let $l = newPrizesAmounts
219223 let $s = size($l)
220224 let $acc0 = ""
221225 func 1 ($a,$i) = if (($i >= $s))
222226 then $a
223227 else inListToStr($a, $l[$i])
224228
225229 func 2 ($a,$i) = if (($i >= $s))
226230 then $a
227231 else throw("List size exceeds 5")
228232
229233 2(1(1(1(1(1($acc0, 0), 1), 2), 3), 4), 5)
230234 }
231235 let inv0 = if ((newPrizesAmounts[0] != prizesAmounts[0]))
232236 then {
233237 let achievementAmount = (newPrizesAmounts[0] - prizesAmounts[0])
234238 invoke(achievements, "add", [prizesAchievementsIds[0], achievementAmount], nil)
235239 }
236240 else 0
237241 if ((inv0 == inv0))
238242 then {
239243 let inv1 = if ((newPrizesAmounts[1] != prizesAmounts[1]))
240244 then {
241245 let achievementAmount = (newPrizesAmounts[1] - prizesAmounts[1])
242246 invoke(achievements, "add", [prizesAchievementsIds[1], achievementAmount], nil)
243247 }
244248 else 0
245249 if ((inv1 == inv1))
246250 then {
247251 let inv2 = if ((newPrizesAmounts[2] != prizesAmounts[2]))
248252 then {
249253 let achievementAmount = (newPrizesAmounts[2] - prizesAmounts[2])
250254 invoke(achievements, "add", [prizesAchievementsIds[2], achievementAmount], nil)
251255 }
252256 else 0
253257 if ((inv2 == inv2))
254258 then {
255259 let inv3 = if ((newPrizesAmounts[3] != prizesAmounts[3]))
256260 then {
257261 let achievementAmount = (newPrizesAmounts[3] - prizesAmounts[3])
258262 invoke(achievements, "add", [prizesAchievementsIds[3], achievementAmount], nil)
259263 }
260264 else 0
261265 if ((inv3 == inv3))
262266 then {
263267 let inv4 = if ((newPrizesAmounts[4] != prizesAmounts[4]))
264268 then {
265269 let achievementAmount = (newPrizesAmounts[4] - prizesAmounts[4])
266270 invoke(achievements, "add", [prizesAchievementsIds[4], achievementAmount], nil)
267271 }
268272 else 0
269273 if ((inv4 == inv4))
270274 then {
271275 let baseEntry = [IntegerEntry(keyTotalBurned, newTotalBurned), IntegerEntry((toString(i.caller) + keyUserTotalBurned), (userTotalBurned + pmtAmount)), StringEntry(keyPrizesAmounts, newPrizesAmountsStr)]
272276 let oldLevel = calcLevel(userTotalBurned)
273277 let newLevel = calcLevel(newTotalBurned)
274278 let levelDiff = (newLevel - oldLevel)
275279 if ((levelDiff > 0))
276280 then {
277281 let inv5 = if ((levelDiff == 1))
278282 then invoke(achievements, "add", [levelAchievementsIds[(newLevel - 1)], 1], nil)
279283 else 0
280284 if ((inv5 == inv5))
281285 then {
282286 let inv6 = if ((levelDiff >= 2))
283287 then invoke(achievements, "add", [levelAchievementsIds[(newLevel - 2)], 1], nil)
284288 else 0
285289 if ((inv6 == inv6))
286290 then {
287291 let inv7 = if ((levelDiff >= 3))
288292 then invoke(achievements, "add", [levelAchievementsIds[(newLevel - 3)], 1], nil)
289293 else 0
290294 if ((inv7 == inv7))
291295 then {
292296 let inv8 = if ((levelDiff == 4))
293297 then invoke(achievements, "add", [levelAchievementsIds[(newLevel - 4)], 1], nil)
294298 else 0
295299 if ((inv8 == inv8))
296300 then baseEntry
297301 else throw("Strict value is not equal to itself.")
298302 }
299303 else throw("Strict value is not equal to itself.")
300304 }
301305 else throw("Strict value is not equal to itself.")
302306 }
303307 else throw("Strict value is not equal to itself.")
304308 }
305309 else baseEntry
306310 }
307311 else throw("Strict value is not equal to itself.")
308312 }
309313 else throw("Strict value is not equal to itself.")
310314 }
311315 else throw("Strict value is not equal to itself.")
312316 }
313317 else throw("Strict value is not equal to itself.")
314318 }
315319 else throw("Strict value is not equal to itself.")
316320 }
317321 }
318322
319323
320324
321325 @Callable(i)
322326 func hashingRandom (hash) = if (!(isActive))
323327 then throw("DApp is inactive at this moment")
324328 else if (!(containsElement([adminPubKey1, adminPubKey2, adminPubKey3], i.callerPublicKey)))
325329 then throw("Only admin can call this function")
326330 else [StringEntry(keyVerifyHash, hash)]
327331
328332
329333
330334 @Callable(i)
331335 func finalize (vrfHeight,secretWord) = {
332336 let savedHash = getStringValue(this, keyVerifyHash)
333337 let calcHash = toBase58String(sha256((toBytes(vrfHeight) + toBytes(secretWord))))
334338 if (!(isActive))
335339 then throw("DApp is inactive at this moment")
336340 else if (!(containsElement([adminPubKey1, adminPubKey2, adminPubKey3], i.callerPublicKey)))
337341 then throw("Only admin can call this function")
338342 else if ((calcHash != savedHash))
339343 then throw("vrf Height hash not matching")
340344 else {
341345 let burnAmount = getIntegerValue(this, keyTotalBurned)
342346 [Burn(swopId, burnAmount), IntegerEntry(keyFinalizeHeight, height)]
343347 }
344348 }
345349
346350
347351
348352 @Callable(i)
349353 func shutdown () = if (!(isActive))
350354 then throw("DApp already inactive")
351355 else if (!(containsElement([adminPubKey1, adminPubKey2, adminPubKey3], i.callerPublicKey)))
352356 then throw("Only admin can call this function")
353357 else [BooleanEntry(keyActive, false)]
354358
355359
356360
357361 @Callable(i)
358362 func activate () = if (isActive)
359363 then throw("DApp already active")
360364 else if (!(containsElement([adminPubKey1, adminPubKey2, adminPubKey3], i.callerPublicKey)))
361365 then throw("Only admin can call this function")
362366 else [BooleanEntry(keyActive, true)]
363367
364368
365369 @Verifier(tx)
366370 func verify () = {
367371 let multiSignedByAdmins = {
368372 let adminPubKey1Signed = if (sigVerify(tx.bodyBytes, tx.proofs[0], adminPubKey1))
369373 then 1
370374 else 0
371375 let adminPubKey2Signed = if (sigVerify(tx.bodyBytes, tx.proofs[1], adminPubKey2))
372376 then 1
373377 else 0
374378 let adminPubKey3Signed = if (sigVerify(tx.bodyBytes, tx.proofs[2], adminPubKey3))
375379 then 1
376380 else 0
377381 (((adminPubKey1Signed + adminPubKey2Signed) + adminPubKey3Signed) >= 2)
378382 }
379383 let signedByAdmin = if (if (if (sigVerify(tx.bodyBytes, tx.proofs[0], adminPubKey1))
380384 then true
381385 else sigVerify(tx.bodyBytes, tx.proofs[0], adminPubKey2))
382386 then true
383387 else sigVerify(tx.bodyBytes, tx.proofs[0], adminPubKey3))
384388 then true
385389 else sigVerify(tx.bodyBytes, tx.proofs[0], adminPubKeyStaking)
386390 match tx {
387391 case _ =>
388392 multiSignedByAdmins
389393 }
390394 }
391395

github/deemru/w8io/169f3d6 
48.97 ms