tx · 3YVrBpMdeue8LMRXdrhZwr3vW45Q3Siw9ihamSgkfWw6

3Mu7VYYXCdKzYgHbTRTiR2GcmRjdKwpcXtx:  -0.01400000 Waves

2019.11.15 14:46 [766153] smart account 3Mu7VYYXCdKzYgHbTRTiR2GcmRjdKwpcXtx > SELF 0.00000000 Waves

{ "type": 13, "id": "3YVrBpMdeue8LMRXdrhZwr3vW45Q3Siw9ihamSgkfWw6", "fee": 1400000, "feeAssetId": null, "timestamp": 1573818311080, "version": 1, "sender": "3Mu7VYYXCdKzYgHbTRTiR2GcmRjdKwpcXtx", "senderPublicKey": "7hst8L8bJqbcGbPC9DbHZ5E83dQ3LXayYttNsUbgZt7r", "proofs": [ "DD7rfKZJYPc2ExmJrxSE8nNfnLkH7cWwQoA9HWayEqFwgD438HkDGciUvZ9BP7LhJ2Lhcj22gZCjSeQuLrxYMA6" ], "script": "base64:AAIDAAAAAAAAAA0IARIECgICARIDCgEIAAAAMgAAAAAFV0FWRVMAAAAAAAX14QAAAAAAA1VTRAAAAAAAAAAAZAAAAAAUcm9vdEFjY291bnRQdWJsaWNLZXkBAAAAIKtxg1qvacBtqcfHnm9nzu1j4fM2f8KAlLVKano9cMMVAAAAAA5saWdhQ29tbWlzc2lvbgAAAAAAAAAABgAAAAAVdG90YWxBc3NldHNQZXJPdXRjb21lAAAAAAAAACcQAAAAABpwcmVzYWxlTWF4QXNzZXRzUGVyT3V0Y29tZQAAAAAAAAALuAAAAAAPZXZlbnRDdXJyZW5jeUlkAQAAACCzq+2OuNxhJLJhVt602yIUBLswcJEXYkm4f70ULNMzNwAAAAAMcHJlc2FsZVByaWNlAAAAAAAAAAAyAAAAAAlsaXZlUHJpY2UAAAAAAAAAAGQAAAAADWxpdmVQcmljZVN0ZXAAAAAAAAAAABQAAAAAE2xpdmVQcmljZVN0ZXBQZXJpb2QAAAAAAAAAA+gAAAAACXN0YXR1c0tleQIAAAAGc3RhdHVzAAAAAAtwYXVzZVN0YXR1cwIAAAAFcGF1c2U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chainId": 84, "height": 766153, "spentComplexity": 0 } View: original | compacted Prev: Emfa2tfzvpTE3ndbcsTJBJ8qo5rcHgsWwj3v7NJkLzqj Next: none Diff:
OldNewDifferences
11 {-# STDLIB_VERSION 3 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
4-let buyOutcomeTokenTxFee = 500000
5-
64 let WAVES = 100000000
75
86 let USD = 100
97
108 let rootAccountPublicKey = base58'CYF7FumpbZzyHMFuFQRQfo9XC9veJemd3XuBkusRCcAg'
119
12-let ligaCommission = 0
10+let ligaCommission = 6
1311
1412 let totalAssetsPerOutcome = 10000
1513
1715
1816 let eventCurrencyId = base58'D6N2rAqWN6ZCWnCeNFWLGqqjS6nJLeK4m19XiuhdDenr'
1917
20-let presalePrice = 1000
18+let presalePrice = 50
2119
22-let livePrice = 5000
20+let livePrice = 100
2321
24-let livePriceStep = 500
22+let livePriceStep = 20
2523
26-let livePriceStepPeriod = 100
24+let livePriceStepPeriod = 1000
2725
2826 let statusKey = "status"
2927
144142 }
145143
146144
147-func getRateWAVESInUSD () = 50
148-
149-
150-func calculateFeeInEventPaymentAsset () = ((buyOutcomeTokenTxFee * getRateWAVESInUSD()) / USD)
151-
152-
153145 func sum (n) = {
154146 let x = (n / livePriceStepPeriod)
155147 let fullSum = arithmeticSeries(livePrice, livePriceStep, x)
178170 func amountToPay (alreadySold,amountToBuy) = (sum((alreadySold + amountToBuy)) - sum(alreadySold))
179171
180172
181-func presaleStrategy (customerAddress,outcomeAssetId,paymentAmount,outcomeAmountToBuy,outcomeAmountEventBalance,fee) = {
173+func presaleStrategy (customerAddress,outcomeAssetId,paymentAmount,outcomeAmountToBuy,outcomeAmountEventBalance) = {
182174 let outcomeAmountAlreadySold = (totalAssetsPerOutcome - outcomeAmountEventBalance)
183175 let outcomeAmountAvailableInPresalePeriod = (presaleMaxAssetsPerOutcome - outcomeAmountAlreadySold)
184- let outcomeRequiredPaymentAmount = ((presalePrice * outcomeAmountToBuy) + fee)
176+ let outcomeRequiredPaymentAmount = (presalePrice * outcomeAmountToBuy)
185177 if ((outcomeAmountToBuy > outcomeAmountAvailableInPresalePeriod))
186178 then throwNotEnoughOutcomeAssetsInPresaleStockError(outcomeAmountToBuy, outcomeAmountAvailableInPresalePeriod)
187179 else if ((paymentAmount != outcomeRequiredPaymentAmount))
191183 let currentPresaleOutcomeAmountSales = getPresaleOutcomeAmountSales(outcomeAssetId)
192184 let newPresaleOutcomeAmountSales = (currentPresaleOutcomeAmountSales + outcomeAmountToBuy)
193185 let writeSet = WriteSet([DataEntry(presaleOutcomeAmountSalesKey, newPresaleOutcomeAmountSales)])
194- let transferSet = TransferSet([ScriptTransfer(customerAddress, buyOutcomeTokenTxFee, unit), ScriptTransfer(customerAddress, outcomeAmountToBuy, outcomeAssetId)])
186+ let transferSet = TransferSet([ScriptTransfer(customerAddress, outcomeAmountToBuy, outcomeAssetId)])
195187 ScriptResult(writeSet, transferSet)
196188 }
197189 }
198190
199191
200-func saleStrategy (customerAddress,outcomeAssetId,paymentAmount,outcomeAmountToBuy,outcomeAmountEventBalance,fee) = {
192+func saleStrategy (customerAddress,outcomeAssetId,paymentAmount,outcomeAmountToBuy,outcomeAmountEventBalance) = {
201193 let presaleOutcomeAmountSales = getPresaleOutcomeAmountSales(outcomeAssetId)
202194 let outcomeAmountAlreadySold = ((totalAssetsPerOutcome - presaleOutcomeAmountSales) - outcomeAmountEventBalance)
203- let outcomeRequiredPaymentAmount = (amountToPay(outcomeAmountAlreadySold, outcomeAmountToBuy) + fee)
195+ let outcomeRequiredPaymentAmount = amountToPay(outcomeAmountAlreadySold, outcomeAmountToBuy)
204196 if ((outcomeAmountToBuy > outcomeAmountEventBalance))
205197 then throwNotEnoughOutcomeAssetsInSaleStockError(outcomeAmountToBuy, outcomeAmountEventBalance)
206198 else if ((paymentAmount != outcomeRequiredPaymentAmount))
207199 then throwInsufficientPaymentError(paymentAmount, outcomeRequiredPaymentAmount)
208- else TransferSet([ScriptTransfer(customerAddress, buyOutcomeTokenTxFee, unit), ScriptTransfer(customerAddress, outcomeAmountToBuy, outcomeAssetId)])
200+ else TransferSet([ScriptTransfer(customerAddress, outcomeAmountToBuy, outcomeAssetId)])
209201 }
210202
211203
212204 @Callable(i)
213205 func buyOutcomeToken (outcomeAssetId,outcomeAmountToBuy) = {
214- let fee = calculateFeeInEventPaymentAsset()
215206 let customerAddress = i.caller
216207 let outcomeAmountEventBalance = assetBalance(this, outcomeAssetId)
217208 let status = getStatus()
231222 else if (!(isSalesAvailable))
232223 then throwSalesIsNotAvailableInStatusError(status)
233224 else if (isPresaleStatus)
234- then presaleStrategy(customerAddress, outcomeAssetId, paymentAmount, outcomeAmountToBuy, outcomeAmountEventBalance, fee)
225+ then presaleStrategy(customerAddress, outcomeAssetId, paymentAmount, outcomeAmountToBuy, outcomeAmountEventBalance)
235226 else if (isLiveStatus)
236- then saleStrategy(customerAddress, outcomeAssetId, paymentAmount, outcomeAmountToBuy, outcomeAmountEventBalance, fee)
227+ then saleStrategy(customerAddress, outcomeAssetId, paymentAmount, outcomeAmountToBuy, outcomeAmountEventBalance)
237228 else throwUndefinedError()
238229 }
239230
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 3 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
4-let buyOutcomeTokenTxFee = 500000
5-
64 let WAVES = 100000000
75
86 let USD = 100
97
108 let rootAccountPublicKey = base58'CYF7FumpbZzyHMFuFQRQfo9XC9veJemd3XuBkusRCcAg'
119
12-let ligaCommission = 0
10+let ligaCommission = 6
1311
1412 let totalAssetsPerOutcome = 10000
1513
1614 let presaleMaxAssetsPerOutcome = 3000
1715
1816 let eventCurrencyId = base58'D6N2rAqWN6ZCWnCeNFWLGqqjS6nJLeK4m19XiuhdDenr'
1917
20-let presalePrice = 1000
18+let presalePrice = 50
2119
22-let livePrice = 5000
20+let livePrice = 100
2321
24-let livePriceStep = 500
22+let livePriceStep = 20
2523
26-let livePriceStepPeriod = 100
24+let livePriceStepPeriod = 1000
2725
2826 let statusKey = "status"
2927
3028 let pauseStatus = "pause"
3129
3230 let presaleStatus = "presale"
3331
3432 let liveStatus = "live"
3533
3634 let completeStatus = "complete"
3735
3836 let payoutStatus = "payout"
3937
4038 func throwSalesIsNotAvailableInStatusError (status) = throw((("salesIsNotAvailableInStatusError" + ",") + status))
4139
4240
4341 func throwNonexistentOutcomeAssetError (outcomeAssetId) = throw(("nonexistentOutcomeAssetError," + toBase58String(outcomeAssetId)))
4442
4543
4644 func throwNotEnoughOutcomeAssetsInPresaleStockError (amountToBuy,balance) = throw((((("notEnoughOutcomeAssetsInPresaleStockError" + ",") + toString(balance)) + ",") + toString(amountToBuy)))
4745
4846
4947 func throwNotEnoughOutcomeAssetsInSaleStockError (amountToBuy,balance) = throw((((("notEnoughOutcomeAssetsInSaleStockError" + ",") + toString(balance)) + ",") + toString(amountToBuy)))
5048
5149
5250 func throwUnsupportedEventPaymentAssetError (paymentCurrency) = throw((((("unsupportedEventPaymentAssetError" + ",") + toBase58String(eventCurrencyId)) + ",") + toBase58String(paymentCurrency)))
5351
5452
5553 func throwInsufficientPaymentError (receivedPaymentAmount,expectedPaymentAmount) = throw((((("insufficientPaymentError" + ",") + toString(expectedPaymentAmount)) + ",") + toString(receivedPaymentAmount)))
5654
5755
5856 func throwUnsupportedEventStatusError () = throw("unsupportedEventStatusError")
5957
6058
6159 func throwIsNotRootCallerError () = throw("isNotRootCallerError")
6260
6361
6462 let noPaymentError = "noPaymentError"
6563
6664 func throwUndefinedError () = throw("undefinedError")
6765
6866
6967 func getIntOr (key,default) = if (isDefined(getInteger(this, key)))
7068 then getIntegerValue(this, key)
7169 else default
7270
7371
7472 func getStringOr (key,default) = if (isDefined(getInteger(this, key)))
7573 then getStringValue(this, key)
7674 else default
7775
7876
7977 func getInt (key) = getIntegerValue(this, key)
8078
8179
8280 func setInt (key,value) = DataEntry(key, value)
8381
8482
8583 func getStr (key) = getStringValue(this, key)
8684
8785
8886 func setStr (key,value) = DataEntry(key, value)
8987
9088
9189 func setBytes (key,value) = DataEntry(key, value)
9290
9391
9492 func getBytes (key) = getBinaryValue(this, key)
9593
9694
9795 func isSupportedStatus (status) = if (if (if (if ((status == pauseStatus))
9896 then true
9997 else (status == presaleStatus))
10098 then true
10199 else (status == liveStatus))
102100 then true
103101 else (status == completeStatus))
104102 then true
105103 else (status == payoutStatus)
106104
107105
108106 func getStatus () = getStr(statusKey)
109107
110108
111109 func setStatus (status) = setStr(statusKey, status)
112110
113111
114112 func getPayment (i) = valueOrErrorMessage(i.payment, noPaymentError)
115113
116114
117115 func getPaymentAssetId (payment) = match payment.assetId {
118116 case assetId: ByteVector =>
119117 assetId
120118 case assetId: Unit =>
121119 fromBase58String("WAVES")
122120 case _ =>
123121 throw()
124122 }
125123
126124
127125 func getIntegerFromAccount (accountAddress,key) = match getInteger(accountAddress, key) {
128126 case i: Int =>
129127 i
130128 case _ =>
131129 0
132130 }
133131
134132
135133 func arithmeticSeries (a,d,n) = ((n * ((2 * a) + ((n - 1) * d))) / 2)
136134
137135
138136 func getPresaleOutcomeAmountSalesKey (outcomeAssetId) = ("presaleOutcomeAmountSales_" + toBase58String(outcomeAssetId))
139137
140138
141139 func getPresaleOutcomeAmountSales (outcomeAssetId) = {
142140 let presaleOutcomeAmountSalesKey = getPresaleOutcomeAmountSalesKey(outcomeAssetId)
143141 getIntegerFromAccount(this, presaleOutcomeAmountSalesKey)
144142 }
145143
146144
147-func getRateWAVESInUSD () = 50
148-
149-
150-func calculateFeeInEventPaymentAsset () = ((buyOutcomeTokenTxFee * getRateWAVESInUSD()) / USD)
151-
152-
153145 func sum (n) = {
154146 let x = (n / livePriceStepPeriod)
155147 let fullSum = arithmeticSeries(livePrice, livePriceStep, x)
156148 ((fullSum * livePriceStepPeriod) + ((arithmeticSeries(livePrice, livePriceStep, (x + 1)) - fullSum) * (n % livePriceStepPeriod)))
157149 }
158150
159151
160152 func isRootCaller (i) = {
161153 let callerAccountPubKey = toBase58String(i.callerPublicKey)
162154 let rootAccountPubKey = toBase58String(rootAccountPublicKey)
163155 if ((callerAccountPubKey == rootAccountPubKey))
164156 then true
165157 else false
166158 }
167159
168160
169161 func isAdminCaller (i) = {
170162 let callerAccountPubKey = toBase58String(i.callerPublicKey)
171163 let rootAccountPubKey = toBase58String(rootAccountPublicKey)
172164 if ((callerAccountPubKey == rootAccountPubKey))
173165 then true
174166 else false
175167 }
176168
177169
178170 func amountToPay (alreadySold,amountToBuy) = (sum((alreadySold + amountToBuy)) - sum(alreadySold))
179171
180172
181-func presaleStrategy (customerAddress,outcomeAssetId,paymentAmount,outcomeAmountToBuy,outcomeAmountEventBalance,fee) = {
173+func presaleStrategy (customerAddress,outcomeAssetId,paymentAmount,outcomeAmountToBuy,outcomeAmountEventBalance) = {
182174 let outcomeAmountAlreadySold = (totalAssetsPerOutcome - outcomeAmountEventBalance)
183175 let outcomeAmountAvailableInPresalePeriod = (presaleMaxAssetsPerOutcome - outcomeAmountAlreadySold)
184- let outcomeRequiredPaymentAmount = ((presalePrice * outcomeAmountToBuy) + fee)
176+ let outcomeRequiredPaymentAmount = (presalePrice * outcomeAmountToBuy)
185177 if ((outcomeAmountToBuy > outcomeAmountAvailableInPresalePeriod))
186178 then throwNotEnoughOutcomeAssetsInPresaleStockError(outcomeAmountToBuy, outcomeAmountAvailableInPresalePeriod)
187179 else if ((paymentAmount != outcomeRequiredPaymentAmount))
188180 then throwInsufficientPaymentError(paymentAmount, outcomeRequiredPaymentAmount)
189181 else {
190182 let presaleOutcomeAmountSalesKey = getPresaleOutcomeAmountSalesKey(outcomeAssetId)
191183 let currentPresaleOutcomeAmountSales = getPresaleOutcomeAmountSales(outcomeAssetId)
192184 let newPresaleOutcomeAmountSales = (currentPresaleOutcomeAmountSales + outcomeAmountToBuy)
193185 let writeSet = WriteSet([DataEntry(presaleOutcomeAmountSalesKey, newPresaleOutcomeAmountSales)])
194- let transferSet = TransferSet([ScriptTransfer(customerAddress, buyOutcomeTokenTxFee, unit), ScriptTransfer(customerAddress, outcomeAmountToBuy, outcomeAssetId)])
186+ let transferSet = TransferSet([ScriptTransfer(customerAddress, outcomeAmountToBuy, outcomeAssetId)])
195187 ScriptResult(writeSet, transferSet)
196188 }
197189 }
198190
199191
200-func saleStrategy (customerAddress,outcomeAssetId,paymentAmount,outcomeAmountToBuy,outcomeAmountEventBalance,fee) = {
192+func saleStrategy (customerAddress,outcomeAssetId,paymentAmount,outcomeAmountToBuy,outcomeAmountEventBalance) = {
201193 let presaleOutcomeAmountSales = getPresaleOutcomeAmountSales(outcomeAssetId)
202194 let outcomeAmountAlreadySold = ((totalAssetsPerOutcome - presaleOutcomeAmountSales) - outcomeAmountEventBalance)
203- let outcomeRequiredPaymentAmount = (amountToPay(outcomeAmountAlreadySold, outcomeAmountToBuy) + fee)
195+ let outcomeRequiredPaymentAmount = amountToPay(outcomeAmountAlreadySold, outcomeAmountToBuy)
204196 if ((outcomeAmountToBuy > outcomeAmountEventBalance))
205197 then throwNotEnoughOutcomeAssetsInSaleStockError(outcomeAmountToBuy, outcomeAmountEventBalance)
206198 else if ((paymentAmount != outcomeRequiredPaymentAmount))
207199 then throwInsufficientPaymentError(paymentAmount, outcomeRequiredPaymentAmount)
208- else TransferSet([ScriptTransfer(customerAddress, buyOutcomeTokenTxFee, unit), ScriptTransfer(customerAddress, outcomeAmountToBuy, outcomeAssetId)])
200+ else TransferSet([ScriptTransfer(customerAddress, outcomeAmountToBuy, outcomeAssetId)])
209201 }
210202
211203
212204 @Callable(i)
213205 func buyOutcomeToken (outcomeAssetId,outcomeAmountToBuy) = {
214- let fee = calculateFeeInEventPaymentAsset()
215206 let customerAddress = i.caller
216207 let outcomeAmountEventBalance = assetBalance(this, outcomeAssetId)
217208 let status = getStatus()
218209 let payment = getPayment(i)
219210 let paymentAmount = payment.amount
220211 let paymentAssetId = getPaymentAssetId(payment)
221212 let isNotSupportedPaymentAsset = (paymentAssetId != eventCurrencyId)
222213 let isPresaleStatus = (status == presaleStatus)
223214 let isLiveStatus = (status == liveStatus)
224215 let isSalesAvailable = if (isPresaleStatus)
225216 then true
226217 else isLiveStatus
227218 if ((outcomeAmountEventBalance == 0))
228219 then throwNonexistentOutcomeAssetError(outcomeAssetId)
229220 else if (isNotSupportedPaymentAsset)
230221 then throwUnsupportedEventPaymentAssetError(paymentAssetId)
231222 else if (!(isSalesAvailable))
232223 then throwSalesIsNotAvailableInStatusError(status)
233224 else if (isPresaleStatus)
234- then presaleStrategy(customerAddress, outcomeAssetId, paymentAmount, outcomeAmountToBuy, outcomeAmountEventBalance, fee)
225+ then presaleStrategy(customerAddress, outcomeAssetId, paymentAmount, outcomeAmountToBuy, outcomeAmountEventBalance)
235226 else if (isLiveStatus)
236- then saleStrategy(customerAddress, outcomeAssetId, paymentAmount, outcomeAmountToBuy, outcomeAmountEventBalance, fee)
227+ then saleStrategy(customerAddress, outcomeAssetId, paymentAmount, outcomeAmountToBuy, outcomeAmountEventBalance)
237228 else throwUndefinedError()
238229 }
239230
240231
241232
242233 @Callable(i)
243234 func changeStatus (newStatus) = if (!(isSupportedStatus(newStatus)))
244235 then throwUnsupportedEventStatusError()
245236 else if (!(isRootCaller(i)))
246237 then throwIsNotRootCallerError()
247238 else WriteSet([setStatus(newStatus)])
248239
249240

github/deemru/w8io/026f985 
40.06 ms