tx · XgZu6NETzQapkUN4K1aSBRNJqquh7mfBooixWEDVUC4

3MumkGGztCKAXpWDqxkddofqXSUbqQkvSJy:  -0.01800000 Waves

2023.05.28 15:42 [2597837] smart account 3MumkGGztCKAXpWDqxkddofqXSUbqQkvSJy > SELF 0.00000000 Waves

{ "type": 13, "id": "XgZu6NETzQapkUN4K1aSBRNJqquh7mfBooixWEDVUC4", "fee": 1800000, "feeAssetId": null, "timestamp": 1685277825333, "version": 2, "chainId": 84, "sender": "3MumkGGztCKAXpWDqxkddofqXSUbqQkvSJy", "senderPublicKey": "C3PaRKeL8AUKbwUqdniMQtThgcTh5DYHV1777Hkxy7rp", "proofs": [ "2gMTkV3eDgkVxSH4RDTJNPjWLsNRJmNsy8NpSXiyGzATe6cpsZFEfuJ1g5qyV1NjSCp3MSHUJyV3fE6JdpD4HUu8" ], "script": "base64:BgJACAISBQoDCAgIEgMKAQgSAwoBCBIDCgEIEgMKAQgSAwoBCBIDCgEYEgMKAQgSAwoBGBIDCgEYEgMKARgSAwoBCEwABWNoYWluCQDJAQIJAMoBAggFBHRoaXMFYnl0ZXMAAQABAAt1c2R0QXNzZXRJZAQHJG1hdGNoMAUFY2hhaW4DCQAAAgEBVwUHJG1hdGNoMAEghNp6sggDP07Ru8qO7ouTvMmC3Qtd+geWqNQj+agP/7kDCQAAAgEBVAUHJG1hdGNoMAEgVbHYn3KHgu/l41uNrAWrZd6aQ6EvFrsF8xq3h6XxxRgJAAIBAg1Vbmtub3duIGNoYWluABFJbmZyYVVwZ3JhZGVDb3N0UwQHJG1hdGNoMAUFY2hhaW4DCQAAAgEBVwUHJG1hdGNoMACAyK+gJQMJAAACAQFUBQckbWF0Y2gwAIDC1y8JAAIBAg1Vbmtub3duIGNoYWluAAVNVUxUNgDAhD0ABU1VTFQ4AIDC1y8ACkxBTkRQUkVGSVgCBExBTkQACkRVQ0tQUkVGSVgCBERVQ0sAA1NFUAICX18ACkFSVFBSRVNBTEUCB1BSRVNBTEUAD0RBSUxZU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QDYW10CQBrAwkA8AcCBQR0aGlzBQt1c2R0QXNzZXRJZAUNVVNEVFBSSVpFUEFSVAUFTVVMVDYJAJQKAgkAzAgCCQEOU2NyaXB0VHJhbnNmZXIDCQERQGV4dHJOYXRpdmUoMTA2MikBBQt1c2VyQWRkcmVzcwUDYW10BQt1c2R0QXNzZXRJZAUDbmlsBQNhbXQAIe298g==", "height": 2597837, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 9ejo6Fwvk6UqY5noPizakPwhBV74X8wQy6j3xYDiwqvJ Next: 8XjkMUYB2VhFvU93P5cinz8cfv9jDU6wiaPzq35HqzoU Diff:
OldNewDifferences
2222 }
2323
2424 let MULT6 = 1000000
25+
26+let MULT8 = 100000000
2527
2628 let LANDPREFIX = "LAND"
2729
4951
5052 let USDTPRIZEPART = 500000
5153
54+let WHMULTIPLIER = 10000000000
55+
5256 let recLandNum = 0
5357
5458 let recLandSize = 1
7579 let IdxCfgEconomyDapp = 2
7680
7781 let IdxCfgGovernanceDapp = 3
82+
83+let productPackages = [10, 10, 10, 100, 100, 100, 10, 10, 10, 100, 100, 100, 10, 10, 10]
7884
7985 func getStringOrFail (address,key) = valueOrErrorMessage(getString(address, key), makeString(["mandatory ", toString(address), ".", key, " is not defined"], ""))
8086
264270 }
265271
266272
267-func getWarehouse (whKey,landIndex,infraLevel) = {
273+func getWarehouseTotalVolume (volPrefix) = {
274+ let parts = split(volPrefix, "_")
275+ ((WHMULTIPLIER * (parseIntValue(parts[1]) + 1)) * parseIntValue(parts[0]))
276+ }
277+
278+
279+func getWarehouseOccupiedVol (currentWh) = {
280+ let goods = currentWh[whIdxProd]
281+ func sumResMat (acc,item) = (acc + parseIntValue(item))
282+
283+ func sumProd (acc,item) = {
284+ let idx = acc._1
285+ let pkgSize = productPackages[idx]
286+ let pkgs = (((parseIntValue(item) + pkgSize) - 1) / pkgSize)
287+ $Tuple2((idx + 1), (acc._2 + (pkgs * MULT8)))
288+ }
289+
290+ let whResVol = {
291+ let $l = split(currentWh[whIdxRes], "_")
292+ let $s = size($l)
293+ let $acc0 = 0
294+ func $f0_1 ($a,$i) = if (($i >= $s))
295+ then $a
296+ else sumResMat($a, $l[$i])
297+
298+ func $f0_2 ($a,$i) = if (($i >= $s))
299+ then $a
300+ else throw("List size exceeds 6")
301+
302+ $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6)
303+ }
304+ let whMatVol = {
305+ let $l = split(currentWh[whIdxMat], "_")
306+ let $s = size($l)
307+ let $acc0 = 0
308+ func $f1_1 ($a,$i) = if (($i >= $s))
309+ then $a
310+ else sumResMat($a, $l[$i])
311+
312+ func $f1_2 ($a,$i) = if (($i >= $s))
313+ then $a
314+ else throw("List size exceeds 6")
315+
316+ $f1_2($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($acc0, 0), 1), 2), 3), 4), 5), 6)
317+ }
318+ let whGoodsVol = if ((goods == ""))
319+ then 0
320+ else ( let $l = split_4C(goods, "_")
321+ let $s = size($l)
322+ let $acc0 = $Tuple2(0, 0)
323+ func $f2_1 ($a,$i) = if (($i >= $s))
324+ then $a
325+ else sumProd($a, $l[$i])
326+
327+ func $f2_2 ($a,$i) = if (($i >= $s))
328+ then $a
329+ else throw("List size exceeds 50")
330+
331+ $f2_2($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_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))._2
332+ ((whResVol + whMatVol) + whGoodsVol)
333+ }
334+
335+
336+func getWarehouseExt (whKey,landIndex,infraLevel) = {
268337 let volPrefix = ((toString(landIndex) + "_") + toString(infraLevel))
269- let p = split(valueOrElse(getString(stakingContract, whKey), (volPrefix + ":0_0_0_0_0_0:0_0_0_0_0_0::0")), ":")
270-[p[whIdxVol], if ((size(split(p[whIdxRes], "_")) == NUMRES))
271- then p[whIdxRes]
272- else "0_0_0_0_0_0", if ((size(split(p[whIdxMat], "_")) == NUMRES))
273- then p[whIdxMat]
274- else "0_0_0_0_0_0", p[whIdxProd], if ((5 > size(p)))
275- then "0"
276- else p[whIdxLockedVol]]
338+ let whTotal = getWarehouseTotalVolume(volPrefix)
339+ let whStr = valueOrElse(getString(stakingContract, whKey), (volPrefix + ":0_0_0_0_0_0:0_0_0_0_0_0::0"))
340+ let wh = split(whStr, ":")
341+ let whLocked = if ((5 > size(wh)))
342+ then 0
343+ else parseIntValue(wh[whIdxLockedVol])
344+ let whOccupied = getWarehouseOccupiedVol(wh)
345+[wh[whIdxVol], if ((size(split(wh[whIdxRes], "_")) == NUMRES))
346+ then wh[whIdxRes]
347+ else "0_0_0_0_0_0", if ((size(split(wh[whIdxMat], "_")) == NUMRES))
348+ then wh[whIdxMat]
349+ else "0_0_0_0_0_0", wh[whIdxProd], makeString([toString(whLocked), toString(whOccupied), toString(((whTotal - whLocked) - whOccupied)), toString(whTotal)], "_")]
277350 }
278351
279352
305378 then asSplitResult(invoke(stakingContract, "splitByGlobalAndLocalWeightsREADONLY", [needMat, availRes, d[recTerrains]], nil))
306379 else $Tuple2(asListIntCompacted(invoke(stakingContract, "splitByGlobalWeightsREADONLY", [needMat], nil)), "")
307380 let customName = valueOrElse(getString(stakingContract, keyLandAssetIdToCustomName(landAssetId)), ((d[recContinent] + "-") + d[recLandNum]))
308-[("%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:"))]
381+[("%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(getWarehouseExt(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:"))]
309382 }
310383
311384
316389 let d = split(a.description, "_")
317390 let pieces = numPiecesBySize(d[recLandSize])
318391 let productivity = applyBonuses(landAssetId, pieces)
319-[("%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:"))]
392+[("%s%s__assetId__" + landAssetId), ("%s%s__owner__" + owner), ("%s%s__warehouse__" + makeString(getWarehouseExt(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:"))]
320393 }
321394
322395
396469
397470 func $f0_2 ($a,$i) = if (($i >= $s))
398471 then $a
399- else throw("List size exceeds 100")
472+ else throw("List size exceeds 40")
400473
401- $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)
474+ $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)
402475 }
403476 $Tuple2(nil, r)
404477 }
427500
428501 func $f0_2 ($a,$i) = if (($i >= $s))
429502 then $a
430- else throw("List size exceeds 100")
503+ else throw("List size exceeds 40")
431504
432- $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)
505+ $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)
433506 }
434507 $Tuple2(nil, r)
435508 }
471544
472545 func $f0_2 ($a,$i) = if (($i >= $s))
473546 then $a
474- else throw("List size exceeds 100")
547+ else throw("List size exceeds 40")
475548
476- $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)
549+ $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)
477550 }
478551 $Tuple2(nil, r)
479552 }
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let chain = take(drop(this.bytes, 1), 1)
55
66 let usdtAssetId = match chain {
77 case _ =>
88 if ((base58'2W' == $match0))
99 then base58'9wc3LXNA4TEBsXyKtoLE9mrbDD7WMHXvXrCjZvabLAsi'
1010 else if ((base58'2T' == $match0))
1111 then base58'6mWwf9mZBjVgkC54idpyaZLQfAosD914wT8fGf2iiY63'
1212 else throw("Unknown chain")
1313 }
1414
1515 let InfraUpgradeCostS = match chain {
1616 case _ =>
1717 if ((base58'2W' == $match0))
1818 then 10000000000
1919 else if ((base58'2T' == $match0))
2020 then 100000000
2121 else throw("Unknown chain")
2222 }
2323
2424 let MULT6 = 1000000
25+
26+let MULT8 = 100000000
2527
2628 let LANDPREFIX = "LAND"
2729
2830 let DUCKPREFIX = "DUCK"
2931
3032 let SEP = "__"
3133
3234 let ARTPRESALE = "PRESALE"
3335
3436 let DAILYRESBYPIECE = 3456000
3537
3638 let DAYMILLIS = 86400000
3739
3840 let NUMRES = 6
3941
4042 let SSIZE = 25
4143
4244 let MSIZE = 100
4345
4446 let LSIZE = 225
4547
4648 let XLSIZE = 400
4749
4850 let XXLSIZE = 625
4951
5052 let USDTPRIZEPART = 500000
5153
54+let WHMULTIPLIER = 10000000000
55+
5256 let recLandNum = 0
5357
5458 let recLandSize = 1
5559
5660 let recTerrains = 2
5761
5862 let recContinent = 3
5963
6064 let whIdxVol = 0
6165
6266 let whIdxRes = 1
6367
6468 let whIdxMat = 2
6569
6670 let whIdxProd = 3
6771
6872 let whIdxLockedVol = 4
6973
7074 func keyRestCfg () = "%s__restConfig"
7175
7276
7377 let IdxCfgStakingDapp = 1
7478
7579 let IdxCfgEconomyDapp = 2
7680
7781 let IdxCfgGovernanceDapp = 3
82+
83+let productPackages = [10, 10, 10, 100, 100, 100, 10, 10, 10, 100, 100, 100, 10, 10, 10]
7884
7985 func getStringOrFail (address,key) = valueOrErrorMessage(getString(address, key), makeString(["mandatory ", toString(address), ".", key, " is not defined"], ""))
8086
8187
8288 func readRestCfgOrFail () = split_4C(getStringOrFail(this, keyRestCfg()), SEP)
8389
8490
8591 func getContractAddressOrFail (restCfg,idx) = valueOrErrorMessage(addressFromString(restCfg[idx]), ("Rest cfg doesn't contain address at index " + toString(idx)))
8692
8793
8894 let restCfg = readRestCfgOrFail()
8995
9096 let stakingContract = getContractAddressOrFail(restCfg, IdxCfgStakingDapp)
9197
9298 let economyContract = getContractAddressOrFail(restCfg, IdxCfgEconomyDapp)
9399
94100 let governanceContract = getContractAddressOrFail(restCfg, IdxCfgEconomyDapp)
95101
96102 func keyBlocked () = "contractsBlocked"
97103
98104
99105 func keyDuckIdToOwner (assetId) = ("duckOwner_" + assetId)
100106
101107
102108 func keyStakedTimeByAssetId (assetId) = ("stakedTime_" + assetId)
103109
104110
105111 func keyStakedDuckByOwner (ownerAddr) = ("stakedDuckByOwner_" + ownerAddr)
106112
107113
108114 func keyStakedTimeByTypeAssetIdAndOwner (nftType,assetId,ownerAddr) = ((((("stakedTimeByTypeAssetIdAndOwner_" + nftType) + "_") + assetId) + "_") + ownerAddr)
109115
110116
111117 func keyBackpackByDuck (duckAssetId) = ("backPack_" + duckAssetId)
112118
113119
114120 func keyWarehouseByLand (landAssetId) = ("wareHouse_" + landAssetId)
115121
116122
117123 func keyDuckLocation (duckAssetId) = ("duckLocation_" + duckAssetId)
118124
119125
120126 func keyDuckHealth (duckAssetId) = ("duckHealth_" + duckAssetId)
121127
122128
123129 func keyLandAssetIdToOwner (assetId) = ("nftOwner_" + assetId)
124130
125131
126132 func keyLandAssetIdToCustomName (assetId) = ("landCustomNameByAssetId_" + assetId)
127133
128134
129135 func keyDuckAssetIdToCustomName (assetId) = ("duckCustomNameByAssetId_" + assetId)
130136
131137
132138 func keyAddressToCustomName (addr) = ("accountCustomNameByAddr_" + addr)
133139
134140
135141 func keyAddressRefBy (addr) = ("accRefBy_" + addr)
136142
137143
138144 func keyAddressReferrals (addr) = ("accReferrals_" + addr)
139145
140146
141147 func keyInfraLevelByAssetId (assetId) = ("infraLevel_" + assetId)
142148
143149
144150 func keyLandArtStatusByTypeAndAssetId (type,assetId) = makeString(["landArtStatus", type, assetId], "_")
145151
146152
147153 func keyPresaleArtActivatedByAssetId (assetId) = ("presaleArtActivated_" + assetId)
148154
149155
150156 func keyStakedLandsByOwner (ownerAddr) = ("stakedLandsByOwner_" + ownerAddr)
151157
152158
153159 func keyLastTxIdByUser (addr) = ("lastTxIdByUser_" + addr)
154160
155161
156162 func keyOrderByLand (landAssetId) = ("landOrder_" + landAssetId)
157163
158164
159165 func asString (v) = match v {
160166 case s: String =>
161167 s
162168 case _ =>
163169 throw("fail to cast into String")
164170 }
165171
166172
167173 func asInt (v) = match v {
168174 case n: Int =>
169175 n
170176 case _ =>
171177 throw("fail to cast into Int")
172178 }
173179
174180
175181 func asBoolean (v) = match v {
176182 case s: Boolean =>
177183 s
178184 case _ =>
179185 throw("fail to cast into Boolean")
180186 }
181187
182188
183189 func asListIntCompacted (val) = match val {
184190 case valAnyList: List[Any] =>
185191 if ((size(valAnyList) != NUMRES))
186192 then throw(("Array size is " + toString(size(valAnyList))))
187193 else {
188194 func conv (acc,item) = match item {
189195 case it: Int =>
190196 (acc :+ toString(it))
191197 case _ =>
192198 throw("List type is not Int")
193199 }
194200
195201 let r = {
196202 let $l = valAnyList
197203 let $s = size($l)
198204 let $acc0 = nil
199205 func $f0_1 ($a,$i) = if (($i >= $s))
200206 then $a
201207 else conv($a, $l[$i])
202208
203209 func $f0_2 ($a,$i) = if (($i >= $s))
204210 then $a
205211 else throw("List size exceeds 6")
206212
207213 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6)
208214 }
209215 makeString(r, "_")
210216 }
211217 case _ =>
212218 throw("fail to cast into List")
213219 }
214220
215221
216222 func asSplitResult (val) = match val {
217223 case t2: (List[Any], List[Any]) =>
218224 $Tuple2(asListIntCompacted(t2._1), asListIntCompacted(t2._2))
219225 case _ =>
220226 throw("fail to cast into (List, List)")
221227 }
222228
223229
224230 func walletInternal (userAddressOpt) = {
225231 let addr = addressFromString(userAddressOpt)
226232 let balance = if (isDefined(addr))
227233 then wavesBalance(value(addr))
228234 else BalanceDetails(0, 0, 0, 0)
229235 let usdtBalance = if (isDefined(addr))
230236 then assetBalance(value(addr), usdtAssetId)
231237 else 0
232238 let customName = valueOrElse(getString(stakingContract, keyAddressToCustomName(userAddressOpt)), userAddressOpt)
233239 let refBy = valueOrElse(getString(stakingContract, keyAddressRefBy(userAddressOpt)), "")
234240 let refs = valueOrElse(getString(stakingContract, keyAddressReferrals(userAddressOpt)), "")
235241 let lastTxId = valueOrElse(getString(stakingContract, keyLastTxIdByUser(userAddressOpt)), "")
236242 [("%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))]
237243 }
238244
239245
240246 func applyBonuses (landAssetId,pieces) = {
241247 let infraLevel = valueOrElse(getInteger(stakingContract, keyInfraLevelByAssetId(landAssetId)), 0)
242248 let artPieces = valueOrElse(getInteger(stakingContract, keyLandArtStatusByTypeAndAssetId(ARTPRESALE, landAssetId)), if (valueOrElse(getBoolean(stakingContract, keyPresaleArtActivatedByAssetId(landAssetId)), false))
243249 then pieces
244250 else 0)
245251 let add6 = (infraLevel / 6)
246252 let add7 = (infraLevel / 7)
247253 $Tuple3(infraLevel, artPieces, ((DAILYRESBYPIECE + fraction(DAILYRESBYPIECE, ((infraLevel + add6) + (2 * add7)), 5)) + fraction(DAILYRESBYPIECE, artPieces, (pieces * 5))))
248254 }
249255
250256
251257 func numPiecesBySize (landSize) = match landSize {
252258 case _ =>
253259 if (("S" == $match0))
254260 then SSIZE
255261 else if (("M" == $match0))
256262 then MSIZE
257263 else if (("L" == $match0))
258264 then LSIZE
259265 else if (("XL" == $match0))
260266 then XLSIZE
261267 else if (("XXL" == $match0))
262268 then XXLSIZE
263269 else throw("Unknown land size")
264270 }
265271
266272
267-func getWarehouse (whKey,landIndex,infraLevel) = {
273+func getWarehouseTotalVolume (volPrefix) = {
274+ let parts = split(volPrefix, "_")
275+ ((WHMULTIPLIER * (parseIntValue(parts[1]) + 1)) * parseIntValue(parts[0]))
276+ }
277+
278+
279+func getWarehouseOccupiedVol (currentWh) = {
280+ let goods = currentWh[whIdxProd]
281+ func sumResMat (acc,item) = (acc + parseIntValue(item))
282+
283+ func sumProd (acc,item) = {
284+ let idx = acc._1
285+ let pkgSize = productPackages[idx]
286+ let pkgs = (((parseIntValue(item) + pkgSize) - 1) / pkgSize)
287+ $Tuple2((idx + 1), (acc._2 + (pkgs * MULT8)))
288+ }
289+
290+ let whResVol = {
291+ let $l = split(currentWh[whIdxRes], "_")
292+ let $s = size($l)
293+ let $acc0 = 0
294+ func $f0_1 ($a,$i) = if (($i >= $s))
295+ then $a
296+ else sumResMat($a, $l[$i])
297+
298+ func $f0_2 ($a,$i) = if (($i >= $s))
299+ then $a
300+ else throw("List size exceeds 6")
301+
302+ $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6)
303+ }
304+ let whMatVol = {
305+ let $l = split(currentWh[whIdxMat], "_")
306+ let $s = size($l)
307+ let $acc0 = 0
308+ func $f1_1 ($a,$i) = if (($i >= $s))
309+ then $a
310+ else sumResMat($a, $l[$i])
311+
312+ func $f1_2 ($a,$i) = if (($i >= $s))
313+ then $a
314+ else throw("List size exceeds 6")
315+
316+ $f1_2($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($acc0, 0), 1), 2), 3), 4), 5), 6)
317+ }
318+ let whGoodsVol = if ((goods == ""))
319+ then 0
320+ else ( let $l = split_4C(goods, "_")
321+ let $s = size($l)
322+ let $acc0 = $Tuple2(0, 0)
323+ func $f2_1 ($a,$i) = if (($i >= $s))
324+ then $a
325+ else sumProd($a, $l[$i])
326+
327+ func $f2_2 ($a,$i) = if (($i >= $s))
328+ then $a
329+ else throw("List size exceeds 50")
330+
331+ $f2_2($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_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))._2
332+ ((whResVol + whMatVol) + whGoodsVol)
333+ }
334+
335+
336+func getWarehouseExt (whKey,landIndex,infraLevel) = {
268337 let volPrefix = ((toString(landIndex) + "_") + toString(infraLevel))
269- let p = split(valueOrElse(getString(stakingContract, whKey), (volPrefix + ":0_0_0_0_0_0:0_0_0_0_0_0::0")), ":")
270-[p[whIdxVol], if ((size(split(p[whIdxRes], "_")) == NUMRES))
271- then p[whIdxRes]
272- else "0_0_0_0_0_0", if ((size(split(p[whIdxMat], "_")) == NUMRES))
273- then p[whIdxMat]
274- else "0_0_0_0_0_0", p[whIdxProd], if ((5 > size(p)))
275- then "0"
276- else p[whIdxLockedVol]]
338+ let whTotal = getWarehouseTotalVolume(volPrefix)
339+ let whStr = valueOrElse(getString(stakingContract, whKey), (volPrefix + ":0_0_0_0_0_0:0_0_0_0_0_0::0"))
340+ let wh = split(whStr, ":")
341+ let whLocked = if ((5 > size(wh)))
342+ then 0
343+ else parseIntValue(wh[whIdxLockedVol])
344+ let whOccupied = getWarehouseOccupiedVol(wh)
345+[wh[whIdxVol], if ((size(split(wh[whIdxRes], "_")) == NUMRES))
346+ then wh[whIdxRes]
347+ else "0_0_0_0_0_0", if ((size(split(wh[whIdxMat], "_")) == NUMRES))
348+ then wh[whIdxMat]
349+ else "0_0_0_0_0_0", wh[whIdxProd], makeString([toString(whLocked), toString(whOccupied), toString(((whTotal - whLocked) - whOccupied)), toString(whTotal)], "_")]
277350 }
278351
279352
280353 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)))
281354
282355
283356 func duckInfoArray (duckAssetId,owner,duckInf) = {
284357 let customName = valueOrElse(getString(stakingContract, keyDuckAssetIdToCustomName(duckAssetId)), duckInf._2)
285358 [("%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)]
286359 }
287360
288361
289362 func landInfoArray (landAssetId,owner,stakedTime) = if ((landAssetId == ""))
290363 then throw("landAssetId is required")
291364 else {
292365 let a = value(assetInfo(fromBase58String(landAssetId)))
293366 let d = split(a.description, "_")
294367 let landNum = if ((a.quantity > 0))
295368 then d[recLandNum]
296369 else ("-" + d[recLandNum])
297370 let pieces = numPiecesBySize(d[recLandSize])
298371 let productivity = applyBonuses(landAssetId, pieces)
299372 let deltaTime = (lastBlock.timestamp - stakedTime)
300373 let availRes = if ((stakedTime > 0))
301374 then fraction(deltaTime, (productivity._3 * pieces), DAYMILLIS)
302375 else 0
303376 let needMat = fraction(InfraUpgradeCostS, (pieces * (productivity._1 + 1)), SSIZE)
304377 let globalAndLocal = if ((stakedTime > 0))
305378 then asSplitResult(invoke(stakingContract, "splitByGlobalAndLocalWeightsREADONLY", [needMat, availRes, d[recTerrains]], nil))
306379 else $Tuple2(asListIntCompacted(invoke(stakingContract, "splitByGlobalWeightsREADONLY", [needMat], nil)), "")
307380 let customName = valueOrElse(getString(stakingContract, keyLandAssetIdToCustomName(landAssetId)), ((d[recContinent] + "-") + d[recLandNum]))
308-[("%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:"))]
381+[("%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(getWarehouseExt(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:"))]
309382 }
310383
311384
312385 func landOrderInfoArray (landAssetId,owner) = if ((landAssetId == ""))
313386 then throw("landAssetId is required")
314387 else {
315388 let a = value(assetInfo(fromBase58String(landAssetId)))
316389 let d = split(a.description, "_")
317390 let pieces = numPiecesBySize(d[recLandSize])
318391 let productivity = applyBonuses(landAssetId, pieces)
319-[("%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:"))]
392+[("%s%s__assetId__" + landAssetId), ("%s%s__owner__" + owner), ("%s%s__warehouse__" + makeString(getWarehouseExt(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:"))]
320393 }
321394
322395
323396 @Callable(i)
324397 func constructorV1 (stakingContract,economyContract,governanceContract) = if ((i.caller != this))
325398 then throw("permissions denied")
326399 else [StringEntry(keyRestCfg(), makeString(["%s%s%s", stakingContract, economyContract, governanceContract], SEP))]
327400
328401
329402
330403 @Callable(i)
331404 func walletInfoREADONLY (userAddressOpt) = $Tuple2(nil, walletInternal(userAddressOpt))
332405
333406
334407
335408 @Callable(i)
336409 func duckByOwnerInfoREADONLY (userAddress) = {
337410 let stakedDuck = getString(stakingContract, keyStakedDuckByOwner(userAddress))
338411 $Tuple2(nil, if (if (isDefined(addressFromString(userAddress)))
339412 then isDefined(stakedDuck)
340413 else false)
341414 then {
342415 let duckAssetId = value(stakedDuck)
343416 duckInfoArray(duckAssetId, userAddress, duckInfoTuple(duckAssetId))
344417 }
345418 else duckInfoArray("", userAddress, $Tuple5(-1, "", "", -1, "")))
346419 }
347420
348421
349422
350423 @Callable(i)
351424 func duckByAssetIdInfoREADONLY (duckAssetId) = {
352425 let owner = getString(stakingContract, keyDuckIdToOwner(duckAssetId))
353426 let duckInf = duckInfoTuple(duckAssetId)
354427 $Tuple2(nil, duckInfoArray(duckAssetId, if (isDefined(owner))
355428 then value(owner)
356429 else "", duckInfoTuple(duckAssetId)))
357430 }
358431
359432
360433
361434 @Callable(i)
362435 func landByAssetIdInfoREADONLY (landAssetId) = if ((landAssetId == ""))
363436 then throw("landAssetId is required")
364437 else {
365438 let stakedTime = valueOrElse(getInteger(stakingContract, keyStakedTimeByAssetId(landAssetId)), -1)
366439 let owner = if ((stakedTime > 0))
367440 then value(getString(stakingContract, keyLandAssetIdToOwner(landAssetId)))
368441 else ""
369442 $Tuple2(nil, landInfoArray(landAssetId, owner, stakedTime))
370443 }
371444
372445
373446
374447 @Callable(i)
375448 func stakedLandsByOwnerInfoREADONLY (landOwnerAddress) = if ((landOwnerAddress == ""))
376449 then throw("landOwnerAddress is required")
377450 else {
378451 let landsStr = getString(stakingContract, keyStakedLandsByOwner(landOwnerAddress))
379452 let lands = if (isDefined(landsStr))
380453 then split_51C(value(landsStr), "_")
381454 else nil
382455 func oneLand (acc,landAssetId) = if ((landAssetId == ""))
383456 then throw("landAssetId is required")
384457 else {
385458 let stakedTime = valueOrElse(getInteger(stakingContract, keyStakedTimeByAssetId(landAssetId)), -1)
386459 (acc :+ landInfoArray(landAssetId, landOwnerAddress, stakedTime))
387460 }
388461
389462 let r = {
390463 let $l = lands
391464 let $s = size($l)
392465 let $acc0 = nil
393466 func $f0_1 ($a,$i) = if (($i >= $s))
394467 then $a
395468 else oneLand($a, $l[$i])
396469
397470 func $f0_2 ($a,$i) = if (($i >= $s))
398471 then $a
399- else throw("List size exceeds 100")
472+ else throw("List size exceeds 40")
400473
401- $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)
474+ $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)
402475 }
403476 $Tuple2(nil, r)
404477 }
405478
406479
407480
408481 @Callable(i)
409482 func landsByIdsInfoREADONLY (landAssetIds) = {
410483 func oneLand (acc,landAssetId) = if ((landAssetId == ""))
411484 then throw("landAssetId is required")
412485 else {
413486 let stakedTime = valueOrElse(getInteger(stakingContract, keyStakedTimeByAssetId(landAssetId)), -1)
414487 let owner = if ((stakedTime > 0))
415488 then value(getString(stakingContract, keyLandAssetIdToOwner(landAssetId)))
416489 else ""
417490 (acc :+ landInfoArray(landAssetId, owner, stakedTime))
418491 }
419492
420493 let r = {
421494 let $l = landAssetIds
422495 let $s = size($l)
423496 let $acc0 = nil
424497 func $f0_1 ($a,$i) = if (($i >= $s))
425498 then $a
426499 else oneLand($a, $l[$i])
427500
428501 func $f0_2 ($a,$i) = if (($i >= $s))
429502 then $a
430- else throw("List size exceeds 100")
503+ else throw("List size exceeds 40")
431504
432- $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)
505+ $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)
433506 }
434507 $Tuple2(nil, r)
435508 }
436509
437510
438511
439512 @Callable(i)
440513 func warehouseOrderByAssetIdInfoREADONLY (landAssetId) = if ((landAssetId == ""))
441514 then throw("landAssetId is required")
442515 else {
443516 let stakedTime = valueOrElse(getInteger(stakingContract, keyStakedTimeByAssetId(landAssetId)), -1)
444517 let owner = if ((stakedTime > 0))
445518 then value(getString(stakingContract, keyLandAssetIdToOwner(landAssetId)))
446519 else ""
447520 $Tuple2(nil, landOrderInfoArray(landAssetId, owner))
448521 }
449522
450523
451524
452525 @Callable(i)
453526 func ordersByLandIdsInfoREADONLY (landAssetIds) = {
454527 func oneLand (acc,landAssetId) = if ((landAssetId == ""))
455528 then throw("landAssetId is required")
456529 else {
457530 let stakedTime = valueOrElse(getInteger(stakingContract, keyStakedTimeByAssetId(landAssetId)), -1)
458531 let owner = if ((stakedTime > 0))
459532 then value(getString(stakingContract, keyLandAssetIdToOwner(landAssetId)))
460533 else ""
461534 (acc :+ landOrderInfoArray(landAssetId, owner))
462535 }
463536
464537 let r = {
465538 let $l = landAssetIds
466539 let $s = size($l)
467540 let $acc0 = nil
468541 func $f0_1 ($a,$i) = if (($i >= $s))
469542 then $a
470543 else oneLand($a, $l[$i])
471544
472545 func $f0_2 ($a,$i) = if (($i >= $s))
473546 then $a
474- else throw("List size exceeds 100")
547+ else throw("List size exceeds 40")
475548
476- $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)
549+ $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)
477550 }
478551 $Tuple2(nil, r)
479552 }
480553
481554
482555
483556 @Callable(i)
484557 func cancelWarehouseOrders (landAssetIds) = if ((i.caller != this))
485558 then throw("permission denied")
486559 else {
487560 let blocked = getBoolean(stakingContract, keyBlocked())
488561 if (if (!(isDefined(blocked)))
489562 then true
490563 else (value(blocked) == false))
491564 then throw("Contracts should be blocked before canceling orders")
492565 else {
493566 func oneLand (a,landAssetId) = if ((landAssetId == ""))
494567 then throw("landAssetId is required")
495568 else {
496569 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))
497570 if (if (a)
498571 then true
499572 else c)
500573 then !(if (a)
501574 then c
502575 else false)
503576 else false
504577 }
505578
506579 let r = {
507580 let $l = landAssetIds
508581 let $s = size($l)
509582 let $acc0 = false
510583 func $f0_1 ($a,$i) = if (($i >= $s))
511584 then $a
512585 else oneLand($a, $l[$i])
513586
514587 func $f0_2 ($a,$i) = if (($i >= $s))
515588 then $a
516589 else throw("List size exceeds 30")
517590
518591 $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)
519592 }
520593 $Tuple2(nil, r)
521594 }
522595 }
523596
524597
525598
526599 @Callable(i)
527600 func replaceBooleanArtifacts (landAssetIds) = if ((i.caller != this))
528601 then throw("permission denied")
529602 else {
530603 func oneLand (acc,landAssetId) = if ((landAssetId == ""))
531604 then throw("landAssetId is required")
532605 else if (isDefined(getBoolean(stakingContract, keyPresaleArtActivatedByAssetId(landAssetId))))
533606 then (acc + asInt(invoke(stakingContract, "replaceBooleanArtifact", [landAssetId], nil)))
534607 else acc
535608
536609 let r = {
537610 let $l = landAssetIds
538611 let $s = size($l)
539612 let $acc0 = 0
540613 func $f0_1 ($a,$i) = if (($i >= $s))
541614 then $a
542615 else oneLand($a, $l[$i])
543616
544617 func $f0_2 ($a,$i) = if (($i >= $s))
545618 then $a
546619 else throw("List size exceeds 25")
547620
548621 $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)
549622 }
550623 $Tuple2(nil, r)
551624 }
552625
553626
554627
555628 @Callable(i)
556629 func sendUsdtPrize (userAddress) = if ((i.caller != stakingContract))
557630 then throw("permission denied")
558631 else {
559632 let amt = fraction(assetBalance(this, usdtAssetId), USDTPRIZEPART, MULT6)
560633 $Tuple2([ScriptTransfer(addressFromStringValue(userAddress), amt, usdtAssetId)], amt)
561634 }
562635
563636

github/deemru/w8io/026f985 
105.28 ms