tx · 9WBRPJvwWwNXTBp9k8ANYTRaxSxxiTmz3SyUeLW8kaZ3 3N1Nb8gVFi3S4Cvt2sBZj7XPkPiWYqKdTfp: -0.01900000 Waves 2024.10.03 11:50 [3310451] smart account 3N1Nb8gVFi3S4Cvt2sBZj7XPkPiWYqKdTfp > SELF 0.00000000 Waves
{ "type": 13, "id": "9WBRPJvwWwNXTBp9k8ANYTRaxSxxiTmz3SyUeLW8kaZ3", "fee": 1900000, "feeAssetId": null, "timestamp": 1727945426896, "version": 2, "chainId": 84, "sender": "3N1Nb8gVFi3S4Cvt2sBZj7XPkPiWYqKdTfp", "senderPublicKey": "8FVyd1UAAKDWDWsLPFgQp4THUXha3DRBmZ9ceTQMMzFk", "proofs": [ "58p14dMSUrwt76jiKyW5ASLPuEb9eRmQoDergYBs4eKxPwp5S6c15JRjuA9XQs38JvosWpBZDgJoCCafufC5TXRu" ], "script": "base64:BgIWCAISAwoBCBIDCgEIEgMKAQgSAwoBCC8BFHRyeUdldFN0cmluZ0V4dGVybmFsAgdhZGRyZXNzA2tleQQHJG1hdGNoMAkAnQgCBQdhZGRyZXNzBQNrZXkDCQABAgUHJG1hdGNoMAIGU3RyaW5nBAFhBQckbWF0Y2gwBQFhAgABDXRyeUdldEludGVnZXIBA2tleQQHJG1hdGNoMAkAmggCBQR0aGlzBQNrZXkDCQABAgUHJG1hdGNoMAIDSW50BAFiBQckbWF0Y2gwBQFiAAABDHRyeUdldFN0cmluZwEDa2V5CQEUdHJ5R2V0U3RyaW5nRXh0ZXJuYWwCBQR0aGlzBQNrZXkBBWFzSW50AQV2YWx1ZQQHJG1hdGNoMAUFdmFsdWUDCQABAgUHJG1hdGNoMAIDSW50BANpbnQFByRtYXRjaDAFA2ludAMJAAECBQckbWF0Y2gwAgZTdHJpbmcEBnN0cmluZwUHJG1hdGNoMAkAAgEJAKwCAgIpUkFJOiB3cm9uZyB0eXBlLCBleHBlY3RlZDogSW50LCBidXQgZ290OiAFBnN0cmluZwkAAgECHlJB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WUgaXMgbm90IGVxdWFsIHRvIGl0c2VsZi4BaQENZmluaXNoUmViaXJ0aAEGaW5pdFR4CQEVZmluaXNoUmViaXJ0aEludGVybmFsBAUGaW5pdFR4CQClCAEIBQFpBmNhbGxlcgkAkQMCCAUBaQhwYXltZW50cwAABwFpARNmaW5pc2hSZWJpcnRoRG91YmxlAQZpbml0VHgDCQEBIQEDCQAAAgkAkAMBCAUBaQhwYXltZW50cwACCQAAAggJAJEDAggFAWkIcGF5bWVudHMAAAZhbW91bnQAAQcJAAIBAg9JbnZhbGlkIHBheW1lbnQEB2Fzc2V0SWQJAQV2YWx1ZQEICQCRAwIIBQFpCHBheW1lbnRzAAAHYXNzZXRJZAQLYm9vc3RlclR5cGUJAQhhc1N0cmluZwEJAPwHBAkBD2dldEl0ZW1zQWRkcmVzcwACFGNoZWNrQXJ0ZWZhY3REZXRhaWxzCQDMCAIJANgEAQUHYXNzZXRJZAUDbmlsBQNuaWwDCQAAAgULYm9vc3RlclR5cGUFC2Jvb3N0ZXJUeXBlAwkAAAIFC2Jvb3N0ZXJUeXBlAg5BUlQtR0lGVF9ET1VCTAkAzggCCQDMCAIJAQRCdXJuAgUHYXNzZXRJZAABBQNuaWwJARVmaW5pc2hSZWJpcnRoSW50ZXJuYWwEBQZpbml0VHgJAKUIAQgFAWkGY2FsbGVyCQCRAwIIBQFpCHBheW1lbnRzAAEGCQACAQItRXJyb3IhIFdyb25nIGl0ZW0gYXR0YWNoZWQgdG8gZG91YmxlIHJld2FyZHMhCQACAQIkU3RyaWN0IHZhbHVlIGlzIG5vdCBlcXVhbCB0byBpdHNlbGYuAGNbbyk=", "height": 3310451, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: none Next: 4eNK2nKeRnFW6PuNpn6GrwLa73KAcy2gcjJ4RdouAyZv Full:
Old | New | Differences | |
---|---|---|---|
1 | - | # no script | |
1 | + | {-# STDLIB_VERSION 6 #-} | |
2 | + | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | + | {-# CONTENT_TYPE DAPP #-} | |
4 | + | func tryGetStringExternal (address,key) = match getString(address, key) { | |
5 | + | case a: String => | |
6 | + | a | |
7 | + | case _ => | |
8 | + | "" | |
9 | + | } | |
10 | + | ||
11 | + | ||
12 | + | func tryGetInteger (key) = match getInteger(this, key) { | |
13 | + | case b: Int => | |
14 | + | b | |
15 | + | case _ => | |
16 | + | 0 | |
17 | + | } | |
18 | + | ||
19 | + | ||
20 | + | func tryGetString (key) = tryGetStringExternal(this, key) | |
21 | + | ||
22 | + | ||
23 | + | func asInt (value) = match value { | |
24 | + | case int: Int => | |
25 | + | int | |
26 | + | case string: String => | |
27 | + | throw(("RAI: wrong type, expected: Int, but got: " + string)) | |
28 | + | case _ => | |
29 | + | throw("RAI: wrong type, expected: Int") | |
30 | + | } | |
31 | + | ||
32 | + | ||
33 | + | func asBoolean (value) = match value { | |
34 | + | case boolean: Boolean => | |
35 | + | boolean | |
36 | + | case _ => | |
37 | + | throw("FAB: wrong type, expected: Boolean") | |
38 | + | } | |
39 | + | ||
40 | + | ||
41 | + | func asString (value) = match value { | |
42 | + | case s: String => | |
43 | + | s | |
44 | + | case s: Int => | |
45 | + | throw("wrong type, expected: String, got: Int") | |
46 | + | case s: Unit => | |
47 | + | throw("wrong type, expected: String, got: Unit") | |
48 | + | case _ => | |
49 | + | throw("wrong type, expected: String") | |
50 | + | } | |
51 | + | ||
52 | + | ||
53 | + | func staticKey_oracleAddress () = "static_oracleAddress" | |
54 | + | ||
55 | + | ||
56 | + | func staticKey_eggAssetId () = "static_eggAssetId" | |
57 | + | ||
58 | + | ||
59 | + | func staticKey_burnAddress () = "static_burnAddress" | |
60 | + | ||
61 | + | ||
62 | + | func staticKey_extraFee () = "static_extraFee" | |
63 | + | ||
64 | + | ||
65 | + | func staticKey_feeAggregator () = "static_feeAggregator" | |
66 | + | ||
67 | + | ||
68 | + | func staticKey_turtleIncubatorAddress () = "static_turtleIncubatorAddress" | |
69 | + | ||
70 | + | ||
71 | + | func staticKey_turtleBreederAddress () = "static_turtleBreederAddress" | |
72 | + | ||
73 | + | ||
74 | + | func staticKey_spiceAssetId () = "static_spiceAssetId" | |
75 | + | ||
76 | + | ||
77 | + | func staticKey_refContractAddress () = "static_refContractAddress" | |
78 | + | ||
79 | + | ||
80 | + | func staticKey_couponsAddress () = "static_couponsAddress" | |
81 | + | ||
82 | + | ||
83 | + | func staticKey_turtleStakingAddress () = "static_turtleStakingAddress" | |
84 | + | ||
85 | + | ||
86 | + | func staticKey_duckStakingAddress () = "static_farmingAddressNew" | |
87 | + | ||
88 | + | ||
89 | + | func staticKey_duckIncubatorAddress () = "static_incubatorAddress" | |
90 | + | ||
91 | + | ||
92 | + | func staticKey_itemsAddress () = "static_itemsAddress" | |
93 | + | ||
94 | + | ||
95 | + | func staticKey_turtleSpiceRebirthPrice () = "static_turtleSpiceRebirthPrice" | |
96 | + | ||
97 | + | ||
98 | + | func staticKey_turtleWavesRebirthPrice () = "static_turtleWavesRebirthPrice" | |
99 | + | ||
100 | + | ||
101 | + | func staticKey_turtleEggRebirthPrice () = "static_turtleEggRebirthPrice" | |
102 | + | ||
103 | + | ||
104 | + | func getOracle () = Address(fromBase58String(tryGetString(staticKey_oracleAddress()))) | |
105 | + | ||
106 | + | ||
107 | + | func getEggAssetId () = fromBase58String(tryGetStringExternal(getOracle(), staticKey_eggAssetId())) | |
108 | + | ||
109 | + | ||
110 | + | func getBurnAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_burnAddress()))) | |
111 | + | ||
112 | + | ||
113 | + | func getFeeAggregator () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_feeAggregator()))) | |
114 | + | ||
115 | + | ||
116 | + | func getTurtleBreederAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_turtleBreederAddress()))) | |
117 | + | ||
118 | + | ||
119 | + | func getTurtleIncubatorAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_turtleIncubatorAddress()))) | |
120 | + | ||
121 | + | ||
122 | + | func getSpiceAssetId () = fromBase58String(tryGetStringExternal(getOracle(), staticKey_spiceAssetId())) | |
123 | + | ||
124 | + | ||
125 | + | func getRefContractAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_refContractAddress()))) | |
126 | + | ||
127 | + | ||
128 | + | func getCouponsAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_couponsAddress()))) | |
129 | + | ||
130 | + | ||
131 | + | func getTurtleStakingAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_turtleStakingAddress()))) | |
132 | + | ||
133 | + | ||
134 | + | func getDuckStakingAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_duckStakingAddress()))) | |
135 | + | ||
136 | + | ||
137 | + | func getDuckIncubatorAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_duckIncubatorAddress()))) | |
138 | + | ||
139 | + | ||
140 | + | func getItemsAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_itemsAddress()))) | |
141 | + | ||
142 | + | ||
143 | + | func tryGetIntegerExternal (address,key) = match getInteger(address, key) { | |
144 | + | case b: Int => | |
145 | + | b | |
146 | + | case _ => | |
147 | + | throw("TR: Value not found in sc!") | |
148 | + | } | |
149 | + | ||
150 | + | ||
151 | + | let spiceAmount = tryGetIntegerExternal(getOracle(), staticKey_turtleSpiceRebirthPrice()) | |
152 | + | ||
153 | + | let eggAmount = tryGetIntegerExternal(getOracle(), staticKey_turtleEggRebirthPrice()) | |
154 | + | ||
155 | + | let wavesAmount = tryGetIntegerExternal(getOracle(), staticKey_turtleWavesRebirthPrice()) | |
156 | + | ||
157 | + | let delayForHatching = 2 | |
158 | + | ||
159 | + | func checkRealTurtle (assetId) = if (if ((value(assetInfo(assetId)).issuer == getTurtleBreederAddress())) | |
160 | + | then true | |
161 | + | else (value(assetInfo(assetId)).issuer == getTurtleIncubatorAddress())) | |
162 | + | then true | |
163 | + | else throw("not valid NFT") | |
164 | + | ||
165 | + | ||
166 | + | func checkAdditionalPayment (payment) = if (isDefined(payment.assetId)) | |
167 | + | then throw("RCAP: Please attach waves") | |
168 | + | else { | |
169 | + | let feeAmount = getIntegerValue(getOracle(), staticKey_extraFee()) | |
170 | + | if ((payment.amount != feeAmount)) | |
171 | + | then throw((("RCAP: Please attach exactly " + toString(feeAmount)) + " amount of wavelets")) | |
172 | + | else [ScriptTransfer(getFeeAggregator(), feeAmount, unit)] | |
173 | + | } | |
174 | + | ||
175 | + | ||
176 | + | func getRandomNumber (options,txId,hatchingFinishHeight,offset) = { | |
177 | + | let randomSeedBlock = value(blockInfoByHeight((hatchingFinishHeight - 1))) | |
178 | + | let randomHash = sha256((txId + value(randomSeedBlock.vrf))) | |
179 | + | (toInt(randomHash, (offset * 8)) % options) | |
180 | + | } | |
181 | + | ||
182 | + | ||
183 | + | func tryGetBoolean (key) = match getBoolean(key) { | |
184 | + | case b: Boolean => | |
185 | + | b | |
186 | + | case _ => | |
187 | + | false | |
188 | + | } | |
189 | + | ||
190 | + | ||
191 | + | func getRandomWin (tx,finishHeight) = { | |
192 | + | let jackpotEnabled = tryGetBoolean("JACKPOT_ENABLED") | |
193 | + | let jackpotRandom = getRandomNumber(300, tx, finishHeight, 1) | |
194 | + | if (if ((jackpotRandom == 1)) | |
195 | + | then jackpotEnabled | |
196 | + | else false) | |
197 | + | then $Tuple2(jackpotRandom, "jackpot") | |
198 | + | else { | |
199 | + | let n = getRandomNumber(1000, tx, finishHeight, 0) | |
200 | + | let result = if ((40 > n)) | |
201 | + | then "item!ART-FIRE_SHIELD" | |
202 | + | else if ((80 > n)) | |
203 | + | then "item!ART-FIRE_TAIL" | |
204 | + | else if ((100 > n)) | |
205 | + | then "item!ART-FREEGENE" | |
206 | + | else if ((150 > n)) | |
207 | + | then "beach_R" | |
208 | + | else if ((200 > n)) | |
209 | + | then "beach_S" | |
210 | + | else if ((250 > n)) | |
211 | + | then "beach_G" | |
212 | + | else if ((300 > n)) | |
213 | + | then "beach_D" | |
214 | + | else if ((380 > n)) | |
215 | + | then "item!ART-MUTARIUM-G" | |
216 | + | else if ((400 > n)) | |
217 | + | then "item!ART-FEED5" | |
218 | + | else if ((600 > n)) | |
219 | + | then "item!ART-FEED10" | |
220 | + | else if ((620 > n)) | |
221 | + | then "item!ART-FEED15" | |
222 | + | else if ((640 > n)) | |
223 | + | then "item!ART-FEED20" | |
224 | + | else if ((660 > n)) | |
225 | + | then "item!ART-FEED25" | |
226 | + | else if ((680 > n)) | |
227 | + | then "item!ART-FEED50" | |
228 | + | else if ((760 > n)) | |
229 | + | then "item!ART-FEED100" | |
230 | + | else if ((780 > n)) | |
231 | + | then "perch_G" | |
232 | + | else if ((800 > n)) | |
233 | + | then "perch_Y" | |
234 | + | else if ((820 > n)) | |
235 | + | then "perch_R" | |
236 | + | else if ((840 > n)) | |
237 | + | then "perch_B" | |
238 | + | else if ((880 > n)) | |
239 | + | then "item!ART-MUTARIUM-D" | |
240 | + | else if ((940 > n)) | |
241 | + | then "incubator" | |
242 | + | else "duck_incubator" | |
243 | + | $Tuple2(n, result) | |
244 | + | } | |
245 | + | } | |
246 | + | ||
247 | + | ||
248 | + | func finishRebirthInternal (initTx,address,additionalPayment,double) = { | |
249 | + | let finishBlock = tryGetInteger((((("address_" + address) + "_initTx_") + initTx) + "_finishBlock")) | |
250 | + | let status = tryGetString((((("address_" + address) + "_initTx_") + initTx) + "_status")) | |
251 | + | let validPayment = checkAdditionalPayment(additionalPayment) | |
252 | + | if ((validPayment == validPayment)) | |
253 | + | then { | |
254 | + | let recordAction = invoke(getCouponsAddress(), "recordAction", ["REBIRTHTURTLE"], nil) | |
255 | + | if ((recordAction == recordAction)) | |
256 | + | then if ((status != "open")) | |
257 | + | then throw("rebirth is finished or not open") | |
258 | + | else if ((finishBlock > height)) | |
259 | + | then throw("you cannot finish rebirth, yet") | |
260 | + | else { | |
261 | + | let output = getRandomWin(fromBase58String(initTx), finishBlock) | |
262 | + | let win = output._2 | |
263 | + | let random = output._1 | |
264 | + | let txId = initTx | |
265 | + | let result = if ((indexOf(win, "perch") != unit)) | |
266 | + | then { | |
267 | + | let color = takeRight(win, 1) | |
268 | + | let call = if (!(double)) | |
269 | + | then { | |
270 | + | let first = invoke(getDuckStakingAddress(), "addFreePerch", [address, color, 1], nil) | |
271 | + | if ((first == first)) | |
272 | + | then [StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_result"), asString(first))] | |
273 | + | else throw("Strict value is not equal to itself.") | |
274 | + | } | |
275 | + | else { | |
276 | + | let first = invoke(getDuckStakingAddress(), "addFreePerch", [address, color, 2], nil) | |
277 | + | if ((first == first)) | |
278 | + | then [StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_result"), asString(first)), StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_result1"), asString(first)), StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_win1"), win)] | |
279 | + | else throw("Strict value is not equal to itself.") | |
280 | + | } | |
281 | + | if ((call == call)) | |
282 | + | then call | |
283 | + | else throw("Strict value is not equal to itself.") | |
284 | + | } | |
285 | + | else if ((indexOf(win, "beach") != unit)) | |
286 | + | then { | |
287 | + | let color = takeRight(win, 1) | |
288 | + | let call = if (!(double)) | |
289 | + | then { | |
290 | + | let first = invoke(getTurtleStakingAddress(), "addFreeBeach", [address, color], nil) | |
291 | + | if ((first == first)) | |
292 | + | then [StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_result"), asString(first))] | |
293 | + | else throw("Strict value is not equal to itself.") | |
294 | + | } | |
295 | + | else { | |
296 | + | let first = invoke(getTurtleStakingAddress(), "addFreeBeach", [address, color], nil) | |
297 | + | if ((first == first)) | |
298 | + | then { | |
299 | + | let second = invoke(getTurtleStakingAddress(), "addFreeBeach", [address, color], nil) | |
300 | + | if ((second == second)) | |
301 | + | then [StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_result"), asString(first)), StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_result1"), asString(second)), StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_win1"), win)] | |
302 | + | else throw("Strict value is not equal to itself.") | |
303 | + | } | |
304 | + | else throw("Strict value is not equal to itself.") | |
305 | + | } | |
306 | + | if ((call == call)) | |
307 | + | then call | |
308 | + | else throw("Strict value is not equal to itself.") | |
309 | + | } | |
310 | + | else if ((win == "jackpot")) | |
311 | + | then { | |
312 | + | let call = invoke(getTurtleIncubatorAddress(), "issueJackpot", [address, txId, valueOrElse(getString("JACKPOT_NAME"), "WWWWXMAS")], nil) | |
313 | + | if ((call == call)) | |
314 | + | then [StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_result"), asString(call))] | |
315 | + | else throw("Strict value is not equal to itself.") | |
316 | + | } | |
317 | + | else if ((win == "incubator")) | |
318 | + | then { | |
319 | + | let call = if (!(double)) | |
320 | + | then { | |
321 | + | let first = invoke(getTurtleIncubatorAddress(), "issueFreeTurtle", [address, txId], nil) | |
322 | + | if ((first == first)) | |
323 | + | then [StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_result"), asString(first))] | |
324 | + | else throw("Strict value is not equal to itself.") | |
325 | + | } | |
326 | + | else { | |
327 | + | let first = invoke(getTurtleIncubatorAddress(), "issueFreeTurtle", [address, txId], nil) | |
328 | + | if ((first == first)) | |
329 | + | then { | |
330 | + | let second = invoke(getDuckIncubatorAddress(), "issueFreeDuckDefinedGenes", [address, txId, "ZZZZZZZZ"], nil) | |
331 | + | if ((second == second)) | |
332 | + | then [StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_result"), asString(first)), StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_result1"), asString(second)), StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_win1"), "duck_incubator")] | |
333 | + | else throw("Strict value is not equal to itself.") | |
334 | + | } | |
335 | + | else throw("Strict value is not equal to itself.") | |
336 | + | } | |
337 | + | if ((call == call)) | |
338 | + | then call | |
339 | + | else throw("Strict value is not equal to itself.") | |
340 | + | } | |
341 | + | else if ((win == "duck_incubator")) | |
342 | + | then { | |
343 | + | let call = if (!(double)) | |
344 | + | then { | |
345 | + | let first = invoke(getDuckIncubatorAddress(), "issueFreeDuckDefinedGenes", [address, txId, "ZZZZZZZZ"], nil) | |
346 | + | if ((first == first)) | |
347 | + | then [StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_result"), asString(first))] | |
348 | + | else throw("Strict value is not equal to itself.") | |
349 | + | } | |
350 | + | else { | |
351 | + | let first = invoke(getDuckIncubatorAddress(), "issueFreeDuckDefinedGenes", [address, txId, "ZZZZZZZZ"], nil) | |
352 | + | if ((first == first)) | |
353 | + | then { | |
354 | + | let second = invoke(getTurtleIncubatorAddress(), "issueFreeTurtle", [address, txId], nil) | |
355 | + | if ((second == second)) | |
356 | + | then [StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_result"), asString(first)), StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_result1"), asString(second)), StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_win1"), "incubator")] | |
357 | + | else throw("Strict value is not equal to itself.") | |
358 | + | } | |
359 | + | else throw("Strict value is not equal to itself.") | |
360 | + | } | |
361 | + | if ((call == call)) | |
362 | + | then call | |
363 | + | else throw("Strict value is not equal to itself.") | |
364 | + | } | |
365 | + | else if ((indexOf(win, "item") != unit)) | |
366 | + | then { | |
367 | + | let itemName = split(win, "!")[1] | |
368 | + | let call = if (!(double)) | |
369 | + | then { | |
370 | + | let first = invoke(getItemsAddress(), "issueArtefactIndex", [itemName, address, 0], nil) | |
371 | + | if ((first == first)) | |
372 | + | then [StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_result"), asString(first))] | |
373 | + | else throw("Strict value is not equal to itself.") | |
374 | + | } | |
375 | + | else { | |
376 | + | let first = invoke(getItemsAddress(), "issueArtefactIndex", [itemName, address, 0], nil) | |
377 | + | if ((first == first)) | |
378 | + | then { | |
379 | + | let second = invoke(getItemsAddress(), "issueArtefactIndex", [itemName, address, 1], nil) | |
380 | + | if ((second == second)) | |
381 | + | then [StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_result"), asString(first)), StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_result1"), asString(second)), StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_win1"), win)] | |
382 | + | else throw("Strict value is not equal to itself.") | |
383 | + | } | |
384 | + | else throw("Strict value is not equal to itself.") | |
385 | + | } | |
386 | + | if ((call == call)) | |
387 | + | then call | |
388 | + | else throw("Strict value is not equal to itself.") | |
389 | + | } | |
390 | + | else throw("RFB: Some error occured, please contact the admins!") | |
391 | + | ((result ++ [StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_win"), win), StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_status"), "finish"), IntegerEntry((((("address_" + address) + "_initTx_") + initTx) + "_random"), random)]) ++ validPayment) | |
392 | + | } | |
393 | + | else throw("Strict value is not equal to itself.") | |
394 | + | } | |
395 | + | else throw("Strict value is not equal to itself.") | |
396 | + | } | |
397 | + | ||
398 | + | ||
399 | + | @Callable(i) | |
400 | + | func configureOracle (oracle) = if ((i.caller != this)) | |
401 | + | then throw("RCU: admin only") | |
402 | + | else [StringEntry("static_oracleAddress", oracle)] | |
403 | + | ||
404 | + | ||
405 | + | ||
406 | + | @Callable(i) | |
407 | + | func initRebirth (refererAddress) = { | |
408 | + | let pmtTurtle = i.payments[0] | |
409 | + | let pmtWaves = i.payments[1] | |
410 | + | let pmtSpice = i.payments[2] | |
411 | + | let assetId = value(pmtTurtle.assetId) | |
412 | + | let initTx = toBase58String(i.transactionId) | |
413 | + | let address = toString(i.caller) | |
414 | + | if ((pmtTurtle.amount != 1)) | |
415 | + | then throw("NFT is not attached") | |
416 | + | else if (if ((pmtWaves.amount != wavesAmount)) | |
417 | + | then true | |
418 | + | else (pmtWaves.assetId != unit)) | |
419 | + | then throw("Wavespayment is not attached or wrong!") | |
420 | + | else if (if ((pmtSpice.amount != spiceAmount)) | |
421 | + | then true | |
422 | + | else (pmtSpice.assetId != getSpiceAssetId())) | |
423 | + | then throw("SpicePayment is not attached or wrong!") | |
424 | + | else { | |
425 | + | let amountPaidByCoupons = asInt(invoke(getCouponsAddress(), "useCoupons", [eggAmount], nil)) | |
426 | + | if ((amountPaidByCoupons == amountPaidByCoupons)) | |
427 | + | then { | |
428 | + | let leftToPay = (eggAmount - amountPaidByCoupons) | |
429 | + | let topup = invoke(getTurtleStakingAddress(), "topUpReward", nil, [AttachedPayment(getSpiceAssetId(), pmtSpice.amount)]) | |
430 | + | if ((topup == topup)) | |
431 | + | then { | |
432 | + | let payment = if ((leftToPay != 0)) | |
433 | + | then { | |
434 | + | let pmtEgg = i.payments[3] | |
435 | + | let feePayment = value(pmtEgg) | |
436 | + | if ((feePayment.assetId != getEggAssetId())) | |
437 | + | then throw("You need to attach EGG tokens as fee") | |
438 | + | else if ((feePayment.amount != leftToPay)) | |
439 | + | then throw(("You need to attach the following amount of EGG tokens as fee: 0." + toString(leftToPay))) | |
440 | + | else { | |
441 | + | let refererRewardForPerch = fraction(leftToPay, 5, 100) | |
442 | + | let refCall = asBoolean(invoke(getRefContractAddress(), "refPayment", [refererAddress], [AttachedPayment(getEggAssetId(), refererRewardForPerch)])) | |
443 | + | if ((refCall == refCall)) | |
444 | + | then { | |
445 | + | let toBurn = if (refCall) | |
446 | + | then (leftToPay - refererRewardForPerch) | |
447 | + | else leftToPay | |
448 | + | let burnCall = invoke(getBurnAddress(), "burnAttachedPayments", nil, [AttachedPayment(getEggAssetId(), toBurn)]) | |
449 | + | if ((burnCall == burnCall)) | |
450 | + | then leftToPay | |
451 | + | else throw("Strict value is not equal to itself.") | |
452 | + | } | |
453 | + | else throw("Strict value is not equal to itself.") | |
454 | + | } | |
455 | + | } | |
456 | + | else 0 | |
457 | + | if ((payment == payment)) | |
458 | + | then { | |
459 | + | let realTurtle = checkRealTurtle(assetId) | |
460 | + | if ((realTurtle == realTurtle)) | |
461 | + | then [IntegerEntry((((("address_" + address) + "_initTx_") + initTx) + "_finishBlock"), (height + delayForHatching)), StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_status"), "open"), StringEntry((((("address_" + address) + "_initTx_") + initTx) + "_assetId"), toBase58String(assetId)), ScriptTransfer(getFeeAggregator(), pmtWaves.amount, unit)] | |
462 | + | else throw("Strict value is not equal to itself.") | |
463 | + | } | |
464 | + | else throw("Strict value is not equal to itself.") | |
465 | + | } | |
466 | + | else throw("Strict value is not equal to itself.") | |
467 | + | } | |
468 | + | else throw("Strict value is not equal to itself.") | |
469 | + | } | |
470 | + | } | |
471 | + | ||
472 | + | ||
473 | + | ||
474 | + | @Callable(i) | |
475 | + | func finishRebirth (initTx) = finishRebirthInternal(initTx, toString(i.caller), i.payments[0], false) | |
476 | + | ||
477 | + | ||
478 | + | ||
479 | + | @Callable(i) | |
480 | + | func finishRebirthDouble (initTx) = if (!(if ((size(i.payments) == 2)) | |
481 | + | then (i.payments[0].amount == 1) | |
482 | + | else false)) | |
483 | + | then throw("Invalid payment") | |
484 | + | else { | |
485 | + | let assetId = value(i.payments[0].assetId) | |
486 | + | let boosterType = asString(invoke(getItemsAddress(), "checkArtefactDetails", [toBase58String(assetId)], nil)) | |
487 | + | if ((boosterType == boosterType)) | |
488 | + | then if ((boosterType == "ART-GIFT_DOUBL")) | |
489 | + | then ([Burn(assetId, 1)] ++ finishRebirthInternal(initTx, toString(i.caller), i.payments[1], true)) | |
490 | + | else throw("Error! Wrong item attached to double rewards!") | |
491 | + | else throw("Strict value is not equal to itself.") | |
492 | + | } | |
493 | + | ||
494 | + |
github/deemru/w8io/026f985 35.23 ms ◑