tx · 7c2GVCRJhmw4D3wpG5koB6qdvNMcN79HD5MNTwq91p39

3MrAg5vWXLFwhWydJmxrsPLL6rdrSUeDNbv:  -0.01000000 Waves

2022.12.20 00:13 [2367709] smart account 3MrAg5vWXLFwhWydJmxrsPLL6rdrSUeDNbv > SELF 0.00000000 Waves

{ "type": 13, "id": "7c2GVCRJhmw4D3wpG5koB6qdvNMcN79HD5MNTwq91p39", "fee": 1000000, "feeAssetId": null, "timestamp": 1671484425200, "version": 2, "chainId": 84, "sender": "3MrAg5vWXLFwhWydJmxrsPLL6rdrSUeDNbv", "senderPublicKey": "6HLvuad4SwFyr1zqYtS718tDkqVKSfUhXGgZTPm6ie6K", "proofs": [ "2DEPsRgdbyfspt3J6iR9niUsZy8HWu1qNt7T9J2hipQNE3ZTw8fjn2z5gyR6qjzHhApWeKr4nGKZ3fePPuWqj4nu" ], "script": "base64:BgEEBkFkbWluMQEg4FpcJMjAYbIll84pMJmfwVw5Ys5pFvEd5cuKWJwyGFgEBkFkbWluMgEgkVqwN8XHi0SW5H6gGgzqNry7fpAkhOk6hsvpfR+G30oEByRtYXRjaDAFAnR4AwkAAQIFByRtYXRjaDACF0ludm9rZVNjcmlwdFRyYW5zYWN0aW9uBAF0BQckbWF0Y2gwAwkAAAIIBQF0BGRBcHAJAKYIAQIjM043YjNrUHVuSFVYaFpwMXZNRzlOaFBNQVJORXByQ01XeFQJAPQDAwgFAnR4CWJvZHlCeXRlcwkAkQMCCAUCdHgGcHJvb2ZzAAAIBQJ0eA9zZW5kZXJQdWJsaWNLZXkJAAIBAiHQutC+0LvQtdC10LUsINC/0L7Qu9GD0YfQuCDQu9C4ID8DCQD0AwMIBQJ0eAlib2R5Qnl0ZXMJAJEDAggFAnR4BnByb29mcwAABQZBZG1pbjEJAPQDAwgFAnR4CWJvZHlCeXRlcwkAkQMCCAUCdHgGcHJvb2ZzAAEFBkFkbWluMgdEGC5g", "height": 2367709, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: HTz6BpfdbaAqdVFtDN9ncwFqCUNSBU3AAvy1DHJ4ERfM Next: none Full:
OldNewDifferences
1-{-# STDLIB_VERSION 5 #-}
2-{-# SCRIPT_TYPE ACCOUNT #-}
3-{-# CONTENT_TYPE DAPP #-}
4-let SEP = "__"
5-
6-let MULT6 = 1000000
7-
8-let MULT8 = 100000000
9-
10-let WAVESIDSTR = "WAVES"
11-
12-let WAVESID = fromBase58String(WAVESIDSTR)
13-
14-@Callable(i)
15-func distributeMinerReward (benificaryAddressStr) = if ((size(i.payments) != 1))
16- then throw("exact 1 payment must be attached")
17- else if ((i.caller != i.originCaller))
18- then throw("dapp to dapp calls are not allowed")
19- else {
20- let pmt = i.payments[0]
21- let minedAmt = pmt.amount
22- let pmtAssetId = valueOrElse(pmt.assetId, WAVESID)
23- let feeAmt = i.fee
24- let feeAssetId = valueOrElse(i.feeAssetId, WAVESID)
25- if ((pmtAssetId != WAVESID))
26- then throw("only Waves can be used in payment")
27- else if ((feeAssetId != WAVESID))
28- then throw("only Waves can be used in fees")
29- else if ((feeAmt != ((5 * MULT8) / 1000)))
30- then throw("fee amount couldn't exceed 0.005")
31- else {
32- let neutrinoAddress = addressFromStringValue("3ND7DYnkhEuT6e5mAXpxY9jwNNQ4rZ7YLx6")
33- let minerAddress = i.caller
34- let benificaryAddress = addressFromStringValue(benificaryAddressStr)
35- let protocolPart = 950000
36- let benificaryPart = 50000
37- let availableBalance = (wavesBalance(minerAddress).available - feeAmt)
38- let benificaryAmt = fraction(minedAmt, benificaryPart, MULT6)
39- let protocolAmt = (minedAmt - benificaryAmt)
40-[ScriptTransfer(benificaryAddress, benificaryAmt, unit), ScriptTransfer(neutrinoAddress, protocolAmt, unit)]
41- }
42- }
43-
44-
1+{-# STDLIB_VERSION 6 #-}
2+{-# CONTENT_TYPE EXPRESSION #-}
3+let Admin1 = base58'G6nEsHCof8Evf9ZZSjfiRotP8uE37cHU2Hrx4r3xiSqV'
4+let Admin2 = base58'AnQKeEVCP9qDgbAqsFmMX7DfpVKdAMxgUHJhFKP8xvGh'
5+match tx {
6+ case t: InvokeScriptTransaction =>
7+ if ((t.dApp == addressFromString("3N7b3kPunHUXhZp1vMG9NhPMARNEprCMWxT")))
8+ then sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)
9+ else throw("колеее, получи ли ?")
10+ case _ =>
11+ if (sigVerify(tx.bodyBytes, tx.proofs[0], Admin1))
12+ then sigVerify(tx.bodyBytes, tx.proofs[1], Admin2)
13+ else false
14+}

github/deemru/w8io/026f985 
22.52 ms