tx · 29DHVjpK6WqrGyFhzLeHQCxEEWbzJzzkp8s9aRfRM1nt 3NBPx1Fciu3JQNEGZ21jSnTdutLNGGBUSXh: -0.01600000 Waves 2024.10.25 19:13 [3342591] smart account 3NBPx1Fciu3JQNEGZ21jSnTdutLNGGBUSXh > SELF 0.00000000 Waves
{ "type": 13, "id": "29DHVjpK6WqrGyFhzLeHQCxEEWbzJzzkp8s9aRfRM1nt", "fee": 1600000, "feeAssetId": null, "timestamp": 1729872791824, "version": 2, "chainId": 84, "sender": "3NBPx1Fciu3JQNEGZ21jSnTdutLNGGBUSXh", "senderPublicKey": "3QtfC1XbLZXdeawMDeSERy9vvjUmj1XYd2GFmrvx7pWQ", "proofs": [ "65D1Zn82YdXbapznJAvuXp9LXNSYWxTDs3QS1fb5dcgh8uREZuXiiyZMsxaurssHCpmnWxFLktH8WGqFkkzMsF5v" ], "script": "base64:BgI7CAISBAoCCAgSBAoCCAESAwoBBBIDCgEBEgASABIDCgEBEgASBAoCCAESABIDCgEIEgMKAQgSBAoCCAE3AANTRVACAl9fAAVNVUxUNgDAhD0ABU1VTFQ3AICt4gQABU1VTFQ4AIDC1y8ACkRBWV9NSUxMSVMAgLiZKQAVVVNEVDJBQ1JFU19NVUxUSVBMSUVSAAoAE0FDUkVTX0xJTUlUX0RJVklTT1IACgAFY2hhaW4JAMkBAgkAygECCAUEdGhpcwVieXRlcwABAAEAC3VzZHRBc3NldElkBAckbWF0Y2gwBQVjaGFpbgMJAAACAQFXBQckbWF0Y2gwASCE2nqyCAM/TtG7yo7ui5O8yYLdC136B5ao1CP5qA//uQMJAAACAQFUBQckbWF0Y2gwASBVsdifcoeC7+XjW42sBatl3ppDoS8WuwXzGreHpfHFGAkAAgECDVVua25vd24gY2hhaW4AFmRlZmF1bHRSZXN0MkFkZHJlc3NTdHIEByRtYXRjaDAFBWNoYWluAwkAAAIBAVcFByRtYXRjaDACIzNQRndZdGE4YmlFejMxenBlRmU1REpLOHdFNXRyU3BRVkY4AwkAAA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HIBaQEac2ltdWxhdGVTdGFrZUFjcmVzUkVBRE9OTFkCB2FkZHJlc3MLYWRkZWRBbW91bnQECWFtb3VudEtleQkBF2tleUFjcmVzU3Rha2VkQW10QnlVc2VyAQUHYWRkcmVzcwQObmV3QWNyZXNBbW91bnQJAGQCCQELdmFsdWVPckVsc2UCCQCfCAEFCWFtb3VudEtleQAABQthZGRlZEFtb3VudAQIb2xkVG90YWwJAQt2YWx1ZU9yRWxzZQIJAJ8IAQUSYWNyZXNTdGFrZFRvdGFsS2V5AAAECXVzZXJGcEtleQkBFWtleUZhcm1pbmdQb3dlckJ5VXNlcgEFB2FkZHJlc3MEBW9sZEZwCQELdmFsdWVPckVsc2UCCQCfCAEFCXVzZXJGcEtleQAABAVuZXdGcAkBFmdldEZhcm1pbmdQb3dlckJ5QWNyZXMBBQ5uZXdBY3Jlc0Ftb3VudAQKb2xkVG90YWxGcAkBC3ZhbHVlT3JFbHNlAgkAnwgBBRR0b3RhbEZhcm1pbmdQb3dlcktleQAABApuZXdUb3RhbEZwCQBkAgkAZQIFCm9sZFRvdGFsRnAFBW9sZEZwBQVuZXdGcAkAlAoCBQNuaWwJAMwIAgUFb2xkRnAJAMwIAgUFbmV3RnAJAMwIAgUKb2xkVG90YWxGcAkAzAgCBQpuZXdUb3RhbEZwBQNuaWwAOYWQ4A==", "height": 3342591, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: GVi6WuHrgeKrY4qHr1Frevp3Z3jbVwSibLHicxWo4DHK Next: 9VbFXUAxkJK5AKkMxcBzGVnxGQsmcdVQBT7USN2rqoos Diff:
Old | New | Differences | |
---|---|---|---|
366 | 366 | else { | |
367 | 367 | let acresAmount = (usdtAmount * USDT2ACRES_MULTIPLIER) | |
368 | 368 | let wlgToBurn = fraction(usdtAmount, MULT8, getWlgPrice(usdtAmount)) | |
369 | - | $Tuple2(nil, [acresAmount, wlgToBurn]) | |
369 | + | $Tuple2(nil, [acresAmount, acresAmount, wlgToBurn]) | |
370 | 370 | } | |
371 | 371 | ||
372 | 372 | ||
406 | 406 | else { | |
407 | 407 | let maxAcres = getSwapLimitAcres(address) | |
408 | 408 | let usdtAmount = ((acresAmount / USDT2ACRES_MULTIPLIER) / 2) | |
409 | - | $Tuple2(nil, [usdtAmount, maxAcres]) | |
409 | + | $Tuple2(nil, [usdtAmount, maxAcres, 0]) | |
410 | 410 | } | |
411 | 411 | ||
412 | 412 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let SEP = "__" | |
5 | 5 | ||
6 | 6 | let MULT6 = 1000000 | |
7 | 7 | ||
8 | 8 | let MULT7 = 10000000 | |
9 | 9 | ||
10 | 10 | let MULT8 = 100000000 | |
11 | 11 | ||
12 | 12 | let DAY_MILLIS = 86400000 | |
13 | 13 | ||
14 | 14 | let USDT2ACRES_MULTIPLIER = 10 | |
15 | 15 | ||
16 | 16 | let ACRES_LIMIT_DIVISOR = 10 | |
17 | 17 | ||
18 | 18 | let chain = take(drop(this.bytes, 1), 1) | |
19 | 19 | ||
20 | 20 | let usdtAssetId = match chain { | |
21 | 21 | case _ => | |
22 | 22 | if ((base58'2W' == $match0)) | |
23 | 23 | then base58'9wc3LXNA4TEBsXyKtoLE9mrbDD7WMHXvXrCjZvabLAsi' | |
24 | 24 | else if ((base58'2T' == $match0)) | |
25 | 25 | then base58'6mWwf9mZBjVgkC54idpyaZLQfAosD914wT8fGf2iiY63' | |
26 | 26 | else throw("Unknown chain") | |
27 | 27 | } | |
28 | 28 | ||
29 | 29 | let defaultRest2AddressStr = match chain { | |
30 | 30 | case _ => | |
31 | 31 | if ((base58'2W' == $match0)) | |
32 | 32 | then "3PFwYta8biEz31zpeFe5DJK8wE5trSpQVF8" | |
33 | 33 | else if ((base58'2T' == $match0)) | |
34 | 34 | then "3N7UuYar6264P58FBhVWKPQAh4Yua2hgngv" | |
35 | 35 | else throw("Unknown chain") | |
36 | 36 | } | |
37 | 37 | ||
38 | 38 | let arbitrageDelay = match chain { | |
39 | 39 | case _ => | |
40 | 40 | if ((base58'2W' == $match0)) | |
41 | 41 | then DAY_MILLIS | |
42 | 42 | else if ((base58'2T' == $match0)) | |
43 | 43 | then 60000 | |
44 | 44 | else throw("Unknown chain") | |
45 | 45 | } | |
46 | 46 | ||
47 | 47 | let oldStakingContractStr = match chain { | |
48 | 48 | case _ => | |
49 | 49 | if ((base58'2W' == $match0)) | |
50 | 50 | then "3PLncXtS1U83D6cQbFD3H8rBHPLgzxSFKZ1" | |
51 | 51 | else if ((base58'2T' == $match0)) | |
52 | 52 | then "3NDCyBG5q85JuaRiigUeEtainyjCQT3XpZm" | |
53 | 53 | else throw("Unknown chain") | |
54 | 54 | } | |
55 | 55 | ||
56 | 56 | func getStringOrFail (address,key) = valueOrErrorMessage(getString(address, key), makeString(["mandatory ", toString(address), ".", key, " is not defined"], "")) | |
57 | 57 | ||
58 | 58 | ||
59 | 59 | let IdxCfgAcres2Dapp = 1 | |
60 | 60 | ||
61 | 61 | let IdxCfgWlgDapp = 2 | |
62 | 62 | ||
63 | 63 | let IdxCfgInvestFundDapp = 5 | |
64 | 64 | ||
65 | 65 | func keyRestCfg () = "%s__restConfig" | |
66 | 66 | ||
67 | 67 | ||
68 | 68 | func keyRest2Address () = "%s__rest2Addr" | |
69 | 69 | ||
70 | 70 | ||
71 | 71 | func readRestCfgOrFail (rest) = split_4C(getStringOrFail(rest, keyRestCfg()), SEP) | |
72 | 72 | ||
73 | 73 | ||
74 | 74 | func getContractAddressOrFail (rest2Cfg,idx) = valueOrErrorMessage(addressFromString(rest2Cfg[idx]), ("Rest cfg doesn't contain address at index " + toString(idx))) | |
75 | 75 | ||
76 | 76 | ||
77 | 77 | let rest2Contract = addressFromStringValue(valueOrElse(getString(this, keyRest2Address()), defaultRest2AddressStr)) | |
78 | 78 | ||
79 | 79 | let rest2Cfg = readRestCfgOrFail(rest2Contract) | |
80 | 80 | ||
81 | 81 | let acres2Contract = getContractAddressOrFail(rest2Cfg, IdxCfgAcres2Dapp) | |
82 | 82 | ||
83 | 83 | let wlgContract = getContractAddressOrFail(rest2Cfg, IdxCfgWlgDapp) | |
84 | 84 | ||
85 | 85 | let investFundContract = getContractAddressOrFail(rest2Cfg, IdxCfgInvestFundDapp) | |
86 | 86 | ||
87 | 87 | let oldAcresContractKey = "oldAcresContract" | |
88 | 88 | ||
89 | 89 | func keyBlocked () = "contractsBlocked" | |
90 | 90 | ||
91 | 91 | ||
92 | 92 | func keyLastTxIdByUser (addr) = ("lastTxIdByUser_" + addr) | |
93 | 93 | ||
94 | 94 | ||
95 | 95 | let acresIssuedAmountKey = "acresIssuedAmount" | |
96 | 96 | ||
97 | 97 | let acresAssetIdKey = "acresAssetId" | |
98 | 98 | ||
99 | 99 | let acresAssetId = valueOrErrorMessage(getBinary(acres2Contract, acresAssetIdKey), "ACRES is not issued yet") | |
100 | 100 | ||
101 | 101 | func keyAcresStakedTimeByUser (addr) = ("acresStakedTimeByUser_" + addr) | |
102 | 102 | ||
103 | 103 | ||
104 | 104 | func keyStakedLandsByOwner (ownerAddr) = ("stakedLandsByOwner_" + ownerAddr) | |
105 | 105 | ||
106 | 106 | ||
107 | 107 | func keyStakedDuckByOwner (ownerAddr) = ("stakedDuckByOwner_" + ownerAddr) | |
108 | 108 | ||
109 | 109 | ||
110 | 110 | func asInt (v) = match v { | |
111 | 111 | case n: Int => | |
112 | 112 | n | |
113 | 113 | case _ => | |
114 | 114 | throw("fail to cast into Int") | |
115 | 115 | } | |
116 | 116 | ||
117 | 117 | ||
118 | 118 | func asTuple5Ints (val) = match val { | |
119 | 119 | case t: (Int, Int, Int, Int, Int) => | |
120 | 120 | t | |
121 | 121 | case _ => | |
122 | 122 | throw("fail to cast into (Int, Int, Int, Int, Int)") | |
123 | 123 | } | |
124 | 124 | ||
125 | 125 | ||
126 | 126 | func asTuple4Ints (val) = match val { | |
127 | 127 | case t: (Int, Int, Int, Int) => | |
128 | 128 | t | |
129 | 129 | case _ => | |
130 | 130 | throw("fail to cast into (Int, Int, Int, Int)") | |
131 | 131 | } | |
132 | 132 | ||
133 | 133 | ||
134 | 134 | func asTuple3Ints (val) = match val { | |
135 | 135 | case t: (Int, Int, Int) => | |
136 | 136 | t | |
137 | 137 | case _ => | |
138 | 138 | throw("fail to cast into (Int, Int, Int)") | |
139 | 139 | } | |
140 | 140 | ||
141 | 141 | ||
142 | 142 | func asTuple2Ints (val) = match val { | |
143 | 143 | case t: (Int, Int) => | |
144 | 144 | t | |
145 | 145 | case _ => | |
146 | 146 | throw("fail to cast into (Int, Int)") | |
147 | 147 | } | |
148 | 148 | ||
149 | 149 | ||
150 | 150 | func fixedPoint (val,decimals) = { | |
151 | 151 | let tenPow = pow(10, 0, decimals, 0, 0, DOWN) | |
152 | 152 | let lowPart = toString((val % tenPow)) | |
153 | 153 | let zeroes = drop(toString(tenPow), (1 + size(lowPart))) | |
154 | 154 | (((toString((val / tenPow)) + ".") + zeroes) + lowPart) | |
155 | 155 | } | |
156 | 156 | ||
157 | 157 | ||
158 | 158 | let M8_ = 100000000 | |
159 | 159 | ||
160 | 160 | let wlgIssuedAmtKey = "wlg_issuedAmount" | |
161 | 161 | ||
162 | 162 | let zbIssuedAmtKey = "zbill_issuedAmount" | |
163 | 163 | ||
164 | 164 | func keyAcresStakedAmtByUser (addr) = ("acresStakedAmountByUser_" + addr) | |
165 | 165 | ||
166 | 166 | ||
167 | 167 | func keyFarmingPowerByUser (addr) = ("farmingPowerByUser_" + addr) | |
168 | 168 | ||
169 | 169 | ||
170 | 170 | let acresStakdTotalKey = "acresStakedAmountTotal" | |
171 | 171 | ||
172 | 172 | let totalFarmingPowerKey = "totalFarmingPower" | |
173 | 173 | ||
174 | 174 | let levelAcres = [0, 10, 20, 40, 80, 150, 250, 400, 700, 1000] | |
175 | 175 | ||
176 | 176 | func getLevelByAcres (acres) = { | |
177 | 177 | let acr = ((acres + 99999999) / M8_) | |
178 | 178 | func checker (acc,item) = if ((item >= acr)) | |
179 | 179 | then acc | |
180 | 180 | else (acc + 1) | |
181 | 181 | ||
182 | 182 | let $l = levelAcres | |
183 | 183 | let $s = size($l) | |
184 | 184 | let $acc0 = 0 | |
185 | 185 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
186 | 186 | then $a | |
187 | 187 | else checker($a, $l[$i]) | |
188 | 188 | ||
189 | 189 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
190 | 190 | then $a | |
191 | 191 | else throw("List size exceeds 10") | |
192 | 192 | ||
193 | 193 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10) | |
194 | 194 | } | |
195 | 195 | ||
196 | 196 | ||
197 | 197 | func getFarmingPowerByAcres (acres) = ((acres * 20) * (getLevelByAcres(acres) + 4)) | |
198 | 198 | ||
199 | 199 | ||
200 | 200 | func prolog (i) = if (if ((i.originCaller != rest2Contract)) | |
201 | 201 | then valueOrElse(getBoolean(keyBlocked()), false) | |
202 | 202 | else false) | |
203 | 203 | then throw("Contracts are under maintenance") | |
204 | 204 | else [StringEntry(keyLastTxIdByUser(toString(i.originCaller)), toBase58String(i.transactionId))] | |
205 | 205 | ||
206 | 206 | ||
207 | 207 | func stakeAcresInternal (amt,address) = { | |
208 | 208 | let wlgResult = invoke(wlgContract, "onStakeUnstakeLand", [address], nil) | |
209 | 209 | if ((wlgResult == wlgResult)) | |
210 | 210 | then { | |
211 | 211 | let now = lastBlock.timestamp | |
212 | 212 | let timeKey = keyAcresStakedTimeByUser(address) | |
213 | 213 | let amountKey = keyAcresStakedAmtByUser(address) | |
214 | 214 | let newAcresAmount = (valueOrElse(getInteger(amountKey), 0) + amt) | |
215 | 215 | let oldTotal = valueOrElse(getInteger(acresStakdTotalKey), 0) | |
216 | 216 | let userFpKey = keyFarmingPowerByUser(address) | |
217 | 217 | let oldFp = valueOrElse(getInteger(userFpKey), 0) | |
218 | 218 | let newFp = getFarmingPowerByAcres(newAcresAmount) | |
219 | 219 | let oldTotalFp = valueOrElse(getInteger(totalFarmingPowerKey), 0) | |
220 | 220 | $Tuple2([IntegerEntry(timeKey, lastBlock.timestamp), IntegerEntry(amountKey, newAcresAmount), IntegerEntry(acresStakdTotalKey, (oldTotal + amt)), IntegerEntry(userFpKey, newFp), IntegerEntry(totalFarmingPowerKey, ((oldTotalFp - oldFp) + newFp))], wlgResult) | |
221 | 221 | } | |
222 | 222 | else throw("Strict value is not equal to itself.") | |
223 | 223 | } | |
224 | 224 | ||
225 | 225 | ||
226 | 226 | func getWlgPrice (usdtBalanceCorrection) = { | |
227 | 227 | let issuedAmount = valueOrErrorMessage(getInteger(wlgContract, wlgIssuedAmtKey), "WLGOLD is not issued yet") | |
228 | 228 | let wlgUsd = assetBalance(wlgContract, usdtAssetId) | |
229 | 229 | let acres2Usd = (assetBalance(acres2Contract, usdtAssetId) - usdtBalanceCorrection) | |
230 | 230 | let investFundTotal = (assetBalance(investFundContract, usdtAssetId) + valueOrElse(getInteger(investFundContract, zbIssuedAmtKey), 0)) | |
231 | 231 | let totalFundsUsd = ((acres2Usd + wlgUsd) + investFundTotal) | |
232 | 232 | fraction(totalFundsUsd, MULT8, issuedAmount) | |
233 | 233 | } | |
234 | 234 | ||
235 | 235 | ||
236 | 236 | func keyLastAcresSellTimeByUser (addr) = ("lastAcresSellTimeUser_" + addr) | |
237 | 237 | ||
238 | 238 | ||
239 | 239 | func getSwapLimitAcres (addr) = { | |
240 | 240 | let lastTime = valueOrElse(getInteger(keyLastAcresSellTimeByUser(addr)), 0) | |
241 | 241 | let now = lastBlock.timestamp | |
242 | 242 | if ((arbitrageDelay > (now - lastTime))) | |
243 | 243 | then throw((("Arbitrages are possible once a " + toString((arbitrageDelay / 60000))) + "min")) | |
244 | 244 | else { | |
245 | 245 | let wlgUsd = assetBalance(wlgContract, usdtAssetId) | |
246 | 246 | let acres2Usd = assetBalance(this, usdtAssetId) | |
247 | 247 | let investFundTotal = (assetBalance(investFundContract, usdtAssetId) + valueOrElse(getInteger(investFundContract, zbIssuedAmtKey), 0)) | |
248 | 248 | (((acres2Usd + wlgUsd) + investFundTotal) / ACRES_LIMIT_DIVISOR) | |
249 | 249 | } | |
250 | 250 | } | |
251 | 251 | ||
252 | 252 | ||
253 | 253 | @Callable(i) | |
254 | 254 | func constructorV1 (rest2Addr,oldAcrContract) = if ((i.caller != this)) | |
255 | 255 | then throw("Permission denied") | |
256 | 256 | else { | |
257 | 257 | let oldAcrContAddr = addressFromStringValue(oldAcrContract) | |
258 | 258 | [IntegerEntry(acresIssuedAmountKey, getIntegerValue(oldAcrContAddr, acresIssuedAmountKey)), BinaryEntry(acresAssetIdKey, getBinaryValue(oldAcrContAddr, acresAssetIdKey)), StringEntry(keyRest2Address(), rest2Addr), StringEntry(oldAcresContractKey, oldAcrContract)] | |
259 | 259 | } | |
260 | 260 | ||
261 | 261 | ||
262 | 262 | ||
263 | 263 | @Callable(i) | |
264 | 264 | func saveInteger (key,amount) = if ((i.caller != this)) | |
265 | 265 | then throw("saveInteger is not public method") | |
266 | 266 | else [IntegerEntry(key, amount)] | |
267 | 267 | ||
268 | 268 | ||
269 | 269 | ||
270 | 270 | @Callable(i) | |
271 | 271 | func setBlocked (isBlocked) = if ((i.caller != this)) | |
272 | 272 | then throw("permission denied") | |
273 | 273 | else [BooleanEntry(keyBlocked(), isBlocked)] | |
274 | 274 | ||
275 | 275 | ||
276 | 276 | ||
277 | 277 | @Callable(i) | |
278 | 278 | func unstakeAcres (amount) = { | |
279 | 279 | let prologActions = prolog(i) | |
280 | 280 | if ((0 >= amount)) | |
281 | 281 | then throw("Amount should be positive") | |
282 | 282 | else { | |
283 | 283 | let address = toString(i.caller) | |
284 | 284 | if ((size(i.payments) != 0)) | |
285 | 285 | then throw("No payments required") | |
286 | 286 | else { | |
287 | 287 | let timeKey = keyAcresStakedTimeByUser(address) | |
288 | 288 | let amountKey = keyAcresStakedAmtByUser(address) | |
289 | 289 | let oldAcresAmount = valueOrElse(getInteger(amountKey), 0) | |
290 | 290 | if ((amount > oldAcresAmount)) | |
291 | 291 | then throw(((("You have only " + fixedPoint(oldAcresAmount, 8)) + " ACRES staked, tried to unstake ") + fixedPoint(amount, 8))) | |
292 | 292 | else { | |
293 | 293 | let oldTotal = valueOrElse(getInteger(acresStakdTotalKey), 0) | |
294 | 294 | let wlgResult = invoke(wlgContract, "onStakeUnstakeLand", [address], nil) | |
295 | 295 | let newAcresAmount = (oldAcresAmount - amount) | |
296 | 296 | let userFpKey = keyFarmingPowerByUser(address) | |
297 | 297 | let oldFp = valueOrElse(getInteger(userFpKey), 0) | |
298 | 298 | let newFp = getFarmingPowerByAcres(newAcresAmount) | |
299 | 299 | let oldTotalFp = valueOrElse(getInteger(totalFarmingPowerKey), 0) | |
300 | 300 | $Tuple2(([IntegerEntry(timeKey, lastBlock.timestamp), IntegerEntry(amountKey, (oldAcresAmount - amount)), IntegerEntry(acresStakdTotalKey, (oldTotal - amount)), IntegerEntry(userFpKey, newFp), IntegerEntry(totalFarmingPowerKey, ((oldTotalFp - oldFp) + newFp)), ScriptTransfer(i.caller, amount, acresAssetId)] ++ prologActions), wlgResult) | |
301 | 301 | } | |
302 | 302 | } | |
303 | 303 | } | |
304 | 304 | } | |
305 | 305 | ||
306 | 306 | ||
307 | 307 | ||
308 | 308 | @Callable(i) | |
309 | 309 | func stakeAcres () = { | |
310 | 310 | let prologActions = prolog(i) | |
311 | 311 | let address = toString(i.caller) | |
312 | 312 | if ((size(i.payments) != 1)) | |
313 | 313 | then throw("exactly 1 payment must be attached") | |
314 | 314 | else { | |
315 | 315 | let pmt = i.payments[0] | |
316 | 316 | let amt = pmt.amount | |
317 | 317 | if (if (!(isDefined(pmt.assetId))) | |
318 | 318 | then true | |
319 | 319 | else (value(pmt.assetId) != acresAssetId)) | |
320 | 320 | then throw("ACRES payments only!") | |
321 | 321 | else { | |
322 | 322 | let $t051735239 = stakeAcresInternal(amt, address) | |
323 | 323 | let actions = $t051735239._1 | |
324 | 324 | let wlgClaimedAmount = $t051735239._2 | |
325 | 325 | $Tuple2((actions ++ prologActions), wlgClaimedAmount) | |
326 | 326 | } | |
327 | 327 | } | |
328 | 328 | } | |
329 | 329 | ||
330 | 330 | ||
331 | 331 | ||
332 | 332 | @Callable(i) | |
333 | 333 | func buyAcres () = { | |
334 | 334 | let prologActions = prolog(i) | |
335 | 335 | if ((size(i.payments) != 1)) | |
336 | 336 | then throw("exactly 1 payment must be attached") | |
337 | 337 | else { | |
338 | 338 | let pmt = i.payments[0] | |
339 | 339 | let usdtAmount = pmt.amount | |
340 | 340 | if (if (!(isDefined(pmt.assetId))) | |
341 | 341 | then true | |
342 | 342 | else (value(pmt.assetId) != usdtAssetId)) | |
343 | 343 | then throw("USDT payments only!") | |
344 | 344 | else if ((MULT6 > usdtAmount)) | |
345 | 345 | then throw((("Min payment should be " + fixedPoint(MULT6, 6)) + " USDT")) | |
346 | 346 | else { | |
347 | 347 | let acresAmount = (usdtAmount * USDT2ACRES_MULTIPLIER) | |
348 | 348 | let wlgAmount = fraction(usdtAmount, MULT8, getWlgPrice(usdtAmount)) | |
349 | 349 | let oldAcresAddress = addressFromStringValue(getStringValue(oldAcresContractKey)) | |
350 | 350 | let req = invoke(oldAcresAddress, "requestAcresCallback", [acresAmount], nil) | |
351 | 351 | if ((req == req)) | |
352 | 352 | then { | |
353 | 353 | let wlgRemain = asInt(invoke(wlgContract, "burnWlgold", [wlgAmount], nil)) | |
354 | 354 | $Tuple2(([ScriptTransfer(i.caller, acresAmount, acresAssetId)] ++ prologActions), wlgRemain) | |
355 | 355 | } | |
356 | 356 | else throw("Strict value is not equal to itself.") | |
357 | 357 | } | |
358 | 358 | } | |
359 | 359 | } | |
360 | 360 | ||
361 | 361 | ||
362 | 362 | ||
363 | 363 | @Callable(i) | |
364 | 364 | func buyAcresREADONLY (usdtAmount) = if ((MULT6 > usdtAmount)) | |
365 | 365 | then throw((("Min payment should be " + fixedPoint(MULT6, 6)) + " USDT")) | |
366 | 366 | else { | |
367 | 367 | let acresAmount = (usdtAmount * USDT2ACRES_MULTIPLIER) | |
368 | 368 | let wlgToBurn = fraction(usdtAmount, MULT8, getWlgPrice(usdtAmount)) | |
369 | - | $Tuple2(nil, [acresAmount, wlgToBurn]) | |
369 | + | $Tuple2(nil, [acresAmount, acresAmount, wlgToBurn]) | |
370 | 370 | } | |
371 | 371 | ||
372 | 372 | ||
373 | 373 | ||
374 | 374 | @Callable(i) | |
375 | 375 | func sellAcres () = { | |
376 | 376 | let prologActions = prolog(i) | |
377 | 377 | if ((size(i.payments) != 1)) | |
378 | 378 | then throw("exactly 1 payment must be attached") | |
379 | 379 | else { | |
380 | 380 | let pmt = i.payments[0] | |
381 | 381 | let acresAmount = pmt.amount | |
382 | 382 | if (if (!(isDefined(pmt.assetId))) | |
383 | 383 | then true | |
384 | 384 | else (value(pmt.assetId) != acresAssetId)) | |
385 | 385 | then throw("ACRES payments only!") | |
386 | 386 | else if ((MULT7 > acresAmount)) | |
387 | 387 | then throw((("Min payment should be " + fixedPoint(MULT7, 8)) + " ACRES")) | |
388 | 388 | else { | |
389 | 389 | let addr = toString(i.caller) | |
390 | 390 | let maxAcres = getSwapLimitAcres(addr) | |
391 | 391 | if ((acresAmount > maxAcres)) | |
392 | 392 | then throw((("You can sell max " + fixedPoint(maxAcres, 8)) + " ACRES")) | |
393 | 393 | else { | |
394 | 394 | let usdtAmount = ((acresAmount / USDT2ACRES_MULTIPLIER) / 2) | |
395 | 395 | $Tuple2(([IntegerEntry(keyLastAcresSellTimeByUser(addr), lastBlock.timestamp), ScriptTransfer(i.caller, usdtAmount, usdtAssetId)] ++ prologActions), usdtAmount) | |
396 | 396 | } | |
397 | 397 | } | |
398 | 398 | } | |
399 | 399 | } | |
400 | 400 | ||
401 | 401 | ||
402 | 402 | ||
403 | 403 | @Callable(i) | |
404 | 404 | func sellAcresREADONLY (address,acresAmount) = if ((MULT7 > acresAmount)) | |
405 | 405 | then throw((("Min payment should be " + fixedPoint(MULT7, 8)) + " ACRES")) | |
406 | 406 | else { | |
407 | 407 | let maxAcres = getSwapLimitAcres(address) | |
408 | 408 | let usdtAmount = ((acresAmount / USDT2ACRES_MULTIPLIER) / 2) | |
409 | - | $Tuple2(nil, [usdtAmount, maxAcres]) | |
409 | + | $Tuple2(nil, [usdtAmount, maxAcres, 0]) | |
410 | 410 | } | |
411 | 411 | ||
412 | 412 | ||
413 | 413 | ||
414 | 414 | @Callable(i) | |
415 | 415 | func convertOldStakes () = { | |
416 | 416 | let address = toString(i.caller) | |
417 | 417 | if ((size(i.payments) != 0)) | |
418 | 418 | then throw("No payments required") | |
419 | 419 | else { | |
420 | 420 | let oldAcresAddress = addressFromStringValue(getStringValue(oldAcresContractKey)) | |
421 | 421 | let amount = valueOrElse(getInteger(oldAcresAddress, keyAcresStakedAmtByUser(address)), 0) | |
422 | 422 | let gotAcres0 = if ((amount > 0)) | |
423 | 423 | then asTuple2Ints(invoke(oldAcresAddress, "unstakeAcresCallback", [amount, address], nil)) | |
424 | 424 | else $Tuple2(0, 0) | |
425 | 425 | let oldStakingAddress = addressFromStringValue(oldStakingContractStr) | |
426 | 426 | let landsStr = getString(oldStakingAddress, keyStakedLandsByOwner(address)) | |
427 | 427 | let landsResult = if (isDefined(landsStr)) | |
428 | 428 | then { | |
429 | 429 | let lands = split_51C(value(landsStr), "_") | |
430 | 430 | func oneLand (acc,landAssetId) = if ((landAssetId == "")) | |
431 | 431 | then throw("landAssetId is required") | |
432 | 432 | else { | |
433 | 433 | let r = asTuple5Ints(invoke(oldStakingAddress, "unstakeLandCallback", [landAssetId, address], nil)) | |
434 | 434 | $Tuple4((acc._1 + r._1), (acc._2 + r._2), (acc._3 + r._3), (acc._4 + r._4)) | |
435 | 435 | } | |
436 | 436 | ||
437 | 437 | let rr = { | |
438 | 438 | let $l = lands | |
439 | 439 | let $s = size($l) | |
440 | 440 | let $acc0 = $Tuple4(0, 0, 0, 0) | |
441 | 441 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
442 | 442 | then $a | |
443 | 443 | else oneLand($a, $l[$i]) | |
444 | 444 | ||
445 | 445 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
446 | 446 | then $a | |
447 | 447 | else throw("List size exceeds 100") | |
448 | 448 | ||
449 | 449 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20), 21), 22), 23), 24), 25), 26), 27), 28), 29), 30), 31), 32), 33), 34), 35), 36), 37), 38), 39), 40), 41), 42), 43), 44), 45), 46), 47), 48), 49), 50), 51), 52), 53), 54), 55), 56), 57), 58), 59), 60), 61), 62), 63), 64), 65), 66), 67), 68), 69), 70), 71), 72), 73), 74), 75), 76), 77), 78), 79), 80), 81), 82), 83), 84), 85), 86), 87), 88), 89), 90), 91), 92), 93), 94), 95), 96), 97), 98), 99), 100) | |
450 | 450 | } | |
451 | 451 | let finalize = invoke(oldStakingAddress, "unstakeLandsFinalizeCallback", [address], nil) | |
452 | 452 | if ((finalize == finalize)) | |
453 | 453 | then { | |
454 | 454 | let req = invoke(oldAcresAddress, "requestAcresCallback", [(((rr._1 + rr._2) + rr._3) + rr._4)], nil) | |
455 | 455 | if ((req == req)) | |
456 | 456 | then { | |
457 | 457 | let issue = Issue("FPOWER10", "FarmingPower +10% NFT for WavesLands game", 1, 0, false) | |
458 | 458 | $Tuple5(rr._1, rr._2, rr._3, rr._4, [issue, ScriptTransfer(i.caller, 1, calculateAssetId(issue))]) | |
459 | 459 | } | |
460 | 460 | else throw("Strict value is not equal to itself.") | |
461 | 461 | } | |
462 | 462 | else throw("Strict value is not equal to itself.") | |
463 | 463 | } | |
464 | 464 | else $Tuple5(0, 0, 0, 0, nil) | |
465 | 465 | let duckAssetId = valueOrElse(getString(oldStakingAddress, keyStakedDuckByOwner(address)), "") | |
466 | 466 | let duckResult = if ((duckAssetId != "")) | |
467 | 467 | then asTuple3Ints(invoke(oldStakingAddress, "unstakeDuckCallback", [duckAssetId, address], nil)) | |
468 | 468 | else $Tuple3(0, 0, 0) | |
469 | 469 | let x = stakeAcresInternal((((((((gotAcres0._1 + landsResult._1) + landsResult._2) + landsResult._3) + landsResult._4) + duckResult._1) + duckResult._2) + duckResult._3), address) | |
470 | 470 | $Tuple2((landsResult._5 ++ x._1), x._2) | |
471 | 471 | } | |
472 | 472 | } | |
473 | 473 | ||
474 | 474 | ||
475 | 475 | ||
476 | 476 | @Callable(i) | |
477 | 477 | func unstakeLandsREADONLY (address) = { | |
478 | 478 | let oldStakingAddress = addressFromStringValue(oldStakingContractStr) | |
479 | 479 | let landsStr = getString(oldStakingAddress, keyStakedLandsByOwner(address)) | |
480 | 480 | let landsResult = if (isDefined(landsStr)) | |
481 | 481 | then { | |
482 | 482 | let lands = split_51C(value(landsStr), "_") | |
483 | 483 | func oneLand (acc,landAssetId) = if ((landAssetId == "")) | |
484 | 484 | then throw("landAssetId is required") | |
485 | 485 | else { | |
486 | 486 | let r = asTuple4Ints(invoke(oldStakingAddress, "unstakeLandREADONLY", [landAssetId, address], nil)) | |
487 | 487 | $Tuple4((acc._1 + r._1), (acc._2 + r._2), (acc._3 + r._3), (acc._4 + r._4)) | |
488 | 488 | } | |
489 | 489 | ||
490 | 490 | let $l = lands | |
491 | 491 | let $s = size($l) | |
492 | 492 | let $acc0 = $Tuple4(0, 0, 0, 0) | |
493 | 493 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
494 | 494 | then $a | |
495 | 495 | else oneLand($a, $l[$i]) | |
496 | 496 | ||
497 | 497 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
498 | 498 | then $a | |
499 | 499 | else throw("List size exceeds 100") | |
500 | 500 | ||
501 | 501 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20), 21), 22), 23), 24), 25), 26), 27), 28), 29), 30), 31), 32), 33), 34), 35), 36), 37), 38), 39), 40), 41), 42), 43), 44), 45), 46), 47), 48), 49), 50), 51), 52), 53), 54), 55), 56), 57), 58), 59), 60), 61), 62), 63), 64), 65), 66), 67), 68), 69), 70), 71), 72), 73), 74), 75), 76), 77), 78), 79), 80), 81), 82), 83), 84), 85), 86), 87), 88), 89), 90), 91), 92), 93), 94), 95), 96), 97), 98), 99), 100) | |
502 | 502 | } | |
503 | 503 | else $Tuple4(0, 0, 0, 0) | |
504 | 504 | $Tuple2(nil, landsResult) | |
505 | 505 | } | |
506 | 506 | ||
507 | 507 | ||
508 | 508 | ||
509 | 509 | @Callable(i) | |
510 | 510 | func stakeAcresCallback (addr) = if ((i.caller != addressFromStringValue(oldStakingContractStr))) | |
511 | 511 | then throw("Permission denied") | |
512 | 512 | else stakeAcresInternal(i.payments[0].amount, addr) | |
513 | 513 | ||
514 | 514 | ||
515 | 515 | ||
516 | 516 | @Callable(i) | |
517 | 517 | func simulateStakeAcresREADONLY (address,addedAmount) = { | |
518 | 518 | let amountKey = keyAcresStakedAmtByUser(address) | |
519 | 519 | let newAcresAmount = (valueOrElse(getInteger(amountKey), 0) + addedAmount) | |
520 | 520 | let oldTotal = valueOrElse(getInteger(acresStakdTotalKey), 0) | |
521 | 521 | let userFpKey = keyFarmingPowerByUser(address) | |
522 | 522 | let oldFp = valueOrElse(getInteger(userFpKey), 0) | |
523 | 523 | let newFp = getFarmingPowerByAcres(newAcresAmount) | |
524 | 524 | let oldTotalFp = valueOrElse(getInteger(totalFarmingPowerKey), 0) | |
525 | 525 | let newTotalFp = ((oldTotalFp - oldFp) + newFp) | |
526 | 526 | $Tuple2(nil, [oldFp, newFp, oldTotalFp, newTotalFp]) | |
527 | 527 | } | |
528 | 528 | ||
529 | 529 |
github/deemru/w8io/026f985 65.36 ms ◑