tx · AsStSyGat4zjoxBfsjDmJDPZrWYizWLEHSDibvyXTCJV 3N7HtrKeFFLz5oy6PfGv1Lg3GwPk4gCPdGy: -0.02600000 Waves 2024.11.25 15:52 [3386966] smart account 3N7HtrKeFFLz5oy6PfGv1Lg3GwPk4gCPdGy > SELF 0.00000000 Waves
{ "type": 13, "id": "AsStSyGat4zjoxBfsjDmJDPZrWYizWLEHSDibvyXTCJV", "fee": 2600000, "feeAssetId": null, "timestamp": 1732539206462, "version": 2, "chainId": 84, "sender": "3N7HtrKeFFLz5oy6PfGv1Lg3GwPk4gCPdGy", "senderPublicKey": "FsR18761ZAsUqsTd7TK3XmR6bhihs1UXVmpHYxz5JzQ1", "proofs": [ "EMTanNWXR95RauygNQM1qZaUJkysLoz9RC1MXAEpHgsGmJ8KdoWVgqA9E19m4gA4w7Xp2oaoLvQUwPNyGLjUqpj" ], "script": "base64:BgJHCAISBgoECAgICBIDCgEIEgMKAQESBAoCCAESAwoBARIECgIIARIAEgMKAQgSAwoBARIDCgEBEgMKAQgSAwoBCBIDCgEBEgCSAQADU0VQAgJfXwAFTVVMVDYAwIQ9AAVNVUxUOACAwtcvAA5NSU5TSE9QUEFZTUVOVACgjQYACkRBWV9NSUxMSVMAgLiZKQAFY2hhaW4JAMkBAgkAygECCAUEdGhpcwVieXRlcwABAAEACkRBWV9CTE9DS1MEByRtYXRjaDAFBWNoYWluAwkAAAIBAVcFByRtYXRjaDAAoAsDCQAAAgEBVAUHJG1hdGNoMAA8CQACAQINVW5rbm93biBjaGFpbgALV0VFS19CTE9DS1MEByRtYXRjaDAFBWNoYWluAwkAAAIBAVcFByRtYXRjaDAA4E4DCQAAAgEBVAUHJG1hdGNoMAC0AQkAAgECDVVua25vd24gY2hhaW4AClZSRl9PRkZTRVQEByRtYXRjaDAFBWNoYWluAwkAAAIBAVcFByRtYXRjaDAAAAMJAAACAQFUBQckbWF0Y2gwAJD5RQkAAgECDVVua25vd24gY2hhaW4AC3VzZHRBc3NldElkBAckbWF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xldmVsVXACCQELdmFsdWVPckVsc2UCCQCaCAIFD3N0YWtpbmdDb250cmFjdAkBDGtleVVzZXJMZXZlbAEFBGFkZHIAAAUFbmV3WFAJAJQKAgUDbmlsCQDNCAIFCWx2bFBvaW50cwUFbmV3WFABaQEMc2V0TnVtUHJpemVzAQludW1Qcml6ZXMDCQECIT0CCAUBaQZjYWxsZXIFBHRoaXMJAAIBAhFQZXJtaXNzaW9uIGRlbmllZAQEd2VlawkAaQIFBmhlaWdodAULV0VFS19CTE9DS1MJAJQKAgkAzAgCCQEMSW50ZWdlckVudHJ5AgkBDmtleU51bU5GVDJEcmF3AQUEd2VlawUJbnVtUHJpemVzBQNuaWwFCW51bVByaXplcwFpAQlvcGVuQ2hlc3QAAwkBASEBBRFLU19BTExPV19ORlRfRFJBVwkAAgECFFRlbXBvcmFyaWx5IGRpc2FibGVkBAxwcm9sb2dSZXN1bHQJAQdwcm9sb2cyAAMJAAACBQxwcm9sb2dSZXN1bHQFDHByb2xvZ1Jlc3VsdAMJAQIhPQIJAJADAQgFAWkIcGF5bWVudHMAAAkAAgECFE5vIHBheW1lbnRzIHJlcXVpcmVkBAhkcmF3V2VlawkAZQIJAGkCBQZoZWlnaHQFC1dFRUtfQkxPQ0tTAAEEBGFkZHIJAKUIAQgFAWkGY2FsbGVyBAt1c2VyVGlja2V0cwkBC3ZhbHVlT3JFbHNlAgkAnwgBCQESa2V5VXNlcldlZWtUaWNrZXRzAgUEYWRkcgUIZHJhd1dlZWsAAAMJAGcCAAAFC3VzZXJUaWNrZXRzCQACAQIZTm8gZ2VtcyB0byBvcGVuIHRoZSBjaGVzdAkBEW9wZW5DaGVzdEludGVybmFsAQUEYWRkcgkAAgECJFN0cmljdCB2YWx1ZSBpcyBub3QgZXF1YWwgdG8gaXRzZWxmLgAJj+2G", "height": 3386966, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 4EbzTKshDBTuVWUL49Cv8rcPoy6tBZuoz1bkHrcUMgr5 Next: J1MKT2c23fPEq9HGgY8L3waCiyk8qshDeYedpnqZYJEY Diff:
Old | New | Differences | |
---|---|---|---|
28 | 28 | then 10080 | |
29 | 29 | else if ((base58'2T' == $match0)) | |
30 | 30 | then 180 | |
31 | + | else throw("Unknown chain") | |
32 | + | } | |
33 | + | ||
34 | + | let VRF_OFFSET = match chain { | |
35 | + | case _ => | |
36 | + | if ((base58'2W' == $match0)) | |
37 | + | then 0 | |
38 | + | else if ((base58'2T' == $match0)) | |
39 | + | then 1146000 | |
31 | 40 | else throw("Unknown chain") | |
32 | 41 | } | |
33 | 42 | ||
145 | 154 | func keyWeekWinners (week) = ("weekWinners_" + toString(week)) | |
146 | 155 | ||
147 | 156 | ||
148 | - | func winningBet (day) = (toInt(value(value(blockInfoByHeight((day * DAY_BLOCKS))).vrf)) % 4) | |
157 | + | func winningBet (day) = (toInt(value(value(blockInfoByHeight(((day * DAY_BLOCKS) + VRF_OFFSET))).vrf)) % 4) | |
149 | 158 | ||
150 | 159 | ||
151 | 160 | func asInt (v) = match v { |
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 MULT8 = 100000000 | |
9 | 9 | ||
10 | 10 | let MINSHOPPAYMENT = 100000 | |
11 | 11 | ||
12 | 12 | let DAY_MILLIS = 86400000 | |
13 | 13 | ||
14 | 14 | let chain = take(drop(this.bytes, 1), 1) | |
15 | 15 | ||
16 | 16 | let DAY_BLOCKS = match chain { | |
17 | 17 | case _ => | |
18 | 18 | if ((base58'2W' == $match0)) | |
19 | 19 | then 1440 | |
20 | 20 | else if ((base58'2T' == $match0)) | |
21 | 21 | then 60 | |
22 | 22 | else throw("Unknown chain") | |
23 | 23 | } | |
24 | 24 | ||
25 | 25 | let WEEK_BLOCKS = match chain { | |
26 | 26 | case _ => | |
27 | 27 | if ((base58'2W' == $match0)) | |
28 | 28 | then 10080 | |
29 | 29 | else if ((base58'2T' == $match0)) | |
30 | 30 | then 180 | |
31 | + | else throw("Unknown chain") | |
32 | + | } | |
33 | + | ||
34 | + | let VRF_OFFSET = match chain { | |
35 | + | case _ => | |
36 | + | if ((base58'2W' == $match0)) | |
37 | + | then 0 | |
38 | + | else if ((base58'2T' == $match0)) | |
39 | + | then 1146000 | |
31 | 40 | else throw("Unknown chain") | |
32 | 41 | } | |
33 | 42 | ||
34 | 43 | let usdtAssetId = match chain { | |
35 | 44 | case _ => | |
36 | 45 | if ((base58'2W' == $match0)) | |
37 | 46 | then base58'9wc3LXNA4TEBsXyKtoLE9mrbDD7WMHXvXrCjZvabLAsi' | |
38 | 47 | else if ((base58'2T' == $match0)) | |
39 | 48 | then base58'6mWwf9mZBjVgkC54idpyaZLQfAosD914wT8fGf2iiY63' | |
40 | 49 | else throw("Unknown chain") | |
41 | 50 | } | |
42 | 51 | ||
43 | 52 | let defaultRest2AddressStr = match chain { | |
44 | 53 | case _ => | |
45 | 54 | if ((base58'2W' == $match0)) | |
46 | 55 | then "3PFwYta8biEz31zpeFe5DJK8wE5trSpQVF8" | |
47 | 56 | else if ((base58'2T' == $match0)) | |
48 | 57 | then "3N7UuYar6264P58FBhVWKPQAh4Yua2hgngv" | |
49 | 58 | else throw("Unknown chain") | |
50 | 59 | } | |
51 | 60 | ||
52 | 61 | let defaultRestAddressStr = match chain { | |
53 | 62 | case _ => | |
54 | 63 | if ((base58'2W' == $match0)) | |
55 | 64 | then "3PQCuvFbvh4LkPUnrnU1z3jnbA1p9m3WNhv" | |
56 | 65 | else if ((base58'2T' == $match0)) | |
57 | 66 | then "3MumkGGztCKAXpWDqxkddofqXSUbqQkvSJy" | |
58 | 67 | else throw("Unknown chain") | |
59 | 68 | } | |
60 | 69 | ||
61 | 70 | let KS_ALLOW_NFT_DRAW = match chain { | |
62 | 71 | case _ => | |
63 | 72 | if ((base58'2W' == $match0)) | |
64 | 73 | then false | |
65 | 74 | else if ((base58'2T' == $match0)) | |
66 | 75 | then true | |
67 | 76 | else throw("Unknown chain") | |
68 | 77 | } | |
69 | 78 | ||
70 | 79 | func getStringOrFail (address,key) = valueOrErrorMessage(getString(address, key), makeString(["mandatory ", toString(address), ".", key, " is not defined"], "")) | |
71 | 80 | ||
72 | 81 | ||
73 | 82 | let IdxCfgAcres2Dapp = 1 | |
74 | 83 | ||
75 | 84 | let IdxCfgWlgDapp = 2 | |
76 | 85 | ||
77 | 86 | let IdxCfgPuzzlePoolDapp = 4 | |
78 | 87 | ||
79 | 88 | let IdxCfgInvestFundDapp = 5 | |
80 | 89 | ||
81 | 90 | func keyRestCfg () = "%s__restConfig" | |
82 | 91 | ||
83 | 92 | ||
84 | 93 | func keyRest2Address () = "%s__rest2Addr" | |
85 | 94 | ||
86 | 95 | ||
87 | 96 | func keyRestAddress () = "%s__restAddr" | |
88 | 97 | ||
89 | 98 | ||
90 | 99 | let restContract = addressFromStringValue(valueOrElse(getString(this, keyRestAddress()), defaultRestAddressStr)) | |
91 | 100 | ||
92 | 101 | func readRestCfgOrFail (rest) = split_4C(getStringOrFail(rest, keyRestCfg()), SEP) | |
93 | 102 | ||
94 | 103 | ||
95 | 104 | func getContractAddressOrFail (rest2Cfg,idx) = valueOrErrorMessage(addressFromString(rest2Cfg[idx]), ("Rest cfg doesn't contain address at index " + toString(idx))) | |
96 | 105 | ||
97 | 106 | ||
98 | 107 | let IdxCfgStakingDapp = 1 | |
99 | 108 | ||
100 | 109 | let IdxCfgAcresDapp = 8 | |
101 | 110 | ||
102 | 111 | let restCfg = readRestCfgOrFail(restContract) | |
103 | 112 | ||
104 | 113 | let stakingContract = getContractAddressOrFail(restCfg, IdxCfgStakingDapp) | |
105 | 114 | ||
106 | 115 | let acresContract = getContractAddressOrFail(restCfg, IdxCfgAcresDapp) | |
107 | 116 | ||
108 | 117 | let rest2Contract = addressFromStringValue(valueOrElse(getString(this, keyRest2Address()), defaultRest2AddressStr)) | |
109 | 118 | ||
110 | 119 | let rest2Cfg = readRestCfgOrFail(rest2Contract) | |
111 | 120 | ||
112 | 121 | let acres2Contract = getContractAddressOrFail(rest2Cfg, IdxCfgAcres2Dapp) | |
113 | 122 | ||
114 | 123 | let wlgContract = getContractAddressOrFail(rest2Cfg, IdxCfgWlgDapp) | |
115 | 124 | ||
116 | 125 | let puzzlePoolContract = getContractAddressOrFail(rest2Cfg, IdxCfgPuzzlePoolDapp) | |
117 | 126 | ||
118 | 127 | let investFundContract = getContractAddressOrFail(rest2Cfg, IdxCfgInvestFundDapp) | |
119 | 128 | ||
120 | 129 | func keyLastWeekTxIdByUser (addr) = ("lastWeekTxIdByUser_" + addr) | |
121 | 130 | ||
122 | 131 | ||
123 | 132 | let wlgAssetIdKey = "wlg_assetId" | |
124 | 133 | ||
125 | 134 | let wlgAssetId = valueOrErrorMessage(getBinary(wlgContract, wlgAssetIdKey), "WLGOLD is not issued yet") | |
126 | 135 | ||
127 | 136 | func keyUserBet (addr) = ("userBet_" + addr) | |
128 | 137 | ||
129 | 138 | ||
130 | 139 | func keyUserWeekTickets (addr,week) = ((("userWeekTickets_" + addr) + "_") + toString(week)) | |
131 | 140 | ||
132 | 141 | ||
133 | 142 | func keyTotalWeekTickets (week) = ("totalWeekTickets_" + toString(week)) | |
134 | 143 | ||
135 | 144 | ||
136 | 145 | func keyTotalWeekParticipants (week) = ("totalWeekParticipants_" + toString(week)) | |
137 | 146 | ||
138 | 147 | ||
139 | 148 | func keyNumNFT2Draw (week) = ("numNFT2Draw_" + toString(week)) | |
140 | 149 | ||
141 | 150 | ||
142 | 151 | func keyNumNFTDrawn (week) = ("numNFTDrawn_" + toString(week)) | |
143 | 152 | ||
144 | 153 | ||
145 | 154 | func keyWeekWinners (week) = ("weekWinners_" + toString(week)) | |
146 | 155 | ||
147 | 156 | ||
148 | - | func winningBet (day) = (toInt(value(value(blockInfoByHeight((day * DAY_BLOCKS))).vrf)) % 4) | |
157 | + | func winningBet (day) = (toInt(value(value(blockInfoByHeight(((day * DAY_BLOCKS) + VRF_OFFSET))).vrf)) % 4) | |
149 | 158 | ||
150 | 159 | ||
151 | 160 | func asInt (v) = match v { | |
152 | 161 | case n: Int => | |
153 | 162 | n | |
154 | 163 | case _ => | |
155 | 164 | throw("fail to cast into Int") | |
156 | 165 | } | |
157 | 166 | ||
158 | 167 | ||
159 | 168 | func fixedPoint (val,decimals) = { | |
160 | 169 | let tenPow = pow(10, 0, decimals, 0, 0, DOWN) | |
161 | 170 | let lowPart = toString((val % tenPow)) | |
162 | 171 | let zeroes = drop(toString(tenPow), (1 + size(lowPart))) | |
163 | 172 | (((toString((val / tenPow)) + ".") + zeroes) + lowPart) | |
164 | 173 | } | |
165 | 174 | ||
166 | 175 | ||
167 | 176 | func getRandomNumber (maxValue,salt,entropy) = if ((0 >= maxValue)) | |
168 | 177 | then throw("maxValue should be > 0") | |
169 | 178 | else { | |
170 | 179 | let randomHash = sha256_16Kb((salt + entropy)) | |
171 | 180 | (toInt(randomHash) % maxValue) | |
172 | 181 | } | |
173 | 182 | ||
174 | 183 | ||
175 | 184 | let SCALE8 = 100000000 | |
176 | 185 | ||
177 | 186 | let xpLevelScale = 3200 | |
178 | 187 | ||
179 | 188 | let xpLevelRecipPow = 4000 | |
180 | 189 | ||
181 | 190 | let numPointsOnLevelUp = 3 | |
182 | 191 | ||
183 | 192 | let wlgBaseAmountXp = 100000000000 | |
184 | 193 | ||
185 | 194 | func keyUserXP (addr) = ("userXP_" + addr) | |
186 | 195 | ||
187 | 196 | ||
188 | 197 | func keyUserLevel (addr) = ("userLevel_" + addr) | |
189 | 198 | ||
190 | 199 | ||
191 | 200 | let xpWlg = 10000 | |
192 | 201 | ||
193 | 202 | func levelByXP (xp) = fraction(xpLevelScale, pow(xp, 4, xpLevelRecipPow, 4, 4, DOWN), SCALE8) | |
194 | 203 | ||
195 | 204 | ||
196 | 205 | func levelUp (currLevel,newXP) = { | |
197 | 206 | let newLevel = levelByXP(newXP) | |
198 | 207 | [newLevel, (numPointsOnLevelUp * (newLevel - currLevel))] | |
199 | 208 | } | |
200 | 209 | ||
201 | 210 | ||
202 | 211 | let MILLION6 = 100000000000000 | |
203 | 212 | ||
204 | 213 | let PLAYERSHARE = 400000 | |
205 | 214 | ||
206 | 215 | let DAYMILLIS = 86400000 | |
207 | 216 | ||
208 | 217 | let teamAddrKey = "teamAddr" | |
209 | 218 | ||
210 | 219 | let lastTeamTimeKey = "lastClaimedTime_team" | |
211 | 220 | ||
212 | 221 | let teamAmountLeftKey = "teamAmountLeft" | |
213 | 222 | ||
214 | 223 | let lastActivitiesTimeKey = "lastClaimedTime_activities" | |
215 | 224 | ||
216 | 225 | let actAmountLeftKey = "activitiesAmountLeft" | |
217 | 226 | ||
218 | 227 | let stakersAmountLeftKey = "stakersAmountLeft" | |
219 | 228 | ||
220 | 229 | func keyLastWlgTradeTimeByUser (addr) = ("lastArbTimeUser_" + addr) | |
221 | 230 | ||
222 | 231 | ||
223 | 232 | func keyLastWlgTradeLimitByUser (addr) = ("lastWlgLimitUser_" + addr) | |
224 | 233 | ||
225 | 234 | ||
226 | 235 | let wlgIssueTimeKey = "wlg_issueTime" | |
227 | 236 | ||
228 | 237 | let wlgIssuedAmountKey = "wlg_issuedAmount" | |
229 | 238 | ||
230 | 239 | func keyAcresStakedAmountByUser (addr) = ("acresStakedAmountByUser_" + addr) | |
231 | 240 | ||
232 | 241 | ||
233 | 242 | func keyWlgStakedAmountByUser (addr) = ("wlgStakedAmountByUser_" + addr) | |
234 | 243 | ||
235 | 244 | ||
236 | 245 | let wlgStakedTotalKey = "wlgStakedAmountTotal" | |
237 | 246 | ||
238 | 247 | func keyWlgStakedTimeByUser (addr) = ("wlgStakedTimeByUser_" + addr) | |
239 | 248 | ||
240 | 249 | ||
241 | 250 | let M6_ = 1000000 | |
242 | 251 | ||
243 | 252 | let M8_ = 100000000 | |
244 | 253 | ||
245 | 254 | let TEAM_SHARE = 200000 | |
246 | 255 | ||
247 | 256 | let ACTIVITY_SHARE = 100000 | |
248 | 257 | ||
249 | 258 | let PLAYER_SHARE = 400000 | |
250 | 259 | ||
251 | 260 | let YEAR_MILLIS = 31557600000 | |
252 | 261 | ||
253 | 262 | let DAY_MS = 86400000 | |
254 | 263 | ||
255 | 264 | let ISSUE10 = 1000000000 | |
256 | 265 | ||
257 | 266 | let PLAYERS10_SHARE = 800000 | |
258 | 267 | ||
259 | 268 | let MARKETING10_SHARE = 100000 | |
260 | 269 | ||
261 | 270 | let TEAM10_SHARE = 100000 | |
262 | 271 | ||
263 | 272 | let NEW_STAKING_START = 1731279600000 | |
264 | 273 | ||
265 | 274 | let marketingAddrKey = "marketingAddr" | |
266 | 275 | ||
267 | 276 | let teamAdrKey = "teamAddr" | |
268 | 277 | ||
269 | 278 | let lastTeamTimKey = "lastClaimedTime_team" | |
270 | 279 | ||
271 | 280 | let teamAmtLeftKey = "teamAmountLeft" | |
272 | 281 | ||
273 | 282 | let lastActivitiesTimKey = "lastClaimedTime_activities" | |
274 | 283 | ||
275 | 284 | let actAmtLeftKey = "activitiesAmountLeft" | |
276 | 285 | ||
277 | 286 | let stakersAmtLeftKey = "stakersAmountLeft" | |
278 | 287 | ||
279 | 288 | func keyLastClaimTimeByUser (addr) = ("lastClaimedTimeUser_" + addr) | |
280 | 289 | ||
281 | 290 | ||
282 | 291 | func distrByPeriod (issuedAmount,period) = fraction(issuedAmount, (PLAYER_SHARE * (period + 1)), (6 * M6_)) | |
283 | 292 | ||
284 | 293 | ||
285 | 294 | let wlgIssue10TimeKey = "wlg_issue10Time" | |
286 | 295 | ||
287 | 296 | let wlgIssueTimKey = "wlg_issueTime" | |
288 | 297 | ||
289 | 298 | let wlgIssuedAmtKey = "wlg_issuedAmount" | |
290 | 299 | ||
291 | 300 | let zbIssuedAmtKey = "zbill_issuedAmount" | |
292 | 301 | ||
293 | 302 | func keyAcresStakedAmtByUser (addr) = ("acresStakedAmountByUser_" + addr) | |
294 | 303 | ||
295 | 304 | ||
296 | 305 | let acresStakdTotalKey = "acresStakedAmountTotal" | |
297 | 306 | ||
298 | 307 | let totalFarmingPowerKey = "totalFarmingPower" | |
299 | 308 | ||
300 | 309 | let dapp2Rest = 0 | |
301 | 310 | ||
302 | 311 | let dapp2Staking = 1 | |
303 | 312 | ||
304 | 313 | let dapp2Wlg = 2 | |
305 | 314 | ||
306 | 315 | let dapp2Puzzle = 3 | |
307 | 316 | ||
308 | 317 | let dapp2InvestFund = 4 | |
309 | 318 | ||
310 | 319 | let IdxDtx1PercGemWinner = 1 | |
311 | 320 | ||
312 | 321 | let DEFAULT_WEEKLY_PRIZES = 5 | |
313 | 322 | ||
314 | 323 | let ACRES_FOR_BET = 100000000 | |
315 | 324 | ||
316 | 325 | func keyUserFullBonus (addr) = ("userFullBonus_" + addr) | |
317 | 326 | ||
318 | 327 | ||
319 | 328 | let levelAcres = [0, 10, 20, 40, 80, 150, 250, 400, 700, 1000] | |
320 | 329 | ||
321 | 330 | func getLevelByAcres (acres) = { | |
322 | 331 | let acr = ((acres + 99999999) / M8_) | |
323 | 332 | func checker (acc,item) = if ((item >= acr)) | |
324 | 333 | then acc | |
325 | 334 | else (acc + 1) | |
326 | 335 | ||
327 | 336 | let $l = levelAcres | |
328 | 337 | let $s = size($l) | |
329 | 338 | let $acc0 = 0 | |
330 | 339 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
331 | 340 | then $a | |
332 | 341 | else checker($a, $l[$i]) | |
333 | 342 | ||
334 | 343 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
335 | 344 | then $a | |
336 | 345 | else throw("List size exceeds 10") | |
337 | 346 | ||
338 | 347 | $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) | |
339 | 348 | } | |
340 | 349 | ||
341 | 350 | ||
342 | 351 | func getFarmingPowerByAcres (acres) = ((acres * 20) * (getLevelByAcres(acres) + 4)) | |
343 | 352 | ||
344 | 353 | ||
345 | 354 | func getFarmingPowerByAcresAndBonus (acres,bonus6) = { | |
346 | 355 | let notBonused = getFarmingPowerByAcres(acres) | |
347 | 356 | $Tuple2(fraction(notBonused, (M6_ + bonus6), M6_), notBonused) | |
348 | 357 | } | |
349 | 358 | ||
350 | 359 | ||
351 | 360 | func getFarmingPowers (userAddrStrOrEmpty,acres2Contract) = { | |
352 | 361 | let totalFP = valueOrElse(getInteger(acres2Contract, totalFarmingPowerKey), 0) | |
353 | 362 | let userAcres = valueOrElse(getInteger(acres2Contract, keyAcresStakedAmtByUser(userAddrStrOrEmpty)), 0) | |
354 | 363 | let userBonus = valueOrElse(getInteger(acres2Contract, keyUserFullBonus(userAddrStrOrEmpty)), 0) | |
355 | 364 | let $t079143 = getFarmingPowerByAcresAndBonus(userAcres, userBonus) | |
356 | 365 | let userFPbonused = $t079143._1 | |
357 | 366 | let userFPnotBonused = $t079143._2 | |
358 | 367 | [totalFP, userFPbonused, userFPnotBonused, userBonus] | |
359 | 368 | } | |
360 | 369 | ||
361 | 370 | ||
362 | 371 | let idxTotalFP = 0 | |
363 | 372 | ||
364 | 373 | let idxUserFPbonused = 1 | |
365 | 374 | ||
366 | 375 | let ixWlgAmount = 0 | |
367 | 376 | ||
368 | 377 | let ixWlgWlg = 1 | |
369 | 378 | ||
370 | 379 | let ixWlgPrice = 2 | |
371 | 380 | ||
372 | 381 | let ixWlgIssueTime = 8 | |
373 | 382 | ||
374 | 383 | let ixWlgTeamAmLeft = 11 | |
375 | 384 | ||
376 | 385 | let ixWlgTeamAmAvailNow = 12 | |
377 | 386 | ||
378 | 387 | let ixWlgActAmLeft = 15 | |
379 | 388 | ||
380 | 389 | let ixWlgActAmAvailNow = 16 | |
381 | 390 | ||
382 | 391 | let ixWlgAmLeftTotal = 19 | |
383 | 392 | ||
384 | 393 | let ixWlgUserAmAvailNow = 23 | |
385 | 394 | ||
386 | 395 | let ixWlgEffUserTime = 24 | |
387 | 396 | ||
388 | 397 | let ixWlgIssue10Amount = 25 | |
389 | 398 | ||
390 | 399 | let ixWlgMarketingIssue10Amount = 26 | |
391 | 400 | ||
392 | 401 | let ixWlgTeamIssue10Amount = 27 | |
393 | 402 | ||
394 | 403 | let ixWlgUser10part = 28 | |
395 | 404 | ||
396 | 405 | let ixWlgIssue10Time = 29 | |
397 | 406 | ||
398 | 407 | func getWlgStats2 (userAddrOpt,contracts,usdtId,usdtBalanceCorrection) = { | |
399 | 408 | let issuedAmount = valueOrErrorMessage(getInteger(contracts[dapp2Wlg], wlgIssuedAmtKey), "WLGOLD is not issued yet") | |
400 | 409 | let restUsd = assetBalance(contracts[dapp2Rest], usdtId) | |
401 | 410 | let wlgUsd = (assetBalance(contracts[dapp2Wlg], usdtId) - usdtBalanceCorrection) | |
402 | 411 | let puzzleUsd = assetBalance(contracts[dapp2Puzzle], usdtId) | |
403 | 412 | let acres2Usd = assetBalance(contracts[dapp2Staking], usdtId) | |
404 | 413 | let investFndContract = contracts[dapp2InvestFund] | |
405 | 414 | let investFundTotal = (assetBalance(investFndContract, usdtId) + valueOrElse(getInteger(investFndContract, zbIssuedAmtKey), 0)) | |
406 | 415 | let totalFundsUsd = ((acres2Usd + wlgUsd) + investFundTotal) | |
407 | 416 | let wlgId = valueOrErrorMessage(getBinary(contracts[dapp2Wlg], "wlg_assetId"), "Not initialized yet") | |
408 | 417 | let now = lastBlock.timestamp | |
409 | 418 | let issueTime = valueOrErrorMessage(getInteger(contracts[dapp2Wlg], wlgIssueTimKey), "Not initialized") | |
410 | 419 | let wlgWlg = assetBalance(contracts[dapp2Wlg], wlgId) | |
411 | 420 | let teamTotal = fraction(issuedAmount, TEAM_SHARE, M6_) | |
412 | 421 | let teamAmountLeft = valueOrElse(getInteger(contracts[dapp2Wlg], teamAmtLeftKey), teamTotal) | |
413 | 422 | let lastTeamTime = valueOrElse(getInteger(contracts[dapp2Wlg], lastTeamTimKey), issueTime) | |
414 | 423 | let teamAddr = addressFromStringValue(value(getString(contracts[dapp2Wlg], teamAdrKey))) | |
415 | 424 | let teamAmountAvailableNow = min([fraction(teamTotal, (now - lastTeamTime), (3 * YEAR_MILLIS)), teamAmountLeft]) | |
416 | 425 | let teamWlgold = assetBalance(teamAddr, wlgId) | |
417 | 426 | let actTotal = fraction(issuedAmount, ACTIVITY_SHARE, M6_) | |
418 | 427 | let actAmountLeft = valueOrElse(getInteger(contracts[dapp2Wlg], actAmtLeftKey), actTotal) | |
419 | 428 | let lastActivitiesTime = valueOrElse(getInteger(contracts[dapp2Wlg], lastActivitiesTimKey), issueTime) | |
420 | 429 | let actAmountAvailableNow = min([fraction(actTotal, (now - lastActivitiesTime), (3 * YEAR_MILLIS)), actAmountLeft]) | |
421 | 430 | let actWlgold = assetBalance(contracts[dapp2Rest], wlgId) | |
422 | 431 | let lastUserTime = valueOrElse(getInteger(contracts[dapp2Wlg], keyLastClaimTimeByUser(userAddrOpt)), issueTime) | |
423 | 432 | let lastUserPeriod = ((lastUserTime - issueTime) / YEAR_MILLIS) | |
424 | 433 | let nowLimited = min([now, (issueTime + (3 * YEAR_MILLIS))]) | |
425 | 434 | let curPeriod = min([((now - issueTime) / YEAR_MILLIS), 2]) | |
426 | 435 | let eff = getFarmingPowers(userAddrOpt, contracts[dapp2Staking]) | |
427 | 436 | let curPeriodDistribution = distrByPeriod(issuedAmount, curPeriod) | |
428 | 437 | let prevPeriodEnd = (issueTime + (YEAR_MILLIS * curPeriod)) | |
429 | 438 | let prevPrevPeriodEnd = (issueTime + (YEAR_MILLIS * (curPeriod - 1))) | |
430 | 439 | let a0 = fraction(curPeriodDistribution, (nowLimited - lastUserTime), YEAR_MILLIS) | |
431 | 440 | let userAvailable = if ((lastUserPeriod == curPeriod)) | |
432 | 441 | then a0 | |
433 | 442 | else if ((lastUserPeriod == (curPeriod - 1))) | |
434 | 443 | then { | |
435 | 444 | let a1 = fraction(distrByPeriod(issuedAmount, (curPeriod - 1)), (prevPeriodEnd - lastUserTime), YEAR_MILLIS) | |
436 | 445 | (a1 + a0) | |
437 | 446 | } | |
438 | 447 | else { | |
439 | 448 | let a2 = fraction(distrByPeriod(issuedAmount, (curPeriod - 2)), (prevPrevPeriodEnd - lastUserTime), YEAR_MILLIS) | |
440 | 449 | let a1 = distrByPeriod(issuedAmount, (curPeriod - 1)) | |
441 | 450 | ((a2 + a1) + a0) | |
442 | 451 | } | |
443 | 452 | let amountLeftTotal = valueOrElse(getInteger(contracts[dapp2Wlg], stakersAmtLeftKey), 0) | |
444 | 453 | let userAmount = if ((eff[idxTotalFP] != 0)) | |
445 | 454 | then fraction(userAvailable, eff[idxUserFPbonused], eff[idxTotalFP]) | |
446 | 455 | else 0 | |
447 | 456 | let lastIssue10Time = valueOrElse(getInteger(contracts[dapp2Wlg], wlgIssue10TimeKey), NEW_STAKING_START) | |
448 | 457 | let issue10Amount = fraction(ISSUE10, max([(now - lastIssue10Time), 0]), DAY_MS) | |
449 | 458 | let marketingIssue10Amount = fraction(issue10Amount, MARKETING10_SHARE, M6_) | |
450 | 459 | let teamIssue10Amount = fraction(issue10Amount, TEAM10_SHARE, M6_) | |
451 | 460 | let user10Interval = max([(now - max([NEW_STAKING_START, lastUserTime])), 0]) | |
452 | 461 | let user10part = if ((eff[idxTotalFP] != 0)) | |
453 | 462 | then fraction(fraction(fraction(ISSUE10, user10Interval, DAY_MS), eff[idxUserFPbonused], eff[idxTotalFP]), PLAYERS10_SHARE, M6_) | |
454 | 463 | else 0 | |
455 | 464 | let newIssue10Time = max([NEW_STAKING_START, now]) | |
456 | 465 | let acresStakedTotal = valueOrElse(getInteger(contracts[dapp2Staking], acresStakdTotalKey), 0) | |
457 | 466 | [issuedAmount, wlgWlg, fraction(totalFundsUsd, M8_, issuedAmount), totalFundsUsd, restUsd, acres2Usd, wlgUsd, puzzleUsd, issueTime, lastTeamTime, teamTotal, teamAmountLeft, teamAmountAvailableNow, teamWlgold, actTotal, actAmountLeft, actAmountAvailableNow, actWlgold, curPeriod, amountLeftTotal, curPeriodDistribution, lastUserTime, investFundTotal, userAmount, nowLimited, issue10Amount, marketingIssue10Amount, teamIssue10Amount, user10part, newIssue10Time, eff[idxTotalFP], acresStakedTotal] | |
458 | 467 | } | |
459 | 468 | ||
460 | 469 | ||
461 | 470 | let profitAddrKey = "profitAddr" | |
462 | 471 | ||
463 | 472 | let stakersAmountPaidTotalKey = "stakersAmountPaidTotal" | |
464 | 473 | ||
465 | 474 | func keyStakersAmountPaidUser (addr) = ("stakersAmountPaidUser_" + addr) | |
466 | 475 | ||
467 | 476 | ||
468 | 477 | func prolog2 () = asInt(reentrantInvoke(acres2Contract, "saveLastTx", nil, nil)) | |
469 | 478 | ||
470 | 479 | ||
471 | 480 | func getSwapLimitWlgold (addr) = { | |
472 | 481 | let lastTime = valueOrElse(getInteger(keyLastWlgTradeTimeByUser(addr)), 0) | |
473 | 482 | let defaultLimit = valueOrElse(getInteger(acres2Contract, keyAcresStakedAmountByUser(addr)), 0) | |
474 | 483 | let lastLimitLeft = valueOrElse(getInteger(keyLastWlgTradeLimitByUser(addr)), defaultLimit) | |
475 | 484 | let currentLimit = (lastLimitLeft + fraction(defaultLimit, (lastBlock.timestamp - lastTime), DAY_MILLIS)) | |
476 | 485 | min([currentLimit, defaultLimit]) | |
477 | 486 | } | |
478 | 487 | ||
479 | 488 | ||
480 | 489 | func claimInternal2 (addr) = { | |
481 | 490 | let curStats = getWlgStats2(addr, [rest2Contract, acres2Contract, wlgContract, puzzlePoolContract, investFundContract], usdtAssetId, 0) | |
482 | 491 | let userTimeKey = keyLastClaimTimeByUser(addr) | |
483 | 492 | let lastUserTime = valueOrElse(getInteger(userTimeKey), 0) | |
484 | 493 | let userEffTime = curStats[ixWlgEffUserTime] | |
485 | 494 | if ((lastUserTime == userEffTime)) | |
486 | 495 | then $Tuple2(nil, 0) | |
487 | 496 | else { | |
488 | 497 | let now = lastBlock.timestamp | |
489 | 498 | let issueTime = curStats[ixWlgIssueTime] | |
490 | 499 | let teamAmountLeft = curStats[ixWlgTeamAmLeft] | |
491 | 500 | let teamAmount = (curStats[ixWlgTeamAmAvailNow] + curStats[ixWlgTeamIssue10Amount]) | |
492 | 501 | let teamTransfer = if ((teamAmount > 0)) | |
493 | 502 | then [ScriptTransfer(addressFromStringValue(value(getString(teamAddrKey))), teamAmount, wlgAssetId)] | |
494 | 503 | else nil | |
495 | 504 | let actAmountLeft = curStats[ixWlgActAmLeft] | |
496 | 505 | let actAmount = curStats[ixWlgActAmAvailNow] | |
497 | 506 | let actTransfer = if ((actAmount > 0)) | |
498 | 507 | then [ScriptTransfer(restContract, actAmount, wlgAssetId)] | |
499 | 508 | else nil | |
500 | 509 | let marketingAmount = curStats[ixWlgMarketingIssue10Amount] | |
501 | 510 | let marketingTransfer = if ((marketingAmount > 0)) | |
502 | 511 | then [ScriptTransfer(addressFromStringValue(value(getString(marketingAddrKey))), marketingAmount, wlgAssetId)] | |
503 | 512 | else nil | |
504 | 513 | let userAmount = curStats[ixWlgUserAmAvailNow] | |
505 | 514 | let userKey = keyStakersAmountPaidUser(addr) | |
506 | 515 | let userTotal = (userAmount + curStats[ixWlgUser10part]) | |
507 | 516 | let issued10Amount = curStats[ixWlgIssue10Amount] | |
508 | 517 | $Tuple2(((([Reissue(wlgAssetId, issued10Amount, true), IntegerEntry(wlgIssuedAmountKey, (curStats[ixWlgAmount] + issued10Amount)), IntegerEntry(wlgIssue10TimeKey, curStats[ixWlgIssue10Time]), IntegerEntry(userKey, (valueOrElse(getInteger(userKey), 0) + userAmount)), IntegerEntry(stakersAmountPaidTotalKey, (valueOrElse(getInteger(stakersAmountPaidTotalKey), 0) + userAmount)), IntegerEntry(stakersAmountLeftKey, (curStats[ixWlgAmLeftTotal] - userAmount)), IntegerEntry(teamAmountLeftKey, ((teamAmountLeft - teamAmount) + curStats[ixWlgTeamIssue10Amount])), IntegerEntry(lastTeamTimeKey, now), IntegerEntry(actAmountLeftKey, (actAmountLeft - actAmount)), IntegerEntry(lastActivitiesTimeKey, now), IntegerEntry(userTimeKey, userEffTime)] ++ teamTransfer) ++ actTransfer) ++ marketingTransfer), userTotal) | |
509 | 518 | } | |
510 | 519 | } | |
511 | 520 | ||
512 | 521 | ||
513 | 522 | func takeXpInternal (addr,delta) = { | |
514 | 523 | let now = lastBlock.timestamp | |
515 | 524 | let timeKey = keyWlgStakedTimeByUser(addr) | |
516 | 525 | let amountKey = keyWlgStakedAmountByUser(addr) | |
517 | 526 | let lastTime = valueOrElse(getInteger(timeKey), 0) | |
518 | 527 | let oldUser = valueOrElse(getInteger(amountKey), 0) | |
519 | 528 | let oldTotal = valueOrElse(getInteger(wlgStakedTotalKey), 0) | |
520 | 529 | let xp = fraction(fraction(xpWlg, oldUser, wlgBaseAmountXp), (lastTime - now), DAYMILLIS) | |
521 | 530 | $Tuple3([IntegerEntry(timeKey, now), IntegerEntry(amountKey, (oldUser + delta)), IntegerEntry(wlgStakedTotalKey, (oldTotal + delta))], xp, oldUser) | |
522 | 531 | } | |
523 | 532 | ||
524 | 533 | ||
525 | 534 | func openChestInternal (addr) = { | |
526 | 535 | let week = (height / WEEK_BLOCKS) | |
527 | 536 | let drawWeek = (week - 1) | |
528 | 537 | let numPrizes = valueOrElse(getInteger(keyNumNFT2Draw(drawWeek)), DEFAULT_WEEKLY_PRIZES) | |
529 | 538 | let prizesDrawn = valueOrElse(getInteger(keyNumNFTDrawn(drawWeek)), 0) | |
530 | 539 | let userTickets = valueOrElse(getInteger(keyUserWeekTickets(addr, drawWeek)), 0) | |
531 | 540 | if ((0 >= userTickets)) | |
532 | 541 | then $Tuple2(nil, unit) | |
533 | 542 | else { | |
534 | 543 | let weekTickets = valueOrElse(getInteger(keyTotalWeekTickets(drawWeek)), 0) | |
535 | 544 | if ((0 >= weekTickets)) | |
536 | 545 | then $Tuple2([DeleteEntry(keyUserWeekTickets(addr, drawWeek))], unit) | |
537 | 546 | else { | |
538 | 547 | let entropy = value(value(blockInfoByHeight((week * WEEK_BLOCKS))).vrf) | |
539 | 548 | let salt = fromBase58String(split(valueOrElse(getString(keyLastWeekTxIdByUser(addr)), "42_DEFAULT"), "_")[1]) | |
540 | 549 | let random = getRandomNumber(weekTickets, salt, entropy) | |
541 | 550 | if (((userTickets * numPrizes) > random)) | |
542 | 551 | then { | |
543 | 552 | let issueResult = invoke(acres2Contract, "issueNFT", [addr, IdxDtx1PercGemWinner], nil) | |
544 | 553 | let winners = getString(keyWeekWinners(drawWeek)) | |
545 | 554 | let newWinners = if (isDefined(winners)) | |
546 | 555 | then ((value(winners) + "_") + addr) | |
547 | 556 | else addr | |
548 | 557 | $Tuple2([IntegerEntry(keyNumNFTDrawn(drawWeek), (prizesDrawn + 1)), DeleteEntry(keyUserWeekTickets(addr, drawWeek)), StringEntry(keyWeekWinners(drawWeek), newWinners)], issueResult) | |
549 | 558 | } | |
550 | 559 | else { | |
551 | 560 | let random1 = (getRandomNumber(9, (base58'29' + salt), entropy) + 1) | |
552 | 561 | let consTickets = fraction(userTickets, random1, 10) | |
553 | 562 | $Tuple2([DeleteEntry(keyUserWeekTickets(addr, drawWeek)), IntegerEntry(keyUserWeekTickets(addr, week), consTickets)], consTickets) | |
554 | 563 | } | |
555 | 564 | } | |
556 | 565 | } | |
557 | 566 | } | |
558 | 567 | ||
559 | 568 | ||
560 | 569 | func claimTicketsInternal (addr,userBetStr) = { | |
561 | 570 | let week = (height / WEEK_BLOCKS) | |
562 | 571 | let ticketsKey = keyUserWeekTickets(addr, week) | |
563 | 572 | let dayBet = split(userBetStr, "_") | |
564 | 573 | let oldTotalTickets = valueOrElse(getInteger(keyTotalWeekTickets(week)), 0) | |
565 | 574 | let oldTickets = valueOrElse(getInteger(ticketsKey), 0) | |
566 | 575 | let deltaTickets = if ((winningBet(parseIntValue(dayBet[0])) == parseIntValue(dayBet[1]))) | |
567 | 576 | then 1 | |
568 | 577 | else 0 | |
569 | 578 | let oldParticipants = valueOrElse(getInteger(keyTotalWeekParticipants(week)), 0) | |
570 | 579 | let updateParticipants = if (if ((oldTickets == 0)) | |
571 | 580 | then (deltaTickets == 1) | |
572 | 581 | else false) | |
573 | 582 | then [IntegerEntry(keyTotalWeekParticipants(week), (oldParticipants + 1))] | |
574 | 583 | else nil | |
575 | 584 | $Tuple2(if ((deltaTickets == 0)) | |
576 | 585 | then nil | |
577 | 586 | else ((updateParticipants :+ IntegerEntry(ticketsKey, (oldTickets + deltaTickets))) :+ IntegerEntry(keyTotalWeekTickets(week), (oldTotalTickets + deltaTickets))), deltaTickets) | |
578 | 587 | } | |
579 | 588 | ||
580 | 589 | ||
581 | 590 | @Callable(i) | |
582 | 591 | func constructorV1 (restAddr,marketingAddr,teamAddr,profitAddr) = if ((i.caller != this)) | |
583 | 592 | then throw("Permission denied") | |
584 | 593 | else if (isDefined(getBinary(wlgAssetIdKey))) | |
585 | 594 | then throw("Already initialized") | |
586 | 595 | else { | |
587 | 596 | let issuedAmount = MILLION6 | |
588 | 597 | let issue = Issue("WLGOLD", "WavesLands Gold investment token", issuedAmount, 8, true, unit, 0) | |
589 | 598 | let assetId = calculateAssetId(issue) | |
590 | 599 | [issue, IntegerEntry(wlgIssueTimeKey, lastBlock.timestamp), IntegerEntry(wlgIssuedAmountKey, issuedAmount), IntegerEntry(stakersAmountPaidTotalKey, 0), IntegerEntry(stakersAmountLeftKey, fraction(MILLION6, PLAYERSHARE, MULT6)), BinaryEntry(wlgAssetIdKey, assetId), StringEntry(keyRestAddress(), restAddr), StringEntry(marketingAddrKey, marketingAddr), StringEntry(teamAddrKey, teamAddr), StringEntry(profitAddrKey, profitAddr)] | |
591 | 600 | } | |
592 | 601 | ||
593 | 602 | ||
594 | 603 | ||
595 | 604 | @Callable(i) | |
596 | 605 | func constructorV2 (rest2Addr) = if ((i.caller != this)) | |
597 | 606 | then throw("Permission denied") | |
598 | 607 | else [StringEntry(keyRest2Address(), rest2Addr)] | |
599 | 608 | ||
600 | 609 | ||
601 | 610 | ||
602 | 611 | @Callable(i) | |
603 | 612 | func buyWlg (minToReceive) = { | |
604 | 613 | let prologResult = prolog2() | |
605 | 614 | if ((prologResult == prologResult)) | |
606 | 615 | then if ((size(i.payments) != 1)) | |
607 | 616 | then throw("exactly 1 payment must be attached") | |
608 | 617 | else { | |
609 | 618 | let pmt = i.payments[0] | |
610 | 619 | let usdtAmt = pmt.amount | |
611 | 620 | if (if (!(isDefined(pmt.assetId))) | |
612 | 621 | then true | |
613 | 622 | else (value(pmt.assetId) != usdtAssetId)) | |
614 | 623 | then throw("USDT payments only!") | |
615 | 624 | else { | |
616 | 625 | let caller = i.caller | |
617 | 626 | let addr = toString(caller) | |
618 | 627 | if ((MINSHOPPAYMENT > usdtAmt)) | |
619 | 628 | then throw((("You can trade min " + fixedPoint(MINSHOPPAYMENT, 6)) + " USDT")) | |
620 | 629 | else { | |
621 | 630 | let curStats = getWlgStats2("", [rest2Contract, acres2Contract, wlgContract, puzzlePoolContract, investFundContract], usdtAssetId, usdtAmt) | |
622 | 631 | let curWlgAmount = curStats[ixWlgAmount] | |
623 | 632 | let wlgPrice = curStats[ixWlgPrice] | |
624 | 633 | let buyPrice = fraction(wlgPrice, 6, 5, CEILING) | |
625 | 634 | let wlgAmount = fraction(usdtAmt, MULT8, buyPrice) | |
626 | 635 | let maxWlg = getSwapLimitWlgold(addr) | |
627 | 636 | if ((wlgAmount > maxWlg)) | |
628 | 637 | then throw((("You can get max " + fixedPoint(maxWlg, 8)) + " WLGOLD at the moment")) | |
629 | 638 | else if ((minToReceive > wlgAmount)) | |
630 | 639 | then throw("Price changed during operation, please try again") | |
631 | 640 | else { | |
632 | 641 | let profitAmount = (usdtAmt / 6) | |
633 | 642 | $Tuple2([Reissue(wlgAssetId, wlgAmount, true), IntegerEntry(wlgIssuedAmountKey, (curWlgAmount + wlgAmount)), IntegerEntry(keyLastWlgTradeTimeByUser(addr), lastBlock.timestamp), IntegerEntry(keyLastWlgTradeLimitByUser(addr), (maxWlg - wlgAmount)), ScriptTransfer(addressFromStringValue(value(getString(profitAddrKey))), profitAmount, usdtAssetId), ScriptTransfer(caller, wlgAmount, wlgAssetId)], prologResult) | |
634 | 643 | } | |
635 | 644 | } | |
636 | 645 | } | |
637 | 646 | } | |
638 | 647 | else throw("Strict value is not equal to itself.") | |
639 | 648 | } | |
640 | 649 | ||
641 | 650 | ||
642 | 651 | ||
643 | 652 | @Callable(i) | |
644 | 653 | func buyWlgREADONLY (address,usdtAmt) = { | |
645 | 654 | let curStats = getWlgStats2("", [rest2Contract, acres2Contract, wlgContract, puzzlePoolContract, investFundContract], usdtAssetId, usdtAmt) | |
646 | 655 | let wlgPrice = curStats[ixWlgPrice] | |
647 | 656 | let buyPrice = fraction(wlgPrice, 6, 5, CEILING) | |
648 | 657 | let wlgAmount = fraction(usdtAmt, MULT8, buyPrice) | |
649 | 658 | let maxWlg = getSwapLimitWlgold(address) | |
650 | 659 | let maxUsdt = fraction(maxWlg, buyPrice, MULT8) | |
651 | 660 | let profitAmount = (usdtAmt / 6) | |
652 | 661 | $Tuple2(nil, [wlgAmount, MINSHOPPAYMENT, maxUsdt, profitAmount]) | |
653 | 662 | } | |
654 | 663 | ||
655 | 664 | ||
656 | 665 | ||
657 | 666 | @Callable(i) | |
658 | 667 | func sellWlg (minAmount) = { | |
659 | 668 | let prologResult = prolog2() | |
660 | 669 | if ((prologResult == prologResult)) | |
661 | 670 | then if ((size(i.payments) != 1)) | |
662 | 671 | then throw("exactly 1 payment must be attached") | |
663 | 672 | else { | |
664 | 673 | let pmt = i.payments[0] | |
665 | 674 | let wlgAmt = pmt.amount | |
666 | 675 | let caller = i.caller | |
667 | 676 | let addr = toString(caller) | |
668 | 677 | let maxWlg = getSwapLimitWlgold(addr) | |
669 | 678 | if ((wlgAmt > maxWlg)) | |
670 | 679 | then throw((("You can spend max " + fixedPoint(maxWlg, 8)) + " WLGOLD at the moment")) | |
671 | 680 | else if (if (!(isDefined(pmt.assetId))) | |
672 | 681 | then true | |
673 | 682 | else (value(pmt.assetId) != wlgAssetId)) | |
674 | 683 | then throw("WLGOLD payments only!") | |
675 | 684 | else { | |
676 | 685 | let curStats = getWlgStats2("", [rest2Contract, acres2Contract, wlgContract, puzzlePoolContract, investFundContract], usdtAssetId, 0) | |
677 | 686 | let curWlgAmount = curStats[ixWlgAmount] | |
678 | 687 | let sellPrice = (curStats[ixWlgPrice] / 2) | |
679 | 688 | let usdtAmt = fraction(wlgAmt, sellPrice, MULT8) | |
680 | 689 | if ((MINSHOPPAYMENT > usdtAmt)) | |
681 | 690 | then throw((("You can trade min " + fixedPoint(MINSHOPPAYMENT, 6)) + " USDT")) | |
682 | 691 | else if ((minAmount > usdtAmt)) | |
683 | 692 | then throw("Price changed during operation, please try again") | |
684 | 693 | else { | |
685 | 694 | let profitAmount = (usdtAmt / 5) | |
686 | 695 | $Tuple2([Burn(wlgAssetId, wlgAmt), IntegerEntry(wlgIssuedAmountKey, (curWlgAmount - wlgAmt)), IntegerEntry(keyLastWlgTradeTimeByUser(addr), lastBlock.timestamp), IntegerEntry(keyLastWlgTradeLimitByUser(addr), (maxWlg - wlgAmt)), ScriptTransfer(addressFromStringValue(value(getString(profitAddrKey))), profitAmount, usdtAssetId), ScriptTransfer(caller, usdtAmt, usdtAssetId)], prologResult) | |
687 | 696 | } | |
688 | 697 | } | |
689 | 698 | } | |
690 | 699 | else throw("Strict value is not equal to itself.") | |
691 | 700 | } | |
692 | 701 | ||
693 | 702 | ||
694 | 703 | ||
695 | 704 | @Callable(i) | |
696 | 705 | func sellWlgREADONLY (address,wlgAmt) = { | |
697 | 706 | let maxWlg = getSwapLimitWlgold(address) | |
698 | 707 | let curStats = getWlgStats2("", [rest2Contract, acres2Contract, wlgContract, puzzlePoolContract, investFundContract], usdtAssetId, 0) | |
699 | 708 | let sellPrice = (curStats[ixWlgPrice] / 2) | |
700 | 709 | let usdtAmt = fraction(wlgAmt, sellPrice, MULT8) | |
701 | 710 | let minWlg = fraction(MINSHOPPAYMENT, MULT8, sellPrice) | |
702 | 711 | let profitAmount = (usdtAmt / 5) | |
703 | 712 | $Tuple2(nil, [usdtAmt, minWlg, maxWlg, profitAmount]) | |
704 | 713 | } | |
705 | 714 | ||
706 | 715 | ||
707 | 716 | ||
708 | 717 | @Callable(i) | |
709 | 718 | func claim () = { | |
710 | 719 | let prologResult = prolog2() | |
711 | 720 | if ((prologResult == prologResult)) | |
712 | 721 | then if ((size(i.payments) != 0)) | |
713 | 722 | then throw("No payments required") | |
714 | 723 | else { | |
715 | 724 | let $t01404514114 = claimInternal2(toString(i.caller)) | |
716 | 725 | let actions = $t01404514114._1 | |
717 | 726 | let wlgClaimedAmount = $t01404514114._2 | |
718 | 727 | $Tuple2((actions :+ ScriptTransfer(i.caller, wlgClaimedAmount, wlgAssetId)), prologResult) | |
719 | 728 | } | |
720 | 729 | else throw("Strict value is not equal to itself.") | |
721 | 730 | } | |
722 | 731 | ||
723 | 732 | ||
724 | 733 | ||
725 | 734 | @Callable(i) | |
726 | 735 | func onStakeUnstakeLand (addr) = if (if (if ((i.caller != stakingContract)) | |
727 | 736 | then (i.caller != acresContract) | |
728 | 737 | else false) | |
729 | 738 | then (i.caller != acres2Contract) | |
730 | 739 | else false) | |
731 | 740 | then throw("Permission denied") | |
732 | 741 | else { | |
733 | 742 | let $t01443314487 = claimInternal2(addr) | |
734 | 743 | let actions = $t01443314487._1 | |
735 | 744 | let wlgClaimedAmount = $t01443314487._2 | |
736 | 745 | $Tuple2(if ((wlgClaimedAmount > 0)) | |
737 | 746 | then (actions :+ ScriptTransfer(addressFromStringValue(addr), wlgClaimedAmount, wlgAssetId)) | |
738 | 747 | else actions, wlgClaimedAmount) | |
739 | 748 | } | |
740 | 749 | ||
741 | 750 | ||
742 | 751 | ||
743 | 752 | @Callable(i) | |
744 | 753 | func burnWlgold (wlgAmt) = if ((i.caller != acres2Contract)) | |
745 | 754 | then throw("Permission denied") | |
746 | 755 | else { | |
747 | 756 | let curStats = getWlgStats2("", [rest2Contract, acres2Contract, wlgContract, puzzlePoolContract, investFundContract], usdtAssetId, 0) | |
748 | 757 | if ((wlgAmt > curStats[ixWlgWlg])) | |
749 | 758 | then throw(((("Only " + fixedPoint(curStats[ixWlgWlg], 8)) + " WLGOLD left on contract, can't burn ") + fixedPoint(wlgAmt, 8))) | |
750 | 759 | else { | |
751 | 760 | let wlgAmountLeft = (curStats[ixWlgAmount] - wlgAmt) | |
752 | 761 | $Tuple2([Burn(wlgAssetId, wlgAmt), IntegerEntry(wlgIssuedAmountKey, wlgAmountLeft)], wlgAmountLeft) | |
753 | 762 | } | |
754 | 763 | } | |
755 | 764 | ||
756 | 765 | ||
757 | 766 | ||
758 | 767 | @Callable(i) | |
759 | 768 | func betForTicket (bet) = { | |
760 | 769 | let prologResult = prolog2() | |
761 | 770 | if ((prologResult == prologResult)) | |
762 | 771 | then if ((size(i.payments) != 0)) | |
763 | 772 | then throw("No payments required") | |
764 | 773 | else { | |
765 | 774 | let addr = toString(i.caller) | |
766 | 775 | let drawWeek = ((height / WEEK_BLOCKS) - 1) | |
767 | 776 | let userTickets = valueOrElse(getInteger(keyUserWeekTickets(addr, drawWeek)), 0) | |
768 | 777 | let weekTickets = valueOrElse(getInteger(keyTotalWeekTickets(drawWeek)), 0) | |
769 | 778 | if (if ((userTickets > 0)) | |
770 | 779 | then (weekTickets > 0) | |
771 | 780 | else false) | |
772 | 781 | then throw("Please open the chest first") | |
773 | 782 | else if (((bet / 4) != 0)) | |
774 | 783 | then throw("Invalid bet: should be 0..3") | |
775 | 784 | else { | |
776 | 785 | let moment = (height % DAY_BLOCKS) | |
777 | 786 | if ((moment > (DAY_BLOCKS - 3))) | |
778 | 787 | then throw((("Cannot bet: the day is almost ended, please wait " + toString((DAY_BLOCKS - moment))) + " blocks")) | |
779 | 788 | else { | |
780 | 789 | let stakedAcres = valueOrElse(getInteger(acres2Contract, keyAcresStakedAmtByUser(addr)), 0) | |
781 | 790 | if ((ACRES_FOR_BET > stakedAcres)) | |
782 | 791 | then throw((("You need to stake at least " + fixedPoint(ACRES_FOR_BET, 8)) + " ACRES to bet")) | |
783 | 792 | else { | |
784 | 793 | let tomorrow = ((height / DAY_BLOCKS) + 1) | |
785 | 794 | let betKey = keyUserBet(addr) | |
786 | 795 | let oldUserBetStr = getString(betKey) | |
787 | 796 | let newBetEntry = StringEntry(betKey, ((toString(tomorrow) + "_") + toString(bet))) | |
788 | 797 | if (isDefined(oldUserBetStr)) | |
789 | 798 | then { | |
790 | 799 | let userBet = value(oldUserBetStr) | |
791 | 800 | if ((split(userBet, "_")[0] == toString(tomorrow))) | |
792 | 801 | then throw("You already bet for tomorrow") | |
793 | 802 | else { | |
794 | 803 | let r = claimTicketsInternal(addr, userBet) | |
795 | 804 | $Tuple2((r._1 :+ newBetEntry), r._2) | |
796 | 805 | } | |
797 | 806 | } | |
798 | 807 | else $Tuple2([newBetEntry], 0) | |
799 | 808 | } | |
800 | 809 | } | |
801 | 810 | } | |
802 | 811 | } | |
803 | 812 | else throw("Strict value is not equal to itself.") | |
804 | 813 | } | |
805 | 814 | ||
806 | 815 | ||
807 | 816 | ||
808 | 817 | @Callable(i) | |
809 | 818 | func takeWlgXp (addr) = if ((i.caller != stakingContract)) | |
810 | 819 | then throw("Permission denied") | |
811 | 820 | else { | |
812 | 821 | let $t01709717140 = takeXpInternal(addr, 0) | |
813 | 822 | let actions = $t01709717140._1 | |
814 | 823 | let xp = $t01709717140._2 | |
815 | 824 | $Tuple2(actions, xp) | |
816 | 825 | } | |
817 | 826 | ||
818 | 827 | ||
819 | 828 | ||
820 | 829 | @Callable(i) | |
821 | 830 | func checkWlgXpREADONLY (addr) = { | |
822 | 831 | let $t01721717265 = takeXpInternal(addr, 0) | |
823 | 832 | let ignored = $t01721717265._1 | |
824 | 833 | let deltaXP = $t01721717265._2 | |
825 | 834 | let newXP = (valueOrElse(getInteger(stakingContract, keyUserXP(addr)), 0) + deltaXP) | |
826 | 835 | let lvlPoints = levelUp(valueOrElse(getInteger(stakingContract, keyUserLevel(addr)), 0), newXP) | |
827 | 836 | $Tuple2(nil, (lvlPoints :+ newXP)) | |
828 | 837 | } | |
829 | 838 | ||
830 | 839 | ||
831 | 840 | ||
832 | 841 | @Callable(i) | |
833 | 842 | func setNumPrizes (numPrizes) = if ((i.caller != this)) | |
834 | 843 | then throw("Permission denied") | |
835 | 844 | else { | |
836 | 845 | let week = (height / WEEK_BLOCKS) | |
837 | 846 | $Tuple2([IntegerEntry(keyNumNFT2Draw(week), numPrizes)], numPrizes) | |
838 | 847 | } | |
839 | 848 | ||
840 | 849 | ||
841 | 850 | ||
842 | 851 | @Callable(i) | |
843 | 852 | func openChest () = if (!(KS_ALLOW_NFT_DRAW)) | |
844 | 853 | then throw("Temporarily disabled") | |
845 | 854 | else { | |
846 | 855 | let prologResult = prolog2() | |
847 | 856 | if ((prologResult == prologResult)) | |
848 | 857 | then if ((size(i.payments) != 0)) | |
849 | 858 | then throw("No payments required") | |
850 | 859 | else { | |
851 | 860 | let drawWeek = ((height / WEEK_BLOCKS) - 1) | |
852 | 861 | let addr = toString(i.caller) | |
853 | 862 | let userTickets = valueOrElse(getInteger(keyUserWeekTickets(addr, drawWeek)), 0) | |
854 | 863 | if ((0 >= userTickets)) | |
855 | 864 | then throw("No gems to open the chest") | |
856 | 865 | else openChestInternal(addr) | |
857 | 866 | } | |
858 | 867 | else throw("Strict value is not equal to itself.") | |
859 | 868 | } | |
860 | 869 | ||
861 | 870 |
github/deemru/w8io/026f985 71.45 ms ◑