tx · 28PurJ8i8d4Yid8Go6UAUd8uNaxRP8qbpW8LQLUrwr3t 3MtCto83UgaYLqkeqUVj3apiBt6YzTHgTsf: -0.01500000 Waves 2024.12.09 19:03 [3407286] smart account 3MtCto83UgaYLqkeqUVj3apiBt6YzTHgTsf > SELF 0.00000000 Waves
{ "type": 13, "id": "28PurJ8i8d4Yid8Go6UAUd8uNaxRP8qbpW8LQLUrwr3t", "fee": 1500000, "feeAssetId": null, "timestamp": 1733760170072, "version": 2, "chainId": 84, "sender": "3MtCto83UgaYLqkeqUVj3apiBt6YzTHgTsf", "senderPublicKey": "7w98hrFimkZ4X8eVspfS6M6P1C8twEuqbXBchKv5zUkn", "proofs": [ "TYRwyyWmNqU7zxJEGqHh6Fu4bWAdL617SGF84AyHmMdmeuAqSoEMA36RCyiUDqAYhRDUmr7GTNF21chUEvAh4c3" ], "script": "base64:AAIFAAAAAAAAABcIAhIECgIICBIDCgEIEgMKAQgSAwoBCAAAADABAAAAF3N0YXRpY0tleV9vcmFjbGVBZGRyZXNzAAAAAAIAAAAUc3RhdGljX29yYWNsZUFkZHJlc3MBAAAAFHN0YXRpY0tleV9lZ2dBc3NldElkAAAAAAIAAAARc3RhdGljX2VnZ0Fzc2V0SWQBAAAAGHN0YXRpY0tleV9icmVlZGVyQWRkcmVzcwAAAAACAAAAFXN0YXRpY19icmVlZGVyQWRkcmVzcwEAAAAac3RhdGljS2V5X2luY3ViYXRvckFkZHJlc3MAAAAAAgAAABdzdGF0aWNfaW5jdWJhdG9yQWRkcmVzcwEAAAAZc3RhdGljS2V5X2JhYnlEdWNrQWRkcmVzcwAAAAACAAAAFnN0YXRpY19iYWJ5RHVja0FkZHJlc3MBAAAAGHN0YXRpY0tleV9mYXJtaW5nQWRkcmVzcwAAAAACAAAAGHN0YXRpY19mYXJtaW5nQWRkcmVzc05ldwEAAAAZc3RhdGljS2V5X2NmTWFzdGVyQWRkcmVzcwAAAAACAAAAFnN0YXRpY19jZk1hc3RlckFkZHJlc3MBA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vb2ZzAAAAAAAAAAAABQAAAApzZWNvbmRVc2VyAAAAAAAAAAABAwkAAfQAAAADCAUAAAACdHgAAAAJYm9keUJ5dGVzCQABkQAAAAIIBQAAAAJ0eAAAAAZwcm9vZnMAAAAAAAAAAAEFAAAACnNlY29uZFVzZXIAAAAAAAAAAAEDCQAB9AAAAAMIBQAAAAJ0eAAAAAlib2R5Qnl0ZXMJAAGRAAAAAggFAAAAAnR4AAAABnByb29mcwAAAAAAAAAAAgUAAAAKc2Vjb25kVXNlcgAAAAAAAAAAAQAAAAAAAAAAAAQAAAAPdGhpcmRVc2VyU2lnbmVkAwkAAfQAAAADCAUAAAACdHgAAAAJYm9keUJ5dGVzCQABkQAAAAIIBQAAAAJ0eAAAAAZwcm9vZnMAAAAAAAAAAAAFAAAACXRoaXJkVXNlcgAAAAAAAAAAAQMJAAH0AAAAAwgFAAAAAnR4AAAACWJvZHlCeXRlcwkAAZEAAAACCAUAAAACdHgAAAAGcHJvb2ZzAAAAAAAAAAABBQAAAAl0aGlyZFVzZXIAAAAAAAAAAAEDCQAB9AAAAAMIBQAAAAJ0eAAAAAlib2R5Qnl0ZXMJAAGRAAAAAggFAAAAAnR4AAAABnByb29mcwAAAAAAAAAAAgUAAAAJdGhpcmRVc2VyAAAAAAAAAAABAAAAAAAAAAAABAAAAA9zaWduYXR1cmVzQ291bnQJAABkAAAAAgkAAGQAAAACBQAAAA9maXJzdFVzZXJTaWduZWQFAAAAEHNlY29uZFVzZXJTaWduZWQFAAAAD3RoaXJkVXNlclNpZ25lZAQAAAAHJG1hdGNoMAUAAAACdHgJAABnAAAAAgUAAAAPc2lnbmF0dXJlc0NvdW50AAAAAAAAAAABTsahKA==", "height": 3407286, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: Cy3BQQPnEamPa6eW5X2CWLdPfhoBv8FkZUEDBfr72jRy Next: none Diff:
Old | New | Differences | |
---|---|---|---|
13 | 13 | func staticKey_incubatorAddress () = "static_incubatorAddress" | |
14 | 14 | ||
15 | 15 | ||
16 | - | func staticKey_babyDuckAddress () = "static_ | |
16 | + | func staticKey_babyDuckAddress () = "static_babyDuckAddress" | |
17 | 17 | ||
18 | 18 | ||
19 | 19 | func staticKey_farmingAddress () = "static_farmingAddressNew" | |
277 | 277 | let signaturesCount = ((firstUserSigned + secondUserSigned) + thirdUserSigned) | |
278 | 278 | match tx { | |
279 | 279 | case _ => | |
280 | - | (signaturesCount >= | |
280 | + | (signaturesCount >= 1) | |
281 | 281 | } | |
282 | 282 | } | |
283 | 283 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | func staticKey_oracleAddress () = "static_oracleAddress" | |
5 | 5 | ||
6 | 6 | ||
7 | 7 | func staticKey_eggAssetId () = "static_eggAssetId" | |
8 | 8 | ||
9 | 9 | ||
10 | 10 | func staticKey_breederAddress () = "static_breederAddress" | |
11 | 11 | ||
12 | 12 | ||
13 | 13 | func staticKey_incubatorAddress () = "static_incubatorAddress" | |
14 | 14 | ||
15 | 15 | ||
16 | - | func staticKey_babyDuckAddress () = "static_ | |
16 | + | func staticKey_babyDuckAddress () = "static_babyDuckAddress" | |
17 | 17 | ||
18 | 18 | ||
19 | 19 | func staticKey_farmingAddress () = "static_farmingAddressNew" | |
20 | 20 | ||
21 | 21 | ||
22 | 22 | func staticKey_cfMasterAddress () = "static_cfMasterAddress" | |
23 | 23 | ||
24 | 24 | ||
25 | 25 | func staticKey_huntAddress () = "static_huntAddress" | |
26 | 26 | ||
27 | 27 | ||
28 | 28 | func staticKey_rebirthAddress () = "static_rebirthAddress" | |
29 | 29 | ||
30 | 30 | ||
31 | 31 | func staticKey_turtleBreederAddress () = "static_turtleBreederAddress" | |
32 | 32 | ||
33 | 33 | ||
34 | 34 | func staticKey_turtleIncubatorAddress () = "static_turtleIncubatorAddress" | |
35 | 35 | ||
36 | 36 | ||
37 | 37 | func staticKey_turtleStakingAddress () = "static_turtleStakingAddress" | |
38 | 38 | ||
39 | 39 | ||
40 | 40 | func staticKey_turtleRebirthAddress () = "static_turtleRebirthAddress" | |
41 | 41 | ||
42 | 42 | ||
43 | 43 | func staticKey_capacityAddress () = "static_capacityAddress" | |
44 | 44 | ||
45 | 45 | ||
46 | 46 | func staticKey_veggFarmingAddress () = "static_veggFarmingAddress" | |
47 | 47 | ||
48 | 48 | ||
49 | 49 | func staticKey_mutantFarmingAddress () = "static_mutantFarmingAddress" | |
50 | 50 | ||
51 | 51 | ||
52 | 52 | func staticKey_felineFarmingAddress () = "static_felineStakingAddress" | |
53 | 53 | ||
54 | 54 | ||
55 | 55 | func staticKey_canineFarmingAddress () = "static_canineStakingAddress" | |
56 | 56 | ||
57 | 57 | ||
58 | 58 | func staticKey_canineBreederAddress () = "static_canineBreederAddress" | |
59 | 59 | ||
60 | 60 | ||
61 | 61 | func staticKey_felineBreederAddress () = "static_felineBreederAddress" | |
62 | 62 | ||
63 | 63 | ||
64 | 64 | func tryGetBoolean (key) = match getBoolean(this, key) { | |
65 | 65 | case b: Boolean => | |
66 | 66 | b | |
67 | 67 | case _ => | |
68 | 68 | false | |
69 | 69 | } | |
70 | 70 | ||
71 | 71 | ||
72 | 72 | func tryGetInteger (key) = match getInteger(this, key) { | |
73 | 73 | case b: Int => | |
74 | 74 | b | |
75 | 75 | case _ => | |
76 | 76 | 0 | |
77 | 77 | } | |
78 | 78 | ||
79 | 79 | ||
80 | 80 | func isValidAddress (address) = match addressFromString(address) { | |
81 | 81 | case a: Address => | |
82 | 82 | true | |
83 | 83 | case _ => | |
84 | 84 | false | |
85 | 85 | } | |
86 | 86 | ||
87 | 87 | ||
88 | 88 | func tryGetStringExternal (address,key) = match getString(address, key) { | |
89 | 89 | case a: String => | |
90 | 90 | a | |
91 | 91 | case _ => | |
92 | 92 | "" | |
93 | 93 | } | |
94 | 94 | ||
95 | 95 | ||
96 | 96 | func tryGetString (key) = tryGetStringExternal(this, key) | |
97 | 97 | ||
98 | 98 | ||
99 | 99 | func getOracle () = Address(fromBase58String(tryGetString(staticKey_oracleAddress()))) | |
100 | 100 | ||
101 | 101 | ||
102 | 102 | func getEggAssetId () = fromBase58String(tryGetStringExternal(getOracle(), staticKey_eggAssetId())) | |
103 | 103 | ||
104 | 104 | ||
105 | 105 | func getBreederAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_breederAddress()))) | |
106 | 106 | ||
107 | 107 | ||
108 | 108 | func getIncubatorAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_incubatorAddress()))) | |
109 | 109 | ||
110 | 110 | ||
111 | 111 | func getBabyDuckAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_babyDuckAddress()))) | |
112 | 112 | ||
113 | 113 | ||
114 | 114 | func getFarmingAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_farmingAddress()))) | |
115 | 115 | ||
116 | 116 | ||
117 | 117 | func getCfMasterAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_cfMasterAddress()))) | |
118 | 118 | ||
119 | 119 | ||
120 | 120 | func getHuntAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_huntAddress()))) | |
121 | 121 | ||
122 | 122 | ||
123 | 123 | func getRebirthAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_rebirthAddress()))) | |
124 | 124 | ||
125 | 125 | ||
126 | 126 | func getTurtleBreederAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_turtleBreederAddress()))) | |
127 | 127 | ||
128 | 128 | ||
129 | 129 | func getTurtleIncubatorAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_turtleIncubatorAddress()))) | |
130 | 130 | ||
131 | 131 | ||
132 | 132 | func getTurtleStakingAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_turtleStakingAddress()))) | |
133 | 133 | ||
134 | 134 | ||
135 | 135 | func getTurtleRebirthAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_turtleRebirthAddress()))) | |
136 | 136 | ||
137 | 137 | ||
138 | 138 | func getCapacityAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_capacityAddress()))) | |
139 | 139 | ||
140 | 140 | ||
141 | 141 | func getVeggFarmingAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_veggFarmingAddress()))) | |
142 | 142 | ||
143 | 143 | ||
144 | 144 | func getMutantFarmingAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_mutantFarmingAddress()))) | |
145 | 145 | ||
146 | 146 | ||
147 | 147 | func getFelineFarmingAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_felineFarmingAddress()))) | |
148 | 148 | ||
149 | 149 | ||
150 | 150 | func getCanineFarmingAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_canineFarmingAddress()))) | |
151 | 151 | ||
152 | 152 | ||
153 | 153 | func getCanineBreederAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_canineBreederAddress()))) | |
154 | 154 | ||
155 | 155 | ||
156 | 156 | func getFelineBreederAddress () = Address(fromBase58String(tryGetStringExternal(getOracle(), staticKey_felineBreederAddress()))) | |
157 | 157 | ||
158 | 158 | ||
159 | 159 | func getTrustedAddress () = [getBreederAddress(), getBabyDuckAddress(), getFarmingAddress(), getHuntAddress(), getRebirthAddress(), getTurtleBreederAddress(), getTurtleIncubatorAddress(), getTurtleStakingAddress(), getTurtleRebirthAddress(), getCapacityAddress(), getVeggFarmingAddress(), getMutantFarmingAddress(), getFelineFarmingAddress(), getCanineFarmingAddress(), getCanineBreederAddress(), getFelineBreederAddress()] | |
160 | 160 | ||
161 | 161 | ||
162 | 162 | func masterTryGetBoolean (key) = match getBoolean(getCfMasterAddress(), key) { | |
163 | 163 | case b: Boolean => | |
164 | 164 | b | |
165 | 165 | case _ => | |
166 | 166 | false | |
167 | 167 | } | |
168 | 168 | ||
169 | 169 | ||
170 | 170 | func isTestEnv () = tryGetBoolean("TESTENV") | |
171 | 171 | ||
172 | 172 | ||
173 | 173 | @Callable(i) | |
174 | 174 | func addRefKey (refererAddress,refererKey) = if ((i.caller != this)) | |
175 | 175 | then throw("admin only") | |
176 | 176 | else { | |
177 | 177 | let refStateKey = (("key_" + refererKey) + "_refererAddress") | |
178 | 178 | if ((tryGetString(refStateKey) == "")) | |
179 | 179 | then [StringEntry(refStateKey, refererAddress), StringEntry(((("address_" + refererAddress) + "_refererKey_") + refererKey), refererKey)] | |
180 | 180 | else throw((("The ref key \"" + refererKey) + "\" is already registered")) | |
181 | 181 | } | |
182 | 182 | ||
183 | 183 | ||
184 | 184 | ||
185 | 185 | @Callable(i) | |
186 | 186 | func whitelistAddress (refererAddress) = if ((i.caller != this)) | |
187 | 187 | then throw("RF: Only for admin!") | |
188 | 188 | else [BooleanEntry((refererAddress + "_whitelisted"), true)] | |
189 | 189 | ||
190 | 190 | ||
191 | 191 | ||
192 | 192 | @Callable(i) | |
193 | 193 | func refPayment (refererKey) = { | |
194 | 194 | let dao = if (isTestEnv()) | |
195 | 195 | then "3Mx9X6Dpj3thXL2So77C4DG9AmBM4WX8Mvw" | |
196 | 196 | else "3PEwRcYNAUtoFvKpBhKoiwajnZfdoDR6h4h" | |
197 | 197 | let alreadySend = tryGetInteger("dao_refund") | |
198 | 198 | let sendFundsToDao = $Tuple2([ScriptTransfer(addressFromStringValue(dao), i.payments[0].amount, i.payments[0].assetId), IntegerEntry("dao_refund", (alreadySend + i.payments[0].amount))], true) | |
199 | 199 | let referalAddress = toString(i.originCaller) | |
200 | 200 | if ((indexOf(getTrustedAddress(), i.caller) == unit)) | |
201 | 201 | then throw("RC: This method can be called only by farming and incubator dApps") | |
202 | 202 | else if (if ((refererKey == "")) | |
203 | 203 | then (tryGetString((("address_" + referalAddress) + "_referedBy")) == "") | |
204 | 204 | else false) | |
205 | 205 | then sendFundsToDao | |
206 | 206 | else if (masterTryGetBoolean(("farm_" + referalAddress))) | |
207 | 207 | then sendFundsToDao | |
208 | 208 | else { | |
209 | 209 | let givenReferer = match getString(this, (("key_" + refererKey) + "_refererAddress")) { | |
210 | 210 | case x: String => | |
211 | 211 | x | |
212 | 212 | case _ => | |
213 | 213 | refererKey | |
214 | 214 | } | |
215 | 215 | let refererAddress = match getString(this, (("address_" + referalAddress) + "_referedBy")) { | |
216 | 216 | case x: String => | |
217 | 217 | x | |
218 | 218 | case _ => | |
219 | 219 | givenReferer | |
220 | 220 | } | |
221 | 221 | let refAmount = i.payments[0].amount | |
222 | 222 | if ((i.payments[0].assetId != getEggAssetId())) | |
223 | 223 | then throw("Don't try to cheat the system!") | |
224 | 224 | else if ((tryGetBoolean((refererAddress + "_whitelisted")) == false)) | |
225 | 225 | then sendFundsToDao | |
226 | 226 | else if ((addressFromString(refererAddress) == unit)) | |
227 | 227 | then sendFundsToDao | |
228 | 228 | else { | |
229 | 229 | let refererAddressValue = addressFromStringValue(refererAddress) | |
230 | 230 | let referalAddressValue = addressFromStringValue(referalAddress) | |
231 | 231 | let paymentForReferer = refAmount | |
232 | 232 | let refererEarnedReward = (("address_" + refererAddress) + "_earnedReward") | |
233 | 233 | let referalDeliveredReward = (((("referer_" + refererAddress) + "_referal_") + referalAddress) + "_deliveredReward") | |
234 | 234 | if ((refererAddress == referalAddress)) | |
235 | 235 | then sendFundsToDao | |
236 | 236 | else $Tuple2([StringEntry((("address_" + referalAddress) + "_referedBy"), refererAddress), IntegerEntry(refererEarnedReward, (tryGetInteger(refererEarnedReward) + paymentForReferer)), IntegerEntry(referalDeliveredReward, (tryGetInteger(referalDeliveredReward) + paymentForReferer)), IntegerEntry((((("referer_" + refererAddress) + "_referal_") + referalAddress) + "_amount"), (tryGetInteger((((("referer_" + refererAddress) + "_referal_") + referalAddress) + "_amount")) + 1)), ScriptTransfer(refererAddressValue, paymentForReferer, getEggAssetId())], true) | |
237 | 237 | } | |
238 | 238 | } | |
239 | 239 | } | |
240 | 240 | ||
241 | 241 | ||
242 | 242 | ||
243 | 243 | @Callable(i) | |
244 | 244 | func configureOracle (oracle) = if ((i.caller != this)) | |
245 | 245 | then throw("RCCO: admin only") | |
246 | 246 | else [StringEntry(staticKey_oracleAddress(), oracle)] | |
247 | 247 | ||
248 | 248 | ||
249 | 249 | @Verifier(tx) | |
250 | 250 | func verify () = if (isTestEnv()) | |
251 | 251 | then sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey) | |
252 | 252 | else { | |
253 | 253 | let firstUser = base58'6TdaXEfhnjYquvPf3yV7MFxt2CbgFmaqsvGwkKfXtKi4' | |
254 | 254 | let secondUser = base58'7DsP2WaMLocbHuUxux7pbXRjTrrZ1TFQPsi5QumS3gr8' | |
255 | 255 | let thirdUser = base58'BpFWP3p3JgYrrP45xfrKzeMcWMEXoinj4FVPPkUiA8D3' | |
256 | 256 | let firstUserSigned = if (sigVerify(tx.bodyBytes, tx.proofs[0], firstUser)) | |
257 | 257 | then 1 | |
258 | 258 | else if (sigVerify(tx.bodyBytes, tx.proofs[1], firstUser)) | |
259 | 259 | then 1 | |
260 | 260 | else if (sigVerify(tx.bodyBytes, tx.proofs[2], firstUser)) | |
261 | 261 | then 1 | |
262 | 262 | else 0 | |
263 | 263 | let secondUserSigned = if (sigVerify(tx.bodyBytes, tx.proofs[0], secondUser)) | |
264 | 264 | then 1 | |
265 | 265 | else if (sigVerify(tx.bodyBytes, tx.proofs[1], secondUser)) | |
266 | 266 | then 1 | |
267 | 267 | else if (sigVerify(tx.bodyBytes, tx.proofs[2], secondUser)) | |
268 | 268 | then 1 | |
269 | 269 | else 0 | |
270 | 270 | let thirdUserSigned = if (sigVerify(tx.bodyBytes, tx.proofs[0], thirdUser)) | |
271 | 271 | then 1 | |
272 | 272 | else if (sigVerify(tx.bodyBytes, tx.proofs[1], thirdUser)) | |
273 | 273 | then 1 | |
274 | 274 | else if (sigVerify(tx.bodyBytes, tx.proofs[2], thirdUser)) | |
275 | 275 | then 1 | |
276 | 276 | else 0 | |
277 | 277 | let signaturesCount = ((firstUserSigned + secondUserSigned) + thirdUserSigned) | |
278 | 278 | match tx { | |
279 | 279 | case _ => | |
280 | - | (signaturesCount >= | |
280 | + | (signaturesCount >= 1) | |
281 | 281 | } | |
282 | 282 | } | |
283 | 283 |
github/deemru/w8io/169f3d6 31.74 ms ◑