tx · DXhct1DQvaxrZftrrzeSP1QSVkxoshF4c1vrTfEj6Tde

3N7HtrKeFFLz5oy6PfGv1Lg3GwPk4gCPdGy:  -0.02100000 Waves

2024.06.27 14:49 [3169094] smart account 3N7HtrKeFFLz5oy6PfGv1Lg3GwPk4gCPdGy > SELF 0.00000000 Waves

{ "type": 13, "id": "DXhct1DQvaxrZftrrzeSP1QSVkxoshF4c1vrTfEj6Tde", "fee": 2100000, "feeAssetId": null, "timestamp": 1719488996547, "version": 2, "chainId": 84, "sender": "3N7HtrKeFFLz5oy6PfGv1Lg3GwPk4gCPdGy", "senderPublicKey": "FsR18761ZAsUqsTd7TK3XmR6bhihs1UXVmpHYxz5JzQ1", "proofs": [ "4KCmo9M561ubnW21Y5FyWsbipAqz2RkW2Y9wgLmD7kC2axdHXHh9diRMnSdqZfkwLJ528GuBMdvbaEJD95rvT4or" ], "script": "base64:BgIsCAISBgoECAgICBIDCgEBEgMKAQESABIDCgEIEgASAwoBARIDCgEIEgMKAQhyAAJNNgDAhD0AAk04AIDC1y8ACE1JTExJT042AICA6YOx3hYADk1BUktFVElOR1NIQVJFAKCNBgAJVEVBTVNIQVJFAMCaDAANQUNUSVZJVFlTSEFSRQCgjQYAC1BMQVlFUlNIQVJFAIC1GAAKWUVBUk1JTExJUwCAhuvHdQAJQ0hFQ0tUSU1FAIDJ4KuwAQAJREFZTUlMTElTAIC4mSkACEJBTktfRkVFANCGAwACY2gJAMkBAgkAygECCAUEdGhpcwVieXRlcwABAAEAE1VTRFRfVFZMX0NPUlJFQ1RJT04EByRtYXRjaDAFAmNoAwkAAAIBAVcFByRtYXRjaDAA8PWowAQDCQAAAgEBVAUHJG1hdGNoMAAACQACAQINVW5rbm93biBjaGFpbgAQbWFya2V0aW5nQWRkcktleQINbWFya2V0aW5nQWRkcgALdGVhbUFkZHJLZXkCCHRlYW1BZGRyABRsYXN0TWFya2V0aW5nVGltZUtleQIZbGFzdENsYWltZWRUaW1lX21hcmtldGluZwAWbWFya2V0a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2FjdGlvbnMJAJQKAgUMcHJvbG9nUmVzdWx0BQ5hY2NTdGF0c1Jlc3VsdAkAAgECJFN0cmljdCB2YWx1ZSBpcyBub3QgZXF1YWwgdG8gaXRzZWxmLgFpAQl0YWtlV2xnWHABBGFkZHIDCQECIT0CCAUBaQZjYWxsZXIFD3N0YWtpbmdDb250cmFjdAkAAgECEVBlcm1pc3Npb24gZGVuaWVkBA0kdDAxMTA5NTExMTM4CQEOdGFrZVhwSW50ZXJuYWwCBQRhZGRyAAAEB2FjdGlvbnMIBQ0kdDAxMTA5NTExMTM4Al8xBAJ4cAgFDSR0MDExMDk1MTExMzgCXzIJAJQKAgUHYWN0aW9ucwUCeHABaQESY2hlY2tXbGdYcFJFQURPTkxZAQRhZGRyBA0kdDAxMTIxNTExMjYzCQEOdGFrZVhwSW50ZXJuYWwCBQRhZGRyAAAEB2lnbm9yZWQIBQ0kdDAxMTIxNTExMjYzAl8xBAdkZWx0YVhQCAUNJHQwMTEyMTUxMTI2MwJfMgQFbmV3WFAJAGQCCQELdmFsdWVPckVsc2UCCQCaCAIFD3N0YWtpbmdDb250cmFjdAkBCWtleVVzZXJYUAEFBGFkZHIAAAUHZGVsdGFYUAQJbHZsUG9pbnRzCQEHbGV2ZWxVcAIJAQt2YWx1ZU9yRWxzZQIJAJoIAgUPc3Rha2luZ0NvbnRyYWN0CQEMa2V5VXNlckxldmVsAQUEYWRkcgAABQVuZXdYUAkAlAoCBQNuaWwJAM0IAgUJbHZsUG9pbnRzBQVuZXdYUABEJ+XN", "height": 3169094, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: J4HPKq5EzF5DhwL1GKHvpVXPcP4Z1moziDgahPLPdJDB Next: FrggMfs6QLRkDrUVXQuvh2ve2y8ajdJQMxy6BvGLWcja Diff:
OldNewDifferences
2222 let DAYMILLIS = 86400000
2323
2424 let BANK_FEE = 50000
25+
26+let ch = take(drop(this.bytes, 1), 1)
27+
28+let USDT_TVL_CORRECTION = match ch {
29+ case _ =>
30+ if ((base58'2W' == $match0))
31+ then 1208630000
32+ else if ((base58'2T' == $match0))
33+ then 0
34+ else throw("Unknown chain")
35+}
2536
2637 let marketingAddrKey = "marketingAddr"
2738
194205 let bankFromUser = fraction(userTemp, BANK_FEE, M6)
195206 let robbedUser = (userTemp - bankFromUser)
196207 let unrobbedUser = fraction(userAvailable, ((eff[idxUserPieces] * M8) + eff[idxUserAcres]), ((eff[idxTotalPieces] * M8) + eff[idxTotalAcres]))
197-[issuedAmount, fraction(totalFundsUsd, M8, issuedAmount), totalFundsUsd, economyUsd, restUsd, wlgUsd, puzzleUsd, issueTime, lastMarketingTime, marketingTotal, marketingAmountLeft, marketingAmountAvailableNow, marketingWlgold, teamTotal, teamAmountLeft, teamAmountAvailableNow, teamWlgold, actTotal, actAmountLeft, actAmountAvailableNow, actWlgold, curPeriod, amountLeftTotal, curPeriodDistribution, lastUserTime, robbedUser, sLandDailyAmount, investFundTotal, unrobbedUser, effLastTime, (bankFromMarketing + bankFromUser), bankWlgold]
208+[issuedAmount, fraction((totalFundsUsd - USDT_TVL_CORRECTION), M8, issuedAmount), totalFundsUsd, economyUsd, restUsd, wlgUsd, puzzleUsd, issueTime, lastMarketingTime, marketingTotal, marketingAmountLeft, marketingAmountAvailableNow, marketingWlgold, teamTotal, teamAmountLeft, teamAmountAvailableNow, teamWlgold, actTotal, actAmountLeft, actAmountAvailableNow, actWlgold, curPeriod, amountLeftTotal, curPeriodDistribution, lastUserTime, robbedUser, sLandDailyAmount, investFundTotal, unrobbedUser, effLastTime, (bankFromMarketing + bankFromUser), bankWlgold]
198209 }
199210
200211
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let M6 = 1000000
55
66 let M8 = 100000000
77
88 let MILLION6 = 100000000000000
99
1010 let MARKETINGSHARE = 100000
1111
1212 let TEAMSHARE = 200000
1313
1414 let ACTIVITYSHARE = 100000
1515
1616 let PLAYERSHARE = 400000
1717
1818 let YEARMILLIS = 31557600000
1919
2020 let CHECKTIME = 47336400000
2121
2222 let DAYMILLIS = 86400000
2323
2424 let BANK_FEE = 50000
25+
26+let ch = take(drop(this.bytes, 1), 1)
27+
28+let USDT_TVL_CORRECTION = match ch {
29+ case _ =>
30+ if ((base58'2W' == $match0))
31+ then 1208630000
32+ else if ((base58'2T' == $match0))
33+ then 0
34+ else throw("Unknown chain")
35+}
2536
2637 let marketingAddrKey = "marketingAddr"
2738
2839 let teamAddrKey = "teamAddr"
2940
3041 let lastMarketingTimeKey = "lastClaimedTime_marketing"
3142
3243 let marketingAmountLeftKey = "marketingAmountLeft"
3344
3445 let lastTeamTimeKey = "lastClaimedTime_team"
3546
3647 let teamAmountLeftKey = "teamAmountLeft"
3748
3849 let lastActivitiesTimeKey = "lastClaimedTime_activities"
3950
4051 let actAmountLeftKey = "activitiesAmountLeft"
4152
4253 let stakersAmountLeftKey = "stakersAmountLeft"
4354
4455 func keyLastClaimedTimeByUser (addr) = ("lastClaimedTimeUser_" + addr)
4556
4657
4758 func keyLastArbTimeByUser (addr) = ("lastArbTimeUser_" + addr)
4859
4960
5061 func distributionByPeriod (period) = fraction(MILLION6, (PLAYERSHARE * (period + 1)), (6 * M6))
5162
5263
5364 let wlgIssueTimeKey = "wlg_issueTime"
5465
5566 let wlgIssuedAmountKey = "wlg_issuedAmount"
5667
5768 let zbIssuedAmountKey = "zbill_issuedAmount"
5869
5970 func keyAcresStakedAmountByUser (addr) = ("acresStakedAmountByUser_" + addr)
6071
6172
6273 let acresStakedTotalKey = "acresStakedAmountTotal"
6374
6475 func keyWlgStakedAmountByUser (addr) = ("wlgStakedAmountByUser_" + addr)
6576
6677
6778 let wlgStakedTotalKey = "wlgStakedAmountTotal"
6879
6980 func keyWlgStakedTimeByUser (addr) = ("wlgStakedTimeByUser_" + addr)
7081
7182
7283 let dappRest = 0
7384
7485 let dappStaking = 1
7586
7687 let dappEconomy = 2
7788
7889 let dappWlg = 3
7990
8091 let dappPuzzle = 4
8192
8293 let dappInvestFund = 5
8394
8495 let dappAcres = 6
8596
8697 func getLands (userAddrStrOrEmpty,stakingContract,acresContract) = {
8798 let props = split(valueOrElse(getString(stakingContract, "resTypesProportions"), "0_0_0_0_0_0"), "_")
8899 func adder (acc,item) = (acc + parseIntValue(item))
89100
90101 let totalPieces = {
91102 let $l = props
92103 let $s = size($l)
93104 let $acc0 = 0
94105 func $f0_1 ($a,$i) = if (($i >= $s))
95106 then $a
96107 else adder($a, $l[$i])
97108
98109 func $f0_2 ($a,$i) = if (($i >= $s))
99110 then $a
100111 else throw("List size exceeds 6")
101112
102113 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6)
103114 }
104115 let userPieces = valueOrElse(getInteger(stakingContract, ("stakedPiecesByOwner_" + userAddrStrOrEmpty)), 0)
105116 let totalAcres = valueOrElse(getInteger(acresContract, acresStakedTotalKey), 0)
106117 let userAcres = valueOrElse(getInteger(acresContract, keyAcresStakedAmountByUser(userAddrStrOrEmpty)), 0)
107118 [totalPieces, userPieces, totalAcres, userAcres]
108119 }
109120
110121
111122 let idxTotalPieces = 0
112123
113124 let idxUserPieces = 1
114125
115126 let idxTotalAcres = 2
116127
117128 let idxUserAcres = 3
118129
119130 func getWlgStats (userAddrOpt,contracts,usdtId,usdtBalanceCorrection,userProportion6) = {
120131 let issuedAmount = valueOrErrorMessage(getInteger(contracts[dappWlg], wlgIssuedAmountKey), "WLGOLD is not issued yet")
121132 let economyUsd = assetBalance(contracts[dappEconomy], usdtId)
122133 let restUsd = assetBalance(contracts[dappRest], usdtId)
123134 let wlgUsd = (assetBalance(contracts[dappWlg], usdtId) - usdtBalanceCorrection)
124135 let puzzleUsd = assetBalance(contracts[dappPuzzle], usdtId)
125136 let investFundContract = contracts[dappInvestFund]
126137 let investFundTotal = (assetBalance(investFundContract, usdtId) + valueOrElse(getInteger(investFundContract, zbIssuedAmountKey), 0))
127138 let totalFundsUsd = ((economyUsd + wlgUsd) + investFundTotal)
128139 let wlgId = valueOrErrorMessage(getBinary(contracts[dappWlg], "wlg_assetId"), "Not initialized yet")
129140 let now = lastBlock.timestamp
130141 let issueTime = valueOrErrorMessage(getInteger(contracts[dappWlg], wlgIssueTimeKey), "Not initialized")
131142 let marketingTotal = fraction(MILLION6, MARKETINGSHARE, M6)
132143 let marketingAmountLeft = valueOrElse(getInteger(contracts[dappWlg], marketingAmountLeftKey), marketingTotal)
133144 let lastMarketingTime = valueOrElse(getInteger(contracts[dappWlg], lastMarketingTimeKey), issueTime)
134145 let marketingAddr = addressFromStringValue(value(getString(contracts[dappWlg], marketingAddrKey)))
135146 let marketingTemp = min([fraction(marketingTotal, (now - lastMarketingTime), YEARMILLIS), marketingAmountLeft])
136147 let bankFromMarketing = fraction(marketingTemp, BANK_FEE, M6)
137148 let marketingAmountAvailableNow = (marketingTemp - bankFromMarketing)
138149 let marketingWlgold = assetBalance(marketingAddr, wlgId)
139150 let bankWlgold = assetBalance(contracts[dappStaking], wlgId)
140151 let teamTotal = fraction(MILLION6, TEAMSHARE, M6)
141152 let teamAmountLeft = valueOrElse(getInteger(contracts[dappWlg], teamAmountLeftKey), teamTotal)
142153 let lastTeamTime = valueOrElse(getInteger(contracts[dappWlg], lastTeamTimeKey), issueTime)
143154 let teamAddr = addressFromStringValue(value(getString(contracts[dappWlg], teamAddrKey)))
144155 let teamAmountAvailableNow = min([fraction(teamTotal, (now - lastTeamTime), (3 * YEARMILLIS)), teamAmountLeft])
145156 let teamWlgold = assetBalance(teamAddr, wlgId)
146157 let actTotal = fraction(MILLION6, ACTIVITYSHARE, M6)
147158 let actAmountLeft = valueOrElse(getInteger(contracts[dappWlg], actAmountLeftKey), actTotal)
148159 let lastActivitiesTime = valueOrElse(getInteger(contracts[dappWlg], lastActivitiesTimeKey), issueTime)
149160 let actAmountAvailableNow = min([fraction(actTotal, (now - lastActivitiesTime), (3 * YEARMILLIS)), actAmountLeft])
150161 let actWlgold = assetBalance(contracts[dappRest], wlgId)
151162 let lastUserTime = valueOrElse(getInteger(contracts[dappWlg], keyLastClaimedTimeByUser(userAddrOpt)), issueTime)
152163 let lastUserPeriod = ((lastUserTime - issueTime) / YEARMILLIS)
153164 let nowLimited = min([now, (issueTime + (3 * YEARMILLIS))])
154165 let curPeriod = min([((now - issueTime) / YEARMILLIS), 2])
155166 let eff = getLands(userAddrOpt, contracts[dappStaking], contracts[dappAcres])
156167 let curPeriodDistribution = distributionByPeriod(curPeriod)
157168 let $t079142 = if ((lastUserPeriod == curPeriod))
158169 then {
159170 let a0 = fraction(curPeriodDistribution, (nowLimited - lastUserTime), YEARMILLIS)
160171 let userPart = fraction(a0, userProportion6, M6)
161172 let effTime = (lastUserTime + fraction((nowLimited - lastUserTime), userProportion6, M6))
162173 $Tuple3(userPart, a0, effTime)
163174 }
164175 else if ((lastUserPeriod == (curPeriod - 1)))
165176 then {
166177 let a1 = fraction(distributionByPeriod((curPeriod - 1)), ((issueTime + (YEARMILLIS * curPeriod)) - lastUserTime), YEARMILLIS)
167178 let a0 = fraction(curPeriodDistribution, (nowLimited - (issueTime + (YEARMILLIS * curPeriod))), YEARMILLIS)
168179 let avail = (a1 + a0)
169180 let userPart = fraction(avail, userProportion6, M6)
170181 let effTime = if ((a1 >= userPart))
171182 then (lastUserTime + fraction(YEARMILLIS, userPart, distributionByPeriod((curPeriod - 1))))
172183 else ((issueTime + (YEARMILLIS * curPeriod)) + fraction(YEARMILLIS, (userPart - a1), curPeriodDistribution))
173184 $Tuple3(userPart, avail, effTime)
174185 }
175186 else {
176187 let a2 = fraction(distributionByPeriod((curPeriod - 2)), ((issueTime + (YEARMILLIS * (curPeriod - 1))) - lastUserTime), YEARMILLIS)
177188 let a1 = distributionByPeriod((curPeriod - 1))
178189 let a0 = fraction(curPeriodDistribution, (nowLimited - (issueTime + (YEARMILLIS * curPeriod))), YEARMILLIS)
179190 let avail = ((a2 + a1) + a0)
180191 let userPart = fraction(avail, userProportion6, M6)
181192 let effTime = if ((a2 >= userPart))
182193 then (lastUserTime + fraction(YEARMILLIS, userPart, distributionByPeriod((curPeriod - 2))))
183194 else if (((a2 + a1) >= userPart))
184195 then ((issueTime + (YEARMILLIS * (curPeriod - 1))) + fraction(YEARMILLIS, (userPart - a2), distributionByPeriod((curPeriod - 1))))
185196 else ((issueTime + (YEARMILLIS * curPeriod)) + fraction(YEARMILLIS, ((userPart - a2) - a1), curPeriodDistribution))
186197 $Tuple3(userPart, avail, effTime)
187198 }
188199 let userAmount = $t079142._1
189200 let userAvailable = $t079142._2
190201 let effLastTime = $t079142._3
191202 let sLandDailyAmount = fraction(fraction(curPeriodDistribution, DAYMILLIS, YEARMILLIS), 25, eff[idxTotalPieces])
192203 let amountLeftTotal = valueOrElse(getInteger(contracts[dappWlg], stakersAmountLeftKey), 0)
193204 let userTemp = fraction(userAmount, ((eff[idxUserPieces] * M8) + eff[idxUserAcres]), ((eff[idxTotalPieces] * M8) + eff[idxTotalAcres]))
194205 let bankFromUser = fraction(userTemp, BANK_FEE, M6)
195206 let robbedUser = (userTemp - bankFromUser)
196207 let unrobbedUser = fraction(userAvailable, ((eff[idxUserPieces] * M8) + eff[idxUserAcres]), ((eff[idxTotalPieces] * M8) + eff[idxTotalAcres]))
197-[issuedAmount, fraction(totalFundsUsd, M8, issuedAmount), totalFundsUsd, economyUsd, restUsd, wlgUsd, puzzleUsd, issueTime, lastMarketingTime, marketingTotal, marketingAmountLeft, marketingAmountAvailableNow, marketingWlgold, teamTotal, teamAmountLeft, teamAmountAvailableNow, teamWlgold, actTotal, actAmountLeft, actAmountAvailableNow, actWlgold, curPeriod, amountLeftTotal, curPeriodDistribution, lastUserTime, robbedUser, sLandDailyAmount, investFundTotal, unrobbedUser, effLastTime, (bankFromMarketing + bankFromUser), bankWlgold]
208+[issuedAmount, fraction((totalFundsUsd - USDT_TVL_CORRECTION), M8, issuedAmount), totalFundsUsd, economyUsd, restUsd, wlgUsd, puzzleUsd, issueTime, lastMarketingTime, marketingTotal, marketingAmountLeft, marketingAmountAvailableNow, marketingWlgold, teamTotal, teamAmountLeft, teamAmountAvailableNow, teamWlgold, actTotal, actAmountLeft, actAmountAvailableNow, actWlgold, curPeriod, amountLeftTotal, curPeriodDistribution, lastUserTime, robbedUser, sLandDailyAmount, investFundTotal, unrobbedUser, effLastTime, (bankFromMarketing + bankFromUser), bankWlgold]
198209 }
199210
200211
201212 let SCALE8 = 100000000
202213
203214 let xpLevelScale = 3200
204215
205216 let xpLevelRecipPow = 4000
206217
207218 let numPointsOnLevelUp = 3
208219
209220 let wlgBaseAmountXp = 100000000000
210221
211222 func keyUserXP (addr) = ("userXP_" + addr)
212223
213224
214225 func keyUserLevel (addr) = ("userLevel_" + addr)
215226
216227
217228 let xpWlg = 10000
218229
219230 func levelByXP (xp) = fraction(xpLevelScale, pow(xp, 4, xpLevelRecipPow, 4, 4, DOWN), SCALE8)
220231
221232
222233 func levelUp (currLevel,newXP) = {
223234 let newLevel = levelByXP(newXP)
224235 [newLevel, (numPointsOnLevelUp * (newLevel - currLevel))]
225236 }
226237
227238
228239 let DAY_MILLIS = 86400000
229240
230241 let chain = take(drop(this.bytes, 1), 1)
231242
232243 let usdtAssetId = match chain {
233244 case _ =>
234245 if ((base58'2W' == $match0))
235246 then base58'9wc3LXNA4TEBsXyKtoLE9mrbDD7WMHXvXrCjZvabLAsi'
236247 else if ((base58'2T' == $match0))
237248 then base58'6mWwf9mZBjVgkC54idpyaZLQfAosD914wT8fGf2iiY63'
238249 else throw("Unknown chain")
239250 }
240251
241252 let defaultRestAddressStr = match chain {
242253 case _ =>
243254 if ((base58'2W' == $match0))
244255 then "3PQCuvFbvh4LkPUnrnU1z3jnbA1p9m3WNhv"
245256 else if ((base58'2T' == $match0))
246257 then "3MumkGGztCKAXpWDqxkddofqXSUbqQkvSJy"
247258 else throw("Unknown chain")
248259 }
249260
250261 let arbitrageDelay = match chain {
251262 case _ =>
252263 if ((base58'2W' == $match0))
253264 then DAY_MILLIS
254265 else if ((base58'2T' == $match0))
255266 then 60000
256267 else throw("Unknown chain")
257268 }
258269
259270 let SEP = "__"
260271
261272 let MULT6 = 1000000
262273
263274 let MULT8 = 100000000
264275
265276 let MINSHOPPAYMENT = 100000
266277
267278 func getStringOrFail (address,key) = valueOrErrorMessage(getString(address, key), makeString(["mandatory ", toString(address), ".", key, " is not defined"], ""))
268279
269280
270281 let IdxCfgStakingDapp = 1
271282
272283 let IdxCfgEconomyDapp = 2
273284
274285 let IdxCfgWlgDapp = 4
275286
276287 let IdxCfgPuzzlePoolDapp = 5
277288
278289 let IdxCfgInvestFundDapp = 6
279290
280291 let IdxCfgAcresDapp = 8
281292
282293 func keyRestCfg () = "%s__restConfig"
283294
284295
285296 func keyRestAddress () = "%s__restAddr"
286297
287298
288299 func readRestCfgOrFail (rest) = split_4C(getStringOrFail(rest, keyRestCfg()), SEP)
289300
290301
291302 func getContractAddressOrFail (restCfg,idx) = valueOrErrorMessage(addressFromString(restCfg[idx]), ("Rest cfg doesn't contain address at index " + toString(idx)))
292303
293304
294305 let restContract = addressFromStringValue(valueOrElse(getString(this, keyRestAddress()), defaultRestAddressStr))
295306
296307 let restCfg = readRestCfgOrFail(restContract)
297308
298309 let stakingContract = getContractAddressOrFail(restCfg, IdxCfgStakingDapp)
299310
300311 let economyContract = getContractAddressOrFail(restCfg, IdxCfgEconomyDapp)
301312
302313 let wlgContract = getContractAddressOrFail(restCfg, IdxCfgWlgDapp)
303314
304315 let puzzlePoolContract = getContractAddressOrFail(restCfg, IdxCfgPuzzlePoolDapp)
305316
306317 let investFundContract = getContractAddressOrFail(restCfg, IdxCfgInvestFundDapp)
307318
308319 let acresContract = getContractAddressOrFail(restCfg, IdxCfgAcresDapp)
309320
310321 let wlgAssetIdKey = "wlg_assetId"
311322
312323 let wlgAssetId = valueOrErrorMessage(getBinary(wlgContract, wlgAssetIdKey), "WLGOLD is not issued yet")
313324
314325 let idxWlgAmount = 0
315326
316327 let idxWlgPrice = 1
317328
318329 let idxWlgFunds = 2
319330
320331 let idxWlgIssueTime = 7
321332
322333 let idxWlgMarketingAmLeft = 10
323334
324335 let idxWlgMarketingAmAvailNow = 11
325336
326337 let idxWlgTeamAmLeft = 14
327338
328339 let idxWlgTeamAmAvailNow = 15
329340
330341 let idxWlgActAmLeft = 18
331342
332343 let idxWlgActAmAvailNow = 19
333344
334345 let idxWlgAmLeftTotal = 22
335346
336347 let idxWlgUserAmAvailNow = 25
337348
338349 let idxWlgUserTotalAvail = 28
339350
340351 let idxWlgEffUserTime = 29
341352
342353 let idxWlgBankAvailNow = 30
343354
344355 let IdxEffUser = 1
345356
346357 func keyResProportions () = "resTypesProportions"
347358
348359
349360 func keyStakedPiecesByOwner (ownerAddr) = ("stakedPiecesByOwner_" + ownerAddr)
350361
351362
352363 func asInt (v) = match v {
353364 case n: Int =>
354365 n
355366 case _ =>
356367 throw("fail to cast into Int")
357368 }
358369
359370
360371 func getVotingPower (userAddrStrOrEmpty) = {
361372 let props = split(valueOrElse(getString(stakingContract, keyResProportions()), "0_0_0_0_0_0"), "_")
362373 func adder (acc,item) = (acc + parseIntValue(item))
363374
364375 let totalPower = {
365376 let $l = props
366377 let $s = size($l)
367378 let $acc0 = 0
368379 func $f0_1 ($a,$i) = if (($i >= $s))
369380 then $a
370381 else adder($a, $l[$i])
371382
372383 func $f0_2 ($a,$i) = if (($i >= $s))
373384 then $a
374385 else throw("List size exceeds 6")
375386
376387 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6)
377388 }
378389 let usersPower = valueOrElse(getInteger(stakingContract, keyStakedPiecesByOwner(userAddrStrOrEmpty)), 0)
379390 [totalPower, usersPower]
380391 }
381392
382393
383394 func fixedPoint (val,decimals) = {
384395 let tenPow = pow(10, 0, decimals, 0, 0, DOWN)
385396 let lowPart = toString((val % tenPow))
386397 let zeroes = drop(toString(tenPow), (1 + size(lowPart)))
387398 (((toString((val / tenPow)) + ".") + zeroes) + lowPart)
388399 }
389400
390401
391402 let profitAddrKey = "profitAddr"
392403
393404 let stakersAmountPaidTotalKey = "stakersAmountPaidTotal"
394405
395406 func keyStakersAmountPaidUser (addr) = ("stakersAmountPaidUser_" + addr)
396407
397408
398409 func prolog () = asInt(reentrantInvoke(stakingContract, "saveLastTx", nil, nil))
399410
400411
401412 func getSwapLimitWlg (addr) = {
402413 let lastTime = valueOrElse(getInteger(keyLastArbTimeByUser(addr)), 0)
403414 let now = lastBlock.timestamp
404415 if ((arbitrageDelay > (now - lastTime)))
405416 then throw((("Arbitrages are possible once a " + toString((arbitrageDelay / 60000))) + "min"))
406417 else {
407418 let pieces = getVotingPower(addr)[IdxEffUser]
408419 let acresAmount = valueOrElse(getInteger(acresContract, keyAcresStakedAmountByUser(addr)), 0)
409420 ((pieces * MULT8) + acresAmount)
410421 }
411422 }
412423
413424
414425 func claimInternal (addr,proportion6) = {
415426 let caller = addressFromStringValue(addr)
416427 let curStats = getWlgStats(addr, [restContract, stakingContract, economyContract, wlgContract, puzzlePoolContract, investFundContract, acresContract], usdtAssetId, 0, proportion6)
417428 let now = lastBlock.timestamp
418429 let issueTime = curStats[idxWlgIssueTime]
419430 let marketingAmountLeft = curStats[idxWlgMarketingAmLeft]
420431 let marketingAmount = curStats[idxWlgMarketingAmAvailNow]
421432 let teamAmountLeft = curStats[idxWlgTeamAmLeft]
422433 let teamAmount = curStats[idxWlgTeamAmAvailNow]
423434 let actAmountLeft = curStats[idxWlgActAmLeft]
424435 let actAmount = curStats[idxWlgActAmAvailNow]
425436 if (((now - issueTime) > CHECKTIME))
426437 then throw("Please modify contract for next 1.5 years, according to stats")
427438 else {
428439 let userAmount = curStats[idxWlgUserAmAvailNow]
429440 let userKey = keyStakersAmountPaidUser(addr)
430441 let userTotal = curStats[idxWlgUserTotalAvail]
431442 let userEffTime = curStats[idxWlgEffUserTime]
432443 let bankAmount = curStats[idxWlgBankAvailNow]
433444 $Tuple2([ScriptTransfer(addressFromStringValue(value(getString(marketingAddrKey))), marketingAmount, wlgAssetId), ScriptTransfer(addressFromStringValue(value(getString(teamAddrKey))), teamAmount, wlgAssetId), ScriptTransfer(restContract, actAmount, wlgAssetId), IntegerEntry(userKey, (valueOrElse(getInteger(userKey), 0) + userAmount)), IntegerEntry(stakersAmountPaidTotalKey, (valueOrElse(getInteger(stakersAmountPaidTotalKey), 0) + userTotal)), IntegerEntry(stakersAmountLeftKey, (curStats[idxWlgAmLeftTotal] - userTotal)), IntegerEntry(marketingAmountLeftKey, (marketingAmountLeft - marketingAmount)), IntegerEntry(lastMarketingTimeKey, now), IntegerEntry(teamAmountLeftKey, (teamAmountLeft - teamAmount)), IntegerEntry(lastTeamTimeKey, now), IntegerEntry(actAmountLeftKey, (actAmountLeft - actAmount)), IntegerEntry(lastActivitiesTimeKey, now), IntegerEntry(keyLastClaimedTimeByUser(addr), userEffTime)], $Tuple2(userAmount, bankAmount))
434445 }
435446 }
436447
437448
438449 func takeXpInternal (addr,delta) = {
439450 let now = lastBlock.timestamp
440451 let timeKey = keyWlgStakedTimeByUser(addr)
441452 let amountKey = keyWlgStakedAmountByUser(addr)
442453 let lastTime = valueOrElse(getInteger(timeKey), 0)
443454 let oldUser = valueOrElse(getInteger(amountKey), 0)
444455 let oldTotal = valueOrElse(getInteger(wlgStakedTotalKey), 0)
445456 let xp = fraction(fraction(xpWlg, oldUser, wlgBaseAmountXp), (lastTime - now), DAYMILLIS)
446457 $Tuple3([IntegerEntry(timeKey, now), IntegerEntry(amountKey, (oldUser + delta)), IntegerEntry(wlgStakedTotalKey, (oldTotal + delta))], xp, oldUser)
447458 }
448459
449460
450461 @Callable(i)
451462 func constructorV1 (restAddr,marketingAddr,teamAddr,profitAddr) = if ((i.caller != this))
452463 then throw("Permission denied")
453464 else if (isDefined(getBinary(wlgAssetIdKey)))
454465 then throw("Already initialized")
455466 else {
456467 let issuedAmount = MILLION6
457468 let issue = Issue("WLGOLD", "WavesLands Gold investment token", issuedAmount, 8, true, unit, 0)
458469 let assetId = calculateAssetId(issue)
459470 [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)]
460471 }
461472
462473
463474
464475 @Callable(i)
465476 func buyWlg (minAmount) = {
466477 let prologResult = prolog()
467478 if ((prologResult == prologResult))
468479 then if ((size(i.payments) != 1))
469480 then throw("exactly 1 payment must be attached")
470481 else {
471482 let pmt = i.payments[0]
472483 let usdtAmt = pmt.amount
473484 if (if (!(isDefined(pmt.assetId)))
474485 then true
475486 else (value(pmt.assetId) != usdtAssetId))
476487 then throw("USDT payments only!")
477488 else {
478489 let caller = i.caller
479490 let addr = toString(caller)
480491 if ((MINSHOPPAYMENT > usdtAmt))
481492 then throw((("You can trade min " + fixedPoint(MINSHOPPAYMENT, 6)) + " USDT"))
482493 else {
483494 let curStats = getWlgStats("", [restContract, stakingContract, economyContract, wlgContract, puzzlePoolContract, investFundContract, acresContract], usdtAssetId, usdtAmt, MULT6)
484495 let curWlgAmount = curStats[idxWlgAmount]
485496 let fundsUsd = curStats[idxWlgFunds]
486497 let wlgPrice = fraction(fundsUsd, MULT8, curWlgAmount)
487498 let buyPrice = fraction(wlgPrice, 6, 5)
488499 let wlgAmount = fraction(usdtAmt, MULT8, buyPrice)
489500 let maxWlg = getSwapLimitWlg(addr)
490501 if ((wlgAmount > maxWlg))
491502 then throw((("You can get max " + fixedPoint(maxWlg, 8)) + " WLGOLD"))
492503 else if ((minAmount > wlgAmount))
493504 then throw("Price changed during operation, please try again")
494505 else {
495506 let profitAmount = (usdtAmt / 6)
496507 let deltaFunds = (usdtAmt - profitAmount)
497508 let reissued = fraction(curWlgAmount, deltaFunds, fundsUsd)
498509 $Tuple2([Reissue(wlgAssetId, reissued, true), IntegerEntry(wlgIssuedAmountKey, (curWlgAmount + reissued)), IntegerEntry(keyLastArbTimeByUser(addr), lastBlock.timestamp), ScriptTransfer(addressFromStringValue(value(getString(profitAddrKey))), profitAmount, usdtAssetId), ScriptTransfer(caller, wlgAmount, wlgAssetId)], prologResult)
499510 }
500511 }
501512 }
502513 }
503514 else throw("Strict value is not equal to itself.")
504515 }
505516
506517
507518
508519 @Callable(i)
509520 func sellWlg (minAmount) = {
510521 let prologResult = prolog()
511522 if ((prologResult == prologResult))
512523 then if ((size(i.payments) != 1))
513524 then throw("exactly 1 payment must be attached")
514525 else {
515526 let pmt = i.payments[0]
516527 let wlgAmt = pmt.amount
517528 let caller = i.caller
518529 let addr = toString(caller)
519530 let maxWlg = getSwapLimitWlg(addr)
520531 if ((wlgAmt > maxWlg))
521532 then throw((("You can spend max " + fixedPoint(maxWlg, 8)) + " WLGOLD"))
522533 else if (if (!(isDefined(pmt.assetId)))
523534 then true
524535 else (value(pmt.assetId) != wlgAssetId))
525536 then throw("WLGOLD payments only!")
526537 else {
527538 let curStats = getWlgStats("", [restContract, stakingContract, economyContract, wlgContract, puzzlePoolContract, investFundContract, acresContract], usdtAssetId, 0, MULT6)
528539 let curWlgAmount = curStats[idxWlgAmount]
529540 let sellPrice = fraction(curStats[idxWlgPrice], 4, 5)
530541 let usdtAmt = fraction(wlgAmt, sellPrice, MULT8)
531542 if ((MINSHOPPAYMENT > usdtAmt))
532543 then throw((("You can trade min " + fixedPoint(MINSHOPPAYMENT, 6)) + " USDT"))
533544 else if ((minAmount > usdtAmt))
534545 then throw("Price changed during operation, please try again")
535546 else {
536547 let profitAmount = (usdtAmt / 4)
537548 $Tuple2([Burn(wlgAssetId, wlgAmt), IntegerEntry(wlgIssuedAmountKey, (curWlgAmount - wlgAmt)), IntegerEntry(keyLastArbTimeByUser(addr), lastBlock.timestamp), ScriptTransfer(addressFromStringValue(value(getString(profitAddrKey))), profitAmount, usdtAssetId), ScriptTransfer(caller, usdtAmt, usdtAssetId)], prologResult)
538549 }
539550 }
540551 }
541552 else throw("Strict value is not equal to itself.")
542553 }
543554
544555
545556
546557 @Callable(i)
547558 func claim () = {
548559 let prologResult = prolog()
549560 if ((prologResult == prologResult))
550561 then if ((size(i.payments) != 0))
551562 then throw("No payments required")
552563 else {
553564 let r = claimInternal(toString(i.caller), MULT6)
554565 let actions = r._1
555566 $Tuple2(((actions :+ ScriptTransfer(i.caller, r._2._1, wlgAssetId)) :+ ScriptTransfer(stakingContract, r._2._2, wlgAssetId)), prologResult)
556567 }
557568 else throw("Strict value is not equal to itself.")
558569 }
559570
560571
561572
562573 @Callable(i)
563574 func onStakeUnstakeLand (addr) = if (if ((i.caller != stakingContract))
564575 then (i.caller != acresContract)
565576 else false)
566577 then throw("Permission denied")
567578 else {
568579 let r = claimInternal(addr, MULT6)
569580 let actions = r._1
570581 $Tuple2(((actions :+ ScriptTransfer(addressFromStringValue(addr), r._2._1, wlgAssetId)) :+ ScriptTransfer(stakingContract, r._2._2, wlgAssetId)), r._2)
571582 }
572583
573584
574585
575586 @Callable(i)
576587 func stakeWlgold () = {
577588 let prologResult = prolog()
578589 if ((prologResult == prologResult))
579590 then if ((size(i.payments) != 1))
580591 then throw("exactly 1 payment must be attached")
581592 else {
582593 let pmt = i.payments[0]
583594 let amt = pmt.amount
584595 let addr = toString(i.caller)
585596 if (if (!(isDefined(pmt.assetId)))
586597 then true
587598 else (value(pmt.assetId) != wlgAssetId))
588599 then throw("WLGOLD payments only!")
589600 else {
590601 let $t01011710162 = takeXpInternal(addr, amt)
591602 let actions = $t01011710162._1
592603 let xp = $t01011710162._2
593604 let accStatsResult = asInt(invoke(stakingContract, "updateAccStats", [addr, xp], nil))
594605 $Tuple2(actions, $Tuple2(prologResult, accStatsResult))
595606 }
596607 }
597608 else throw("Strict value is not equal to itself.")
598609 }
599610
600611
601612
602613 @Callable(i)
603614 func unstakeWlgold (amount) = {
604615 let prologResult = prolog()
605616 if ((prologResult == prologResult))
606617 then if ((size(i.payments) != 0))
607618 then throw("No payments required")
608619 else if ((0 >= amount))
609620 then throw("Amount should be positive")
610621 else {
611622 let addr = toString(i.caller)
612623 let $t01054910607 = takeXpInternal(addr, -(amount))
613624 let actions = $t01054910607._1
614625 let xp = $t01054910607._2
615626 let oldUser = $t01054910607._3
616627 if ((amount > oldUser))
617628 then throw(((("You have only " + fixedPoint(oldUser, 8)) + " WLGOLD staked, tried to unstake ") + fixedPoint(amount, 8)))
618629 else {
619630 let accStatsResult = asInt(invoke(stakingContract, "updateAccStats", [addr, xp], nil))
620631 $Tuple2(actions, $Tuple2(prologResult, accStatsResult))
621632 }
622633 }
623634 else throw("Strict value is not equal to itself.")
624635 }
625636
626637
627638
628639 @Callable(i)
629640 func takeWlgXp (addr) = if ((i.caller != stakingContract))
630641 then throw("Permission denied")
631642 else {
632643 let $t01109511138 = takeXpInternal(addr, 0)
633644 let actions = $t01109511138._1
634645 let xp = $t01109511138._2
635646 $Tuple2(actions, xp)
636647 }
637648
638649
639650
640651 @Callable(i)
641652 func checkWlgXpREADONLY (addr) = {
642653 let $t01121511263 = takeXpInternal(addr, 0)
643654 let ignored = $t01121511263._1
644655 let deltaXP = $t01121511263._2
645656 let newXP = (valueOrElse(getInteger(stakingContract, keyUserXP(addr)), 0) + deltaXP)
646657 let lvlPoints = levelUp(valueOrElse(getInteger(stakingContract, keyUserLevel(addr)), 0), newXP)
647658 $Tuple2(nil, (lvlPoints :+ newXP))
648659 }
649660
650661

github/deemru/w8io/026f985 
65.26 ms