tx · yxPxYAHG7h93UE5ZkToYGHvWfp98aqYk4x4zVAqjBDi 3N8y4wxX3JC4TdrCJBXX16SjWf6X256hrep: -0.03200000 Waves 2023.05.30 00:48 [2599824] smart account 3N8y4wxX3JC4TdrCJBXX16SjWf6X256hrep > SELF 0.00000000 Waves
{ "type": 13, "id": "yxPxYAHG7h93UE5ZkToYGHvWfp98aqYk4x4zVAqjBDi", "fee": 3200000, "feeAssetId": null, "timestamp": 1685396997046, "version": 2, "chainId": 84, "sender": "3N8y4wxX3JC4TdrCJBXX16SjWf6X256hrep", "senderPublicKey": "7v5L7QkXxfkirALdyqmox38QCsa9jtfAtgUfHTh34eWq", "proofs": [ "3V2RydrXFrMsKBbBGixV9gAnbgMQW7em1ys2Haojt34rRb6pnd3ThTEqoFDbknLfPBExZ3YGDFqthCYdSXum5oYm" ], "script": "base64:BgIrCAISAwoBCBIECgIRERIECgIRERIDCgEREgQKAgEBEgQKAggIEgUKAwgICFoAA1NFUAICX18ABU1VTFQ2AMCEPQAFTVVMVDcAgK3iBAAFTVVMVDgAgMLXLwAGTVVMVDEwAIDIr6AlAAVjaGFpbgkAyQECCQDKAQIIBQR0aGlzBWJ5dGVzAAEAAQALdXNkdEFzc2V0SWQEByRtYXRjaDAFBWNoYWluAwkAAAIBAVcFByRtYXRjaDABIITaerIIAz9O0bvKju6Lk7zJgt0LXfoHlqjUI/moD/+5AwkAAAIBAVQFByRtYXRjaDABIFWx2J9yh4Lv5eNbjawFq2XemkOhLxa7BfMat4el8cUYCQACAQINVW5rbm93biBjaGFpbgAVZGVmYXVsdFJlc3RBZGRyZXNzU3RyBAckbWF0Y2gwBQVjaGFpbgMJAAACAQFXBQckbWF0Y2gwAiMzUFFDdXZGYnZoNExrUFVucm5VMXozam5iQTFwOW0zV05odgMJAAACAQFUBQckbWF0Y2gwAiMzTXVta0dHenRDS0FYcFdEcXhrZGRvZnFYU1VicVFrdlNKeQkAAgECDVVua25vd24gY2hhaW4BD2dldFN0cmluZ09yRmFp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ZHRBc3NldElkCQEOU2NyaXB0VHJhbnNmZXIDBQxyZXN0Q29udHJhY3QFC3VzZEJwMldoRmVlBQt1c2R0QXNzZXRJZAMJAQIhPQIJAJADAQgFAWkIcGF5bWVudHMAAAkAAgECEk5vIHBheW1lbnRzIG5lZWRlZAUIYWN0aW9uczEJAAIBAiRTdHJpY3QgdmFsdWUgaXMgbm90IGVxdWFsIHRvIGl0c2VsZi4JAAIBAiRTdHJpY3QgdmFsdWUgaXMgbm90IGVxdWFsIHRvIGl0c2VsZi4JAAIBAiRTdHJpY3QgdmFsdWUgaXMgbm90IGVxdWFsIHRvIGl0c2VsZi4A6enecg==", "height": 2599824, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 6Ht9SJk9iSqC6y2sMfiq1w1BV91zoHCUyvyzySfmaA3E Next: Fpuy5PgkmwqLJ9QXA5m2BBySV8TBEGSQEJhH2EFnvYXp Diff:
Old | New | Differences | |
---|---|---|---|
377 | 377 | let whOrdUsd = fraction(whOrdAm, whOrdPr, MULT8) | |
378 | 378 | let deltaVol = toVolume(bpOrdAm, pkgSize, isProd) | |
379 | 379 | if ((bpOrdAm == 0)) | |
380 | - | then $ | |
380 | + | then $Tuple12((acc._1 :+ toString(whInit)), (acc._2 :+ acc._10[j]), (acc._3 :+ toString(bpInit)), acc._4, acc._5, acc._6, (acc._7 + 1), acc._8, acc._9, acc._10, acc._11, isProd) | |
381 | 381 | else if ((bpOrdAm > 0)) | |
382 | 382 | then if ((0 > whOrdAm)) | |
383 | 383 | then if ((bpOrdAm > -(whOrdAm))) | |
384 | 384 | then throw(((((("Attempt to buy " + toString(bpOrdAm)) + " of ") + acc._11[j]) + ", but warehouse only sells ") + toString(-(whOrdAm)))) | |
385 | - | else $ | |
385 | + | else $Tuple12((acc._1 :+ toString(whInit)), (acc._2 :+ ((toString((whOrdAm + bpOrdAm)) + "@") + toString(whOrdPr))), (acc._3 :+ toString((bpInit + bpOrdAm))), (acc._4 + deltaVol), acc._5, (acc._6 + bpOrdUsd), (acc._7 + 1), acc._8, acc._9, acc._10, acc._11, isProd) | |
386 | 386 | else throw((("Attempt to buy " + acc._11[j]) + " while warehouse doesn't sell it")) | |
387 | 387 | else if ((whOrdAm > 0)) | |
388 | 388 | then if ((-(bpOrdAm) > whOrdAm)) | |
389 | 389 | then throw(((((("Attempt to sell " + toString(-(bpOrdAm))) + " of ") + acc._11[j]) + ", but warehouse only buys ") + toString(whOrdAm))) | |
390 | 390 | else if ((-(bpOrdAm) > bpInit)) | |
391 | 391 | then throw(((((("Attempt to sell " + toString(-(bpOrdAm))) + ", but you only have ") + toString(bpInit)) + " of ") + acc._11[j])) | |
392 | - | else $ | |
392 | + | else $Tuple12((acc._1 :+ toString((whInit - bpOrdAm))), (acc._2 :+ ((toString((whOrdAm + bpOrdAm)) + "@") + toString(whOrdPr))), (acc._3 :+ toString((bpInit + bpOrdAm))), (acc._4 - deltaVol), (acc._5 - bpOrdUsd), acc._6, (acc._7 + 1), acc._8, acc._9, acc._10, acc._11, isProd) | |
393 | 393 | else throw((("Attempt to sell " + acc._11[j]) + " while warehouse doesn't buy it")) | |
394 | 394 | } | |
395 | 395 | } |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let SEP = "__" | |
5 | 5 | ||
6 | 6 | let MULT6 = 1000000 | |
7 | 7 | ||
8 | 8 | let MULT7 = 10000000 | |
9 | 9 | ||
10 | 10 | let MULT8 = 100000000 | |
11 | 11 | ||
12 | 12 | let MULT10 = 10000000000 | |
13 | 13 | ||
14 | 14 | let chain = take(drop(this.bytes, 1), 1) | |
15 | 15 | ||
16 | 16 | let usdtAssetId = match chain { | |
17 | 17 | case _ => | |
18 | 18 | if ((base58'2W' == $match0)) | |
19 | 19 | then base58'9wc3LXNA4TEBsXyKtoLE9mrbDD7WMHXvXrCjZvabLAsi' | |
20 | 20 | else if ((base58'2T' == $match0)) | |
21 | 21 | then base58'6mWwf9mZBjVgkC54idpyaZLQfAosD914wT8fGf2iiY63' | |
22 | 22 | else throw("Unknown chain") | |
23 | 23 | } | |
24 | 24 | ||
25 | 25 | let defaultRestAddressStr = match chain { | |
26 | 26 | case _ => | |
27 | 27 | if ((base58'2W' == $match0)) | |
28 | 28 | then "3PQCuvFbvh4LkPUnrnU1z3jnbA1p9m3WNhv" | |
29 | 29 | else if ((base58'2T' == $match0)) | |
30 | 30 | then "3MumkGGztCKAXpWDqxkddofqXSUbqQkvSJy" | |
31 | 31 | else throw("Unknown chain") | |
32 | 32 | } | |
33 | 33 | ||
34 | 34 | func getStringOrFail (address,key) = valueOrErrorMessage(getString(address, key), makeString(["mandatory ", toString(address), ".", key, " is not defined"], "")) | |
35 | 35 | ||
36 | 36 | ||
37 | 37 | func getIntOrElse (key,defaultVal) = valueOrElse(getInteger(this, key), defaultVal) | |
38 | 38 | ||
39 | 39 | ||
40 | 40 | let IdxCfgStakingDapp = 1 | |
41 | 41 | ||
42 | 42 | let IdxCfgEconomyDapp = 2 | |
43 | 43 | ||
44 | 44 | let IdxCfgGovernanceDapp = 3 | |
45 | 45 | ||
46 | 46 | func keyRestCfg () = "%s__restConfig" | |
47 | 47 | ||
48 | 48 | ||
49 | 49 | func keyRestAddress () = "%s__restAddr" | |
50 | 50 | ||
51 | 51 | ||
52 | 52 | func readRestCfgOrFail (rest) = split_4C(getStringOrFail(rest, keyRestCfg()), SEP) | |
53 | 53 | ||
54 | 54 | ||
55 | 55 | func getContractAddressOrFail (restCfg,idx) = valueOrErrorMessage(addressFromString(restCfg[idx]), ("Rest cfg doesn't contain address at index " + toString(idx))) | |
56 | 56 | ||
57 | 57 | ||
58 | 58 | let restContract = addressFromStringValue(valueOrElse(getString(this, keyRestAddress()), defaultRestAddressStr)) | |
59 | 59 | ||
60 | 60 | let restCfg = readRestCfgOrFail(restContract) | |
61 | 61 | ||
62 | 62 | let stakingContract = getContractAddressOrFail(restCfg, IdxCfgStakingDapp) | |
63 | 63 | ||
64 | 64 | let DEFAULTLOCATION = "Africa_F_Africa" | |
65 | 65 | ||
66 | 66 | let NUMRES = 6 | |
67 | 67 | ||
68 | 68 | let FACTORYMAXWAREHOUSE = 10000000000 | |
69 | 69 | ||
70 | 70 | let RESOURCEPRICEMIN = 39637 | |
71 | 71 | ||
72 | 72 | let MINPAYMENT = 10000 | |
73 | 73 | ||
74 | 74 | let SELLMULTIPLIER = 200 | |
75 | 75 | ||
76 | 76 | let BUYMULTIPLIER = 300 | |
77 | 77 | ||
78 | 78 | let LANDPREFIX = "LAND" | |
79 | 79 | ||
80 | 80 | let DUCKPREFIX = "DUCK" | |
81 | 81 | ||
82 | 82 | let WHMULTIPLIER = 10000000000 | |
83 | 83 | ||
84 | 84 | let AUCTIONFEE = 10000 | |
85 | 85 | ||
86 | 86 | let MINSHOPPAYMENT = 100000 | |
87 | 87 | ||
88 | 88 | let resTypes = ["Oil", "Ore", "Wood", "Sand", "Clay", "Organic"] | |
89 | 89 | ||
90 | 90 | let matTypes = ["Fuel", "Metal", "Plank", "Glass", "Plastic", "Protein"] | |
91 | 91 | ||
92 | 92 | let prodTypes = ["First Aid Kit", "Backpack", "Food Ration", "Jet Pack", "Shield"] | |
93 | 93 | ||
94 | 94 | let continents = ["Americas", "Europe", "Asia", "Africa", "Oceania"] | |
95 | 95 | ||
96 | 96 | 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"] | |
97 | 97 | ||
98 | 98 | let contIdxAmericas = 0 | |
99 | 99 | ||
100 | 100 | let contIdxEurope = 1 | |
101 | 101 | ||
102 | 102 | let contIdxAsia = 2 | |
103 | 103 | ||
104 | 104 | let contIdxAfrica = 3 | |
105 | 105 | ||
106 | 106 | let contIdxOceania = 4 | |
107 | 107 | ||
108 | 108 | let recipeIdxFuel = 0 | |
109 | 109 | ||
110 | 110 | let recipeIdxMetal = 1 | |
111 | 111 | ||
112 | 112 | let recipeIdxPlank = 2 | |
113 | 113 | ||
114 | 114 | let recipeIdxGlass = 3 | |
115 | 115 | ||
116 | 116 | let recipeIdxPlastic = 4 | |
117 | 117 | ||
118 | 118 | let recipeIdxProtein = 5 | |
119 | 119 | ||
120 | 120 | let recipeIdxWeight = 6 | |
121 | 121 | ||
122 | 122 | let recipeIdxPacksize = 7 | |
123 | 123 | ||
124 | 124 | let recipeIdxContinent = 8 | |
125 | 125 | ||
126 | 126 | func keyFactoryWarehouseByIdAndType (factoryId,resType) = ((("factoryWhByContinentAndRes_" + factoryId) + "_") + toString(resType)) | |
127 | 127 | ||
128 | 128 | ||
129 | 129 | func keyOrderByLand (landAssetId) = ("landOrder_" + landAssetId) | |
130 | 130 | ||
131 | 131 | ||
132 | 132 | func keyStakedDuckByOwner (ownerAddr) = ("stakedDuckByOwner_" + ownerAddr) | |
133 | 133 | ||
134 | 134 | ||
135 | 135 | func keyBackpackByDuck (duckAssetId) = ("backPack_" + duckAssetId) | |
136 | 136 | ||
137 | 137 | ||
138 | 138 | func keyDuckLocation (duckAssetId) = ("duckLocation_" + duckAssetId) | |
139 | 139 | ||
140 | 140 | ||
141 | 141 | func keyBlocked () = "contractsBlocked" | |
142 | 142 | ||
143 | 143 | ||
144 | 144 | func keyLandAssetIdToOwner (assetId) = ("nftOwner_" + assetId) | |
145 | 145 | ||
146 | 146 | ||
147 | 147 | func keyStakedTimeByAssetId (assetId) = ("stakedTime_" + assetId) | |
148 | 148 | ||
149 | 149 | ||
150 | 150 | func keyAddressRefBy (addr) = ("accRefBy_" + addr) | |
151 | 151 | ||
152 | 152 | ||
153 | 153 | let locIdxContinent = 0 | |
154 | 154 | ||
155 | 155 | let locIdxType = 1 | |
156 | 156 | ||
157 | 157 | let locIdxId = 2 | |
158 | 158 | ||
159 | 159 | let bpIdxLevel = 0 | |
160 | 160 | ||
161 | 161 | let bpIdxRes = 1 | |
162 | 162 | ||
163 | 163 | let bpIdxMat = 2 | |
164 | 164 | ||
165 | 165 | let bpIdxProd = 3 | |
166 | 166 | ||
167 | 167 | let whIdxLevels = 0 | |
168 | 168 | ||
169 | 169 | let whIdxRes = 1 | |
170 | 170 | ||
171 | 171 | let whIdxMat = 2 | |
172 | 172 | ||
173 | 173 | let whIdxProd = 3 | |
174 | 174 | ||
175 | 175 | let whIdxLOFT = 4 | |
176 | 176 | ||
177 | 177 | let volLocked = 0 | |
178 | 178 | ||
179 | 179 | let volOccupied = 1 | |
180 | 180 | ||
181 | 181 | let volFree = 2 | |
182 | 182 | ||
183 | 183 | let volTotal = 3 | |
184 | 184 | ||
185 | 185 | let ordIdxRes = 0 | |
186 | 186 | ||
187 | 187 | let ordIdxMat = 1 | |
188 | 188 | ||
189 | 189 | let ordIdxProd = 2 | |
190 | 190 | ||
191 | 191 | func asString (v) = match v { | |
192 | 192 | case s: String => | |
193 | 193 | s | |
194 | 194 | case _ => | |
195 | 195 | throw("fail to cast into String") | |
196 | 196 | } | |
197 | 197 | ||
198 | 198 | ||
199 | 199 | func getOrder (ordKey) = { | |
200 | 200 | let p = split(valueOrElse(getString(ordKey), "0@0_0@0_0@0_0@0_0@0_0@0:0@0_0@0_0@0_0@0_0@0_0@0:"), ":") | |
201 | 201 | [if ((size(split(p[ordIdxRes], "_")) == NUMRES)) | |
202 | 202 | then p[ordIdxRes] | |
203 | 203 | else "0@0_0@0_0@0_0@0_0@0_0@0", if ((size(split(p[ordIdxMat], "_")) == NUMRES)) | |
204 | 204 | then p[ordIdxMat] | |
205 | 205 | else "0@0_0@0_0@0_0@0_0@0_0@0", p[ordIdxProd]] | |
206 | 206 | } | |
207 | 207 | ||
208 | 208 | ||
209 | 209 | func toVolume (amount,pkgSize,isProduct) = if (isProduct) | |
210 | 210 | then { | |
211 | 211 | let pkgs = if ((amount >= 0)) | |
212 | 212 | then (((amount + pkgSize) - 1) / pkgSize) | |
213 | 213 | else -((((-(amount) + pkgSize) - 1) / pkgSize)) | |
214 | 214 | (pkgs * MULT8) | |
215 | 215 | } | |
216 | 216 | else amount | |
217 | 217 | ||
218 | 218 | ||
219 | 219 | func getWarehouseTotalVolume (volPrefix) = { | |
220 | 220 | let parts = split(volPrefix, "_") | |
221 | 221 | ((WHMULTIPLIER * (parseIntValue(parts[1]) + 1)) * parseIntValue(parts[0])) | |
222 | 222 | } | |
223 | 223 | ||
224 | 224 | ||
225 | 225 | func getWarehouseCurrGoodsVolume (currentWh) = { | |
226 | 226 | let goods = currentWh[whIdxProd] | |
227 | 227 | if ((goods == "")) | |
228 | 228 | then 0 | |
229 | 229 | else { | |
230 | 230 | func sum (acc,item) = { | |
231 | 231 | let idx = acc._1 | |
232 | 232 | let pkgSize = parseIntValue(split(productionMatrix[idx], "_")[recipeIdxPacksize]) | |
233 | 233 | $Tuple2((idx + 1), (acc._2 + toVolume(parseIntValue(item), pkgSize, true))) | |
234 | 234 | } | |
235 | 235 | ||
236 | 236 | ( let $l = split_4C(goods, "_") | |
237 | 237 | let $s = size($l) | |
238 | 238 | let $acc0 = $Tuple2(0, 0) | |
239 | 239 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
240 | 240 | then $a | |
241 | 241 | else sum($a, $l[$i]) | |
242 | 242 | ||
243 | 243 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
244 | 244 | then $a | |
245 | 245 | else throw("List size exceeds 50") | |
246 | 246 | ||
247 | 247 | $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))._2 | |
248 | 248 | } | |
249 | 249 | } | |
250 | 250 | ||
251 | 251 | ||
252 | 252 | func sellInternal (locId,resType,amount,minPrice) = { | |
253 | 253 | let whKey = keyFactoryWarehouseByIdAndType(locId, resType) | |
254 | 254 | let w0 = valueOrElse(getInteger(whKey), 0) | |
255 | 255 | let r0 = if ((w0 > FACTORYMAXWAREHOUSE)) | |
256 | 256 | then 0 | |
257 | 257 | else if (((w0 + amount) > FACTORYMAXWAREHOUSE)) | |
258 | 258 | then (FACTORYMAXWAREHOUSE - w0) | |
259 | 259 | else amount | |
260 | 260 | let usdtReceived = (fraction(r0, ((SELLMULTIPLIER * RESOURCEPRICEMIN) - fraction(((100 * w0) + (50 * r0)), RESOURCEPRICEMIN, FACTORYMAXWAREHOUSE)), MULT10) + fraction((amount - r0), RESOURCEPRICEMIN, MULT8)) | |
261 | 261 | let min99 = (minPrice - (minPrice / 100)) | |
262 | 262 | if (((min99 * amount) > (usdtReceived * MULT8))) | |
263 | 263 | then throw((((((((((("Actual price = " + toString(usdtReceived)) + " / ") + toString(amount)) + " < minPrice = ") + toString(minPrice)) + ", (") + locId) + ", ") + resTypes[resType]) + ")")) | |
264 | 264 | else $Tuple2(IntegerEntry(whKey, (w0 + amount)), usdtReceived) | |
265 | 265 | } | |
266 | 266 | ||
267 | 267 | ||
268 | 268 | func buyInternal (locId,matType,amount,maxPrice) = { | |
269 | 269 | let whKey = keyFactoryWarehouseByIdAndType(locId, matType) | |
270 | 270 | let w0 = valueOrElse(getInteger(whKey), 0) | |
271 | 271 | let m1 = if ((w0 > FACTORYMAXWAREHOUSE)) | |
272 | 272 | then min([amount, (w0 - FACTORYMAXWAREHOUSE)]) | |
273 | 273 | else 0 | |
274 | 274 | let m0 = min([w0, (amount - m1)]) | |
275 | 275 | let m = (m0 + m1) | |
276 | 276 | let usdtSpent = (fraction(m0, ((BUYMULTIPLIER * RESOURCEPRICEMIN) - fraction(((100 * w0) - (50 * m0)), RESOURCEPRICEMIN, FACTORYMAXWAREHOUSE)), MULT10) + fraction(m1, (2 * RESOURCEPRICEMIN), MULT8)) | |
277 | 277 | let max101 = (maxPrice + (maxPrice / 100)) | |
278 | 278 | if (((usdtSpent * MULT8) > (max101 * m))) | |
279 | 279 | then throw((((((((((("Actual price = " + toString(usdtSpent)) + " / ") + toString(m)) + " > maxPrice = ") + toString(maxPrice)) + ", (") + locId) + ", ") + matTypes[matType]) + ")")) | |
280 | 280 | else $Tuple3(IntegerEntry(whKey, (w0 - m)), usdtSpent, m) | |
281 | 281 | } | |
282 | 282 | ||
283 | 283 | ||
284 | 284 | func getBackpack (bpKey) = { | |
285 | 285 | let p = split(valueOrElse(getString(stakingContract, bpKey), "0:0_0_0_0_0_0:0_0_0_0_0_0:"), ":") | |
286 | 286 | [toString(valueOrElse(parseInt(p[bpIdxLevel]), 0)), if ((size(split(p[bpIdxRes], "_")) == NUMRES)) | |
287 | 287 | then p[bpIdxRes] | |
288 | 288 | else "0_0_0_0_0_0", if ((size(split(p[bpIdxMat], "_")) == NUMRES)) | |
289 | 289 | then p[bpIdxMat] | |
290 | 290 | else "0_0_0_0_0_0", p[bpIdxProd]] | |
291 | 291 | } | |
292 | 292 | ||
293 | 293 | ||
294 | 294 | func checkBlocked () = if (valueOrElse(getBoolean(stakingContract, keyBlocked()), false)) | |
295 | 295 | then throw("Contracts are under maintenance") | |
296 | 296 | else unit | |
297 | 297 | ||
298 | 298 | ||
299 | 299 | func setCommon (acc,item) = { | |
300 | 300 | let j = acc._1 | |
301 | 301 | let isProd = acc._8 | |
302 | 302 | let pkgSize = if (isProd) | |
303 | 303 | then parseIntValue(split(productionMatrix[j], "_")[recipeIdxPacksize]) | |
304 | 304 | else 0 | |
305 | 305 | let itemParts = split(item, "@") | |
306 | 306 | if ((size(itemParts) != 2)) | |
307 | 307 | then throw("Incorrect order format, should be amount@price") | |
308 | 308 | else { | |
309 | 309 | let newOrdAm = parseIntValue(itemParts[0]) | |
310 | 310 | let newOrdPr = parseIntValue(itemParts[1]) | |
311 | 311 | let newOrdUsd = fraction(newOrdAm, newOrdPr, MULT8) | |
312 | 312 | let newOrdVol = toVolume(newOrdAm, pkgSize, isProd) | |
313 | 313 | let whInit = if ((size(acc._6) > j)) | |
314 | 314 | then parseIntValue(acc._6[j]) | |
315 | 315 | else 0 | |
316 | 316 | let curOrdParts = split(if ((size(acc._7) > j)) | |
317 | 317 | then acc._7[j] | |
318 | 318 | else "0@0", "@") | |
319 | 319 | let curOrdAm = parseIntValue(curOrdParts[0]) | |
320 | 320 | let curOrdPr = parseIntValue(curOrdParts[1]) | |
321 | 321 | if (if ((0 > curOrdPr)) | |
322 | 322 | then true | |
323 | 323 | else (0 > newOrdPr)) | |
324 | 324 | then throw("Price can't be negative") | |
325 | 325 | else { | |
326 | 326 | let curOrdUsd = fraction(curOrdAm, curOrdPr, MULT8) | |
327 | 327 | let curOrdVol = toVolume(curOrdAm, pkgSize, isProd) | |
328 | 328 | if ((newOrdAm == 0)) | |
329 | 329 | then if ((curOrdAm > 0)) | |
330 | 330 | then $Tuple8((j + 1), (acc._2 :+ toString(whInit)), acc._3, acc._4, (acc._5 - curOrdUsd), acc._6, acc._7, isProd) | |
331 | 331 | else $Tuple8((j + 1), (acc._2 :+ toString((whInit - curOrdAm))), acc._3, acc._4, acc._5, acc._6, acc._7, isProd) | |
332 | 332 | else if ((newOrdAm > 0)) | |
333 | 333 | then if ((0 > curOrdAm)) | |
334 | 334 | then $Tuple8((j + 1), (acc._2 :+ toString((whInit - curOrdAm))), (acc._3 + newOrdVol), acc._4, (acc._5 + newOrdUsd), acc._6, acc._7, isProd) | |
335 | 335 | else $Tuple8((j + 1), (acc._2 :+ toString(whInit)), (acc._3 + newOrdVol), acc._4, ((acc._5 + newOrdUsd) - curOrdUsd), acc._6, acc._7, isProd) | |
336 | 336 | else if ((0 > curOrdAm)) | |
337 | 337 | then { | |
338 | 338 | let amDiff = (curOrdAm - newOrdAm) | |
339 | 339 | if ((0 > (whInit - amDiff))) | |
340 | 340 | then throw((((("Attempt to take " + toString(amDiff)) + " from warehouse, but only ") + toString(whInit)) + " available")) | |
341 | 341 | else $Tuple8((j + 1), (acc._2 :+ toString((whInit - amDiff))), acc._3, (acc._4 - newOrdVol), acc._5, acc._6, acc._7, isProd) | |
342 | 342 | } | |
343 | 343 | else if ((0 > (whInit + newOrdAm))) | |
344 | 344 | then throw((((("Attempt to take " + toString(-(newOrdAm))) + " from warehouse, but only ") + toString(whInit)) + " available")) | |
345 | 345 | else $Tuple8((j + 1), (acc._2 :+ toString((whInit + newOrdAm))), acc._3, (acc._4 - newOrdVol), (acc._5 - curOrdUsd), acc._6, acc._7, isProd) | |
346 | 346 | } | |
347 | 347 | } | |
348 | 348 | } | |
349 | 349 | ||
350 | 350 | ||
351 | 351 | func acceptCommon (acc,bpOrdItem) = { | |
352 | 352 | let j = acc._7 | |
353 | 353 | let isProd = acc._12 | |
354 | 354 | let pkgSize = if (isProd) | |
355 | 355 | then parseIntValue(split(productionMatrix[j], "_")[recipeIdxPacksize]) | |
356 | 356 | else 0 | |
357 | 357 | let bpOrdParts = split(bpOrdItem, "@") | |
358 | 358 | if ((size(bpOrdParts) != 2)) | |
359 | 359 | then throw("Incorrect order format, should be amount@price") | |
360 | 360 | else { | |
361 | 361 | let bpOrdAm = parseIntValue(bpOrdParts[0]) | |
362 | 362 | let bpOrdPr = parseIntValue(bpOrdParts[1]) | |
363 | 363 | if ((0 > bpOrdPr)) | |
364 | 364 | then throw("Price can't be negative") | |
365 | 365 | else { | |
366 | 366 | let bpOrdUsd = fraction(bpOrdAm, bpOrdPr, MULT8) | |
367 | 367 | let bpInit = parseIntValue(acc._8[j]) | |
368 | 368 | let whInit = parseIntValue(acc._9[j]) | |
369 | 369 | let whOrdParts = split(acc._10[j], "@") | |
370 | 370 | let whOrdAm = parseIntValue(whOrdParts[0]) | |
371 | 371 | let whOrdPr = parseIntValue(whOrdParts[1]) | |
372 | 372 | if (if ((bpOrdAm != 0)) | |
373 | 373 | then (bpOrdPr != whOrdPr) | |
374 | 374 | else false) | |
375 | 375 | then throw(((((("Prices of " + acc._11[j]) + " don't match! WH price=") + toString(whOrdPr)) + ", your price=") + toString(bpOrdPr))) | |
376 | 376 | else { | |
377 | 377 | let whOrdUsd = fraction(whOrdAm, whOrdPr, MULT8) | |
378 | 378 | let deltaVol = toVolume(bpOrdAm, pkgSize, isProd) | |
379 | 379 | if ((bpOrdAm == 0)) | |
380 | - | then $ | |
380 | + | then $Tuple12((acc._1 :+ toString(whInit)), (acc._2 :+ acc._10[j]), (acc._3 :+ toString(bpInit)), acc._4, acc._5, acc._6, (acc._7 + 1), acc._8, acc._9, acc._10, acc._11, isProd) | |
381 | 381 | else if ((bpOrdAm > 0)) | |
382 | 382 | then if ((0 > whOrdAm)) | |
383 | 383 | then if ((bpOrdAm > -(whOrdAm))) | |
384 | 384 | then throw(((((("Attempt to buy " + toString(bpOrdAm)) + " of ") + acc._11[j]) + ", but warehouse only sells ") + toString(-(whOrdAm)))) | |
385 | - | else $ | |
385 | + | else $Tuple12((acc._1 :+ toString(whInit)), (acc._2 :+ ((toString((whOrdAm + bpOrdAm)) + "@") + toString(whOrdPr))), (acc._3 :+ toString((bpInit + bpOrdAm))), (acc._4 + deltaVol), acc._5, (acc._6 + bpOrdUsd), (acc._7 + 1), acc._8, acc._9, acc._10, acc._11, isProd) | |
386 | 386 | else throw((("Attempt to buy " + acc._11[j]) + " while warehouse doesn't sell it")) | |
387 | 387 | else if ((whOrdAm > 0)) | |
388 | 388 | then if ((-(bpOrdAm) > whOrdAm)) | |
389 | 389 | then throw(((((("Attempt to sell " + toString(-(bpOrdAm))) + " of ") + acc._11[j]) + ", but warehouse only buys ") + toString(whOrdAm))) | |
390 | 390 | else if ((-(bpOrdAm) > bpInit)) | |
391 | 391 | then throw(((((("Attempt to sell " + toString(-(bpOrdAm))) + ", but you only have ") + toString(bpInit)) + " of ") + acc._11[j])) | |
392 | - | else $ | |
392 | + | else $Tuple12((acc._1 :+ toString((whInit - bpOrdAm))), (acc._2 :+ ((toString((whOrdAm + bpOrdAm)) + "@") + toString(whOrdPr))), (acc._3 :+ toString((bpInit + bpOrdAm))), (acc._4 - deltaVol), (acc._5 - bpOrdUsd), acc._6, (acc._7 + 1), acc._8, acc._9, acc._10, acc._11, isProd) | |
393 | 393 | else throw((("Attempt to sell " + acc._11[j]) + " while warehouse doesn't buy it")) | |
394 | 394 | } | |
395 | 395 | } | |
396 | 396 | } | |
397 | 397 | } | |
398 | 398 | ||
399 | 399 | ||
400 | 400 | @Callable(i) | |
401 | 401 | func constructorV1 (restAddr) = if ((i.caller != this)) | |
402 | 402 | then throw("Permission denied") | |
403 | 403 | else [StringEntry(keyRestAddress(), restAddr)] | |
404 | 404 | ||
405 | 405 | ||
406 | 406 | ||
407 | 407 | @Callable(i) | |
408 | 408 | func sellResources (amounts,minPrices) = { | |
409 | 409 | let blocked = checkBlocked() | |
410 | 410 | if ((blocked == blocked)) | |
411 | 411 | then { | |
412 | 412 | let duckAssetId = valueOrErrorMessage(getString(stakingContract, keyStakedDuckByOwner(toString(i.caller))), "You don't have a duck staked") | |
413 | 413 | if ((size(i.payments) != 0)) | |
414 | 414 | then throw("sellResources doesn't require any payments") | |
415 | 415 | else { | |
416 | 416 | let curLocation = split(valueOrElse(getString(stakingContract, keyDuckLocation(duckAssetId)), DEFAULTLOCATION), "_") | |
417 | 417 | if ((curLocation[locIdxType] != "F")) | |
418 | 418 | then throw(("Duck location type should be Factory, but is " + curLocation[locIdxType])) | |
419 | 419 | else { | |
420 | 420 | let locId = curLocation[locIdxId] | |
421 | 421 | let currentPack = getBackpack(keyBackpackByDuck(duckAssetId)) | |
422 | 422 | let resList = split(currentPack[bpIdxRes], "_") | |
423 | 423 | func adder (acc,j) = if ((amounts[j] > parseIntValue(resList[j]))) | |
424 | 424 | then throw(((((("You have " + resList[j]) + " of ") + resTypes[j]) + ", but tried to sell ") + toString(amounts[j]))) | |
425 | 425 | else if ((0 > amounts[j])) | |
426 | 426 | then throw(((("You tried to sell negative amount of " + resTypes[j]) + ": ") + toString(amounts[j]))) | |
427 | 427 | else if ((amounts[j] > 0)) | |
428 | 428 | then { | |
429 | 429 | let b = sellInternal(locId, j, amounts[j], minPrices[j]) | |
430 | 430 | $Tuple3((acc._1 :+ b._1), (acc._2 :+ toString((parseIntValue(resList[j]) - amounts[j]))), (acc._3 + b._2)) | |
431 | 431 | } | |
432 | 432 | else $Tuple3(acc._1, (acc._2 :+ resList[j]), acc._3) | |
433 | 433 | ||
434 | 434 | let merged = { | |
435 | 435 | let $l = [0, 1, 2, 3, 4, 5] | |
436 | 436 | let $s = size($l) | |
437 | 437 | let $acc0 = $Tuple3(nil, nil, 0) | |
438 | 438 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
439 | 439 | then $a | |
440 | 440 | else adder($a, $l[$i]) | |
441 | 441 | ||
442 | 442 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
443 | 443 | then $a | |
444 | 444 | else throw("List size exceeds 6") | |
445 | 445 | ||
446 | 446 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6) | |
447 | 447 | } | |
448 | 448 | let newPack = makeString([currentPack[bpIdxLevel], makeString(merged._2, "_"), currentPack[bpIdxMat], currentPack[bpIdxProd]], ":") | |
449 | 449 | let result = asString(invoke(stakingContract, "updateBackpack", [duckAssetId, newPack], nil)) | |
450 | 450 | $Tuple2((merged._1 :+ ScriptTransfer(i.caller, merged._3, usdtAssetId)), result) | |
451 | 451 | } | |
452 | 452 | } | |
453 | 453 | } | |
454 | 454 | else throw("Strict value is not equal to itself.") | |
455 | 455 | } | |
456 | 456 | ||
457 | 457 | ||
458 | 458 | ||
459 | 459 | @Callable(i) | |
460 | 460 | func buyMaterials (amounts,maxPrices) = { | |
461 | 461 | let blocked = checkBlocked() | |
462 | 462 | if ((blocked == blocked)) | |
463 | 463 | then { | |
464 | 464 | let duckAssetId = valueOrErrorMessage(getString(stakingContract, keyStakedDuckByOwner(toString(i.caller))), "You don't have a duck staked") | |
465 | 465 | if ((size(i.payments) != 1)) | |
466 | 466 | then throw("exactly 1 payment must be attached") | |
467 | 467 | else { | |
468 | 468 | let pmt = i.payments[0] | |
469 | 469 | let amt = pmt.amount | |
470 | 470 | let pmtAssetId = valueOrErrorMessage(pmt.assetId, "WAVES can't be used as payment") | |
471 | 471 | if ((pmtAssetId != usdtAssetId)) | |
472 | 472 | then throw("USDT payments only!") | |
473 | 473 | else { | |
474 | 474 | let curLocation = split(valueOrElse(getString(stakingContract, keyDuckLocation(duckAssetId)), DEFAULTLOCATION), "_") | |
475 | 475 | if ((curLocation[locIdxType] != "F")) | |
476 | 476 | then throw(("Duck location type should be Factory, but is " + curLocation[locIdxType])) | |
477 | 477 | else { | |
478 | 478 | let locId = curLocation[locIdxId] | |
479 | 479 | let currentPack = getBackpack(keyBackpackByDuck(duckAssetId)) | |
480 | 480 | let matList = split(currentPack[bpIdxMat], "_") | |
481 | 481 | func mUpdater (acc,j) = if ((0 > amounts[j])) | |
482 | 482 | then throw(((("You tried to buy negative amount of " + matTypes[j]) + ": ") + toString(amounts[j]))) | |
483 | 483 | else if ((amounts[j] > 0)) | |
484 | 484 | then { | |
485 | 485 | let b = buyInternal(locId, j, amounts[j], maxPrices[j]) | |
486 | 486 | $Tuple3((acc._1 :+ b._1), (acc._2 :+ toString((parseIntValue(matList[j]) + b._3))), (acc._3 + b._2)) | |
487 | 487 | } | |
488 | 488 | else $Tuple3(acc._1, (acc._2 :+ matList[j]), acc._3) | |
489 | 489 | ||
490 | 490 | let merged = { | |
491 | 491 | let $l = [0, 1, 2, 3, 4, 5] | |
492 | 492 | let $s = size($l) | |
493 | 493 | let $acc0 = $Tuple3(nil, nil, 0) | |
494 | 494 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
495 | 495 | then $a | |
496 | 496 | else mUpdater($a, $l[$i]) | |
497 | 497 | ||
498 | 498 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
499 | 499 | then $a | |
500 | 500 | else throw("List size exceeds 6") | |
501 | 501 | ||
502 | 502 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6) | |
503 | 503 | } | |
504 | 504 | if ((merged._3 > amt)) | |
505 | 505 | then throw(((("Insufficient payment! Attached=" + toString(amt)) + ", required=") + toString(merged._3))) | |
506 | 506 | else { | |
507 | 507 | let newPack = makeString([currentPack[bpIdxLevel], currentPack[bpIdxRes], makeString(merged._2, "_"), currentPack[bpIdxProd]], ":") | |
508 | 508 | let result = asString(invoke(stakingContract, "updateBackpack", [duckAssetId, newPack], nil)) | |
509 | 509 | let rest = if (((amt - merged._3) > 0)) | |
510 | 510 | then [ScriptTransfer(i.caller, (amt - merged._3), usdtAssetId)] | |
511 | 511 | else nil | |
512 | 512 | let activitiesAmount = (merged._3 / 100) | |
513 | 513 | $Tuple2(((merged._1 ++ rest) :+ ScriptTransfer(restContract, activitiesAmount, usdtAssetId)), result) | |
514 | 514 | } | |
515 | 515 | } | |
516 | 516 | } | |
517 | 517 | } | |
518 | 518 | } | |
519 | 519 | else throw("Strict value is not equal to itself.") | |
520 | 520 | } | |
521 | 521 | ||
522 | 522 | ||
523 | 523 | ||
524 | 524 | @Callable(i) | |
525 | 525 | func exchangeResources (amounts) = { | |
526 | 526 | let blocked = checkBlocked() | |
527 | 527 | if ((blocked == blocked)) | |
528 | 528 | then { | |
529 | 529 | let duckAssetId = valueOrErrorMessage(getString(stakingContract, keyStakedDuckByOwner(toString(i.caller))), "You don't have a duck staked") | |
530 | 530 | if ((size(i.payments) != 1)) | |
531 | 531 | then throw("exactly 1 payment must be attached") | |
532 | 532 | else { | |
533 | 533 | let pmt = i.payments[0] | |
534 | 534 | let amt = pmt.amount | |
535 | 535 | let pmtAssetId = valueOrErrorMessage(pmt.assetId, "WAVES can't be used as payment") | |
536 | 536 | if ((pmtAssetId != usdtAssetId)) | |
537 | 537 | then throw("USDT payments only!") | |
538 | 538 | else { | |
539 | 539 | let curLocation = split(valueOrElse(getString(stakingContract, keyDuckLocation(duckAssetId)), DEFAULTLOCATION), "_") | |
540 | 540 | if ((curLocation[locIdxType] != "F")) | |
541 | 541 | then throw(("Duck location type should be Factory, but is " + curLocation[locIdxType])) | |
542 | 542 | else { | |
543 | 543 | let locId = curLocation[locIdxId] | |
544 | 544 | let currentPack = getBackpack(keyBackpackByDuck(duckAssetId)) | |
545 | 545 | let resList = split(currentPack[bpIdxRes], "_") | |
546 | 546 | let matList = split(currentPack[bpIdxMat], "_") | |
547 | 547 | func exchanger (acc,j) = { | |
548 | 548 | let whKey = keyFactoryWarehouseByIdAndType(locId, j) | |
549 | 549 | let w0 = valueOrElse(getInteger(whKey), 0) | |
550 | 550 | let amj = amounts[j] | |
551 | 551 | if ((amj > parseIntValue(resList[j]))) | |
552 | 552 | then throw(((((("You have " + resList[j]) + " of ") + resTypes[j]) + ", but tried to exchange ") + toString(amj))) | |
553 | 553 | else if ((0 > amj)) | |
554 | 554 | then throw(((("You tried to exchange negative amount of " + resTypes[j]) + ": ") + toString(amj))) | |
555 | 555 | else if ((amj > 0)) | |
556 | 556 | then $Tuple4((acc._1 :+ toString((parseIntValue(resList[j]) - amj))), (acc._2 :+ toString((parseIntValue(matList[j]) + amj))), (acc._3 + fraction(amj, RESOURCEPRICEMIN, MULT8)), (acc._4 :+ IntegerEntry(whKey, w0))) | |
557 | 557 | else $Tuple4((acc._1 :+ resList[j]), (acc._2 :+ matList[j]), acc._3, acc._4) | |
558 | 558 | } | |
559 | 559 | ||
560 | 560 | let merged = { | |
561 | 561 | let $l = [0, 1, 2, 3, 4, 5] | |
562 | 562 | let $s = size($l) | |
563 | 563 | let $acc0 = $Tuple4(nil, nil, 0, nil) | |
564 | 564 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
565 | 565 | then $a | |
566 | 566 | else exchanger($a, $l[$i]) | |
567 | 567 | ||
568 | 568 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
569 | 569 | then $a | |
570 | 570 | else throw("List size exceeds 6") | |
571 | 571 | ||
572 | 572 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6) | |
573 | 573 | } | |
574 | 574 | if ((merged._3 > amt)) | |
575 | 575 | then throw(((("Insufficient payment! Attached=" + toString(amt)) + ", required=") + toString(merged._3))) | |
576 | 576 | else { | |
577 | 577 | let newPack = makeString([currentPack[bpIdxLevel], makeString(merged._1, "_"), makeString(merged._2, "_"), currentPack[bpIdxProd]], ":") | |
578 | 578 | let result = asString(invoke(stakingContract, "updateBackpack", [duckAssetId, newPack], nil)) | |
579 | 579 | let rest = if (((amt - merged._3) > 0)) | |
580 | 580 | then [ScriptTransfer(i.caller, (amt - merged._3), usdtAssetId)] | |
581 | 581 | else nil | |
582 | 582 | let activitiesAmount = (merged._3 / 100) | |
583 | 583 | $Tuple2(((rest ++ merged._4) :+ ScriptTransfer(restContract, activitiesAmount, usdtAssetId)), result) | |
584 | 584 | } | |
585 | 585 | } | |
586 | 586 | } | |
587 | 587 | } | |
588 | 588 | } | |
589 | 589 | else throw("Strict value is not equal to itself.") | |
590 | 590 | } | |
591 | 591 | ||
592 | 592 | ||
593 | 593 | ||
594 | 594 | @Callable(i) | |
595 | 595 | func craftGoods (productIdx,quantity) = { | |
596 | 596 | let blocked = checkBlocked() | |
597 | 597 | if ((blocked == blocked)) | |
598 | 598 | then if ((size(i.payments) != 1)) | |
599 | 599 | then throw("exactly 1 payment must be attached") | |
600 | 600 | else { | |
601 | 601 | let pmt = i.payments[0] | |
602 | 602 | let amt = pmt.amount | |
603 | 603 | let pmtAssetId = valueOrErrorMessage(pmt.assetId, "WAVES can't be used as payment") | |
604 | 604 | if ((pmtAssetId != usdtAssetId)) | |
605 | 605 | then throw("USDT payments only!") | |
606 | 606 | else if ((amt != MULT6)) | |
607 | 607 | then throw("exactly 1 USDT must be attached as payment") | |
608 | 608 | else if ((0 >= quantity)) | |
609 | 609 | then throw("Quantity should be positive") | |
610 | 610 | else { | |
611 | 611 | let duckAssetId = valueOrErrorMessage(getString(stakingContract, keyStakedDuckByOwner(toString(i.caller))), "You don't have a duck staked") | |
612 | 612 | let curLocation = split(valueOrElse(getString(stakingContract, keyDuckLocation(duckAssetId)), DEFAULTLOCATION), "_") | |
613 | 613 | if ((curLocation[locIdxType] != "M")) | |
614 | 614 | then throw(("Duck location type should be Manufactory, but is " + curLocation[locIdxType])) | |
615 | 615 | else { | |
616 | 616 | let cont = curLocation[locIdxContinent] | |
617 | 617 | let currentPack = getBackpack(keyBackpackByDuck(duckAssetId)) | |
618 | 618 | let matList = split(currentPack[bpIdxMat], "_") | |
619 | 619 | if (if ((0 > productIdx)) | |
620 | 620 | then true | |
621 | 621 | else (productIdx >= size(productionMatrix))) | |
622 | 622 | then throw(("Unknown product idx=" + toString(productIdx))) | |
623 | 623 | else { | |
624 | 624 | let recipe = split(productionMatrix[productIdx], "_") | |
625 | 625 | if ((size(recipe) != (NUMRES + 3))) | |
626 | 626 | then throw(("Fatal: unknown recipe: " + productionMatrix[productIdx])) | |
627 | 627 | else { | |
628 | 628 | let productContIdx = parseIntValue(recipe[recipeIdxContinent]) | |
629 | 629 | if ((continents[productContIdx] != cont)) | |
630 | 630 | then throw(((("This product is available in " + continents[productContIdx]) + ", but you are in ") + cont)) | |
631 | 631 | else { | |
632 | 632 | let prodList = if ((currentPack[bpIdxProd] == "")) | |
633 | 633 | then nil | |
634 | 634 | else split(currentPack[bpIdxProd], "_") | |
635 | 635 | func filler (acc,ignoredItem) = { | |
636 | 636 | let n = acc._2 | |
637 | 637 | let xs = if ((size(prodList) > n)) | |
638 | 638 | then prodList[n] | |
639 | 639 | else "0" | |
640 | 640 | let x = parseIntValue(xs) | |
641 | 641 | let amount = (quantity * parseIntValue(recipe[recipeIdxPacksize])) | |
642 | 642 | let y = if ((n == productIdx)) | |
643 | 643 | then toString((x + amount)) | |
644 | 644 | else xs | |
645 | 645 | $Tuple2((acc._1 :+ y), (n + 1)) | |
646 | 646 | } | |
647 | 647 | ||
648 | 648 | let bpProd = ( let $l = productionMatrix | |
649 | 649 | let $s = size($l) | |
650 | 650 | let $acc0 = $Tuple2(nil, 0) | |
651 | 651 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
652 | 652 | then $a | |
653 | 653 | else filler($a, $l[$i]) | |
654 | 654 | ||
655 | 655 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
656 | 656 | then $a | |
657 | 657 | else throw("List size exceeds 50") | |
658 | 658 | ||
659 | 659 | $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 | |
660 | 660 | func producer (acc,j) = { | |
661 | 661 | let needMat = ((parseIntValue(recipe[j]) * MULT7) * quantity) | |
662 | 662 | let haveMat = parseIntValue(matList[j]) | |
663 | 663 | if ((needMat > haveMat)) | |
664 | 664 | then throw(((((((("You have " + matList[j]) + " of ") + matTypes[j]) + ", but recipe requires ") + toString(needMat)) + " for quantity ") + toString(quantity))) | |
665 | 665 | else if ((needMat > 0)) | |
666 | 666 | then (acc :+ toString((haveMat - needMat))) | |
667 | 667 | else (acc :+ matList[j]) | |
668 | 668 | } | |
669 | 669 | ||
670 | 670 | let merged = { | |
671 | 671 | let $l = [0, 1, 2, 3, 4, 5] | |
672 | 672 | let $s = size($l) | |
673 | 673 | let $acc0 = nil | |
674 | 674 | func $f1_1 ($a,$i) = if (($i >= $s)) | |
675 | 675 | then $a | |
676 | 676 | else producer($a, $l[$i]) | |
677 | 677 | ||
678 | 678 | func $f1_2 ($a,$i) = if (($i >= $s)) | |
679 | 679 | then $a | |
680 | 680 | else throw("List size exceeds 6") | |
681 | 681 | ||
682 | 682 | $f1_2($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($acc0, 0), 1), 2), 3), 4), 5), 6) | |
683 | 683 | } | |
684 | 684 | let newPack = makeString([currentPack[bpIdxLevel], currentPack[bpIdxRes], makeString(merged, "_"), makeString(bpProd, "_")], ":") | |
685 | 685 | let result = asString(invoke(stakingContract, "updateBackpack", [duckAssetId, newPack], nil)) | |
686 | 686 | $Tuple2(nil, result) | |
687 | 687 | } | |
688 | 688 | } | |
689 | 689 | } | |
690 | 690 | } | |
691 | 691 | } | |
692 | 692 | } | |
693 | 693 | else throw("Strict value is not equal to itself.") | |
694 | 694 | } | |
695 | 695 | ||
696 | 696 | ||
697 | 697 | ||
698 | 698 | @Callable(i) | |
699 | 699 | func setWarehouseOrder (cargoListStr,landAssetId) = { | |
700 | 700 | let user = i.originCaller | |
701 | 701 | let addr = toString(user) | |
702 | 702 | let result = if ((user != restContract)) | |
703 | 703 | then checkBlocked() | |
704 | 704 | else false | |
705 | 705 | let asset = value(assetInfo(fromBase58String(landAssetId))) | |
706 | 706 | if (!(isDefined(getInteger(stakingContract, keyStakedTimeByAssetId(landAssetId))))) | |
707 | 707 | then throw((("NFT " + asset.name) + " is not staked")) | |
708 | 708 | else { | |
709 | 709 | let owner = valueOrErrorMessage(getString(stakingContract, keyLandAssetIdToOwner(landAssetId)), (("NFT " + asset.name) + " is orphaned")) | |
710 | 710 | if (if ((user != restContract)) | |
711 | 711 | then (owner != addr) | |
712 | 712 | else false) | |
713 | 713 | then throw((LANDPREFIX + " is not yours")) | |
714 | 714 | else { | |
715 | 715 | let cargoParts = split_4C(cargoListStr, ":") | |
716 | 716 | if ((size(cargoParts) != 3)) | |
717 | 717 | then throw("cargoListStr should contain exactly 2 ':' separators") | |
718 | 718 | else { | |
719 | 719 | let resParts = split(cargoParts[0], "_") | |
720 | 720 | let matParts = split(cargoParts[1], "_") | |
721 | 721 | let prodParts = if ((cargoParts[2] == "")) | |
722 | 722 | then nil | |
723 | 723 | else split(cargoParts[2], "_") | |
724 | 724 | if ((size(resParts) != NUMRES)) | |
725 | 725 | then throw("All 6 resources should be passed") | |
726 | 726 | else if ((size(matParts) != NUMRES)) | |
727 | 727 | then throw("All 6 materials should be passed") | |
728 | 728 | else { | |
729 | 729 | let wh = asString(invoke(stakingContract, "getWarehouseREADONLY", [landAssetId], nil)) | |
730 | 730 | let currentWh = split_4C(wh, ":") | |
731 | 731 | let currWhRes = split(currentWh[whIdxRes], "_") | |
732 | 732 | let currWhMat = split(currentWh[whIdxMat], "_") | |
733 | 733 | let currWhProd = if ((currentWh[whIdxProd] == "")) | |
734 | 734 | then nil | |
735 | 735 | else split(currentWh[whIdxProd], "_") | |
736 | 736 | let loft = split(currentWh[whIdxLOFT], "_") | |
737 | 737 | let whOccupied = parseIntValue(loft[volOccupied]) | |
738 | 738 | let whFree = parseIntValue(loft[volFree]) | |
739 | 739 | let ordKey = keyOrderByLand(landAssetId) | |
740 | 740 | let currentOrd = getOrder(ordKey) | |
741 | 741 | let currentOrdRes = split(currentOrd[ordIdxRes], "_") | |
742 | 742 | let currentOrdMat = split(currentOrd[ordIdxMat], "_") | |
743 | 743 | let currentOrdProd = if ((currentOrd[ordIdxProd] == "")) | |
744 | 744 | then nil | |
745 | 745 | else split(currentOrd[ordIdxProd], "_") | |
746 | 746 | let usdtNeed2Lock = 0 | |
747 | 747 | let r = { | |
748 | 748 | let $l = resParts | |
749 | 749 | let $s = size($l) | |
750 | 750 | let $acc0 = $Tuple8(0, nil, 0, 0, 0, currWhRes, currentOrdRes, false) | |
751 | 751 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
752 | 752 | then $a | |
753 | 753 | else setCommon($a, $l[$i]) | |
754 | 754 | ||
755 | 755 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
756 | 756 | then $a | |
757 | 757 | else throw("List size exceeds 6") | |
758 | 758 | ||
759 | 759 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6) | |
760 | 760 | } | |
761 | 761 | let m = { | |
762 | 762 | let $l = matParts | |
763 | 763 | let $s = size($l) | |
764 | 764 | let $acc0 = $Tuple8(0, nil, r._3, r._4, r._5, currWhMat, currentOrdMat, false) | |
765 | 765 | func $f1_1 ($a,$i) = if (($i >= $s)) | |
766 | 766 | then $a | |
767 | 767 | else setCommon($a, $l[$i]) | |
768 | 768 | ||
769 | 769 | func $f1_2 ($a,$i) = if (($i >= $s)) | |
770 | 770 | then $a | |
771 | 771 | else throw("List size exceeds 6") | |
772 | 772 | ||
773 | 773 | $f1_2($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($acc0, 0), 1), 2), 3), 4), 5), 6) | |
774 | 774 | } | |
775 | 775 | let p = if ((size(prodParts) != 0)) | |
776 | 776 | then { | |
777 | 777 | let $l = prodParts | |
778 | 778 | let $s = size($l) | |
779 | 779 | let $acc0 = $Tuple8(0, nil, m._3, m._4, m._5, currWhProd, currentOrdProd, true) | |
780 | 780 | func $f2_1 ($a,$i) = if (($i >= $s)) | |
781 | 781 | then $a | |
782 | 782 | else setCommon($a, $l[$i]) | |
783 | 783 | ||
784 | 784 | func $f2_2 ($a,$i) = if (($i >= $s)) | |
785 | 785 | then $a | |
786 | 786 | else throw("List size exceeds 50") | |
787 | 787 | ||
788 | 788 | $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) | |
789 | 789 | } | |
790 | 790 | else $Tuple8(0, currWhProd, m._3, m._4, m._5, currWhProd, currentOrdProd, true) | |
791 | 791 | let buyVolSaldo = p._3 | |
792 | 792 | let sellVolSaldo = p._4 | |
793 | 793 | if ((buyVolSaldo > whFree)) | |
794 | 794 | then throw((((("Attempt to reserve " + toString(buyVolSaldo)) + " space for buy orders, but only ") + toString(whFree)) + " warehouse empty space left")) | |
795 | 795 | else if ((sellVolSaldo > whOccupied)) | |
796 | 796 | then throw((((("Attempt to lock " + toString(sellVolSaldo)) + " space for sell orders, but only ") + toString(whOccupied)) + " warehouse space occupied")) | |
797 | 797 | else { | |
798 | 798 | let whStr = makeString_2C([currentWh[whIdxLevels], makeString(r._2, "_"), makeString(m._2, "_"), makeString(p._2, "_"), toString((buyVolSaldo + sellVolSaldo))], ":") | |
799 | 799 | let whSave = invoke(stakingContract, "saveWarehouse", [whStr, landAssetId], nil) | |
800 | 800 | if ((whSave == whSave)) | |
801 | 801 | then { | |
802 | 802 | let usdSaldo = p._5 | |
803 | 803 | let actions = if ((usdSaldo > 0)) | |
804 | 804 | then if ((size(i.payments) != 1)) | |
805 | 805 | then throw("exactly 1 payment must be attached") | |
806 | 806 | else { | |
807 | 807 | let pmt = i.payments[0] | |
808 | 808 | let amt = pmt.amount | |
809 | 809 | let pmtAssetId = valueOrErrorMessage(pmt.assetId, "WAVES can't be used as payment") | |
810 | 810 | if ((pmtAssetId != usdtAssetId)) | |
811 | 811 | then throw("USDT payments only!") | |
812 | 812 | else if ((amt != usdSaldo)) | |
813 | 813 | then throw(("Payment needed is " + toString(usdSaldo))) | |
814 | 814 | else [StringEntry(ordKey, cargoListStr)] | |
815 | 815 | } | |
816 | 816 | else if ((usdSaldo == 0)) | |
817 | 817 | then if ((size(i.payments) != 0)) | |
818 | 818 | then throw("No payments needed") | |
819 | 819 | else [StringEntry(ordKey, cargoListStr)] | |
820 | 820 | else if ((size(i.payments) != 0)) | |
821 | 821 | then throw("No payments needed") | |
822 | 822 | else [ScriptTransfer(addressFromStringValue(owner), -(usdSaldo), usdtAssetId), StringEntry(ordKey, cargoListStr)] | |
823 | 823 | $Tuple2(actions, result) | |
824 | 824 | } | |
825 | 825 | else throw("Strict value is not equal to itself.") | |
826 | 826 | } | |
827 | 827 | } | |
828 | 828 | } | |
829 | 829 | } | |
830 | 830 | } | |
831 | 831 | } | |
832 | 832 | ||
833 | 833 | ||
834 | 834 | ||
835 | 835 | @Callable(i) | |
836 | 836 | func acceptWarehouseOrder (bpOrderStr,landAssetId,duckAssetId) = { | |
837 | 837 | let blocked = checkBlocked() | |
838 | 838 | if ((blocked == blocked)) | |
839 | 839 | then { | |
840 | 840 | let caller = i.originCaller | |
841 | 841 | let callerAddr = toString(caller) | |
842 | 842 | let stakedDuckAssetId = valueOrErrorMessage(getString(stakingContract, keyStakedDuckByOwner(callerAddr)), "You don't have a duck staked") | |
843 | 843 | let curLocation = valueOrElse(getString(stakingContract, keyDuckLocation(stakedDuckAssetId)), DEFAULTLOCATION) | |
844 | 844 | let loc = split(value(curLocation), "_") | |
845 | 845 | if ((loc[locIdxType] != "L")) | |
846 | 846 | then throw((("Duck location type is " + loc[locIdxType]) + ", but should be L")) | |
847 | 847 | else if ((stakedDuckAssetId != duckAssetId)) | |
848 | 848 | then throw(((("Your staked duck is " + stakedDuckAssetId) + ", but passed ") + duckAssetId)) | |
849 | 849 | else { | |
850 | 850 | let landAsset = value(assetInfo(fromBase58String(landAssetId))) | |
851 | 851 | if (!(isDefined(getInteger(stakingContract, keyStakedTimeByAssetId(landAssetId))))) | |
852 | 852 | then throw((("NFT " + landAsset.name) + " is not staked")) | |
853 | 853 | else { | |
854 | 854 | let landOwner = valueOrErrorMessage(getString(stakingContract, keyLandAssetIdToOwner(landAssetId)), (("NFT " + landAsset.name) + " is orphaned")) | |
855 | 855 | if ((landOwner == callerAddr)) | |
856 | 856 | then throw("You cannot trade with yourself") | |
857 | 857 | else { | |
858 | 858 | let bpOrderParts = split_4C(bpOrderStr, ":") | |
859 | 859 | if ((size(bpOrderParts) != 3)) | |
860 | 860 | then throw("bpOrderStr should contain exactly 2 ':' separators") | |
861 | 861 | else { | |
862 | 862 | let bpOrdRes = split(bpOrderParts[0], "_") | |
863 | 863 | let bpOrdMat = split(bpOrderParts[1], "_") | |
864 | 864 | let bpOrdProd = if ((bpOrderParts[2] == "")) | |
865 | 865 | then nil | |
866 | 866 | else split(bpOrderParts[2], "_") | |
867 | 867 | if ((size(bpOrdRes) != NUMRES)) | |
868 | 868 | then throw("All 6 resources should be passed") | |
869 | 869 | else if ((size(bpOrdMat) != NUMRES)) | |
870 | 870 | then throw("All 6 materials should be passed") | |
871 | 871 | else { | |
872 | 872 | let wh = asString(invoke(stakingContract, "getWarehouseREADONLY", [landAssetId], nil)) | |
873 | 873 | let currentWh = split_4C(wh, ":") | |
874 | 874 | let currWhRes = split(currentWh[whIdxRes], "_") | |
875 | 875 | let currWhMat = split(currentWh[whIdxMat], "_") | |
876 | 876 | let currWhProd = if ((currentWh[whIdxProd] == "")) | |
877 | 877 | then nil | |
878 | 878 | else split(currentWh[whIdxProd], "_") | |
879 | 879 | let currWhLockedVol = parseIntValue(split(currentWh[whIdxLOFT], "_")[volLocked]) | |
880 | 880 | let bpKey = keyBackpackByDuck(duckAssetId) | |
881 | 881 | let currentPack = getBackpack(bpKey) | |
882 | 882 | let bpResList = split(currentPack[bpIdxRes], "_") | |
883 | 883 | let bpMatList = split(currentPack[bpIdxMat], "_") | |
884 | 884 | let bpProdList = if ((currentPack[bpIdxProd] == "")) | |
885 | 885 | then nil | |
886 | 886 | else split(currentPack[bpIdxProd], "_") | |
887 | 887 | let ordKey = keyOrderByLand(landAssetId) | |
888 | 888 | let whOrd = getOrder(ordKey) | |
889 | 889 | let whOrdRes = split(whOrd[ordIdxRes], "_") | |
890 | 890 | let whOrdMat = split(whOrd[ordIdxMat], "_") | |
891 | 891 | let whOrdProd = if ((whOrd[ordIdxProd] == "")) | |
892 | 892 | then nil | |
893 | 893 | else split(whOrd[ordIdxProd], "_") | |
894 | 894 | let usdtNeed2Lock = 0 | |
895 | 895 | let r = { | |
896 | 896 | let $l = bpOrdRes | |
897 | 897 | let $s = size($l) | |
898 | 898 | let $acc0 = $Tuple12(nil, nil, nil, 0, 0, 0, 0, bpResList, currWhRes, whOrdRes, resTypes, false) | |
899 | 899 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
900 | 900 | then $a | |
901 | 901 | else acceptCommon($a, $l[$i]) | |
902 | 902 | ||
903 | 903 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
904 | 904 | then $a | |
905 | 905 | else throw("List size exceeds 6") | |
906 | 906 | ||
907 | 907 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6) | |
908 | 908 | } | |
909 | 909 | let m = { | |
910 | 910 | let $l = bpOrdMat | |
911 | 911 | let $s = size($l) | |
912 | 912 | let $acc0 = $Tuple12(nil, nil, nil, r._4, r._5, r._6, 0, bpMatList, currWhMat, whOrdMat, matTypes, false) | |
913 | 913 | func $f1_1 ($a,$i) = if (($i >= $s)) | |
914 | 914 | then $a | |
915 | 915 | else acceptCommon($a, $l[$i]) | |
916 | 916 | ||
917 | 917 | func $f1_2 ($a,$i) = if (($i >= $s)) | |
918 | 918 | then $a | |
919 | 919 | else throw("List size exceeds 6") | |
920 | 920 | ||
921 | 921 | $f1_2($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($acc0, 0), 1), 2), 3), 4), 5), 6) | |
922 | 922 | } | |
923 | 923 | let p = if ((size(bpOrdProd) != 0)) | |
924 | 924 | then { | |
925 | 925 | let $l = bpOrdProd | |
926 | 926 | let $s = size($l) | |
927 | 927 | let $acc0 = $Tuple12(nil, nil, nil, m._4, m._5, m._6, 0, bpProdList, currWhProd, whOrdProd, prodTypes, true) | |
928 | 928 | func $f2_1 ($a,$i) = if (($i >= $s)) | |
929 | 929 | then $a | |
930 | 930 | else acceptCommon($a, $l[$i]) | |
931 | 931 | ||
932 | 932 | func $f2_2 ($a,$i) = if (($i >= $s)) | |
933 | 933 | then $a | |
934 | 934 | else throw("List size exceeds 50") | |
935 | 935 | ||
936 | 936 | $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) | |
937 | 937 | } | |
938 | 938 | else $Tuple12(currWhProd, whOrdProd, bpProdList, m._4, m._5, m._6, 0, bpProdList, currWhProd, whOrdProd, prodTypes, true) | |
939 | 939 | let volSaldo = p._4 | |
940 | 940 | let newLockedVol = if ((0 > (currWhLockedVol - volSaldo))) | |
941 | 941 | then 0 | |
942 | 942 | else (currWhLockedVol - volSaldo) | |
943 | 943 | let whStr = makeString_2C([currentWh[whIdxLevels], makeString(r._1, "_"), makeString(m._1, "_"), makeString(p._1, "_"), toString(newLockedVol)], ":") | |
944 | 944 | let newWhOrdStr = makeString_2C([makeString(r._2, "_"), makeString(m._2, "_"), makeString(p._2, "_")], ":") | |
945 | 945 | let newBpStr = makeString_2C([currentPack[bpIdxLevel], makeString(r._3, "_"), makeString(m._3, "_"), makeString(p._3, "_")], ":") | |
946 | 946 | let whSave = invoke(stakingContract, "saveWarehouse", [whStr, landAssetId], nil) | |
947 | 947 | if ((whSave == whSave)) | |
948 | 948 | then { | |
949 | 949 | let bpSave = invoke(stakingContract, "updateBackpack", [duckAssetId, newBpStr], nil) | |
950 | 950 | if ((bpSave == bpSave)) | |
951 | 951 | then { | |
952 | 952 | let actions = [StringEntry(ordKey, newWhOrdStr)] | |
953 | 953 | let usdWh2BpSaldo = p._5 | |
954 | 954 | let actions1 = if ((usdWh2BpSaldo > 0)) | |
955 | 955 | then { | |
956 | 956 | let usdWh2BpFee = fraction(p._5, AUCTIONFEE, MULT6) | |
957 | 957 | let refByKey = keyAddressRefBy(callerAddr) | |
958 | 958 | let refBy = getString(stakingContract, refByKey) | |
959 | 959 | if (isDefined(refBy)) | |
960 | 960 | then (((actions :+ ScriptTransfer(caller, (p._5 - (3 * usdWh2BpFee)), usdtAssetId)) :+ ScriptTransfer(restContract, usdWh2BpFee, usdtAssetId)) :+ ScriptTransfer(addressFromStringValue(value(refBy)), usdWh2BpFee, usdtAssetId)) | |
961 | 961 | else ((actions :+ ScriptTransfer(caller, (p._5 - (3 * usdWh2BpFee)), usdtAssetId)) :+ ScriptTransfer(restContract, usdWh2BpFee, usdtAssetId)) | |
962 | 962 | } | |
963 | 963 | else actions | |
964 | 964 | let usdBp2WhSaldo = p._6 | |
965 | 965 | if ((usdBp2WhSaldo > 0)) | |
966 | 966 | then if ((size(i.payments) != 1)) | |
967 | 967 | then throw("exactly 1 payment must be attached") | |
968 | 968 | else { | |
969 | 969 | let pmt = i.payments[0] | |
970 | 970 | let amt = pmt.amount | |
971 | 971 | let pmtAssetId = valueOrErrorMessage(pmt.assetId, "WAVES can't be used as payment") | |
972 | 972 | if ((pmtAssetId != usdtAssetId)) | |
973 | 973 | then throw("USDT payments only!") | |
974 | 974 | else if ((amt != usdBp2WhSaldo)) | |
975 | 975 | then throw(("Payment needed is " + toString(usdBp2WhSaldo))) | |
976 | 976 | else if ((MINSHOPPAYMENT > amt)) | |
977 | 977 | then throw(("Payment should be at least " + toString(MINSHOPPAYMENT))) | |
978 | 978 | else { | |
979 | 979 | let usdBp2WhFee = fraction(p._6, AUCTIONFEE, MULT6) | |
980 | 980 | let refByKey = keyAddressRefBy(landOwner) | |
981 | 981 | let refBy = getString(stakingContract, refByKey) | |
982 | 982 | if (isDefined(refBy)) | |
983 | 983 | then (((actions1 :+ ScriptTransfer(addressFromStringValue(landOwner), (p._6 - (3 * usdBp2WhFee)), usdtAssetId)) :+ ScriptTransfer(restContract, usdBp2WhFee, usdtAssetId)) :+ ScriptTransfer(addressFromStringValue(value(refBy)), usdBp2WhFee, usdtAssetId)) | |
984 | 984 | else ((actions1 :+ ScriptTransfer(addressFromStringValue(landOwner), (p._6 - (3 * usdBp2WhFee)), usdtAssetId)) :+ ScriptTransfer(restContract, usdBp2WhFee, usdtAssetId)) | |
985 | 985 | } | |
986 | 986 | } | |
987 | 987 | else if ((size(i.payments) != 0)) | |
988 | 988 | then throw("No payments needed") | |
989 | 989 | else actions1 | |
990 | 990 | } | |
991 | 991 | else throw("Strict value is not equal to itself.") | |
992 | 992 | } | |
993 | 993 | else throw("Strict value is not equal to itself.") | |
994 | 994 | } | |
995 | 995 | } | |
996 | 996 | } | |
997 | 997 | } | |
998 | 998 | } | |
999 | 999 | } | |
1000 | 1000 | else throw("Strict value is not equal to itself.") | |
1001 | 1001 | } | |
1002 | 1002 | ||
1003 | 1003 |
github/deemru/w8io/026f985 127.16 ms ◑