tx · 79LB3d775zFyxAnyhqUJveBX71FNYShdAZXHKXogKH2F

3NBqs2vfpyT5cMdUJ97mEJ1Ycp2y8GbAZDA:  -0.01300000 Waves

2023.03.24 14:02 [2504001] smart account 3NBqs2vfpyT5cMdUJ97mEJ1Ycp2y8GbAZDA > SELF 0.00000000 Waves

{ "type": 13, "id": "79LB3d775zFyxAnyhqUJveBX71FNYShdAZXHKXogKH2F", "fee": 1300000, "feeAssetId": null, "timestamp": 1679655772647, "version": 2, "chainId": 84, "sender": "3NBqs2vfpyT5cMdUJ97mEJ1Ycp2y8GbAZDA", "senderPublicKey": "H19CeJVbUnfsK8EYs8K6fHxwBH7pLyxw8WCDFu7D4rGQ", "proofs": [ "Mvxh5ScDaXzJbRfFVnwXRZhfpaNqXw6WsJpqn4PspSidGG7FTu7PkvPZf6ga6dgCApjtEKfZwP7wTiL7KomHPZt" ], "script": "base64:AAIFAAAAAAAABfAIAhIJCgcIAQEBAQEIEgMKAQgSAwoBARIAEgMKAQgSACIDU0VQIg9nZXRTdHJpbmdPckZhaWwiB2FkZHJlc3MiA2tleSIRa2V5RmFjdG9yeUFkZHJlc3MiGWtleVZvdGluZ1ZlcmlmaWVkQ29udHJhY3QiImtleVZvdGluZ0VtaXNzaW9uQ2FuZGlkYXRlQ29udHJhY3QiFGtleVVzZXJQb29sc0NvbnRyYWN0IhZ2b3RpbmdWZXJpZmllZENvbnRyYWN0Ih92b3RpbmdFbWlzc2lvbkNhbmRpZGF0ZUNvbnRyYWN0IhF1c2VyUG9vbHNDb250cmFjdCIYSWR4RmFjdG9yeUNmZ1N0YWtpbmdEYXBwIhlJZHhGYWN0b3J5Q2ZnQm9vc3RpbmdEYXBwIhRJZHhGYWN0b3J5Q2ZnSWRvRGFwcCIVSWR4RmFjdG9yeUNmZ1RlYW1EYXBwIhlJZHhGYWN0b3J5Q2ZnRW1pc3Npb25EYXBwIhVJZHhGYWN0b3J5Q2ZnUmVzdERhcHAiGUlkeEZhY3RvcnlDZmdTbGlw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AACCQEAAAALRGVsZXRlRW50cnkAAAABCQEAAAABVQAAAAAFAAAAA25pbAkAAAIAAAABAgAAACRTdHJpY3QgdmFsdWUgaXMgbm90IGVxdWFsIHRvIGl0c2VsZi4JAAACAAAAAQIAAAAkU3RyaWN0IHZhbHVlIGlzIG5vdCBlcXVhbCB0byBpdHNlbGYuAAAAAQAAAAJhQgEAAAACYUMAAAAABAAAAAJhRAQAAAABVwkBAAAAAVYAAAAAAwkAAAEAAAACBQAAAAFXAgAAAApCeXRlVmVjdG9yBAAAAAJhYwUAAAABVwUAAAACYWMDCQAAAQAAAAIFAAAAAVcCAAAABFVuaXQIBQAAAAJhQgAAAA9zZW5kZXJQdWJsaWNLZXkJAAACAAAAAQIAAAALTWF0Y2ggZXJyb3IJAAH0AAAAAwgFAAAAAmFCAAAACWJvZHlCeXRlcwkAAZEAAAACCAUAAAACYUIAAAAGcHJvb2ZzAAAAAAAAAAAABQAAAAJhRKkqZmI=", "height": 2504001, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: FcLZZNR1cJ4JVNL3waJGxcT1KkYxxEyv4ucjB7vG2xMc Next: 9LX9TmfgFMvNdxpdNuFmF1cnHUb3bVbQmBTqccJWMyWe Diff:
OldNewDifferences
9696
9797 func keyEmissionEndBlock () = "%s%s__emission__endBlock"
9898
99-
100-func keyBoostCoeff () = "%s__boostCoeff"
101-
102-
103-let boostCoeffDefault = 3
104-
105-let boostCoeff = valueOrElse(getInteger(this, keyBoostCoeff()), boostCoeffDefault)
10699
107100 func keyManagerPublicKey () = "%s__managerPublicKey"
108101
245238 }
246239
247240
248-
249-@Callable(i)
250-func getBoostCoeffREADONLY () = $Tuple2(nil, boostCoeff)
251-
252-
253241 @Verifier(tx)
254242 func verify () = {
255243 let targetPublicKey = match managerPublicKeyOrUnit() {
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let SEP = "__"
55
66 func getStringOrFail (address,key) = valueOrErrorMessage(getString(address, key), (("mandatory this." + key) + " is not defined"))
77
88
99 func keyFactoryAddress () = "%s%s__config__factoryAddress"
1010
1111
1212 let keyVotingVerifiedContract = "%s%s__config__votingVerifiedContract"
1313
1414 let keyVotingEmissionCandidateContract = "%s%s__config__votingEmissionCandidateContract"
1515
1616 let keyUserPoolsContract = "%s%s__config__userPoolsContract"
1717
1818 let votingVerifiedContract = addressFromStringValue(getStringOrFail(this, keyVotingVerifiedContract))
1919
2020 let votingEmissionCandidateContract = addressFromStringValue(getStringOrFail(this, keyVotingEmissionCandidateContract))
2121
2222 let userPoolsContract = addressFromStringValue(getStringOrFail(this, keyUserPoolsContract))
2323
2424 let IdxFactoryCfgStakingDapp = 1
2525
2626 let IdxFactoryCfgBoostingDapp = 2
2727
2828 let IdxFactoryCfgIdoDapp = 3
2929
3030 let IdxFactoryCfgTeamDapp = 4
3131
3232 let IdxFactoryCfgEmissionDapp = 5
3333
3434 let IdxFactoryCfgRestDapp = 6
3535
3636 let IdxFactoryCfgSlippageDapp = 7
3737
3838 let IdxFactoryCfgGwxRewardDapp = 10
3939
4040 func keyFactoryCfg () = "%s__factoryConfig"
4141
4242
4343 func keyFactoryLp2AssetsMapping (lpAssetStr) = makeString(["%s%s%s", lpAssetStr, "mappings__lpAsset2PoolContract"], SEP)
4444
4545
4646 func keyFactoryLpList () = "%s__lpTokensList"
4747
4848
4949 func keyFactoryLpAssetToPoolContractAddress (lpAssetStr) = makeString(["%s%s%s", lpAssetStr, "mappings__lpAsset2PoolContract"], SEP)
5050
5151
5252 func keyFactoryPoolWeight (contractAddress) = makeString(["%s%s", "poolWeight", contractAddress], SEP)
5353
5454
5555 func readFactoryAddressOrFail () = addressFromStringValue(getStringOrFail(this, keyFactoryAddress()))
5656
5757
5858 func readLpList () = split(valueOrElse(getString(readFactoryAddressOrFail(), keyFactoryLpList()), ""), SEP)
5959
6060
6161 func readFactoryCfgOrFail (factory) = split(getStringOrFail(factory, keyFactoryCfg()), SEP)
6262
6363
6464 func getBoostingAddressOrFail (factoryCfg) = addressFromStringValue(factoryCfg[IdxFactoryCfgBoostingDapp])
6565
6666
6767 func getEmissionAddressOrFail (factoryCfg) = addressFromStringValue(factoryCfg[IdxFactoryCfgEmissionDapp])
6868
6969
7070 func getStakingAddressOrFail (factoryCfg) = addressFromStringValue(factoryCfg[IdxFactoryCfgStakingDapp])
7171
7272
7373 func getGwxRewardAddressOrFail (factoryCfg) = addressFromStringValue(factoryCfg[IdxFactoryCfgGwxRewardDapp])
7474
7575
7676 func keyConfig () = "%s__config"
7777
7878
7979 func keyRatePerBlockMaxCurrent () = "%s%s__ratePerBlockMax__current"
8080
8181
8282 func keyRatePerBlockMaxStartFrom (timestamp,block) = makeString(["%s%s%d%d__ratePerBlockMax__start", toString(timestamp), toString(block)], SEP)
8383
8484
8585 func keyRatePerBlockCurrent () = "%s%s__ratePerBlock__current"
8686
8787
8888 func keyRatePerBlockStartFrom (timestamp,block) = makeString(["%s%s%d%d__ratePerBlock__start", toString(timestamp), toString(block)], SEP)
8989
9090
9191 func keyEmissionStartBlock () = "%s%s__emission__startBlock"
9292
9393
9494 func keyEmissionDurationInBlocks () = "%s%s__emission__duration"
9595
9696
9797 func keyEmissionEndBlock () = "%s%s__emission__endBlock"
9898
99-
100-func keyBoostCoeff () = "%s__boostCoeff"
101-
102-
103-let boostCoeffDefault = 3
104-
105-let boostCoeff = valueOrElse(getInteger(this, keyBoostCoeff()), boostCoeffDefault)
10699
107100 func keyManagerPublicKey () = "%s__managerPublicKey"
108101
109102
110103 func keyPendingManagerPublicKey () = "%s__pendingManagerPublicKey"
111104
112105
113106 func managerPublicKeyOrUnit () = match getString(keyManagerPublicKey()) {
114107 case s: String =>
115108 fromBase58String(s)
116109 case _: Unit =>
117110 unit
118111 case _ =>
119112 throw("Match error")
120113 }
121114
122115
123116 func pendingManagerPublicKeyOrUnit () = match getString(keyPendingManagerPublicKey()) {
124117 case s: String =>
125118 fromBase58String(s)
126119 case _: Unit =>
127120 unit
128121 case _ =>
129122 throw("Match error")
130123 }
131124
132125
133126 func mustManager (i) = {
134127 let pd = throw("Permission denied")
135128 match managerPublicKeyOrUnit() {
136129 case pk: ByteVector =>
137130 if ((i.callerPublicKey == pk))
138131 then true
139132 else pd
140133 case _: Unit =>
141134 if ((i.caller == this))
142135 then true
143136 else pd
144137 case _ =>
145138 throw("Match error")
146139 }
147140 }
148141
149142
150143 @Callable(i)
151144 func constructor (factoryAddress,ratePerBlockMax,ratePerBlock,emissionStartBlock,emissionDuration,emissionStartTimestamp,wxAssetIdStr) = {
152145 let checkCaller = mustManager(i)
153146 if ((checkCaller == checkCaller))
154147 then [IntegerEntry(keyRatePerBlockMaxStartFrom(emissionStartTimestamp, emissionStartBlock), ratePerBlockMax), IntegerEntry(keyRatePerBlockMaxCurrent(), ratePerBlockMax), IntegerEntry(keyRatePerBlockStartFrom(emissionStartTimestamp, emissionStartBlock), ratePerBlock), IntegerEntry(keyRatePerBlockCurrent(), ratePerBlock), IntegerEntry(keyEmissionStartBlock(), emissionStartBlock), IntegerEntry(keyEmissionDurationInBlocks(), emissionDuration), IntegerEntry(keyEmissionEndBlock(), (emissionStartBlock + emissionDuration)), StringEntry(keyFactoryAddress(), factoryAddress), StringEntry(keyConfig(), ("%s__" + wxAssetIdStr))]
155148 else throw("Strict value is not equal to itself.")
156149 }
157150
158151
159152
160153 @Callable(i)
161154 func constructorV2 (votingVerifiedContractPrm) = {
162155 let checkCaller = mustManager(i)
163156 if ((checkCaller == checkCaller))
164157 then $Tuple2([StringEntry(keyVotingVerifiedContract, votingVerifiedContractPrm)], unit)
165158 else throw("Strict value is not equal to itself.")
166159 }
167160
168161
169162
170163 @Callable(i)
171164 func emit (amount) = if ((0 >= amount))
172165 then $Tuple2(nil, nil)
173166 else {
174167 let factoryContract = readFactoryAddressOrFail()
175168 let factoryCfg = readFactoryCfgOrFail(factoryContract)
176169 let stakingContract = getStakingAddressOrFail(factoryCfg)
177170 let gwxRewardsContract = getGwxRewardAddressOrFail(factoryCfg)
178171 let caller = i.caller
179172 if (if ((caller != stakingContract))
180173 then (caller != gwxRewardsContract)
181174 else false)
182175 then throw("permissions denied")
183176 else {
184177 let wxAssetIdStr = split(getStringOrFail(this, keyConfig()), SEP)[1]
185178 let wxAssetId = fromBase58String(wxAssetIdStr)
186179 $Tuple2([ScriptTransfer(caller, amount, wxAssetId)], [wxAssetId])
187180 }
188181 }
189182
190183
191184
192185 @Callable(i)
193186 func burn () = {
194187 let factoryContract = readFactoryAddressOrFail()
195188 let factoryCfg = readFactoryCfgOrFail(factoryContract)
196189 let boostingContract = getBoostingAddressOrFail(factoryCfg)
197190 if ((size(i.payments) != 1))
198191 then throw("exact one payment is allowed")
199192 else {
200193 let pmt = i.payments[0]
201194 let assetId = value(pmt.assetId)
202195 let pmtAmount = pmt.amount
203196 let wxAssetId = fromBase58String(split(getStringOrFail(this, keyConfig()), SEP)[1])
204197 if ((assetId != wxAssetId))
205198 then throw("invalid wxAssetId is passed")
206199 else if (!(containsElement([boostingContract, votingVerifiedContract, votingEmissionCandidateContract, userPoolsContract], i.caller)))
207200 then throw("permissions denied")
208201 else [Burn(assetId, pmtAmount), StringEntry(("%s%s%s__history__burn__" + toBase58String(i.transactionId)), makeString(["%d%d%d", toString(height), toString(lastBlock.timestamp), toString(pmtAmount)], SEP))]
209202 }
210203 }
211204
212205
213206
214207 @Callable(i)
215208 func setManager (pendingManagerPublicKey) = {
216209 let checkCaller = mustManager(i)
217210 if ((checkCaller == checkCaller))
218211 then {
219212 let checkManagerPublicKey = fromBase58String(pendingManagerPublicKey)
220213 if ((checkManagerPublicKey == checkManagerPublicKey))
221214 then [StringEntry(keyPendingManagerPublicKey(), pendingManagerPublicKey)]
222215 else throw("Strict value is not equal to itself.")
223216 }
224217 else throw("Strict value is not equal to itself.")
225218 }
226219
227220
228221
229222 @Callable(i)
230223 func confirmManager () = {
231224 let pm = pendingManagerPublicKeyOrUnit()
232225 let hasPM = if (isDefined(pm))
233226 then true
234227 else throw("No pending manager")
235228 if ((hasPM == hasPM))
236229 then {
237230 let checkPM = if ((i.callerPublicKey == value(pm)))
238231 then true
239232 else throw("You are not pending manager")
240233 if ((checkPM == checkPM))
241234 then [StringEntry(keyManagerPublicKey(), toBase58String(value(pm))), DeleteEntry(keyPendingManagerPublicKey())]
242235 else throw("Strict value is not equal to itself.")
243236 }
244237 else throw("Strict value is not equal to itself.")
245238 }
246239
247240
248-
249-@Callable(i)
250-func getBoostCoeffREADONLY () = $Tuple2(nil, boostCoeff)
251-
252-
253241 @Verifier(tx)
254242 func verify () = {
255243 let targetPublicKey = match managerPublicKeyOrUnit() {
256244 case pk: ByteVector =>
257245 pk
258246 case _: Unit =>
259247 tx.senderPublicKey
260248 case _ =>
261249 throw("Match error")
262250 }
263251 sigVerify(tx.bodyBytes, tx.proofs[0], targetPublicKey)
264252 }
265253

github/deemru/w8io/026f985 
47.14 ms