tx · 2GAjtyLj88beJnhyWe4iLjFazENSowTdnEqBa9s5eHJ7 3N61Cvq5XcnPk9rxpy2Rnp3bSr4syNGUJph: -0.01400000 Waves 2021.11.05 17:20 [1777798] smart account 3N61Cvq5XcnPk9rxpy2Rnp3bSr4syNGUJph > SELF 0.00000000 Waves
{ "type": 13, "id": "2GAjtyLj88beJnhyWe4iLjFazENSowTdnEqBa9s5eHJ7", "fee": 1400000, "feeAssetId": null, "timestamp": 1636122046601, "version": 2, "chainId": 84, "sender": "3N61Cvq5XcnPk9rxpy2Rnp3bSr4syNGUJph", "senderPublicKey": "G7cNXePvAHUHmZfXa1eHnvFeH6DuykPC5wm9v9djTKgD", "proofs": [ "4QU3mt2UTpiPBUTHzr2bnpf5wPjp9bGg9MHdKXv9LZzy152dUfhok912MHXn6UxYQkzi9ZhFJdGkSkFmmiVTu5VV" ], "script": "base64:AAIFAAAAAAAAABkIAhIAEgYKBBgYGBESABIDCgEIEgQKAggBAAAAAwAAAAAKZGVwb3NpdEZlZQAAAAAAAAAD6AAAAAANY29udHJvbGxlckZlZQAAAAAAAAAnEAAAAAALcGxhdGZvcm1GZWUAAAAAAAAAJxAAAAAFAAAAAmE4AQAAAARpbml0AAAAAAkABEwAAAACCQEAAAAMSW50ZWdlckVudHJ5AAAAAgIAAAAxM1BQSDd4N2lxb2JXNXppeWlSQ2ljMTlyUXFLcjZuUFlhSzFfYXNzZXRfYmFsYW5jZQAAAAAAAG3UrQUAAAADbmlsAAAAAWkBAAAACGFkZFBvb2xzAAAABAAAAAVwb29scwAAAA9saXF1aWRpdHlUb2tlbnMAAAANc2VydmljZVRva2VucwAAABZsaXF1aWRpdHlUb2tlbkRlY2ltYWxzCgEAAAAQZ2VuZXJhdGVQb29sS2V5cwAAAAIAAAALYWNjdW11bGF0ZWQAAAAEcG9vbAkABEwAAAACCQEAAAAMSW50ZWdlckVudHJ5AAAAAgkAASwAAAACBQAAAARwb29sAgAAAA5fYXNzZXRfYmFsYW5jZQAAAAAAA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aWwJAAACAAAAAQIAAAAmWW91IGhhdmUgbm90IHN1Y2ggYmFsYW5jZSBmb3Igd2l0aGRyYXcAAAABAAAAAmI2AQAAAAJiNwAAAAAJAAH0AAAAAwgFAAAAAmI2AAAACWJvZHlCeXRlcwkAAZEAAAACCAUAAAACYjYAAAAGcHJvb2ZzAAAAAAAAAAAACAUAAAACYjYAAAAPc2VuZGVyUHVibGljS2V5gbnptw==", "height": 1777798, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: GUc8TqPWiw85D4e3VpTuoQMkJxE6PZZ3kmLPiTf6TPv9 Next: AJtyQqfcBfweA2uoLAqTnXu8ZjtgDZothrZugZtC61Bi Diff:
Old | New | Differences | |
---|---|---|---|
88 | 88 | ||
89 | 89 | 2(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20) | |
90 | 90 | } | |
91 | - | | |
91 | + | poolServiceTokenKeys | |
92 | 92 | } | |
93 | 93 | ||
94 | 94 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let depositFee = 1000 | |
5 | 5 | ||
6 | 6 | let controllerFee = 10000 | |
7 | 7 | ||
8 | 8 | let platformFee = 10000 | |
9 | 9 | ||
10 | 10 | @Callable(a8) | |
11 | 11 | func init () = [IntegerEntry("3PPH7x7iqobW5ziyiRCic19rQqKr6nPYaK1_asset_balance", 7197869)] | |
12 | 12 | ||
13 | 13 | ||
14 | 14 | ||
15 | 15 | @Callable(i) | |
16 | 16 | func addPools (pools,liquidityTokens,serviceTokens,liquidityTokenDecimals) = { | |
17 | 17 | func generatePoolKeys (accumulated,pool) = IntegerEntry((pool + "_asset_balance"), 0) :: accumulated | |
18 | 18 | ||
19 | 19 | func generatePoolLiquidityTokenKeys (accumulated,pool) = { | |
20 | 20 | let poolIndex = value(indexOf(pools, pool)) | |
21 | 21 | let liquidityToken = liquidityTokens[poolIndex] | |
22 | 22 | StringEntry((pool + "_liquidity_token"), liquidityToken) | |
23 | 23 | } | |
24 | 24 | ||
25 | 25 | func generatePoolServiceTokenKeys (accumulated,pool) = throw("DApp is inactive at this moment") | |
26 | 26 | ||
27 | 27 | func generatePoolLiquidityTokenDecimalKeys (accumulated,pool) = { | |
28 | 28 | let poolIndex = value(indexOf(pools, pool)) | |
29 | 29 | let liquidityToken = liquidityTokenDecimals[poolIndex] | |
30 | 30 | IntegerEntry((pool + "_service_token"), liquidityToken) | |
31 | 31 | } | |
32 | 32 | ||
33 | 33 | func generatePoolActiveKeys (accumulated,pool) = BooleanEntry((pool + "_active"), true) | |
34 | 34 | ||
35 | 35 | let poolLiquidityTokenKeys = { | |
36 | 36 | let $l = pools | |
37 | 37 | let $s = size($l) | |
38 | 38 | let $acc0 = nil | |
39 | 39 | func 1 ($a,$i) = if (($i >= $s)) | |
40 | 40 | then $a | |
41 | 41 | else generatePoolLiquidityTokenKeys($a, $l[$i]) | |
42 | 42 | ||
43 | 43 | func 2 ($a,$i) = if (($i >= $s)) | |
44 | 44 | then $a | |
45 | 45 | else throw("List size exceeds 20") | |
46 | 46 | ||
47 | 47 | 2(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20) | |
48 | 48 | } | |
49 | 49 | let poolServiceTokenKeys = { | |
50 | 50 | let $l = pools | |
51 | 51 | let $s = size($l) | |
52 | 52 | let $acc0 = nil | |
53 | 53 | func 1 ($a,$i) = if (($i >= $s)) | |
54 | 54 | then $a | |
55 | 55 | else generatePoolServiceTokenKeys($a, $l[$i]) | |
56 | 56 | ||
57 | 57 | func 2 ($a,$i) = if (($i >= $s)) | |
58 | 58 | then $a | |
59 | 59 | else throw("List size exceeds 20") | |
60 | 60 | ||
61 | 61 | 2(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20) | |
62 | 62 | } | |
63 | 63 | let poolLiquidityTokenDecimalKeys = { | |
64 | 64 | let $l = pools | |
65 | 65 | let $s = size($l) | |
66 | 66 | let $acc0 = nil | |
67 | 67 | func 1 ($a,$i) = if (($i >= $s)) | |
68 | 68 | then $a | |
69 | 69 | else generatePoolLiquidityTokenDecimalKeys($a, $l[$i]) | |
70 | 70 | ||
71 | 71 | func 2 ($a,$i) = if (($i >= $s)) | |
72 | 72 | then $a | |
73 | 73 | else throw("List size exceeds 20") | |
74 | 74 | ||
75 | 75 | 2(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20) | |
76 | 76 | } | |
77 | 77 | let poolActiveKeys = { | |
78 | 78 | let $l = pools | |
79 | 79 | let $s = size($l) | |
80 | 80 | let $acc0 = nil | |
81 | 81 | func 1 ($a,$i) = if (($i >= $s)) | |
82 | 82 | then $a | |
83 | 83 | else generatePoolActiveKeys($a, $l[$i]) | |
84 | 84 | ||
85 | 85 | func 2 ($a,$i) = if (($i >= $s)) | |
86 | 86 | then $a | |
87 | 87 | else throw("List size exceeds 20") | |
88 | 88 | ||
89 | 89 | 2(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20) | |
90 | 90 | } | |
91 | - | | |
91 | + | poolServiceTokenKeys | |
92 | 92 | } | |
93 | 93 | ||
94 | 94 | ||
95 | 95 | ||
96 | 96 | @Callable(a8) | |
97 | 97 | func call () = { | |
98 | 98 | let a9 = Issue("Asset1", "Asset from dApp", 100000, 2, true, unit, 0) | |
99 | 99 | let b1 = calculateAssetId(a9) | |
100 | 100 | [BinaryEntry("bin", base58''), BooleanEntry("bool", true), IntegerEntry("int", 1), StringEntry("str", ""), DeleteEntry("str"), a9] | |
101 | 101 | } | |
102 | 102 | ||
103 | 103 | ||
104 | 104 | ||
105 | 105 | @Callable(i) | |
106 | 106 | func deposit (pool) = { | |
107 | 107 | let amount = i.payments[0].amount | |
108 | 108 | let assetId = i.payments[0].assetId | |
109 | 109 | let poolAmountKey = (pool + "_asset_balance") | |
110 | 110 | let userAddress = toString(i.caller) | |
111 | 111 | let userPoolAmountKey = (((pool + "_") + userAddress) + "_asset_balance") | |
112 | 112 | let dAppAssetAddress = getStringValue(this, (pool + "_service_token")) | |
113 | 113 | let poolAmount = getIntegerValue(this, poolAmountKey) | |
114 | 114 | let userAmount = match getInteger(userPoolAmountKey) { | |
115 | 115 | case int: Int => | |
116 | 116 | int | |
117 | 117 | case nothing => | |
118 | 118 | 0 | |
119 | 119 | } | |
120 | 120 | let newPoolAmount = (poolAmount + amount) | |
121 | 121 | let userAmountWithoutFee = ((amount - fraction(amount, 1, depositFee, HALFUP)) - fraction(amount, 1, controllerFee, HALFUP)) | |
122 | 122 | let newUserPoolAmount = (userAmount + userAmountWithoutFee) | |
123 | 123 | [Reissue(fromBase58String(dAppAssetAddress), userAmountWithoutFee, true), ScriptTransfer(i.caller, userAmountWithoutFee, fromBase58String(dAppAssetAddress)), IntegerEntry(poolAmountKey, newPoolAmount), IntegerEntry(userPoolAmountKey, newUserPoolAmount)] | |
124 | 124 | } | |
125 | 125 | ||
126 | 126 | ||
127 | 127 | ||
128 | 128 | @Callable(i) | |
129 | 129 | func withdraw (pool,userEarned) = { | |
130 | 130 | let amount = i.payments[0].amount | |
131 | 131 | let assetId = i.payments[0].assetId | |
132 | 132 | let poolAmountKey = (pool + "_asset_balance") | |
133 | 133 | let userAddress = toString(i.caller) | |
134 | 134 | let userPoolAmountKey = (((pool + "_") + userAddress) + "_asset_balance") | |
135 | 135 | let userPoolEarnedKey = (((pool + "_") + userAddress) + "_earned") | |
136 | 136 | let poolAmount = getIntegerValue(this, poolAmountKey) | |
137 | 137 | let userAmount = match getInteger(userPoolAmountKey) { | |
138 | 138 | case int: Int => | |
139 | 139 | int | |
140 | 140 | case nothing => | |
141 | 141 | 0 | |
142 | 142 | } | |
143 | 143 | let userEarnedBefore = match getInteger(userPoolEarnedKey) { | |
144 | 144 | case int: Int => | |
145 | 145 | int | |
146 | 146 | case nothing => | |
147 | 147 | 0 | |
148 | 148 | } | |
149 | 149 | let liquidutyAssetAddress = getStringValue(this, (pool + "_liquidity_token")) | |
150 | 150 | let liquidityTokenDecimal = match assetInfo(fromBase58String(liquidutyAssetAddress)) { | |
151 | 151 | case asset: Asset => | |
152 | 152 | asset.decimals | |
153 | 153 | case _ => | |
154 | 154 | throw("Can't find asset") | |
155 | 155 | } | |
156 | 156 | let dAppAssetAddress = getStringValue(this, (pool + "_service_token")) | |
157 | 157 | let userEarnedTotal = (userEarned + userEarnedBefore) | |
158 | 158 | let amountWithoutFee = ((amount - fraction(amount, 1, platformFee, HALFUP)) - fraction(amount, 1, controllerFee, HALFUP)) | |
159 | 159 | let newPoolAmount = (poolAmount - amountWithoutFee) | |
160 | 160 | if ((userAmount >= amount)) | |
161 | 161 | then { | |
162 | 162 | let newUserPoolAmount = (userAmount - amountWithoutFee) | |
163 | 163 | [Burn(fromBase58String(dAppAssetAddress), amountWithoutFee), ScriptTransfer(i.caller, amountWithoutFee, fromBase58String(liquidutyAssetAddress)), IntegerEntry(poolAmountKey, newPoolAmount), IntegerEntry(userPoolAmountKey, newUserPoolAmount), IntegerEntry(userPoolEarnedKey, userEarnedTotal)] | |
164 | 164 | } | |
165 | 165 | else throw("You have not such balance for withdraw") | |
166 | 166 | } | |
167 | 167 | ||
168 | 168 | ||
169 | 169 | @Verifier(b6) | |
170 | 170 | func b7 () = sigVerify(b6.bodyBytes, b6.proofs[0], b6.senderPublicKey) | |
171 | 171 |
github/deemru/w8io/026f985 37.83 ms ◑