tx · 4EVkYYtm3ADUPKvwauKoi8qTiV8QeXKz9gZjPCEGd25Y 3MuGfNhF98CNBCfthhoJEo6SYUv7zTgkK4J: -0.03000000 Waves 2023.10.11 15:44 [2793964] smart account 3MuGfNhF98CNBCfthhoJEo6SYUv7zTgkK4J > SELF 0.00000000 Waves
{ "type": 13, "id": "4EVkYYtm3ADUPKvwauKoi8qTiV8QeXKz9gZjPCEGd25Y", "fee": 3000000, "feeAssetId": null, "timestamp": 1697028277437, "version": 2, "chainId": 84, "sender": "3MuGfNhF98CNBCfthhoJEo6SYUv7zTgkK4J", "senderPublicKey": "4DthuG3xjZV9WtZ34Y66AummdAr67wRzwWsVQL4y2bob", "proofs": [ "5qUao6RohKtZe9Z67Ndv4wRvwccscnMuYdXs6NQL7EGTXNA8KEZrigfFzPCH95E8pXFuSrp2APpiqVMadrBtEboY", "5QdtzW4bhudgaYMyCtsRSwB4suT9LC5AFFUo4n61cKS6egbr8FSWwBmkwxqWTb72oeSa653UZnjPjrW5n3GGYzuE", "4qCTShhhdNjGBM13a7X6Cm57Y2Jz9g1DkZVAFsAkWbxMH9GmUdWAbUDNEoC46Y9xvDnVigftvnYgv5BzuYSbPLTG" ], "script": "base64:BgIzCAISBwoFCAgBAQgSBAoCAQESABIDCgEBEgASABIAEgASABIDCgEIEgQKAggBEgQKAggBXgAJc2VwYXJhdG9yAgJfXwADU0VQAgJfXwAFTVVMVDYAwIQ9AAVNVUxUOACAwtcvAAZNVUxUWDYJALYCAQUFTVVMVDYABk1VTFRYOAkAtgIBBQVNVUxUOAAHTVVMVFgxOAkAtgIBAICAkLu61q3wDQAKV0FWRVNJRFNUUgIFV0FWRVMAB1dBVkVTSUQJANkEAQUKV0FWRVNJRFNUUgAJREFZTUlMTElTAIC4mSkACU1BWEJBU0tFVAAJABlJZHhDb250cm9sQ2ZnTmV1dHJpbm9EYXBwAAEAGElkeENvbnRyb2xDZmdBdWN0aW9uRGFwcAACABRJZHhDb250cm9sQ2ZnUnBkRGFwcA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1pjN2Zxd0NUanRBM25uUndnVGJrTVNyNVNVMk5tRFIJAMwIAgIsRFV1dUxqWHU5OG5Cd1pjN2Zxd0NUanRBM25uUndnVGJrTVNyNVNVMk5tRFIFA25pbAUDU0VQBBBwdWJLZXlBZG1pbnNMaXN0CQC1CQIJAQt2YWx1ZU9yRWxzZQIJAJ0IAgUPY29udHJvbENvbnRyYWN0Agwlc19fbXVsdGlzaWcFE3B1YktleUFkbWluc0xpc3RTdHIFA1NFUAQFY291bnQJAGQCCQBkAgkAZAIDCQD0AwMIBQJ0eAlib2R5Qnl0ZXMJAJEDAggFAnR4BnByb29mcwAACQDZBAEJAJEDAgUQcHViS2V5QWRtaW5zTGlzdAAAAAEAAAMJAPQDAwgFAnR4CWJvZHlCeXRlcwkAkQMCCAUCdHgGcHJvb2ZzAAEJANkEAQkAkQMCBRBwdWJLZXlBZG1pbnNMaXN0AAEAAQAAAwkA9AMDCAUCdHgJYm9keUJ5dGVzCQCRAwIIBQJ0eAZwcm9vZnMAAgkA2QQBCQCRAwIFEHB1YktleUFkbWluc0xpc3QAAgABAAADCQD0AwMIBQJ0eAlib2R5Qnl0ZXMJAJEDAggFAnR4BnByb29mcwADCQDZBAEJAJEDAgUQcHViS2V5QWRtaW5zTGlzdAADAAIAAAkAZwIFBWNvdW50AAPnadIS", "height": 2793964, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: CZpLBavoeneH3HLSnD9uSZ7bVcrixZpQdVx1hGbFCk8v Next: Gsn8hUuJ3TctkoqY5qkGHEW3qdZnVrpKeHRo2JfzMB9R Full:
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let separator = "__" | |
5 | 5 | ||
6 | 6 | let SEP = "__" | |
7 | 7 | ||
8 | 8 | let MULT6 = 1000000 | |
9 | 9 | ||
10 | 10 | let MULT8 = 100000000 | |
11 | 11 | ||
12 | 12 | let MULTX6 = toBigInt(MULT6) | |
13 | 13 | ||
14 | 14 | let MULTX8 = toBigInt(MULT8) | |
15 | 15 | ||
16 | 16 | let MULTX18 = toBigInt(1000000000000000000) | |
17 | 17 | ||
18 | 18 | let WAVESIDSTR = "WAVES" | |
19 | 19 | ||
20 | 20 | let WAVESID = fromBase58String(WAVESIDSTR) | |
21 | 21 | ||
22 | 22 | let DAYMILLIS = 86400000 | |
23 | 23 | ||
24 | 24 | let MAXBASKET = 9 | |
25 | 25 | ||
26 | 26 | let IdxControlCfgNeutrinoDapp = 1 | |
27 | 27 | ||
28 | 28 | let IdxControlCfgAuctionDapp = 2 | |
29 | 29 | ||
30 | 30 | let IdxControlCfgRpdDapp = 3 | |
31 | 31 | ||
32 | 32 | let IdxControlCfgMathDapp = 4 | |
33 | 33 | ||
34 | 34 | let IdxControlCfgLiquidationDapp = 5 | |
35 | 35 | ||
36 | 36 | let IdxControlCfgRestDapp = 6 | |
37 | 37 | ||
38 | 38 | let IdxControlCfgNodeRegistryDapp = 7 | |
39 | 39 | ||
40 | 40 | let IdxControlCfgNsbtStakingDapp = 8 | |
41 | 41 | ||
42 | 42 | let IdxControlCfgMediatorDapp = 9 | |
43 | 43 | ||
44 | 44 | let IdxControlCfgGovernanceDapp = 13 | |
45 | 45 | ||
46 | 46 | func getStringOrFail (address,key) = valueOrErrorMessage(getString(address, key), (((("mandatory " + toString(address)) + ".") + key) + " is not defined")) | |
47 | 47 | ||
48 | 48 | ||
49 | 49 | func keyCfgX2GnsbtOfferHeightStart () = "%s%s__config__x2GnsbtOfferHeightStart" | |
50 | 50 | ||
51 | 51 | ||
52 | 52 | func keyCfgX2GnsbtOfferHeightEnd () = "%s%s__config__x2GnsbtOfferHeightEnd" | |
53 | 53 | ||
54 | 54 | ||
55 | 55 | func keyControlAddress () = "%s%s__config__controlAddress" | |
56 | 56 | ||
57 | 57 | ||
58 | 58 | func keyControlCfg () = "%s__controlConfig" | |
59 | 59 | ||
60 | 60 | ||
61 | 61 | func readControlCfgOrFail (control) = split_4C(getStringOrFail(control, keyControlCfg()), SEP) | |
62 | 62 | ||
63 | 63 | ||
64 | 64 | func getContractAddressOrFail (controlCfg,idx) = valueOrErrorMessage(addressFromString(controlCfg[idx]), ("Control cfg doesn't contain address at index " + toString(idx))) | |
65 | 65 | ||
66 | 66 | ||
67 | 67 | let controlContract = addressFromStringValue(valueOrElse(getString(this, keyControlAddress()), "3N4NS7d4Jo9a6F14LiFUKKYVdUkkf2eP4Zx")) | |
68 | 68 | ||
69 | 69 | let controlCfg = readControlCfgOrFail(controlContract) | |
70 | 70 | ||
71 | 71 | let mathContract = getContractAddressOrFail(controlCfg, IdxControlCfgMathDapp) | |
72 | 72 | ||
73 | 73 | let neutrinoContract = getContractAddressOrFail(controlCfg, IdxControlCfgNeutrinoDapp) | |
74 | 74 | ||
75 | 75 | let auctionContract = getContractAddressOrFail(controlCfg, IdxControlCfgAuctionDapp) | |
76 | 76 | ||
77 | 77 | let govContract = getContractAddressOrFail(controlCfg, IdxControlCfgGovernanceDapp) | |
78 | 78 | ||
79 | 79 | let RENEW_START_HEIGHT = valueOrElse(getInteger(this, keyCfgX2GnsbtOfferHeightStart()), 0) | |
80 | 80 | ||
81 | 81 | let RENEW_END_HEIGHT = valueOrElse(getInteger(this, keyCfgX2GnsbtOfferHeightEnd()), 0) | |
82 | 82 | ||
83 | 83 | func keyBondAsset () = "bond_asset_id" | |
84 | 84 | ||
85 | 85 | ||
86 | 86 | func keyUserGnsbtReleaseTime (userAddr) = ("%s%s_userGnsbtReleaseTime__" + userAddr) | |
87 | 87 | ||
88 | 88 | ||
89 | 89 | func keyNeutrinoContractAddress () = "%s__neutrinoContractAddress" | |
90 | 90 | ||
91 | 91 | ||
92 | 92 | func keyMathContractAddress () = "%s__mathContract" | |
93 | 93 | ||
94 | 94 | ||
95 | 95 | func keyMinLockAmount () = "%s__minLockAmount" | |
96 | 96 | ||
97 | 97 | ||
98 | 98 | func keyHalfLife () = "%s__halfLife" | |
99 | 99 | ||
100 | 100 | ||
101 | 101 | func keyLockParamUserAmount (userAddress) = makeString(["%s%s%s", "paramByUser", toString(userAddress), "amount"], separator) | |
102 | 102 | ||
103 | 103 | ||
104 | 104 | func keyLockParamStartBlock (userAddress) = makeString(["%s%s%s", "paramByUser", toString(userAddress), "start"], separator) | |
105 | 105 | ||
106 | 106 | ||
107 | 107 | func keyLockParamUserGnsbt (userAddress) = makeString(["%s%s%s", "paramByUser", toString(userAddress), "gNsbt"], separator) | |
108 | 108 | ||
109 | 109 | ||
110 | 110 | func keyUserConsentedToX2Gnsbt (userAddress) = makeString(["%s%s%s", "paramByUser", toString(userAddress), "consentedToX2Gnsbt"], separator) | |
111 | 111 | ||
112 | 112 | ||
113 | 113 | func keyHistoryRecord (type,userAddress,txId) = makeString(["%s%s%s%s", "history", type, toString(userAddress), toBase58String(txId)], separator) | |
114 | 114 | ||
115 | 115 | ||
116 | 116 | func keyLockParamTotalAmount () = makeString(["%s%s", "stats", "activeTotalLocked"], separator) | |
117 | 117 | ||
118 | 118 | ||
119 | 119 | func keyLockParamTotalGnsbt () = makeString(["%s%s", "stats", "activeTotalGnsbt"], separator) | |
120 | 120 | ||
121 | 121 | ||
122 | 122 | func keyStatsLocksCount () = makeString(["%s%s", "stats", "locksCount"], separator) | |
123 | 123 | ||
124 | 124 | ||
125 | 125 | func keyStatsUsersCount () = makeString(["%s%s", "stats", "activeUsersCount"], separator) | |
126 | 126 | ||
127 | 127 | ||
128 | 128 | func keyStatsDepositAmtByDay (timestamp) = makeString(["%s%s%d", "stats", "depositAmtByDay", toString(timestamp)], separator) | |
129 | 129 | ||
130 | 130 | ||
131 | 131 | func keyStatsDepositAmtTotals () = makeString(["%s%s%d", "stats", "depositAmtTotals"], separator) | |
132 | 132 | ||
133 | 133 | ||
134 | 134 | func keyNextPeriod () = "%s__nextPeriod" | |
135 | 135 | ||
136 | 136 | ||
137 | 137 | func keySupportedRewardAssets () = "supportedRewardAssets" | |
138 | 138 | ||
139 | 139 | ||
140 | 140 | func keyDepositNumLast () = makeString(["%s%s%s", "dep", "lastNum"], separator) | |
141 | 141 | ||
142 | 142 | ||
143 | 143 | func keyUserRewardFromDepositNum (userAddress) = makeString(["%s%s%s", "userRwdFromDepNum", userAddress], separator) | |
144 | 144 | ||
145 | 145 | ||
146 | 146 | func keyRewardPerNsbtSumAt (depositNum,tkn) = makeString(["%s%d", "rwdPerNsbtSumByDepNum", toString(depositNum), tkn], separator) | |
147 | 147 | ||
148 | 148 | ||
149 | 149 | func keyReward (userAddress,tkn) = makeString(["%s%s%s", "rwd", userAddress, tkn], separator) | |
150 | 150 | ||
151 | 151 | ||
152 | 152 | func keyClaimed (userAddress,tkn) = makeString(["%s%s%s", "clm", userAddress, tkn], separator) | |
153 | 153 | ||
154 | 154 | ||
155 | 155 | func keyNotDistributedReward (tkn) = makeString(["%s%s", "notDistributed", tkn], separator) | |
156 | 156 | ||
157 | 157 | ||
158 | 158 | func toX18 (origVal,origMult) = fraction(toBigInt(origVal), MULTX18, origMult) | |
159 | 159 | ||
160 | 160 | ||
161 | 161 | func getIntOrZero (key) = valueOrElse(getInteger(this, key), 0) | |
162 | 162 | ||
163 | 163 | ||
164 | 164 | func getIntOrElse (key,defaultVal) = valueOrElse(getInteger(this, key), defaultVal) | |
165 | 165 | ||
166 | 166 | ||
167 | 167 | func getIntOrFail (key) = valueOrErrorMessage(getInteger(this, key), (("Mandatory this." + key) + " is not defined")) | |
168 | 168 | ||
169 | 169 | ||
170 | 170 | func getStrOrElse (key,defaultVal) = valueOrElse(getString(this, key), defaultVal) | |
171 | 171 | ||
172 | 172 | ||
173 | 173 | func toAddressOrFail (addressStr) = valueOrErrorMessage(addressFromString(addressStr), ("couldn't parse passed addressStr=" + addressStr)) | |
174 | 174 | ||
175 | 175 | ||
176 | 176 | func toAssetVect (assetStr) = if ((assetStr == WAVESIDSTR)) | |
177 | 177 | then unit | |
178 | 178 | else fromBase58String(assetStr) | |
179 | 179 | ||
180 | 180 | ||
181 | 181 | func asInt (val) = match val { | |
182 | 182 | case valInt: Int => | |
183 | 183 | valInt | |
184 | 184 | case _ => | |
185 | 185 | throw("fail to cast into Int") | |
186 | 186 | } | |
187 | 187 | ||
188 | 188 | ||
189 | 189 | func formatHistoryRecord (oldAmount,oldStart,newAmount,newStart) = makeString(["%d%d%d%d%d%d", toString(lastBlock.height), toString(lastBlock.timestamp), toString(oldAmount), toString(oldStart), toString(newAmount), toString(newStart)], separator) | |
190 | 190 | ||
191 | 191 | ||
192 | 192 | func formatClaimHistoryRecord (user,claimedRewards) = makeString(["%s%d%d%s", user, toString(lastBlock.height), toString(lastBlock.timestamp), claimedRewards], separator) | |
193 | 193 | ||
194 | 194 | ||
195 | 195 | func HistoryRecordEntry (type,userAddress,txId,oldAmount,oldStart,newAmount,newStart) = StringEntry(keyHistoryRecord(type, userAddress, txId), formatHistoryRecord(oldAmount, oldStart, newAmount, newStart)) | |
196 | 196 | ||
197 | 197 | ||
198 | 198 | func ClaimHistoryEntry (userAddress,txId,claimedRewards) = StringEntry(keyHistoryRecord("claim", userAddress, txId), formatClaimHistoryRecord(toString(userAddress), claimedRewards)) | |
199 | 199 | ||
200 | 200 | ||
201 | 201 | func StatsResult (totalLockedInc,lockCountInc,usersCountInc,totalGnsbtInc) = { | |
202 | 202 | let locksCount = getIntOrZero(keyStatsLocksCount()) | |
203 | 203 | let usersCount = getIntOrZero(keyStatsUsersCount()) | |
204 | 204 | let totalAmount = getIntOrZero(keyLockParamTotalAmount()) | |
205 | 205 | let totalAmountNew = (totalAmount + totalLockedInc) | |
206 | 206 | let totalGnsbt = getIntOrElse(keyLockParamTotalGnsbt(), totalAmount) | |
207 | 207 | $Tuple3([IntegerEntry(keyStatsLocksCount(), (locksCount + lockCountInc)), IntegerEntry(keyStatsUsersCount(), (usersCount + usersCountInc)), IntegerEntry(keyLockParamTotalAmount(), totalAmountNew), IntegerEntry(keyLockParamTotalGnsbt(), (totalGnsbt + totalGnsbtInc))], totalAmount, totalAmountNew) | |
208 | 208 | } | |
209 | 209 | ||
210 | 210 | ||
211 | 211 | func LockParamsEntry (userAddress,nsbtAmount,start,gNsbtAmount) = [IntegerEntry(keyLockParamUserAmount(userAddress), nsbtAmount), IntegerEntry(keyLockParamUserGnsbt(userAddress), gNsbtAmount), IntegerEntry(keyLockParamStartBlock(userAddress), start)] | |
212 | 212 | ||
213 | 213 | ||
214 | 214 | func getParamsOrFail () = $Tuple3(fromBase58String(getStringValue(neutrinoContract, keyBondAsset())), getIntOrFail(keyMinLockAmount()), getIntOrFail(keyHalfLife())) | |
215 | 215 | ||
216 | 216 | ||
217 | 217 | func isActiveUser (userAddress) = (getIntOrElse(keyLockParamUserAmount(userAddress), 0) > 0) | |
218 | 218 | ||
219 | 219 | ||
220 | 220 | func isBonusPeriod (h) = if ((h >= RENEW_START_HEIGHT)) | |
221 | 221 | then (RENEW_END_HEIGHT >= h) | |
222 | 222 | else false | |
223 | 223 | ||
224 | 224 | ||
225 | 225 | func getUserParamsOrUnit (userAddress) = if (isActiveUser(userAddress)) | |
226 | 226 | then { | |
227 | 227 | let amount = getIntOrFail(keyLockParamUserAmount(userAddress)) | |
228 | 228 | $Tuple4(false, amount, getIntOrFail(keyLockParamStartBlock(userAddress)), getIntOrElse(keyLockParamUserGnsbt(userAddress), amount)) | |
229 | 229 | } | |
230 | 230 | else unit | |
231 | 231 | ||
232 | 232 | ||
233 | 233 | func getUserParamsOrFail (userAddress) = valueOrErrorMessage(getUserParamsOrUnit(userAddress), (("User " + toString(userAddress)) + " is not defined")) | |
234 | 234 | ||
235 | 235 | ||
236 | 236 | let supportedAssetsStr = getStrOrElse(keySupportedRewardAssets(), "") | |
237 | 237 | ||
238 | 238 | let supportedAssetsList = split(supportedAssetsStr, "_") | |
239 | 239 | ||
240 | 240 | func calcReward (userAddress,assetId,stakedAmountX,depositNumUser,depositNumLast) = { | |
241 | 241 | let rewardPerNsbtSumLastKEY = keyRewardPerNsbtSumAt(depositNumLast, assetId) | |
242 | 242 | let sumLastX18 = parseBigIntValue(getStrOrElse(keyRewardPerNsbtSumAt(depositNumLast, assetId), "0")) | |
243 | 243 | let sumUserX18 = parseBigIntValue(getStrOrElse(keyRewardPerNsbtSumAt(depositNumUser, assetId), "0")) | |
244 | 244 | let rewardDynamicPart = toInt(fraction((sumLastX18 - sumUserX18), stakedAmountX, MULTX18)) | |
245 | 245 | let rewardCachedPartKEY = keyReward(userAddress, assetId) | |
246 | 246 | let rewardCachedPart = getIntOrElse(rewardCachedPartKEY, 0) | |
247 | 247 | $Tuple4((rewardCachedPart + rewardDynamicPart), rewardCachedPart, rewardDynamicPart, rewardCachedPartKEY) | |
248 | 248 | } | |
249 | 249 | ||
250 | 250 | ||
251 | 251 | func toStartOfDay (timestamp) = ((timestamp / DAYMILLIS) * DAYMILLIS) | |
252 | 252 | ||
253 | 253 | ||
254 | 254 | func findElementPosition (src,element,sep) = { | |
255 | 255 | let elementStart = valueOrErrorMessage(indexOf(src, element), ((("there is no substring " + element) + " in ") + src)) | |
256 | 256 | if ((elementStart == 0)) | |
257 | 257 | then 0 | |
258 | 258 | else { | |
259 | 259 | let left = take(src, elementStart) | |
260 | 260 | (size(split(left, sep)) - 1) | |
261 | 261 | } | |
262 | 262 | } | |
263 | 263 | ||
264 | 264 | ||
265 | 265 | let DepositTotalsPREFIX = "%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d" | |
266 | 266 | ||
267 | 267 | let defaultTotalsDATA = (DepositTotalsPREFIX + "__0__0__0__0__0__0__0__0__0__0__0__0__0__0__0__0__0__0") | |
268 | 268 | ||
269 | 269 | func padList (in) = { | |
270 | 270 | let currSize = (size(in) - 1) | |
271 | 271 | func listPadder (acc,idx) = if ((currSize > idx)) | |
272 | 272 | then acc | |
273 | 273 | else (acc :+ "0") | |
274 | 274 | ||
275 | 275 | let $l = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17] | |
276 | 276 | let $s = size($l) | |
277 | 277 | let $acc0 = in | |
278 | 278 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
279 | 279 | then $a | |
280 | 280 | else listPadder($a, $l[$i]) | |
281 | 281 | ||
282 | 282 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
283 | 283 | then $a | |
284 | 284 | else throw("List size exceeds 18") | |
285 | 285 | ||
286 | 286 | $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($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18) | |
287 | 287 | } | |
288 | 288 | ||
289 | 289 | ||
290 | 290 | func padString (in) = { | |
291 | 291 | let currSize = (size(split_4C(in, SEP)) - 1) | |
292 | 292 | func strPadder (acc,idx) = if ((currSize > idx)) | |
293 | 293 | then acc | |
294 | 294 | else (acc + "__0") | |
295 | 295 | ||
296 | 296 | let $l = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17] | |
297 | 297 | let $s = size($l) | |
298 | 298 | let $acc0 = in | |
299 | 299 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
300 | 300 | then $a | |
301 | 301 | else strPadder($a, $l[$i]) | |
302 | 302 | ||
303 | 303 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
304 | 304 | then $a | |
305 | 305 | else throw("List size exceeds 18") | |
306 | 306 | ||
307 | 307 | $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($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18) | |
308 | 308 | } | |
309 | 309 | ||
310 | 310 | ||
311 | 311 | func RewardEntries (isNewUser,userAddress,stakedAmount) = { | |
312 | 312 | let stakedAmountX = toBigInt(stakedAmount) | |
313 | 313 | let userRewardFromDepositNumKEY = keyUserRewardFromDepositNum(userAddress) | |
314 | 314 | let depositNumUser = getIntOrElse(userRewardFromDepositNumKEY, -1) | |
315 | 315 | let depositNumLast = getIntOrElse(keyDepositNumLast(), -1) | |
316 | 316 | func forEachAssetCacheUserReward (accum,asset) = { | |
317 | 317 | let $t01139311528 = calcReward(userAddress, asset, stakedAmountX, depositNumUser, depositNumLast) | |
318 | 318 | let rewardTotal = $t01139311528._1 | |
319 | 319 | let cached = $t01139311528._2 | |
320 | 320 | let dynamic = $t01139311528._3 | |
321 | 321 | let rewardCachedPartKEY = $t01139311528._4 | |
322 | 322 | (accum :+ IntegerEntry(rewardCachedPartKEY, rewardTotal)) | |
323 | 323 | } | |
324 | 324 | ||
325 | 325 | if (if ((depositNumLast == -1)) | |
326 | 326 | then (depositNumUser == -1) | |
327 | 327 | else false) | |
328 | 328 | then nil | |
329 | 329 | else if (if ((depositNumLast == -1)) | |
330 | 330 | then (depositNumUser > -1) | |
331 | 331 | else false) | |
332 | 332 | then throw("invalid depositNumLast and depositNumUser state") | |
333 | 333 | else if (if ((depositNumLast > -1)) | |
334 | 334 | then (depositNumUser >= -1) | |
335 | 335 | else false) | |
336 | 336 | then if (isNewUser) | |
337 | 337 | then [IntegerEntry(userRewardFromDepositNumKEY, depositNumLast)] | |
338 | 338 | else ({ | |
339 | 339 | let $l = supportedAssetsList | |
340 | 340 | let $s = size($l) | |
341 | 341 | let $acc0 = nil | |
342 | 342 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
343 | 343 | then $a | |
344 | 344 | else forEachAssetCacheUserReward($a, $l[$i]) | |
345 | 345 | ||
346 | 346 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
347 | 347 | then $a | |
348 | 348 | else throw("List size exceeds 9") | |
349 | 349 | ||
350 | 350 | $f0_2($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) | |
351 | 351 | } :+ IntegerEntry(userRewardFromDepositNumKEY, depositNumLast)) | |
352 | 352 | else throw(((("uncovered condition: depositNumLast=" + toString(depositNumLast)) + " depositNumUser=") + toString(depositNumUser))) | |
353 | 353 | } | |
354 | 354 | ||
355 | 355 | ||
356 | 356 | func IncrementNotDistributedRewardEntry (tkn,amountInc) = { | |
357 | 357 | let notDistributedRewardKEY = keyNotDistributedReward(tkn) | |
358 | 358 | let notDistributedReward = getIntOrElse(notDistributedRewardKEY, 0) | |
359 | 359 | IntegerEntry(notDistributedRewardKEY, (notDistributedReward + amountInc)) | |
360 | 360 | } | |
361 | 361 | ||
362 | 362 | ||
363 | 363 | func commonClaim (userAddress,i) = { | |
364 | 364 | let userAddressStr = toString(userAddress) | |
365 | 365 | if ((size(i.payments) > 0)) | |
366 | 366 | then throw("payments are not accepted") | |
367 | 367 | else { | |
368 | 368 | let $t01446914590 = valueOrElse(getUserParamsOrUnit(userAddress), $Tuple4(true, 0, 0, 0)) | |
369 | 369 | let isNewUser = $t01446914590._1 | |
370 | 370 | let stakedAmount = $t01446914590._2 | |
371 | 371 | let stakingStart = $t01446914590._3 | |
372 | 372 | let gNsbtAmount = $t01446914590._4 | |
373 | 373 | let stakedAmountX = toBigInt(gNsbtAmount) | |
374 | 374 | let userRewardFromDepositNumKEY = keyUserRewardFromDepositNum(userAddressStr) | |
375 | 375 | let depositNumUser = getIntOrElse(userRewardFromDepositNumKEY, -1) | |
376 | 376 | let depositNumLast = getIntOrElse(keyDepositNumLast(), -1) | |
377 | 377 | func forEachAssetCalcUnclaimedReward (accum,asset) = { | |
378 | 378 | let $t01496015098 = calcReward(userAddressStr, asset, stakedAmountX, depositNumUser, depositNumLast) | |
379 | 379 | let rewardTotal = $t01496015098._1 | |
380 | 380 | let cached = $t01496015098._2 | |
381 | 381 | let dynamic = $t01496015098._3 | |
382 | 382 | let rewardCachedPartKEY = $t01496015098._4 | |
383 | 383 | let claimedKEY = keyClaimed(userAddressStr, asset) | |
384 | 384 | let $t01515815195 = accum | |
385 | 385 | let data = $t01515815195._1 | |
386 | 386 | let claimedAmtByAsset = $t01515815195._2 | |
387 | 387 | let newPart = makeString([asset, toString(rewardTotal)], ":") | |
388 | 388 | let claimedAmtByAssetNew = makeString([claimedAmtByAsset, newPart], "_") | |
389 | 389 | if ((0 >= rewardTotal)) | |
390 | 390 | then $Tuple2(data, claimedAmtByAssetNew) | |
391 | 391 | else $Tuple2((((data :+ ScriptTransfer(userAddress, rewardTotal, toAssetVect(asset))) :+ IntegerEntry(claimedKEY, (valueOrElse(getInteger(claimedKEY), 0) + rewardTotal))) :+ IntegerEntry(rewardCachedPartKEY, 0)), claimedAmtByAssetNew) | |
392 | 392 | } | |
393 | 393 | ||
394 | 394 | let $t01565515768 = { | |
395 | 395 | let $l = supportedAssetsList | |
396 | 396 | let $s = size($l) | |
397 | 397 | let $acc0 = $Tuple2(nil, "") | |
398 | 398 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
399 | 399 | then $a | |
400 | 400 | else forEachAssetCalcUnclaimedReward($a, $l[$i]) | |
401 | 401 | ||
402 | 402 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
403 | 403 | then $a | |
404 | 404 | else throw("List size exceeds 9") | |
405 | 405 | ||
406 | 406 | $f0_2($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) | |
407 | 407 | } | |
408 | 408 | let transfers = $t01565515768._1 | |
409 | 409 | let claimedAmtByAssetResult = $t01565515768._2 | |
410 | 410 | if ((0 >= size(transfers))) | |
411 | 411 | then $Tuple2(nil, 0) | |
412 | 412 | else $Tuple2(((transfers :+ IntegerEntry(userRewardFromDepositNumKEY, depositNumLast)) :+ ClaimHistoryEntry(userAddress, i.transactionId, drop(claimedAmtByAssetResult, 1))), size(transfers)) | |
413 | 413 | } | |
414 | 414 | } | |
415 | 415 | ||
416 | 416 | ||
417 | 417 | func readUserConsentToX2Gnsbt (userAddress) = { | |
418 | 418 | let key = keyUserConsentedToX2Gnsbt(userAddress) | |
419 | 419 | let val = valueOrElse(getBoolean(this, key), false) | |
420 | 420 | $Tuple2(key, val) | |
421 | 421 | } | |
422 | 422 | ||
423 | 423 | ||
424 | 424 | func commonX2Gnsbt (userAddress,i) = if (!(isBonusPeriod(height))) | |
425 | 425 | then throw("No 'Double gNSBT action' available now") | |
426 | 426 | else { | |
427 | 427 | let $t01633016391 = commonClaim(userAddress, i) | |
428 | 428 | let claimActions = $t01633016391._1 | |
429 | 429 | let claimResult = $t01633016391._2 | |
430 | 430 | let $t01639416519 = valueOrElse(getUserParamsOrUnit(userAddress), $Tuple4(true, 0, -1, 0)) | |
431 | 431 | let isNewUser = $t01639416519._1 | |
432 | 432 | let lockAmount = $t01639416519._2 | |
433 | 433 | let lockStartHeight = $t01639416519._3 | |
434 | 434 | let currUserGnsbt = $t01639416519._4 | |
435 | 435 | if (isNewUser) | |
436 | 436 | then throw("You have nothing to restake") | |
437 | 437 | else { | |
438 | 438 | let newUserGnsbt = (2 * lockAmount) | |
439 | 439 | let totalNsbt = getIntOrZero(keyLockParamTotalAmount()) | |
440 | 440 | let totalGnsbt = getIntOrElse(keyLockParamTotalGnsbt(), totalNsbt) | |
441 | 441 | let newTotalGnsbt = ((totalGnsbt - currUserGnsbt) + newUserGnsbt) | |
442 | 442 | let userConsentTuple = readUserConsentToX2Gnsbt(userAddress) | |
443 | 443 | let userConsentedToX2GnsbtKEY = userConsentTuple._1 | |
444 | 444 | let userConsentedToX2Gnsbt = userConsentTuple._2 | |
445 | 445 | if (userConsentedToX2Gnsbt) | |
446 | 446 | then throw("User has already doubled its gNSBT value") | |
447 | 447 | else $Tuple2((((claimActions ++ LockParamsEntry(userAddress, lockAmount, height, newUserGnsbt)) :+ IntegerEntry(keyLockParamTotalGnsbt(), newTotalGnsbt)) :+ BooleanEntry(userConsentedToX2GnsbtKEY, true)), claimResult) | |
448 | 448 | } | |
449 | 449 | } | |
450 | 450 | ||
451 | 451 | ||
452 | 452 | @Callable(i) | |
453 | 453 | func constructorV1 (neutrinoContractAddress,mathContractAddress,minLockAmount,halfLife,supportedRewardAssets) = if ((i.caller != this)) | |
454 | 454 | then throw("Permission denied") | |
455 | 455 | else [StringEntry(keyNeutrinoContractAddress(), neutrinoContractAddress), StringEntry(keyMathContractAddress(), mathContractAddress), IntegerEntry(keyMinLockAmount(), minLockAmount), IntegerEntry(keyHalfLife(), halfLife), StringEntry(keySupportedRewardAssets(), supportedRewardAssets)] | |
456 | 456 | ||
457 | 457 | ||
458 | 458 | ||
459 | 459 | @Callable(i) | |
460 | 460 | func constructorV2 (x2GnsbtOfferHeightStart,x2GnsbtOfferHeightEnd) = if ((i.caller != this)) | |
461 | 461 | then throw("Permission denied") | |
462 | 462 | else [IntegerEntry(keyCfgX2GnsbtOfferHeightStart(), x2GnsbtOfferHeightStart), IntegerEntry(keyCfgX2GnsbtOfferHeightEnd(), x2GnsbtOfferHeightEnd)] | |
463 | 463 | ||
464 | 464 | ||
465 | 465 | ||
466 | 466 | @Callable(i) | |
467 | 467 | func stake () = { | |
468 | 468 | let $t01821518277 = getParamsOrFail() | |
469 | 469 | let bondAssetId = $t01821518277._1 | |
470 | 470 | let minLockAmount = $t01821518277._2 | |
471 | 471 | let halfLife = $t01821518277._3 | |
472 | 472 | if ((size(i.payments) != 1)) | |
473 | 473 | then throw("Invalid payments size") | |
474 | 474 | else { | |
475 | 475 | let payment = i.payments[0] | |
476 | 476 | let amount = payment.amount | |
477 | 477 | let invalidAssetMessage = (("Invalid asset. " + toBase58String(bondAssetId)) + " is expected") | |
478 | 478 | let assetId = valueOrErrorMessage(payment.assetId, invalidAssetMessage) | |
479 | 479 | if ((assetId != bondAssetId)) | |
480 | 480 | then throw(invalidAssetMessage) | |
481 | 481 | else { | |
482 | 482 | let userAddress = i.caller | |
483 | 483 | let userAddressStr = toString(i.caller) | |
484 | 484 | let $t01881918944 = valueOrElse(getUserParamsOrUnit(userAddress), $Tuple4(true, 0, -1, 0)) | |
485 | 485 | let isNewUser = $t01881918944._1 | |
486 | 486 | let lockAmount = $t01881918944._2 | |
487 | 487 | let lockStartHeight = $t01881918944._3 | |
488 | 488 | let currUserGnsbt = $t01881918944._4 | |
489 | 489 | let mergedAmount = if (isNewUser) | |
490 | 490 | then amount | |
491 | 491 | else (amount + lockAmount) | |
492 | 492 | let mergedStartHeight = if (isNewUser) | |
493 | 493 | then height | |
494 | 494 | else asInt(invoke(mathContract, "mergeStakesREADONLY", [amount, height, lockAmount, lockStartHeight, halfLife], nil)) | |
495 | 495 | if ((minLockAmount > mergedAmount)) | |
496 | 496 | then throw(("Min lock amount is " + toString(minLockAmount))) | |
497 | 497 | else { | |
498 | 498 | let userConsentTuple = readUserConsentToX2Gnsbt(userAddress) | |
499 | 499 | let userConsentedToX2GnsbtKEY = userConsentTuple._1 | |
500 | 500 | let userConsentedToX2Gnsbt = userConsentTuple._2 | |
501 | 501 | let deltaUserGnsbt = if (if (isBonusPeriod(height)) | |
502 | 502 | then if (isNewUser) | |
503 | 503 | then true | |
504 | 504 | else userConsentedToX2Gnsbt | |
505 | 505 | else false) | |
506 | 506 | then (2 * amount) | |
507 | 507 | else amount | |
508 | 508 | let x2GnsbtConsentEntry = if (isNewUser) | |
509 | 509 | then [BooleanEntry(userConsentedToX2GnsbtKEY, true)] | |
510 | 510 | else nil | |
511 | 511 | let $t01994820066 = StatsResult(amount, 1, if (isNewUser) | |
512 | 512 | then 1 | |
513 | 513 | else 0, deltaUserGnsbt) | |
514 | 514 | let statsEntries = $t01994820066._1 | |
515 | 515 | let totalStaked = $t01994820066._2 | |
516 | 516 | let totalStakedNew = $t01994820066._3 | |
517 | 517 | (((([HistoryRecordEntry("stake", userAddress, i.transactionId, lockAmount, lockStartHeight, mergedAmount, mergedStartHeight)] ++ RewardEntries(isNewUser, userAddressStr, lockAmount)) ++ LockParamsEntry(userAddress, mergedAmount, mergedStartHeight, (currUserGnsbt + deltaUserGnsbt))) ++ statsEntries) ++ x2GnsbtConsentEntry) | |
518 | 518 | } | |
519 | 519 | } | |
520 | 520 | } | |
521 | 521 | } | |
522 | 522 | ||
523 | 523 | ||
524 | 524 | ||
525 | 525 | @Callable(i) | |
526 | 526 | func unstake (amount) = if ((size(i.payments) != 0)) | |
527 | 527 | then throw("unstake doesn't require any payment") | |
528 | 528 | else { | |
529 | 529 | let userAddress = i.caller | |
530 | 530 | let userAddressStr = toString(userAddress) | |
531 | 531 | let $t02060920671 = getParamsOrFail() | |
532 | 532 | let bondAssetId = $t02060920671._1 | |
533 | 533 | let minLockAmount = $t02060920671._2 | |
534 | 534 | let halfLife = $t02060920671._3 | |
535 | 535 | let $t02067420763 = getUserParamsOrFail(userAddress) | |
536 | 536 | let isNewUser = $t02067420763._1 | |
537 | 537 | let lockAmount = $t02067420763._2 | |
538 | 538 | let lockStart = $t02067420763._3 | |
539 | 539 | let currUserGnsbt = $t02067420763._4 | |
540 | 540 | if ((0 >= lockAmount)) | |
541 | 541 | then throw("Nothing to unstake") | |
542 | 542 | else if ((amount > lockAmount)) | |
543 | 543 | then throw(((("Requested " + toString(amount)) + ", but staked only ") + toString(lockAmount))) | |
544 | 544 | else { | |
545 | 545 | let t = value(blockInfoByHeight(height)).timestamp | |
546 | 546 | let releaseTime = valueOrElse(getInteger(govContract, keyUserGnsbtReleaseTime(userAddressStr)), 0) | |
547 | 547 | if ((releaseTime >= t)) | |
548 | 548 | then throw(("Your gNsbt are taking part in voting, cannot unstake until " + toString(releaseTime))) | |
549 | 549 | else { | |
550 | 550 | let comissionAmount = asInt(invoke(mathContract, "getUnstakeComissionAmountREADONLY", [amount, lockStart, halfLife], nil)) | |
551 | 551 | let bonusGnsbtPart = (currUserGnsbt - lockAmount) | |
552 | 552 | let bonusNsbtAmount = min([amount, bonusGnsbtPart]) | |
553 | 553 | let deltaGnsbt = (bonusNsbtAmount + amount) | |
554 | 554 | let $t02160121772 = StatsResult(-(amount), if ((amount == lockAmount)) | |
555 | 555 | then -1 | |
556 | 556 | else 0, if ((amount == lockAmount)) | |
557 | 557 | then -1 | |
558 | 558 | else 0, -(deltaGnsbt)) | |
559 | 559 | let statsEntries = $t02160121772._1 | |
560 | 560 | let totalStaked = $t02160121772._2 | |
561 | 561 | let totalStakedNew = $t02160121772._3 | |
562 | 562 | ((([ScriptTransfer(userAddress, (amount - comissionAmount), bondAssetId), ScriptTransfer(auctionContract, comissionAmount, bondAssetId), HistoryRecordEntry("unstake", userAddress, i.transactionId, lockAmount, lockStart, (lockAmount - amount), lockStart)] ++ RewardEntries(false, userAddressStr, lockAmount)) ++ LockParamsEntry(userAddress, (lockAmount - amount), lockStart, (currUserGnsbt - deltaGnsbt))) ++ statsEntries) | |
563 | 563 | } | |
564 | 564 | } | |
565 | 565 | } | |
566 | 566 | ||
567 | 567 | ||
568 | 568 | ||
569 | 569 | @Callable(i) | |
570 | 570 | func deposit () = { | |
571 | 571 | let totalStaked = getIntOrElse(keyLockParamTotalGnsbt(), getIntOrElse(keyLockParamTotalAmount(), 0)) | |
572 | 572 | if ((0 > totalStaked)) | |
573 | 573 | then throw("TODO: case is not supported") | |
574 | 574 | else { | |
575 | 575 | let depositNumLastKEY = keyDepositNumLast() | |
576 | 576 | let depositNumLast = getIntOrElse(depositNumLastKEY, -1) | |
577 | 577 | let depositNumNew = (depositNumLast + 1) | |
578 | 578 | let totalsKEY = keyStatsDepositAmtTotals() | |
579 | 579 | let byDayKEY = keyStatsDepositAmtByDay(toStartOfDay(lastBlock.timestamp)) | |
580 | 580 | let currTotals = padList(split(valueOrElse(getString(totalsKEY), defaultTotalsDATA), SEP)) | |
581 | 581 | func dep (acc,pmt) = { | |
582 | 582 | let amount = pmt.amount | |
583 | 583 | let pmtAssetIdStr = toBase58String(valueOrElse(pmt.assetId, WAVESID)) | |
584 | 584 | if (!(contains(supportedAssetsStr, pmtAssetIdStr))) | |
585 | 585 | then throw(((supportedAssetsStr + " doesn't contain ") + pmtAssetIdStr)) | |
586 | 586 | else if ((totalStaked == 0)) | |
587 | 587 | then $Tuple4((acc._1 :+ IncrementNotDistributedRewardEntry(pmtAssetIdStr, amount)), (acc._2 :+ pmtAssetIdStr), (acc._3 :+ toBigInt(0)), (acc._4 :+ amount)) | |
588 | 588 | else { | |
589 | 589 | let rewardPerNsbtX18 = fraction(toBigInt(amount), MULTX18, toBigInt(totalStaked)) | |
590 | 590 | $Tuple4(acc._1, (acc._2 :+ pmtAssetIdStr), (acc._3 :+ rewardPerNsbtX18), (acc._4 :+ amount)) | |
591 | 591 | } | |
592 | 592 | } | |
593 | 593 | ||
594 | 594 | let pmtsResult = { | |
595 | 595 | let $l = i.payments | |
596 | 596 | let $s = size($l) | |
597 | 597 | let $acc0 = $Tuple4(nil, nil, nil, nil) | |
598 | 598 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
599 | 599 | then $a | |
600 | 600 | else dep($a, $l[$i]) | |
601 | 601 | ||
602 | 602 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
603 | 603 | then $a | |
604 | 604 | else throw("List size exceeds 10") | |
605 | 605 | ||
606 | 606 | $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) | |
607 | 607 | } | |
608 | 608 | func refreshRewardUpdateTotals (accum,nextAsset) = { | |
609 | 609 | let k = accum._3 | |
610 | 610 | let sumLastStr = getStrOrElse(keyRewardPerNsbtSumAt(depositNumLast, nextAsset), "0") | |
611 | 611 | let idx = indexOf(pmtsResult._2, nextAsset) | |
612 | 612 | let sum = if (isDefined(idx)) | |
613 | 613 | then { | |
614 | 614 | let j = value(idx) | |
615 | 615 | let statsDelta = pmtsResult._4[j] | |
616 | 616 | $Tuple2(toString((parseBigIntValue(sumLastStr) + pmtsResult._3[j])), toString((parseIntValue(currTotals[(k + 1)]) + statsDelta))) | |
617 | 617 | } | |
618 | 618 | else $Tuple2(sumLastStr, currTotals[(k + 1)]) | |
619 | 619 | $Tuple3((accum._1 :+ StringEntry(keyRewardPerNsbtSumAt(depositNumNew, nextAsset), sum._1)), ((accum._2 + SEP) + sum._2), (k + 1)) | |
620 | 620 | } | |
621 | 621 | ||
622 | 622 | let assetsResult = { | |
623 | 623 | let $l = supportedAssetsList | |
624 | 624 | let $s = size($l) | |
625 | 625 | let $acc0 = $Tuple3(nil, DepositTotalsPREFIX, 0) | |
626 | 626 | func $f1_1 ($a,$i) = if (($i >= $s)) | |
627 | 627 | then $a | |
628 | 628 | else refreshRewardUpdateTotals($a, $l[$i]) | |
629 | 629 | ||
630 | 630 | func $f1_2 ($a,$i) = if (($i >= $s)) | |
631 | 631 | then $a | |
632 | 632 | else throw("List size exceeds 9") | |
633 | 633 | ||
634 | 634 | $f1_2($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9) | |
635 | 635 | } | |
636 | 636 | let totals = padString(assetsResult._2) | |
637 | 637 | $Tuple2(((((pmtsResult._1 ++ assetsResult._1) :+ IntegerEntry(depositNumLastKEY, depositNumNew)) :+ StringEntry(totalsKEY, totals)) :+ StringEntry(byDayKEY, totals)), depositNumNew) | |
638 | 638 | } | |
639 | 639 | } | |
640 | 640 | ||
641 | 641 | ||
642 | 642 | ||
643 | 643 | @Callable(i) | |
644 | 644 | func claimRewards () = commonClaim(i.caller, i) | |
645 | 645 | ||
646 | 646 | ||
647 | 647 | ||
648 | 648 | @Callable(i) | |
649 | 649 | func claimRewardsByOriginCaller () = commonClaim(i.originCaller, i) | |
650 | 650 | ||
651 | 651 | ||
652 | 652 | ||
653 | 653 | @Callable(i) | |
654 | 654 | func x2Gnsbt () = commonX2Gnsbt(i.caller, i) | |
655 | 655 | ||
656 | 656 | ||
657 | 657 | ||
658 | 658 | @Callable(i) | |
659 | 659 | func x2GnsbtByOriginCaller () = commonX2Gnsbt(i.originCaller, i) | |
660 | 660 | ||
661 | 661 | ||
662 | 662 | ||
663 | 663 | @Callable(i) | |
664 | 664 | func unclaimedRewardsREADONLY (userAddressStr) = { | |
665 | 665 | func forEachAssetZeroReward (accum,asset) = ((accum + makeString([asset, "0", "0"], ":")) + "_") | |
666 | 666 | ||
667 | 667 | let unclaimedRewardStr = if ((userAddressStr == "")) | |
668 | 668 | then { | |
669 | 669 | let $l = supportedAssetsList | |
670 | 670 | let $s = size($l) | |
671 | 671 | let $acc0 = "" | |
672 | 672 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
673 | 673 | then $a | |
674 | 674 | else forEachAssetZeroReward($a, $l[$i]) | |
675 | 675 | ||
676 | 676 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
677 | 677 | then $a | |
678 | 678 | else throw("List size exceeds 9") | |
679 | 679 | ||
680 | 680 | $f0_2($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) | |
681 | 681 | } | |
682 | 682 | else { | |
683 | 683 | let userAddress = addressFromStringValue(userAddressStr) | |
684 | 684 | let $t02583625955 = valueOrElse(getUserParamsOrUnit(userAddress), $Tuple4(true, 0, 0, 0)) | |
685 | 685 | let isNewUser = $t02583625955._1 | |
686 | 686 | let stakedAmount = $t02583625955._2 | |
687 | 687 | let stakingStart = $t02583625955._3 | |
688 | 688 | let userGnsbt = $t02583625955._4 | |
689 | 689 | let stakedAmountX = toBigInt(userGnsbt) | |
690 | 690 | let userRewardFromDepositNumKEY = keyUserRewardFromDepositNum(userAddressStr) | |
691 | 691 | let depositNumUser = getIntOrElse(userRewardFromDepositNumKEY, -1) | |
692 | 692 | let depositNumLast = getIntOrElse(keyDepositNumLast(), -1) | |
693 | 693 | func forEachAssetCalcUnclaimedReward (accum,asset) = { | |
694 | 694 | let $t02629826436 = calcReward(userAddressStr, asset, stakedAmountX, depositNumUser, depositNumLast) | |
695 | 695 | let rewardTotal = $t02629826436._1 | |
696 | 696 | let cached = $t02629826436._2 | |
697 | 697 | let dynamic = $t02629826436._3 | |
698 | 698 | let rewardCachedPartKEY = $t02629826436._4 | |
699 | 699 | let claimed = valueOrElse(getInteger(keyClaimed(userAddressStr, asset)), 0) | |
700 | 700 | ((accum + makeString([asset, toString(rewardTotal), toString(claimed)], ":")) + "_") | |
701 | 701 | } | |
702 | 702 | ||
703 | 703 | let $l = supportedAssetsList | |
704 | 704 | let $s = size($l) | |
705 | 705 | let $acc0 = "" | |
706 | 706 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
707 | 707 | then $a | |
708 | 708 | else forEachAssetCalcUnclaimedReward($a, $l[$i]) | |
709 | 709 | ||
710 | 710 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
711 | 711 | then $a | |
712 | 712 | else throw("List size exceeds 9") | |
713 | 713 | ||
714 | 714 | $f0_2($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) | |
715 | 715 | } | |
716 | 716 | $Tuple2(nil, dropRight(unclaimedRewardStr, 1)) | |
717 | 717 | } | |
718 | 718 | ||
719 | 719 | ||
720 | 720 | ||
721 | 721 | @Callable(i) | |
722 | 722 | func nsbtUnstakingSYSREADONLY (userAddressStrOrEmpty,unstakeAmtP) = { | |
723 | 723 | let resultArray = if ((userAddressStrOrEmpty == "")) | |
724 | 724 | then [0, 0, 0, 0] | |
725 | 725 | else { | |
726 | 726 | let userAddress = addressFromStringValue(userAddressStrOrEmpty) | |
727 | 727 | let cfgDATA = getParamsOrFail() | |
728 | 728 | let nsbtAssetId = cfgDATA._1 | |
729 | 729 | let minLockAmount = cfgDATA._2 | |
730 | 730 | let halfLife = cfgDATA._3 | |
731 | 731 | let userDATA = valueOrElse(getUserParamsOrUnit(userAddress), $Tuple4(true, 0, 0, 0)) | |
732 | 732 | let isNewUser = userDATA._1 | |
733 | 733 | let stakedAmount = userDATA._2 | |
734 | 734 | let lockStart = userDATA._3 | |
735 | 735 | let unstakeAmt = if ((unstakeAmtP > stakedAmount)) | |
736 | 736 | then stakedAmount | |
737 | 737 | else unstakeAmtP | |
738 | 738 | let stakedAmountNEW = (stakedAmount - unstakeAmt) | |
739 | 739 | let comissionAmount = if ((unstakeAmt == 0)) | |
740 | 740 | then 0 | |
741 | 741 | else asInt(invoke(mathContract, "getUnstakeComissionAmountREADONLY", [unstakeAmt, lockStart, halfLife], nil)) | |
742 | 742 | let receiveAmount = (unstakeAmt - comissionAmount) | |
743 | 743 | [stakedAmount, stakedAmountNEW, receiveAmount, comissionAmount] | |
744 | 744 | } | |
745 | 745 | $Tuple2(nil, resultArray) | |
746 | 746 | } | |
747 | 747 | ||
748 | 748 | ||
749 | 749 | ||
750 | 750 | @Callable(i) | |
751 | 751 | func nsbtStakingSYSREADONLY (userAddressStr,nsbtDiff) = { | |
752 | 752 | let totalNsbtAmt = getIntOrElse(keyLockParamTotalAmount(), 0) | |
753 | 753 | let totalGnsbt = getIntOrElse(keyLockParamTotalGnsbt(), totalNsbtAmt) | |
754 | 754 | if ((userAddressStr == "")) | |
755 | 755 | then $Tuple2(nil, [0, totalNsbtAmt, 0, 0, totalGnsbt]) | |
756 | 756 | else { | |
757 | 757 | let userAddress = toAddressOrFail(userAddressStr) | |
758 | 758 | let $t02822628344 = valueOrElse(getUserParamsOrUnit(userAddress), $Tuple4(true, 0, 0, 0)) | |
759 | 759 | let isNewUser = $t02822628344._1 | |
760 | 760 | let userNsbtAmt = $t02822628344._2 | |
761 | 761 | let stakingStart = $t02822628344._3 | |
762 | 762 | let userGnsbt = $t02822628344._4 | |
763 | 763 | $Tuple2(nil, [userNsbtAmt, totalNsbtAmt, stakingStart, userGnsbt, totalGnsbt]) | |
764 | 764 | } | |
765 | 765 | } | |
766 | 766 | ||
767 | 767 | ||
768 | 768 | @Verifier(tx) | |
769 | 769 | func verify () = { | |
770 | 770 | let pubKeyAdminsListStr = makeString(["ExtEEK19nmKj9mCpnWyvEEJFYATLMcVEMvohhUHkyHNm", "Ev5py5FfBQX9cZpYKnfQrTB49Byf8QmpZWeDVRim4yV7", "DUuuLjXu98nBwZc7fqwCTjtA3nnRwgTbkMSr5SU2NmDR", "DUuuLjXu98nBwZc7fqwCTjtA3nnRwgTbkMSr5SU2NmDR"], SEP) | |
771 | 771 | let pubKeyAdminsList = split(valueOrElse(getString(controlContract, "%s__multisig"), pubKeyAdminsListStr), SEP) | |
772 | 772 | let count = ((((if (sigVerify(tx.bodyBytes, tx.proofs[0], fromBase58String(pubKeyAdminsList[0]))) | |
773 | 773 | then 1 | |
774 | 774 | else 0) + (if (sigVerify(tx.bodyBytes, tx.proofs[1], fromBase58String(pubKeyAdminsList[1]))) | |
775 | 775 | then 1 | |
776 | 776 | else 0)) + (if (sigVerify(tx.bodyBytes, tx.proofs[2], fromBase58String(pubKeyAdminsList[2]))) | |
777 | 777 | then 1 | |
778 | 778 | else 0)) + (if (sigVerify(tx.bodyBytes, tx.proofs[3], fromBase58String(pubKeyAdminsList[3]))) | |
779 | 779 | then 2 | |
780 | 780 | else 0)) | |
781 | 781 | (count >= 3) | |
782 | 782 | } | |
783 | 783 |
github/deemru/w8io/169f3d6 70.06 ms ◑