tx · 2cZVyvBHKd7w5G2oj2uPqDLvuyUWDjewBryYNKfpGr4j 3MumkGGztCKAXpWDqxkddofqXSUbqQkvSJy: -0.02500000 Waves 2023.06.19 14:29 [2629449] smart account 3MumkGGztCKAXpWDqxkddofqXSUbqQkvSJy > SELF 0.00000000 Waves
{ "type": 13, "id": "2cZVyvBHKd7w5G2oj2uPqDLvuyUWDjewBryYNKfpGr4j", "fee": 2500000, "feeAssetId": null, "timestamp": 1687174163920, "version": 2, "chainId": 84, "sender": "3MumkGGztCKAXpWDqxkddofqXSUbqQkvSJy", "senderPublicKey": "C3PaRKeL8AUKbwUqdniMQtThgcTh5DYHV1777Hkxy7rp", "proofs": [ "4KdT3gLHhY43D1BggwYSTird5aDGyn4uUTGdUZu2yZUUpjGnDeDYhuPFETL3D93nHP4TMDhhq6Z7V8mPKT5G1iNC" ], "script": "base64:BgJHCAISAwoBGBIDCgEIEgMKAQgSAwoBCBIDCgEIEgMKAQgSAwoBGBIDCgEIEgMKARgSAwoBGBIDCgEYEgMKARgSAwoBCBIAEgCEAQAFY2hhaW4JAMkBAgkAygECCAUEdGhpcwVieXRlcwABAAEAC3VzZHRBc3NldElkBAckbWF0Y2gwBQVjaGFpbgMJAAACAQFXBQckbWF0Y2gwASCE2nqyCAM/TtG7yo7ui5O8yYLdC136B5ao1CP5qA//uQMJAAACAQFUBQckbWF0Y2gwASBVsdifcoeC7+XjW42sBatl3ppDoS8WuwXzGreHpfHFGAkAAgECDVVua25vd24gY2hhaW4AFWRlZmF1bHRSZXN0QWRkcmVzc1N0cgQHJG1hdGNoMAUFY2hhaW4DCQAAAgEBVwUHJG1hdGNoMAIjM1BRQ3V2RmJ2aDRMa1BVbnJuVTF6M2puYkExcDltM1dOaHYDCQAAAgEBVAUHJG1hdGNoMAIjM011bWtHR3p0Q0tBWHBXRHF4a2Rkb2ZxWFNVYnFRa3ZTSnkJAAIBAg1Vbmtub3duIGNoYWluABFJbmZyYVVwZ3JhZGVDb3N0UwQHJG1hdG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mMF8xAgkBBSRmMF8xAgkBBSRmMF8xAgkBBSRmMF8xAgkBBSRmMF8xAgkBBSRmMF8xAgkBBSRmMF8xAgkBBSRmMF8xAgkBBSRmMF8xAgkBBSRmMF8xAgkBBSRmMF8xAgkBBSRmMF8xAgkBBSRmMF8xAgkBBSRmMF8xAgkBBSRmMF8xAgkBBSRmMF8xAgkBBSRmMF8xAgkBBSRmMF8xAgkBBSRmMF8xAgkBBSRmMF8xAgkBBSRmMF8xAgkBBSRmMF8xAgkBBSRmMF8xAgUFJGFjYzAAAAABAAIAAwAEAAUABgAHAAgACQAKAAsADAANAA4ADwAQABEAEgATABQAFQAWABcAGAAZABoAGwAcAB0AHgAfACAAIQAiACMAJAAlACYAJwAoACkAKgArACwALQAuAC8AMAAxADICXzECAToEBnJlc3VsdAkArAICAhwlcyVzX19lbWVyZ2VuY3lTZXJ2aWNlRGF0YV9fBQFzCQCUCgIFA25pbAUGcmVzdWx0AWkBEHdsZ1N0YXRzUkVBRE9OTFkABAhjdXJTdGF0cwkBC2dldFdsZ1N0YXRzAAkAlAoCBQNuaWwJAMwIAgkArAICAhMlcyVzJWRfX3dsZ0Ftb3VudF9fCQCkAwEJAJEDAgUIY3VyU3RhdHMFDGlkeFdsZ0Ftb3VudAkAzAgCCQCsAgICEiVzJXMlZF9fd2xnUHJpY2VfXwkApAMBCQCRAwIFCGN1clN0YXRzBQtpZHhXbGdQcmljZQkAzAgCCQCsAgICEyVzJXMlZF9fdXNkdEZ1bmRzX18JAKQDAQkAkQMCBQhjdXJTdGF0cwULaWR4V2xnRnVuZHMFA25pbAACvF9H", "height": 2629449, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 2yXc28EAoPnVATw8xsefEGBgSHen8r191kpwkotSJEDg Next: 3WPaa5MMuvdphvLmonoBBv4ykNhojDYpNkk7pFzp5fCF Diff:
Old | New | Differences | |
---|---|---|---|
34 | 34 | ||
35 | 35 | let MULT6 = 1000000 | |
36 | 36 | ||
37 | + | let MULT7 = 10000000 | |
38 | + | ||
39 | + | let MULT8 = 100000000 | |
40 | + | ||
41 | + | let MULT10 = 10000000000 | |
42 | + | ||
43 | + | let LANDPREFIX = "LAND" | |
44 | + | ||
45 | + | let DUCKPREFIX = "DUCK" | |
46 | + | ||
37 | 47 | let ARTPRESALE = "PRESALE" | |
38 | 48 | ||
39 | 49 | let NUMRES = 6 | |
54 | 64 | ||
55 | 65 | let WHMULTIPLIER = 10000000000 | |
56 | 66 | ||
67 | + | let DEFAULTLOCATION = "Africa_F_Africa" | |
68 | + | ||
57 | 69 | let RESOURCEPRICEMIN = 39637 | |
58 | 70 | ||
59 | 71 | let ESMAXPACKAGES = 3 | |
62 | 74 | ||
63 | 75 | let ESSELLCOEF = 10 | |
64 | 76 | ||
77 | + | let MAXHP = 100 | |
78 | + | ||
79 | + | let resTypes = ["Oil", "Ore", "Wood", "Sand", "Clay", "Organic"] | |
80 | + | ||
81 | + | let matTypes = ["Fuel", "Metal", "Plank", "Glass", "Plastic", "Protein"] | |
82 | + | ||
83 | + | let prodTypes = ["First Aid Kit L1", "First Aid Kit L2", "First Aid Kit L3", "Backpack L1", "Backpack L2", "Backpack L3", "Food Ration L1", "Food Ration L2", "Food Ration L3", "Jet Pack L1", "Jet Pack L2", "Jet Pack L3", "Shield L1", "Shield L2", "Shield L3"] | |
84 | + | ||
85 | + | let continents = ["Americas", "Europe", "Asia", "Africa", "Oceania"] | |
86 | + | ||
65 | 87 | let productionMatrix = ["1_1_1_2_2_5_1_10_0", "2_2_2_4_4_10_1_10_0", "3_3_3_6_6_15_1_10_0", "2_5_5_2_7_5_2_100_1", "4_10_10_4_14_10_2_100_1", "6_15_15_6_21_15_2_100_1", "1_1_1_1_1_8_1_10_2", "2_2_2_2_2_16_1_10_2", "3_3_3_3_3_24_1_10_2", "9_9_1_5_5_1_5_100_3", "18_18_2_10_10_2_5_100_3", "27_27_3_15_15_3_5_100_3", "2_2_1_2_2_2_1_10_4", "4_4_2_4_4_4_1_10_4", "6_6_3_6_6_6_1_10_4"] | |
66 | 88 | ||
89 | + | let contIdxAmericas = 0 | |
90 | + | ||
91 | + | let contIdxEurope = 1 | |
92 | + | ||
93 | + | let contIdxAsia = 2 | |
94 | + | ||
95 | + | let contIdxAfrica = 3 | |
96 | + | ||
97 | + | let contIdxOceania = 4 | |
98 | + | ||
99 | + | let recipeIdxFuel = 0 | |
100 | + | ||
101 | + | let recipeIdxMetal = 1 | |
102 | + | ||
103 | + | let recipeIdxPlank = 2 | |
104 | + | ||
105 | + | let recipeIdxGlass = 3 | |
106 | + | ||
107 | + | let recipeIdxPlastic = 4 | |
108 | + | ||
109 | + | let recipeIdxProtein = 5 | |
110 | + | ||
111 | + | let recipeIdxWeight = 6 | |
112 | + | ||
67 | 113 | let recipeIdxPacksize = 7 | |
114 | + | ||
115 | + | let recipeIdxContinent = 8 | |
68 | 116 | ||
69 | 117 | let recLandNum = 0 | |
70 | 118 | ||
74 | 122 | ||
75 | 123 | let recContinent = 3 | |
76 | 124 | ||
125 | + | let whIdxLevels = 0 | |
126 | + | ||
127 | + | let whIdxRes = 1 | |
128 | + | ||
129 | + | let whIdxMat = 2 | |
130 | + | ||
131 | + | let whIdxProd = 3 | |
132 | + | ||
133 | + | let whIdxLOFT = 4 | |
134 | + | ||
135 | + | let volLocked = 0 | |
136 | + | ||
137 | + | let volOccupied = 1 | |
138 | + | ||
139 | + | let volFree = 2 | |
140 | + | ||
141 | + | let volTotal = 3 | |
142 | + | ||
143 | + | let bpIdxLevel = 0 | |
144 | + | ||
145 | + | let bpIdxRes = 1 | |
146 | + | ||
147 | + | let bpIdxMat = 2 | |
148 | + | ||
149 | + | let bpIdxProd = 3 | |
150 | + | ||
151 | + | func getPkgSize (prodIdx) = parseIntValue(split(productionMatrix[prodIdx], "_")[recipeIdxPacksize]) | |
152 | + | ||
153 | + | ||
77 | 154 | func getStringOrFail (address,key) = valueOrErrorMessage(getString(address, key), makeString(["mandatory ", toString(address), ".", key, " is not defined"], "")) | |
155 | + | ||
156 | + | ||
157 | + | func getIntOrElse (key,defaultVal) = valueOrElse(getInteger(this, key), defaultVal) | |
78 | 158 | ||
79 | 159 | ||
80 | 160 | let IdxCfgStakingDapp = 1 | |
81 | 161 | ||
82 | 162 | let IdxCfgEconomyDapp = 2 | |
163 | + | ||
164 | + | let IdxCfgGovernanceDapp = 3 | |
165 | + | ||
166 | + | let IdxCfgWlgDapp = 4 | |
83 | 167 | ||
84 | 168 | func keyRestCfg () = "%s__restConfig" | |
85 | 169 | ||
101 | 185 | ||
102 | 186 | let economyContract = getContractAddressOrFail(restCfg, IdxCfgEconomyDapp) | |
103 | 187 | ||
188 | + | let govContract = getContractAddressOrFail(restCfg, IdxCfgGovernanceDapp) | |
189 | + | ||
190 | + | let wlgContract = getContractAddressOrFail(restCfg, IdxCfgWlgDapp) | |
191 | + | ||
104 | 192 | func keyLastTxIdByUser (addr) = ("lastTxIdByUser_" + addr) | |
105 | 193 | ||
106 | 194 | ||
119 | 207 | func keyLandArtStatusByTypeAndAssetId (type,assetId) = makeString(["landArtStatus", type, assetId], "_") | |
120 | 208 | ||
121 | 209 | ||
210 | + | func keyStakedTimeByTypeAssetIdAndOwner (nftType,assetId,ownerAddr) = ((((("stakedTimeByTypeAssetIdAndOwner_" + nftType) + "_") + assetId) + "_") + ownerAddr) | |
211 | + | ||
212 | + | ||
122 | 213 | func keyWarehouseByLand (landAssetId) = ("wareHouse_" + landAssetId) | |
123 | 214 | ||
124 | 215 | ||
125 | 216 | func keyStakedLandsByOwner (ownerAddr) = ("stakedLandsByOwner_" + ownerAddr) | |
217 | + | ||
218 | + | ||
219 | + | func keyStakedPiecesByOwner (ownerAddr) = ("stakedPiecesByOwner_" + ownerAddr) | |
126 | 220 | ||
127 | 221 | ||
128 | 222 | func keyDuckAssetIdToCustomName (assetId) = ("duckCustomNameByAssetId_" + assetId) | |
143 | 237 | func keyStakedDuckByOwner (ownerAddr) = ("stakedDuckByOwner_" + ownerAddr) | |
144 | 238 | ||
145 | 239 | ||
240 | + | func keyBackpackByDuck (duckAssetId) = ("backPack_" + duckAssetId) | |
241 | + | ||
242 | + | ||
146 | 243 | func keyDuckLocation (duckAssetId) = ("duckLocation_" + duckAssetId) | |
147 | 244 | ||
148 | 245 | ||
149 | 246 | func keyDuckHealth (duckAssetId) = ("duckHealth_" + duckAssetId) | |
150 | 247 | ||
151 | 248 | ||
249 | + | func keyResProportions () = "resTypesProportions" | |
250 | + | ||
251 | + | ||
152 | 252 | func keyBlocked () = "contractsBlocked" | |
253 | + | ||
254 | + | ||
255 | + | func keyUserGwlReleaseTime (userAddr) = ("%s%s__userGwlReleaseTime__" + userAddr) | |
153 | 256 | ||
154 | 257 | ||
155 | 258 | func keyOrderByLand (landAssetId) = ("landOrder_" + landAssetId) | |
157 | 260 | ||
158 | 261 | func keyEsWarehouse () = "emergencyWarehouseProducts" | |
159 | 262 | ||
263 | + | ||
264 | + | let locIdxContinent = 0 | |
265 | + | ||
266 | + | let locIdxType = 1 | |
267 | + | ||
268 | + | let locIdxId = 2 | |
160 | 269 | ||
161 | 270 | func asString (v) = match v { | |
162 | 271 | case s: String => | |
171 | 280 | n | |
172 | 281 | case _ => | |
173 | 282 | throw("fail to cast into Int") | |
283 | + | } | |
284 | + | ||
285 | + | ||
286 | + | func asAnyList (v) = match v { | |
287 | + | case l: List[Any] => | |
288 | + | l | |
289 | + | case _ => | |
290 | + | throw("fail to cast into List[Any]") | |
174 | 291 | } | |
175 | 292 | ||
176 | 293 | ||
198 | 315 | } | |
199 | 316 | ||
200 | 317 | ||
318 | + | let IdxEffTotal = 0 | |
319 | + | ||
320 | + | let IdxEffUser = 1 | |
321 | + | ||
322 | + | func getVotingPower (userAddrStrOrEmpty) = { | |
323 | + | let props = split(valueOrElse(getString(stakingContract, keyResProportions()), "0_0_0_0_0_0"), "_") | |
324 | + | func adder (acc,item) = (acc + parseIntValue(item)) | |
325 | + | ||
326 | + | let totalPower = { | |
327 | + | let $l = props | |
328 | + | let $s = size($l) | |
329 | + | let $acc0 = 0 | |
330 | + | func $f0_1 ($a,$i) = if (($i >= $s)) | |
331 | + | then $a | |
332 | + | else adder($a, $l[$i]) | |
333 | + | ||
334 | + | func $f0_2 ($a,$i) = if (($i >= $s)) | |
335 | + | then $a | |
336 | + | else throw("List size exceeds 6") | |
337 | + | ||
338 | + | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6) | |
339 | + | } | |
340 | + | let usersPower = if ((userAddrStrOrEmpty == "")) | |
341 | + | then 0 | |
342 | + | else { | |
343 | + | let landsStr = getString(stakingContract, keyStakedLandsByOwner(userAddrStrOrEmpty)) | |
344 | + | let lands = if (isDefined(landsStr)) | |
345 | + | then split_51C(value(landsStr), "_") | |
346 | + | else nil | |
347 | + | func oneLand (acc,landAssetId) = { | |
348 | + | let asset = value(assetInfo(fromBase58String(landAssetId))) | |
349 | + | let landSize = split(asset.description, "_")[recLandSize] | |
350 | + | (acc + numPiecesBySize(landSize)) | |
351 | + | } | |
352 | + | ||
353 | + | let $l = lands | |
354 | + | let $s = size($l) | |
355 | + | let $acc0 = 0 | |
356 | + | func $f1_1 ($a,$i) = if (($i >= $s)) | |
357 | + | then $a | |
358 | + | else oneLand($a, $l[$i]) | |
359 | + | ||
360 | + | func $f1_2 ($a,$i) = if (($i >= $s)) | |
361 | + | then $a | |
362 | + | else throw("List size exceeds 100") | |
363 | + | ||
364 | + | $f1_2($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($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), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20), 21), 22), 23), 24), 25), 26), 27), 28), 29), 30), 31), 32), 33), 34), 35), 36), 37), 38), 39), 40), 41), 42), 43), 44), 45), 46), 47), 48), 49), 50), 51), 52), 53), 54), 55), 56), 57), 58), 59), 60), 61), 62), 63), 64), 65), 66), 67), 68), 69), 70), 71), 72), 73), 74), 75), 76), 77), 78), 79), 80), 81), 82), 83), 84), 85), 86), 87), 88), 89), 90), 91), 92), 93), 94), 95), 96), 97), 98), 99), 100) | |
365 | + | } | |
366 | + | [totalPower, usersPower] | |
367 | + | } | |
368 | + | ||
369 | + | ||
201 | 370 | func getRecipeMaterials (recipe) = { | |
202 | 371 | func addMat (ac,j) = (ac + parseIntValue(recipe[j])) | |
203 | 372 | ||
217 | 386 | ||
218 | 387 | ||
219 | 388 | let USDTPRIZEPART = 500000 | |
389 | + | ||
390 | + | let wlgIssuedAmountKey = "wlg_issuedAmount" | |
391 | + | ||
392 | + | let idxWlgAmount = 0 | |
393 | + | ||
394 | + | let idxWlgPrice = 1 | |
395 | + | ||
396 | + | let idxWlgFunds = 2 | |
220 | 397 | ||
221 | 398 | func asListIntCompacted (val) = match val { | |
222 | 399 | case valAnyList: List[Any] => | |
339 | 516 | let productivity = applyBonuses(landAssetId, pieces) | |
340 | 517 | [("%s%s__assetId__" + landAssetId), ("%s%s__owner__" + owner), ("%s%s__warehouse__" + makeString(getWarehouse(keyWarehouseByLand(landAssetId), (pieces / SSIZE), productivity._1), ":")), ("%s%s__landOrder__" + valueOrElse(getString(economyContract, keyOrderByLand(landAssetId)), "0@0_0@0_0@0_0@0_0@0_0@0:0@0_0@0_0@0_0@0_0@0_0@0:"))] | |
341 | 518 | } | |
519 | + | ||
520 | + | ||
521 | + | func getWlgStats () = { | |
522 | + | let issuedAmount = valueOrErrorMessage(getInteger(wlgContract, wlgIssuedAmountKey), "WLGOLD is not issued yet") | |
523 | + | let funds = ((assetBalance(economyContract, usdtAssetId) + assetBalance(restContract, usdtAssetId)) + assetBalance(wlgContract, usdtAssetId)) | |
524 | + | [issuedAmount, fraction(funds, MULT8, issuedAmount), funds] | |
525 | + | } | |
342 | 526 | ||
343 | 527 | ||
344 | 528 | @Callable(i) | |
666 | 850 | } | |
667 | 851 | ||
668 | 852 | ||
853 | + | ||
854 | + | @Callable(i) | |
855 | + | func wlgStatsREADONLY () = { | |
856 | + | let curStats = getWlgStats() | |
857 | + | $Tuple2(nil, [("%s%s%d__wlgAmount__" + toString(curStats[idxWlgAmount])), ("%s%s%d__wlgPrice__" + toString(curStats[idxWlgPrice])), ("%s%s%d__usdtFunds__" + toString(curStats[idxWlgFunds]))]) | |
858 | + | } | |
859 | + | ||
860 | + |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let chain = take(drop(this.bytes, 1), 1) | |
5 | 5 | ||
6 | 6 | let usdtAssetId = match chain { | |
7 | 7 | case _ => | |
8 | 8 | if ((base58'2W' == $match0)) | |
9 | 9 | then base58'9wc3LXNA4TEBsXyKtoLE9mrbDD7WMHXvXrCjZvabLAsi' | |
10 | 10 | else if ((base58'2T' == $match0)) | |
11 | 11 | then base58'6mWwf9mZBjVgkC54idpyaZLQfAosD914wT8fGf2iiY63' | |
12 | 12 | else throw("Unknown chain") | |
13 | 13 | } | |
14 | 14 | ||
15 | 15 | let defaultRestAddressStr = match chain { | |
16 | 16 | case _ => | |
17 | 17 | if ((base58'2W' == $match0)) | |
18 | 18 | then "3PQCuvFbvh4LkPUnrnU1z3jnbA1p9m3WNhv" | |
19 | 19 | else if ((base58'2T' == $match0)) | |
20 | 20 | then "3MumkGGztCKAXpWDqxkddofqXSUbqQkvSJy" | |
21 | 21 | else throw("Unknown chain") | |
22 | 22 | } | |
23 | 23 | ||
24 | 24 | let InfraUpgradeCostS = match chain { | |
25 | 25 | case _ => | |
26 | 26 | if ((base58'2W' == $match0)) | |
27 | 27 | then 10000000000 | |
28 | 28 | else if ((base58'2T' == $match0)) | |
29 | 29 | then 100000000 | |
30 | 30 | else throw("Unknown chain") | |
31 | 31 | } | |
32 | 32 | ||
33 | 33 | let SEP = "__" | |
34 | 34 | ||
35 | 35 | let MULT6 = 1000000 | |
36 | 36 | ||
37 | + | let MULT7 = 10000000 | |
38 | + | ||
39 | + | let MULT8 = 100000000 | |
40 | + | ||
41 | + | let MULT10 = 10000000000 | |
42 | + | ||
43 | + | let LANDPREFIX = "LAND" | |
44 | + | ||
45 | + | let DUCKPREFIX = "DUCK" | |
46 | + | ||
37 | 47 | let ARTPRESALE = "PRESALE" | |
38 | 48 | ||
39 | 49 | let NUMRES = 6 | |
40 | 50 | ||
41 | 51 | let SSIZE = 25 | |
42 | 52 | ||
43 | 53 | let MSIZE = 100 | |
44 | 54 | ||
45 | 55 | let LSIZE = 225 | |
46 | 56 | ||
47 | 57 | let XLSIZE = 400 | |
48 | 58 | ||
49 | 59 | let XXLSIZE = 625 | |
50 | 60 | ||
51 | 61 | let DAILYRESBYPIECE = 3456000 | |
52 | 62 | ||
53 | 63 | let DAYMILLIS = 86400000 | |
54 | 64 | ||
55 | 65 | let WHMULTIPLIER = 10000000000 | |
56 | 66 | ||
67 | + | let DEFAULTLOCATION = "Africa_F_Africa" | |
68 | + | ||
57 | 69 | let RESOURCEPRICEMIN = 39637 | |
58 | 70 | ||
59 | 71 | let ESMAXPACKAGES = 3 | |
60 | 72 | ||
61 | 73 | let ESBUYCOEF = 4 | |
62 | 74 | ||
63 | 75 | let ESSELLCOEF = 10 | |
64 | 76 | ||
77 | + | let MAXHP = 100 | |
78 | + | ||
79 | + | let resTypes = ["Oil", "Ore", "Wood", "Sand", "Clay", "Organic"] | |
80 | + | ||
81 | + | let matTypes = ["Fuel", "Metal", "Plank", "Glass", "Plastic", "Protein"] | |
82 | + | ||
83 | + | let prodTypes = ["First Aid Kit L1", "First Aid Kit L2", "First Aid Kit L3", "Backpack L1", "Backpack L2", "Backpack L3", "Food Ration L1", "Food Ration L2", "Food Ration L3", "Jet Pack L1", "Jet Pack L2", "Jet Pack L3", "Shield L1", "Shield L2", "Shield L3"] | |
84 | + | ||
85 | + | let continents = ["Americas", "Europe", "Asia", "Africa", "Oceania"] | |
86 | + | ||
65 | 87 | let productionMatrix = ["1_1_1_2_2_5_1_10_0", "2_2_2_4_4_10_1_10_0", "3_3_3_6_6_15_1_10_0", "2_5_5_2_7_5_2_100_1", "4_10_10_4_14_10_2_100_1", "6_15_15_6_21_15_2_100_1", "1_1_1_1_1_8_1_10_2", "2_2_2_2_2_16_1_10_2", "3_3_3_3_3_24_1_10_2", "9_9_1_5_5_1_5_100_3", "18_18_2_10_10_2_5_100_3", "27_27_3_15_15_3_5_100_3", "2_2_1_2_2_2_1_10_4", "4_4_2_4_4_4_1_10_4", "6_6_3_6_6_6_1_10_4"] | |
66 | 88 | ||
89 | + | let contIdxAmericas = 0 | |
90 | + | ||
91 | + | let contIdxEurope = 1 | |
92 | + | ||
93 | + | let contIdxAsia = 2 | |
94 | + | ||
95 | + | let contIdxAfrica = 3 | |
96 | + | ||
97 | + | let contIdxOceania = 4 | |
98 | + | ||
99 | + | let recipeIdxFuel = 0 | |
100 | + | ||
101 | + | let recipeIdxMetal = 1 | |
102 | + | ||
103 | + | let recipeIdxPlank = 2 | |
104 | + | ||
105 | + | let recipeIdxGlass = 3 | |
106 | + | ||
107 | + | let recipeIdxPlastic = 4 | |
108 | + | ||
109 | + | let recipeIdxProtein = 5 | |
110 | + | ||
111 | + | let recipeIdxWeight = 6 | |
112 | + | ||
67 | 113 | let recipeIdxPacksize = 7 | |
114 | + | ||
115 | + | let recipeIdxContinent = 8 | |
68 | 116 | ||
69 | 117 | let recLandNum = 0 | |
70 | 118 | ||
71 | 119 | let recLandSize = 1 | |
72 | 120 | ||
73 | 121 | let recTerrains = 2 | |
74 | 122 | ||
75 | 123 | let recContinent = 3 | |
76 | 124 | ||
125 | + | let whIdxLevels = 0 | |
126 | + | ||
127 | + | let whIdxRes = 1 | |
128 | + | ||
129 | + | let whIdxMat = 2 | |
130 | + | ||
131 | + | let whIdxProd = 3 | |
132 | + | ||
133 | + | let whIdxLOFT = 4 | |
134 | + | ||
135 | + | let volLocked = 0 | |
136 | + | ||
137 | + | let volOccupied = 1 | |
138 | + | ||
139 | + | let volFree = 2 | |
140 | + | ||
141 | + | let volTotal = 3 | |
142 | + | ||
143 | + | let bpIdxLevel = 0 | |
144 | + | ||
145 | + | let bpIdxRes = 1 | |
146 | + | ||
147 | + | let bpIdxMat = 2 | |
148 | + | ||
149 | + | let bpIdxProd = 3 | |
150 | + | ||
151 | + | func getPkgSize (prodIdx) = parseIntValue(split(productionMatrix[prodIdx], "_")[recipeIdxPacksize]) | |
152 | + | ||
153 | + | ||
77 | 154 | func getStringOrFail (address,key) = valueOrErrorMessage(getString(address, key), makeString(["mandatory ", toString(address), ".", key, " is not defined"], "")) | |
155 | + | ||
156 | + | ||
157 | + | func getIntOrElse (key,defaultVal) = valueOrElse(getInteger(this, key), defaultVal) | |
78 | 158 | ||
79 | 159 | ||
80 | 160 | let IdxCfgStakingDapp = 1 | |
81 | 161 | ||
82 | 162 | let IdxCfgEconomyDapp = 2 | |
163 | + | ||
164 | + | let IdxCfgGovernanceDapp = 3 | |
165 | + | ||
166 | + | let IdxCfgWlgDapp = 4 | |
83 | 167 | ||
84 | 168 | func keyRestCfg () = "%s__restConfig" | |
85 | 169 | ||
86 | 170 | ||
87 | 171 | func keyRestAddress () = "%s__restAddr" | |
88 | 172 | ||
89 | 173 | ||
90 | 174 | func readRestCfgOrFail (rest) = split_4C(getStringOrFail(rest, keyRestCfg()), SEP) | |
91 | 175 | ||
92 | 176 | ||
93 | 177 | func getContractAddressOrFail (restCfg,idx) = valueOrErrorMessage(addressFromString(restCfg[idx]), ("Rest cfg doesn't contain address at index " + toString(idx))) | |
94 | 178 | ||
95 | 179 | ||
96 | 180 | let restContract = addressFromStringValue(valueOrElse(getString(this, keyRestAddress()), defaultRestAddressStr)) | |
97 | 181 | ||
98 | 182 | let restCfg = readRestCfgOrFail(restContract) | |
99 | 183 | ||
100 | 184 | let stakingContract = getContractAddressOrFail(restCfg, IdxCfgStakingDapp) | |
101 | 185 | ||
102 | 186 | let economyContract = getContractAddressOrFail(restCfg, IdxCfgEconomyDapp) | |
103 | 187 | ||
188 | + | let govContract = getContractAddressOrFail(restCfg, IdxCfgGovernanceDapp) | |
189 | + | ||
190 | + | let wlgContract = getContractAddressOrFail(restCfg, IdxCfgWlgDapp) | |
191 | + | ||
104 | 192 | func keyLastTxIdByUser (addr) = ("lastTxIdByUser_" + addr) | |
105 | 193 | ||
106 | 194 | ||
107 | 195 | func keyLandAssetIdToOwner (assetId) = ("nftOwner_" + assetId) | |
108 | 196 | ||
109 | 197 | ||
110 | 198 | func keyLandAssetIdToCustomName (assetId) = ("landCustomNameByAssetId_" + assetId) | |
111 | 199 | ||
112 | 200 | ||
113 | 201 | func keyStakedTimeByAssetId (assetId) = ("stakedTime_" + assetId) | |
114 | 202 | ||
115 | 203 | ||
116 | 204 | func keyInfraLevelByAssetId (assetId) = ("infraLevel_" + assetId) | |
117 | 205 | ||
118 | 206 | ||
119 | 207 | func keyLandArtStatusByTypeAndAssetId (type,assetId) = makeString(["landArtStatus", type, assetId], "_") | |
120 | 208 | ||
121 | 209 | ||
210 | + | func keyStakedTimeByTypeAssetIdAndOwner (nftType,assetId,ownerAddr) = ((((("stakedTimeByTypeAssetIdAndOwner_" + nftType) + "_") + assetId) + "_") + ownerAddr) | |
211 | + | ||
212 | + | ||
122 | 213 | func keyWarehouseByLand (landAssetId) = ("wareHouse_" + landAssetId) | |
123 | 214 | ||
124 | 215 | ||
125 | 216 | func keyStakedLandsByOwner (ownerAddr) = ("stakedLandsByOwner_" + ownerAddr) | |
217 | + | ||
218 | + | ||
219 | + | func keyStakedPiecesByOwner (ownerAddr) = ("stakedPiecesByOwner_" + ownerAddr) | |
126 | 220 | ||
127 | 221 | ||
128 | 222 | func keyDuckAssetIdToCustomName (assetId) = ("duckCustomNameByAssetId_" + assetId) | |
129 | 223 | ||
130 | 224 | ||
131 | 225 | func keyAddressToCustomName (addr) = ("accountCustomNameByAddr_" + addr) | |
132 | 226 | ||
133 | 227 | ||
134 | 228 | func keyAddressRefBy (addr) = ("accRefBy_" + addr) | |
135 | 229 | ||
136 | 230 | ||
137 | 231 | func keyAddressReferrals (addr) = ("accReferrals_" + addr) | |
138 | 232 | ||
139 | 233 | ||
140 | 234 | func keyDuckIdToOwner (assetId) = ("duckOwner_" + assetId) | |
141 | 235 | ||
142 | 236 | ||
143 | 237 | func keyStakedDuckByOwner (ownerAddr) = ("stakedDuckByOwner_" + ownerAddr) | |
144 | 238 | ||
145 | 239 | ||
240 | + | func keyBackpackByDuck (duckAssetId) = ("backPack_" + duckAssetId) | |
241 | + | ||
242 | + | ||
146 | 243 | func keyDuckLocation (duckAssetId) = ("duckLocation_" + duckAssetId) | |
147 | 244 | ||
148 | 245 | ||
149 | 246 | func keyDuckHealth (duckAssetId) = ("duckHealth_" + duckAssetId) | |
150 | 247 | ||
151 | 248 | ||
249 | + | func keyResProportions () = "resTypesProportions" | |
250 | + | ||
251 | + | ||
152 | 252 | func keyBlocked () = "contractsBlocked" | |
253 | + | ||
254 | + | ||
255 | + | func keyUserGwlReleaseTime (userAddr) = ("%s%s__userGwlReleaseTime__" + userAddr) | |
153 | 256 | ||
154 | 257 | ||
155 | 258 | func keyOrderByLand (landAssetId) = ("landOrder_" + landAssetId) | |
156 | 259 | ||
157 | 260 | ||
158 | 261 | func keyEsWarehouse () = "emergencyWarehouseProducts" | |
159 | 262 | ||
263 | + | ||
264 | + | let locIdxContinent = 0 | |
265 | + | ||
266 | + | let locIdxType = 1 | |
267 | + | ||
268 | + | let locIdxId = 2 | |
160 | 269 | ||
161 | 270 | func asString (v) = match v { | |
162 | 271 | case s: String => | |
163 | 272 | s | |
164 | 273 | case _ => | |
165 | 274 | throw("fail to cast into String") | |
166 | 275 | } | |
167 | 276 | ||
168 | 277 | ||
169 | 278 | func asInt (v) = match v { | |
170 | 279 | case n: Int => | |
171 | 280 | n | |
172 | 281 | case _ => | |
173 | 282 | throw("fail to cast into Int") | |
283 | + | } | |
284 | + | ||
285 | + | ||
286 | + | func asAnyList (v) = match v { | |
287 | + | case l: List[Any] => | |
288 | + | l | |
289 | + | case _ => | |
290 | + | throw("fail to cast into List[Any]") | |
174 | 291 | } | |
175 | 292 | ||
176 | 293 | ||
177 | 294 | func asBoolean (v) = match v { | |
178 | 295 | case s: Boolean => | |
179 | 296 | s | |
180 | 297 | case _ => | |
181 | 298 | throw("fail to cast into Boolean") | |
182 | 299 | } | |
183 | 300 | ||
184 | 301 | ||
185 | 302 | func numPiecesBySize (landSize) = match landSize { | |
186 | 303 | case _ => | |
187 | 304 | if (("S" == $match0)) | |
188 | 305 | then SSIZE | |
189 | 306 | else if (("M" == $match0)) | |
190 | 307 | then MSIZE | |
191 | 308 | else if (("L" == $match0)) | |
192 | 309 | then LSIZE | |
193 | 310 | else if (("XL" == $match0)) | |
194 | 311 | then XLSIZE | |
195 | 312 | else if (("XXL" == $match0)) | |
196 | 313 | then XXLSIZE | |
197 | 314 | else throw("Unknown land size") | |
198 | 315 | } | |
199 | 316 | ||
200 | 317 | ||
318 | + | let IdxEffTotal = 0 | |
319 | + | ||
320 | + | let IdxEffUser = 1 | |
321 | + | ||
322 | + | func getVotingPower (userAddrStrOrEmpty) = { | |
323 | + | let props = split(valueOrElse(getString(stakingContract, keyResProportions()), "0_0_0_0_0_0"), "_") | |
324 | + | func adder (acc,item) = (acc + parseIntValue(item)) | |
325 | + | ||
326 | + | let totalPower = { | |
327 | + | let $l = props | |
328 | + | let $s = size($l) | |
329 | + | let $acc0 = 0 | |
330 | + | func $f0_1 ($a,$i) = if (($i >= $s)) | |
331 | + | then $a | |
332 | + | else adder($a, $l[$i]) | |
333 | + | ||
334 | + | func $f0_2 ($a,$i) = if (($i >= $s)) | |
335 | + | then $a | |
336 | + | else throw("List size exceeds 6") | |
337 | + | ||
338 | + | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6) | |
339 | + | } | |
340 | + | let usersPower = if ((userAddrStrOrEmpty == "")) | |
341 | + | then 0 | |
342 | + | else { | |
343 | + | let landsStr = getString(stakingContract, keyStakedLandsByOwner(userAddrStrOrEmpty)) | |
344 | + | let lands = if (isDefined(landsStr)) | |
345 | + | then split_51C(value(landsStr), "_") | |
346 | + | else nil | |
347 | + | func oneLand (acc,landAssetId) = { | |
348 | + | let asset = value(assetInfo(fromBase58String(landAssetId))) | |
349 | + | let landSize = split(asset.description, "_")[recLandSize] | |
350 | + | (acc + numPiecesBySize(landSize)) | |
351 | + | } | |
352 | + | ||
353 | + | let $l = lands | |
354 | + | let $s = size($l) | |
355 | + | let $acc0 = 0 | |
356 | + | func $f1_1 ($a,$i) = if (($i >= $s)) | |
357 | + | then $a | |
358 | + | else oneLand($a, $l[$i]) | |
359 | + | ||
360 | + | func $f1_2 ($a,$i) = if (($i >= $s)) | |
361 | + | then $a | |
362 | + | else throw("List size exceeds 100") | |
363 | + | ||
364 | + | $f1_2($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($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), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20), 21), 22), 23), 24), 25), 26), 27), 28), 29), 30), 31), 32), 33), 34), 35), 36), 37), 38), 39), 40), 41), 42), 43), 44), 45), 46), 47), 48), 49), 50), 51), 52), 53), 54), 55), 56), 57), 58), 59), 60), 61), 62), 63), 64), 65), 66), 67), 68), 69), 70), 71), 72), 73), 74), 75), 76), 77), 78), 79), 80), 81), 82), 83), 84), 85), 86), 87), 88), 89), 90), 91), 92), 93), 94), 95), 96), 97), 98), 99), 100) | |
365 | + | } | |
366 | + | [totalPower, usersPower] | |
367 | + | } | |
368 | + | ||
369 | + | ||
201 | 370 | func getRecipeMaterials (recipe) = { | |
202 | 371 | func addMat (ac,j) = (ac + parseIntValue(recipe[j])) | |
203 | 372 | ||
204 | 373 | let $l = [0, 1, 2, 3, 4, 5] | |
205 | 374 | let $s = size($l) | |
206 | 375 | let $acc0 = 0 | |
207 | 376 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
208 | 377 | then $a | |
209 | 378 | else addMat($a, $l[$i]) | |
210 | 379 | ||
211 | 380 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
212 | 381 | then $a | |
213 | 382 | else throw("List size exceeds 6") | |
214 | 383 | ||
215 | 384 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6) | |
216 | 385 | } | |
217 | 386 | ||
218 | 387 | ||
219 | 388 | let USDTPRIZEPART = 500000 | |
389 | + | ||
390 | + | let wlgIssuedAmountKey = "wlg_issuedAmount" | |
391 | + | ||
392 | + | let idxWlgAmount = 0 | |
393 | + | ||
394 | + | let idxWlgPrice = 1 | |
395 | + | ||
396 | + | let idxWlgFunds = 2 | |
220 | 397 | ||
221 | 398 | func asListIntCompacted (val) = match val { | |
222 | 399 | case valAnyList: List[Any] => | |
223 | 400 | if ((size(valAnyList) != NUMRES)) | |
224 | 401 | then throw(("Array size is " + toString(size(valAnyList)))) | |
225 | 402 | else { | |
226 | 403 | func conv (acc,item) = match item { | |
227 | 404 | case it: Int => | |
228 | 405 | (acc :+ toString(it)) | |
229 | 406 | case _ => | |
230 | 407 | throw("List type is not Int") | |
231 | 408 | } | |
232 | 409 | ||
233 | 410 | let r = { | |
234 | 411 | let $l = valAnyList | |
235 | 412 | let $s = size($l) | |
236 | 413 | let $acc0 = nil | |
237 | 414 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
238 | 415 | then $a | |
239 | 416 | else conv($a, $l[$i]) | |
240 | 417 | ||
241 | 418 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
242 | 419 | then $a | |
243 | 420 | else throw("List size exceeds 6") | |
244 | 421 | ||
245 | 422 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6) | |
246 | 423 | } | |
247 | 424 | makeString(r, "_") | |
248 | 425 | } | |
249 | 426 | case _ => | |
250 | 427 | throw("fail to cast into List") | |
251 | 428 | } | |
252 | 429 | ||
253 | 430 | ||
254 | 431 | func asSplitResult (val) = match val { | |
255 | 432 | case t2: (List[Any], List[Any]) => | |
256 | 433 | $Tuple2(asListIntCompacted(t2._1), asListIntCompacted(t2._2)) | |
257 | 434 | case _ => | |
258 | 435 | throw("fail to cast into (List, List)") | |
259 | 436 | } | |
260 | 437 | ||
261 | 438 | ||
262 | 439 | func walletInternal (userAddressOpt) = { | |
263 | 440 | let addr = addressFromString(userAddressOpt) | |
264 | 441 | let balance = if (isDefined(addr)) | |
265 | 442 | then wavesBalance(value(addr)) | |
266 | 443 | else BalanceDetails(0, 0, 0, 0) | |
267 | 444 | let usdtBalance = if (isDefined(addr)) | |
268 | 445 | then assetBalance(value(addr), usdtAssetId) | |
269 | 446 | else 0 | |
270 | 447 | let customName = valueOrElse(getString(stakingContract, keyAddressToCustomName(userAddressOpt)), userAddressOpt) | |
271 | 448 | let refBy = valueOrElse(getString(stakingContract, keyAddressRefBy(userAddressOpt)), "") | |
272 | 449 | let refs = valueOrElse(getString(stakingContract, keyAddressReferrals(userAddressOpt)), "") | |
273 | 450 | let lastTxId = valueOrElse(getString(stakingContract, keyLastTxIdByUser(userAddressOpt)), "") | |
274 | 451 | [("%s%s__customName__" + customName), ("%s%s__referredBy__" + refBy), ("%s%s__referrals__" + refs), ("%s%s__lastTxId__" + lastTxId), ("%s%s%d__wavesBalance__" + toString(balance.available)), ("%s%s%d__usdtBalance__" + toString(usdtBalance))] | |
275 | 452 | } | |
276 | 453 | ||
277 | 454 | ||
278 | 455 | func applyBonuses (landAssetId,pieces) = { | |
279 | 456 | let infraLevel = valueOrElse(getInteger(stakingContract, keyInfraLevelByAssetId(landAssetId)), 0) | |
280 | 457 | let artPieces = valueOrElse(getInteger(stakingContract, keyLandArtStatusByTypeAndAssetId(ARTPRESALE, landAssetId)), 0) | |
281 | 458 | let add6 = (infraLevel / 6) | |
282 | 459 | let add7 = (infraLevel / 7) | |
283 | 460 | $Tuple3(infraLevel, artPieces, ((DAILYRESBYPIECE + fraction(DAILYRESBYPIECE, ((infraLevel + add6) + (2 * add7)), 5)) + fraction(DAILYRESBYPIECE, artPieces, (pieces * 5)))) | |
284 | 461 | } | |
285 | 462 | ||
286 | 463 | ||
287 | 464 | func getWarehouseTotalVolume (volPrefix) = { | |
288 | 465 | let parts = split(volPrefix, "_") | |
289 | 466 | ((WHMULTIPLIER * (parseIntValue(parts[1]) + 1)) * parseIntValue(parts[0])) | |
290 | 467 | } | |
291 | 468 | ||
292 | 469 | ||
293 | 470 | func getWarehouse (whKey,landIndex,infraLevel) = { | |
294 | 471 | let volPrefix = ((toString(landIndex) + "_") + toString(infraLevel)) | |
295 | 472 | let totS = toString(getWarehouseTotalVolume(volPrefix)) | |
296 | 473 | let whStr = valueOrElse(getString(stakingContract, whKey), ((((volPrefix + ":0_0_0_0_0_0:0_0_0_0_0_0::0_0_") + totS) + "_") + totS)) | |
297 | 474 | split(whStr, ":") | |
298 | 475 | } | |
299 | 476 | ||
300 | 477 | ||
301 | 478 | func duckInfoTuple (duckAssetId) = $Tuple5(valueOrElse(getInteger(stakingContract, keyStakedTimeByAssetId(duckAssetId)), -1), value(assetInfo(fromBase58String(duckAssetId))).name, valueOrElse(getString(stakingContract, keyDuckLocation(duckAssetId)), ""), valueOrElse(getInteger(stakingContract, keyDuckHealth(duckAssetId)), -1), asString(invoke(stakingContract, "getBackpackREADONLY", [duckAssetId], nil))) | |
302 | 479 | ||
303 | 480 | ||
304 | 481 | func duckInfoArray (duckAssetId,owner,duckInf) = { | |
305 | 482 | let customName = valueOrElse(getString(stakingContract, keyDuckAssetIdToCustomName(duckAssetId)), duckInf._2) | |
306 | 483 | [("%s%s__assetId__" + duckAssetId), ("%s%s__owner__" + owner), ("%s%s__customName__" + customName), ("%s%d__stakedTime__" + toString(duckInf._1)), ("%s%s__name__" + duckInf._2), ("%s%s__location__" + duckInf._3), ("%s%d__health__" + toString(duckInf._4)), ("%s%s__backPack__" + duckInf._5)] | |
307 | 484 | } | |
308 | 485 | ||
309 | 486 | ||
310 | 487 | func landInfoArray (landAssetId,owner,stakedTime) = if ((landAssetId == "")) | |
311 | 488 | then throw("landAssetId is required") | |
312 | 489 | else { | |
313 | 490 | let a = value(assetInfo(fromBase58String(landAssetId))) | |
314 | 491 | let d = split(a.description, "_") | |
315 | 492 | let landNum = if ((a.quantity > 0)) | |
316 | 493 | then d[recLandNum] | |
317 | 494 | else ("-" + d[recLandNum]) | |
318 | 495 | let pieces = numPiecesBySize(d[recLandSize]) | |
319 | 496 | let productivity = applyBonuses(landAssetId, pieces) | |
320 | 497 | let deltaTime = (lastBlock.timestamp - stakedTime) | |
321 | 498 | let availRes = if ((stakedTime > 0)) | |
322 | 499 | then fraction(deltaTime, (productivity._3 * pieces), DAYMILLIS) | |
323 | 500 | else 0 | |
324 | 501 | let needMat = fraction(InfraUpgradeCostS, (pieces * (productivity._1 + 1)), SSIZE) | |
325 | 502 | let globalAndLocal = if ((stakedTime > 0)) | |
326 | 503 | then asSplitResult(invoke(stakingContract, "splitByGlobalAndLocalWeightsREADONLY", [needMat, availRes, d[recTerrains]], nil)) | |
327 | 504 | else $Tuple2(asListIntCompacted(invoke(stakingContract, "splitByGlobalWeightsREADONLY", [needMat], nil)), "") | |
328 | 505 | let customName = valueOrElse(getString(stakingContract, keyLandAssetIdToCustomName(landAssetId)), ((d[recContinent] + "-") + d[recLandNum])) | |
329 | 506 | [("%s%s__assetId__" + landAssetId), ("%s%s__owner__" + owner), ("%s%s__customName__" + customName), ("%s%d__stakedTime__" + toString(stakedTime)), ("%s%s__description__" + makeString([landNum, d[recLandSize], d[recTerrains], d[recContinent]], "_")), ("%s%d__infraLevel__" + toString(productivity._1)), ("%s%s__availResByType__" + globalAndLocal._2), ("%s%d__availResTotal__" + toString(availRes)), ("%s%s__needMaterial__" + globalAndLocal._1), makeString(["%s%s", "landArtefacts", ("PRESALE:" + toString(productivity._2))], SEP), ("%s%s__warehouse__" + makeString(getWarehouse(keyWarehouseByLand(landAssetId), (pieces / SSIZE), productivity._1), ":")), ("%s%s__landOrder__" + valueOrElse(getString(economyContract, keyOrderByLand(landAssetId)), "0@0_0@0_0@0_0@0_0@0_0@0:0@0_0@0_0@0_0@0_0@0_0@0:"))] | |
330 | 507 | } | |
331 | 508 | ||
332 | 509 | ||
333 | 510 | func landOrderInfoArray (landAssetId,owner) = if ((landAssetId == "")) | |
334 | 511 | then throw("landAssetId is required") | |
335 | 512 | else { | |
336 | 513 | let a = value(assetInfo(fromBase58String(landAssetId))) | |
337 | 514 | let d = split(a.description, "_") | |
338 | 515 | let pieces = numPiecesBySize(d[recLandSize]) | |
339 | 516 | let productivity = applyBonuses(landAssetId, pieces) | |
340 | 517 | [("%s%s__assetId__" + landAssetId), ("%s%s__owner__" + owner), ("%s%s__warehouse__" + makeString(getWarehouse(keyWarehouseByLand(landAssetId), (pieces / SSIZE), productivity._1), ":")), ("%s%s__landOrder__" + valueOrElse(getString(economyContract, keyOrderByLand(landAssetId)), "0@0_0@0_0@0_0@0_0@0_0@0:0@0_0@0_0@0_0@0_0@0_0@0:"))] | |
341 | 518 | } | |
519 | + | ||
520 | + | ||
521 | + | func getWlgStats () = { | |
522 | + | let issuedAmount = valueOrErrorMessage(getInteger(wlgContract, wlgIssuedAmountKey), "WLGOLD is not issued yet") | |
523 | + | let funds = ((assetBalance(economyContract, usdtAssetId) + assetBalance(restContract, usdtAssetId)) + assetBalance(wlgContract, usdtAssetId)) | |
524 | + | [issuedAmount, fraction(funds, MULT8, issuedAmount), funds] | |
525 | + | } | |
342 | 526 | ||
343 | 527 | ||
344 | 528 | @Callable(i) | |
345 | 529 | func constructorV1 (contracts) = if ((i.caller != this)) | |
346 | 530 | then throw("permissions denied") | |
347 | 531 | else { | |
348 | 532 | func descriptor (acc,ignoredItem) = (acc + "%s") | |
349 | 533 | ||
350 | 534 | let descr = { | |
351 | 535 | let $l = contracts | |
352 | 536 | let $s = size($l) | |
353 | 537 | let $acc0 = "" | |
354 | 538 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
355 | 539 | then $a | |
356 | 540 | else descriptor($a, $l[$i]) | |
357 | 541 | ||
358 | 542 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
359 | 543 | then $a | |
360 | 544 | else throw("List size exceeds 10") | |
361 | 545 | ||
362 | 546 | $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) | |
363 | 547 | } | |
364 | 548 | [StringEntry(keyRestCfg(), makeString(descr :: contracts, SEP)), StringEntry(keyRestAddress(), toString(this))] | |
365 | 549 | } | |
366 | 550 | ||
367 | 551 | ||
368 | 552 | ||
369 | 553 | @Callable(i) | |
370 | 554 | func walletInfoREADONLY (userAddressOpt) = $Tuple2(nil, walletInternal(userAddressOpt)) | |
371 | 555 | ||
372 | 556 | ||
373 | 557 | ||
374 | 558 | @Callable(i) | |
375 | 559 | func duckByOwnerInfoREADONLY (userAddress) = { | |
376 | 560 | let stakedDuck = getString(stakingContract, keyStakedDuckByOwner(userAddress)) | |
377 | 561 | $Tuple2(nil, if (if (isDefined(addressFromString(userAddress))) | |
378 | 562 | then isDefined(stakedDuck) | |
379 | 563 | else false) | |
380 | 564 | then { | |
381 | 565 | let duckAssetId = value(stakedDuck) | |
382 | 566 | duckInfoArray(duckAssetId, userAddress, duckInfoTuple(duckAssetId)) | |
383 | 567 | } | |
384 | 568 | else duckInfoArray("", userAddress, $Tuple5(-1, "", "", -1, ""))) | |
385 | 569 | } | |
386 | 570 | ||
387 | 571 | ||
388 | 572 | ||
389 | 573 | @Callable(i) | |
390 | 574 | func duckByAssetIdInfoREADONLY (duckAssetId) = { | |
391 | 575 | let owner = getString(stakingContract, keyDuckIdToOwner(duckAssetId)) | |
392 | 576 | let duckInf = duckInfoTuple(duckAssetId) | |
393 | 577 | $Tuple2(nil, duckInfoArray(duckAssetId, if (isDefined(owner)) | |
394 | 578 | then value(owner) | |
395 | 579 | else "", duckInfoTuple(duckAssetId))) | |
396 | 580 | } | |
397 | 581 | ||
398 | 582 | ||
399 | 583 | ||
400 | 584 | @Callable(i) | |
401 | 585 | func landByAssetIdInfoREADONLY (landAssetId) = if ((landAssetId == "")) | |
402 | 586 | then throw("landAssetId is required") | |
403 | 587 | else { | |
404 | 588 | let stakedTime = valueOrElse(getInteger(stakingContract, keyStakedTimeByAssetId(landAssetId)), -1) | |
405 | 589 | let owner = if ((stakedTime > 0)) | |
406 | 590 | then value(getString(stakingContract, keyLandAssetIdToOwner(landAssetId))) | |
407 | 591 | else "" | |
408 | 592 | $Tuple2(nil, landInfoArray(landAssetId, owner, stakedTime)) | |
409 | 593 | } | |
410 | 594 | ||
411 | 595 | ||
412 | 596 | ||
413 | 597 | @Callable(i) | |
414 | 598 | func stakedLandsByOwnerInfoREADONLY (landOwnerAddress) = if ((landOwnerAddress == "")) | |
415 | 599 | then throw("landOwnerAddress is required") | |
416 | 600 | else { | |
417 | 601 | let landsStr = getString(stakingContract, keyStakedLandsByOwner(landOwnerAddress)) | |
418 | 602 | let lands = if (isDefined(landsStr)) | |
419 | 603 | then split_51C(value(landsStr), "_") | |
420 | 604 | else nil | |
421 | 605 | func oneLand (acc,landAssetId) = if ((landAssetId == "")) | |
422 | 606 | then throw("landAssetId is required") | |
423 | 607 | else { | |
424 | 608 | let stakedTime = valueOrElse(getInteger(stakingContract, keyStakedTimeByAssetId(landAssetId)), -1) | |
425 | 609 | (acc :+ landInfoArray(landAssetId, landOwnerAddress, stakedTime)) | |
426 | 610 | } | |
427 | 611 | ||
428 | 612 | let r = { | |
429 | 613 | let $l = lands | |
430 | 614 | let $s = size($l) | |
431 | 615 | let $acc0 = nil | |
432 | 616 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
433 | 617 | then $a | |
434 | 618 | else oneLand($a, $l[$i]) | |
435 | 619 | ||
436 | 620 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
437 | 621 | then $a | |
438 | 622 | else throw("List size exceeds 100") | |
439 | 623 | ||
440 | 624 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20), 21), 22), 23), 24), 25), 26), 27), 28), 29), 30), 31), 32), 33), 34), 35), 36), 37), 38), 39), 40), 41), 42), 43), 44), 45), 46), 47), 48), 49), 50), 51), 52), 53), 54), 55), 56), 57), 58), 59), 60), 61), 62), 63), 64), 65), 66), 67), 68), 69), 70), 71), 72), 73), 74), 75), 76), 77), 78), 79), 80), 81), 82), 83), 84), 85), 86), 87), 88), 89), 90), 91), 92), 93), 94), 95), 96), 97), 98), 99), 100) | |
441 | 625 | } | |
442 | 626 | $Tuple2(nil, r) | |
443 | 627 | } | |
444 | 628 | ||
445 | 629 | ||
446 | 630 | ||
447 | 631 | @Callable(i) | |
448 | 632 | func landsByIdsInfoREADONLY (landAssetIds) = { | |
449 | 633 | func oneLand (acc,landAssetId) = if ((landAssetId == "")) | |
450 | 634 | then throw("landAssetId is required") | |
451 | 635 | else { | |
452 | 636 | let stakedTime = valueOrElse(getInteger(stakingContract, keyStakedTimeByAssetId(landAssetId)), -1) | |
453 | 637 | let owner = if ((stakedTime > 0)) | |
454 | 638 | then value(getString(stakingContract, keyLandAssetIdToOwner(landAssetId))) | |
455 | 639 | else "" | |
456 | 640 | (acc :+ landInfoArray(landAssetId, owner, stakedTime)) | |
457 | 641 | } | |
458 | 642 | ||
459 | 643 | let r = { | |
460 | 644 | let $l = landAssetIds | |
461 | 645 | let $s = size($l) | |
462 | 646 | let $acc0 = nil | |
463 | 647 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
464 | 648 | then $a | |
465 | 649 | else oneLand($a, $l[$i]) | |
466 | 650 | ||
467 | 651 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
468 | 652 | then $a | |
469 | 653 | else throw("List size exceeds 100") | |
470 | 654 | ||
471 | 655 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20), 21), 22), 23), 24), 25), 26), 27), 28), 29), 30), 31), 32), 33), 34), 35), 36), 37), 38), 39), 40), 41), 42), 43), 44), 45), 46), 47), 48), 49), 50), 51), 52), 53), 54), 55), 56), 57), 58), 59), 60), 61), 62), 63), 64), 65), 66), 67), 68), 69), 70), 71), 72), 73), 74), 75), 76), 77), 78), 79), 80), 81), 82), 83), 84), 85), 86), 87), 88), 89), 90), 91), 92), 93), 94), 95), 96), 97), 98), 99), 100) | |
472 | 656 | } | |
473 | 657 | $Tuple2(nil, r) | |
474 | 658 | } | |
475 | 659 | ||
476 | 660 | ||
477 | 661 | ||
478 | 662 | @Callable(i) | |
479 | 663 | func warehouseOrderByAssetIdInfoREADONLY (landAssetId) = if ((landAssetId == "")) | |
480 | 664 | then throw("landAssetId is required") | |
481 | 665 | else { | |
482 | 666 | let stakedTime = valueOrElse(getInteger(stakingContract, keyStakedTimeByAssetId(landAssetId)), -1) | |
483 | 667 | let owner = if ((stakedTime > 0)) | |
484 | 668 | then value(getString(stakingContract, keyLandAssetIdToOwner(landAssetId))) | |
485 | 669 | else "" | |
486 | 670 | $Tuple2(nil, landOrderInfoArray(landAssetId, owner)) | |
487 | 671 | } | |
488 | 672 | ||
489 | 673 | ||
490 | 674 | ||
491 | 675 | @Callable(i) | |
492 | 676 | func ordersByLandIdsInfoREADONLY (landAssetIds) = { | |
493 | 677 | func oneLand (acc,landAssetId) = if ((landAssetId == "")) | |
494 | 678 | then throw("landAssetId is required") | |
495 | 679 | else { | |
496 | 680 | let stakedTime = valueOrElse(getInteger(stakingContract, keyStakedTimeByAssetId(landAssetId)), -1) | |
497 | 681 | let owner = if ((stakedTime > 0)) | |
498 | 682 | then value(getString(stakingContract, keyLandAssetIdToOwner(landAssetId))) | |
499 | 683 | else "" | |
500 | 684 | (acc :+ landOrderInfoArray(landAssetId, owner)) | |
501 | 685 | } | |
502 | 686 | ||
503 | 687 | let r = { | |
504 | 688 | let $l = landAssetIds | |
505 | 689 | let $s = size($l) | |
506 | 690 | let $acc0 = nil | |
507 | 691 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
508 | 692 | then $a | |
509 | 693 | else oneLand($a, $l[$i]) | |
510 | 694 | ||
511 | 695 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
512 | 696 | then $a | |
513 | 697 | else throw("List size exceeds 40") | |
514 | 698 | ||
515 | 699 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20), 21), 22), 23), 24), 25), 26), 27), 28), 29), 30), 31), 32), 33), 34), 35), 36), 37), 38), 39), 40) | |
516 | 700 | } | |
517 | 701 | $Tuple2(nil, r) | |
518 | 702 | } | |
519 | 703 | ||
520 | 704 | ||
521 | 705 | ||
522 | 706 | @Callable(i) | |
523 | 707 | func cancelWarehouseOrders (landAssetIds) = if ((i.caller != this)) | |
524 | 708 | then throw("permission denied") | |
525 | 709 | else { | |
526 | 710 | let blocked = getBoolean(stakingContract, keyBlocked()) | |
527 | 711 | if (if (!(isDefined(blocked))) | |
528 | 712 | then true | |
529 | 713 | else (value(blocked) == false)) | |
530 | 714 | then throw("Contracts should be blocked before canceling orders") | |
531 | 715 | else { | |
532 | 716 | func oneLand (a,landAssetId) = if ((landAssetId == "")) | |
533 | 717 | then throw("landAssetId is required") | |
534 | 718 | else { | |
535 | 719 | let c = asBoolean(invoke(economyContract, "setWarehouseOrder", ["0@0_0@0_0@0_0@0_0@0_0@0:0@0_0@0_0@0_0@0_0@0_0@0:", landAssetId], nil)) | |
536 | 720 | if (if (a) | |
537 | 721 | then true | |
538 | 722 | else c) | |
539 | 723 | then !(if (a) | |
540 | 724 | then c | |
541 | 725 | else false) | |
542 | 726 | else false | |
543 | 727 | } | |
544 | 728 | ||
545 | 729 | let r = { | |
546 | 730 | let $l = landAssetIds | |
547 | 731 | let $s = size($l) | |
548 | 732 | let $acc0 = false | |
549 | 733 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
550 | 734 | then $a | |
551 | 735 | else oneLand($a, $l[$i]) | |
552 | 736 | ||
553 | 737 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
554 | 738 | then $a | |
555 | 739 | else throw("List size exceeds 30") | |
556 | 740 | ||
557 | 741 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20), 21), 22), 23), 24), 25), 26), 27), 28), 29), 30) | |
558 | 742 | } | |
559 | 743 | $Tuple2(nil, r) | |
560 | 744 | } | |
561 | 745 | } | |
562 | 746 | ||
563 | 747 | ||
564 | 748 | ||
565 | 749 | @Callable(i) | |
566 | 750 | func fixWarehouseFormats (landAssetIds) = if ((i.caller != this)) | |
567 | 751 | then throw("permission denied") | |
568 | 752 | else { | |
569 | 753 | func oneLand (acc,landAssetId) = if ((landAssetId == "")) | |
570 | 754 | then throw("landAssetId is required") | |
571 | 755 | else (acc + size(asString(invoke(stakingContract, "fixWarehouseFormat", [landAssetId], nil)))) | |
572 | 756 | ||
573 | 757 | let r = { | |
574 | 758 | let $l = landAssetIds | |
575 | 759 | let $s = size($l) | |
576 | 760 | let $acc0 = 0 | |
577 | 761 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
578 | 762 | then $a | |
579 | 763 | else oneLand($a, $l[$i]) | |
580 | 764 | ||
581 | 765 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
582 | 766 | then $a | |
583 | 767 | else throw("List size exceeds 25") | |
584 | 768 | ||
585 | 769 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20), 21), 22), 23), 24), 25) | |
586 | 770 | } | |
587 | 771 | $Tuple2(nil, r) | |
588 | 772 | } | |
589 | 773 | ||
590 | 774 | ||
591 | 775 | ||
592 | 776 | @Callable(i) | |
593 | 777 | func fixStakedPieces (users) = if ((i.caller != this)) | |
594 | 778 | then throw("permission denied") | |
595 | 779 | else { | |
596 | 780 | func oneUser (acc,addr) = if ((addr == "")) | |
597 | 781 | then throw("address is required") | |
598 | 782 | else (acc + asInt(invoke(stakingContract, "fixStakedPieces", [addr], nil))) | |
599 | 783 | ||
600 | 784 | let r = { | |
601 | 785 | let $l = users | |
602 | 786 | let $s = size($l) | |
603 | 787 | let $acc0 = 0 | |
604 | 788 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
605 | 789 | then $a | |
606 | 790 | else oneUser($a, $l[$i]) | |
607 | 791 | ||
608 | 792 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
609 | 793 | then $a | |
610 | 794 | else throw("List size exceeds 16") | |
611 | 795 | ||
612 | 796 | $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($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16) | |
613 | 797 | } | |
614 | 798 | $Tuple2(nil, r) | |
615 | 799 | } | |
616 | 800 | ||
617 | 801 | ||
618 | 802 | ||
619 | 803 | @Callable(i) | |
620 | 804 | func sendUsdtPrize (userAddress) = if ((i.caller != stakingContract)) | |
621 | 805 | then throw("permission denied") | |
622 | 806 | else { | |
623 | 807 | let amt = fraction(assetBalance(this, usdtAssetId), USDTPRIZEPART, MULT6) | |
624 | 808 | $Tuple2([ScriptTransfer(addressFromStringValue(userAddress), amt, usdtAssetId)], amt) | |
625 | 809 | } | |
626 | 810 | ||
627 | 811 | ||
628 | 812 | ||
629 | 813 | @Callable(i) | |
630 | 814 | func getEmergencyServiceDataREADONLY () = { | |
631 | 815 | let existStr = getString(economyContract, keyEsWarehouse()) | |
632 | 816 | let existAmounts = if (isDefined(existStr)) | |
633 | 817 | then split(value(existStr), "_") | |
634 | 818 | else nil | |
635 | 819 | func singleProd (acc,recipeStr) = { | |
636 | 820 | let n = acc._2 | |
637 | 821 | let recipe = split(recipeStr, "_") | |
638 | 822 | let packSize = parseIntValue(recipe[recipeIdxPacksize]) | |
639 | 823 | let maxAmount = if ((n == 0)) | |
640 | 824 | then (ESMAXPACKAGES * packSize) | |
641 | 825 | else 0 | |
642 | 826 | let existAmount = if ((size(existAmounts) > n)) | |
643 | 827 | then parseIntValue(existAmounts[n]) | |
644 | 828 | else 0 | |
645 | 829 | let totalMat = getRecipeMaterials(recipe) | |
646 | 830 | let buyPrice = fraction((totalMat * ESBUYCOEF), RESOURCEPRICEMIN, (10 * packSize)) | |
647 | 831 | let sellPrice = fraction((totalMat * ESSELLCOEF), RESOURCEPRICEMIN, (10 * packSize)) | |
648 | 832 | let y = makeString([toString(maxAmount), toString(existAmount), toString(buyPrice), toString(sellPrice)], "_") | |
649 | 833 | $Tuple2((acc._1 :+ y), (n + 1)) | |
650 | 834 | } | |
651 | 835 | ||
652 | 836 | let s = makeString_2C(( let $l = productionMatrix | |
653 | 837 | let $s = size($l) | |
654 | 838 | let $acc0 = $Tuple2(nil, 0) | |
655 | 839 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
656 | 840 | then $a | |
657 | 841 | else singleProd($a, $l[$i]) | |
658 | 842 | ||
659 | 843 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
660 | 844 | then $a | |
661 | 845 | else throw("List size exceeds 50") | |
662 | 846 | ||
663 | 847 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20), 21), 22), 23), 24), 25), 26), 27), 28), 29), 30), 31), 32), 33), 34), 35), 36), 37), 38), 39), 40), 41), 42), 43), 44), 45), 46), 47), 48), 49), 50))._1, ":") | |
664 | 848 | let result = ("%s%s__emergencyServiceData__" + s) | |
665 | 849 | $Tuple2(nil, result) | |
666 | 850 | } | |
667 | 851 | ||
668 | 852 | ||
853 | + | ||
854 | + | @Callable(i) | |
855 | + | func wlgStatsREADONLY () = { | |
856 | + | let curStats = getWlgStats() | |
857 | + | $Tuple2(nil, [("%s%s%d__wlgAmount__" + toString(curStats[idxWlgAmount])), ("%s%s%d__wlgPrice__" + toString(curStats[idxWlgPrice])), ("%s%s%d__usdtFunds__" + toString(curStats[idxWlgFunds]))]) | |
858 | + | } | |
859 | + | ||
860 | + |
github/deemru/w8io/169f3d6 96.81 ms ◑