tx · 3EE1eyYp7t3hALuDohhqjYJLxy68PHBAnji6zQuLhhBM 3NB8zm28NsK2qD7oJng5SszwXWzLuTkj64t: -0.01000000 Waves 2019.10.14 15:13 [719591] smart account 3NB8zm28NsK2qD7oJng5SszwXWzLuTkj64t > SELF 0.00000000 Waves
{ "type": 13, "id": "3EE1eyYp7t3hALuDohhqjYJLxy68PHBAnji6zQuLhhBM", "fee": 1000000, "feeAssetId": null, "timestamp": 1571055228628, "version": 1, "sender": "3NB8zm28NsK2qD7oJng5SszwXWzLuTkj64t", "senderPublicKey": "GYgCJzCuvC2F4MJeoMc66vagrbF8FRW8AZH8kdV3pgR3", "proofs": [ "4H8v3SKrKHKraMA4B1WzuV4eqgzKSsqbnXzuu9DVHdX3QFZarZe2bFvbTc4zGrahaWy1CH7vpJhhcT1wx7SWzSjf" ], "script": "base64:AAIDAAAAAAAAAA0IARIDCgEBEgQKAgEIAAAAIQAAAAAHV0FWRUxFVAkAAGgAAAACCQAAaAAAAAIAAAAAAAAAAGQAAAAAAAAAA+gAAAAAAAAAA+gAAAAABU1SVEVDAAAAAAAAAABkAAAAAApwbXRPblN0YXJ0CQAAaAAAAAIAAAAAAAAAAAoFAAAABU1SVEVDAAAAABBwYXJ0eU93bmVyUHViS2V5CQACWQAAAAECAAAALEZDYVA0akxoTGF3ekVxYndBUUdBVnZQUUJ2MmgzTGRFUkN4N2Zja0R2bnpyAAAAABFwYXJ0eU93bmVyQWRkcmVzcwkBAAAAFGFkZHJlc3NGcm9tUHVibGljS2V5AAAAAQUAAAAQcGFydHlPd25lclB1YktleQAAAAANbGVhc2luZ1BlcmlvZAAAAAAAAAknwAAAAAAGd2luQW10CQAAaAAAAAIAAAAAAAAAAAEFAAAAB1dBVkVMRVQAAAAADW1pbkhlaWdodERpZmYAAAAAAAAAAAEAAAAADW1heEhlaWdodERpZmYAAAAAAAAAAAMAAAAAEWJsb2Nrc09uR2FtZVN0YXJ0AAAAAAAACvrmAAAAAA5ibG9ja3NQZXJSb3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"height": 719591, "spentComplexity": 0 } View: original | compacted Prev: none Next: none Full:
Old | New | Differences | |
---|---|---|---|
1 | - | # no script | |
1 | + | {-# STDLIB_VERSION 3 #-} | |
2 | + | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | + | {-# CONTENT_TYPE DAPP #-} | |
4 | + | let WAVELET = ((100 * 1000) * 1000) | |
5 | + | ||
6 | + | let MRTEC = 100 | |
7 | + | ||
8 | + | let pmtOnStart = (10 * MRTEC) | |
9 | + | ||
10 | + | let partyOwnerPubKey = fromBase58String("FCaP4jLhLawzEqbwAQGAVvPQBv2h3LdERCx7fckDvnzr") | |
11 | + | ||
12 | + | let partyOwnerAddress = addressFromPublicKey(partyOwnerPubKey) | |
13 | + | ||
14 | + | let leasingPeriod = 600000 | |
15 | + | ||
16 | + | let winAmt = (1 * WAVELET) | |
17 | + | ||
18 | + | let minHeightDiff = 1 | |
19 | + | ||
20 | + | let maxHeightDiff = 3 | |
21 | + | ||
22 | + | let blocksOnGameStart = 719590 | |
23 | + | ||
24 | + | let blocksPerRound = 12 | |
25 | + | ||
26 | + | let blocksPerCompetition = 8 | |
27 | + | ||
28 | + | let MRT = fromBase58String("8b4jE7X1yCNcbF4YXZGBKc8T5xdit7b1gENxxx31daua") | |
29 | + | ||
30 | + | let MinFEE = ((5 * WAVELET) / 1000) | |
31 | + | ||
32 | + | let IdxWinHeight = 0 | |
33 | + | ||
34 | + | let IdxWinPubKey = 1 | |
35 | + | ||
36 | + | let IdxLeasingId = 2 | |
37 | + | ||
38 | + | func getRoundDataKeyOrFail (round) = if ((0 > round)) | |
39 | + | then throw("Invalid round number") | |
40 | + | else ("round" + toString(round)) | |
41 | + | ||
42 | + | ||
43 | + | func readRoundDataListOrFail (round) = { | |
44 | + | let roundDataOpt = getString(this, getRoundDataKeyOrFail(round)) | |
45 | + | let roundDataStr = if (isDefined(roundDataOpt)) | |
46 | + | then extract(roundDataOpt) | |
47 | + | else "" | |
48 | + | let partyOwnerAddressStr = toBase58String(partyOwnerAddress.bytes) | |
49 | + | if ((roundDataStr != "")) | |
50 | + | then split(roundDataStr, "_") | |
51 | + | else ["0", toString(pmtOnStart), partyOwnerAddressStr, "UNDEFINED"] | |
52 | + | } | |
53 | + | ||
54 | + | ||
55 | + | func readCommonStLastPlayersAddr () = { | |
56 | + | let commonStateOpt = getString(this, "CommonState") | |
57 | + | let commonStateStr = if (isDefined(commonStateOpt)) | |
58 | + | then extract(commonStateOpt) | |
59 | + | else "" | |
60 | + | if ((commonStateStr != "")) | |
61 | + | then split(commonStateStr, "_")[1] | |
62 | + | else "" | |
63 | + | } | |
64 | + | ||
65 | + | ||
66 | + | func writeSetOfRoundData (type,round,newWinHeight,newWinPubKeyStr,newWinPubKey,leasingId58) = { | |
67 | + | let newWinHeightStr = toString(newWinHeight) | |
68 | + | if ((type == "MOVE")) | |
69 | + | then { | |
70 | + | let newWinAddressStr = toString(addressFromPublicKey(newWinPubKey)) | |
71 | + | let currCommonStLastPlayersAddr = readCommonStLastPlayersAddr() | |
72 | + | let newCommonStLastPlayersAddr = if ((currCommonStLastPlayersAddr != "")) | |
73 | + | then (("-" + newWinAddressStr) + dropRight(currCommonStLastPlayersAddr, (size(newWinAddressStr) + 1))) | |
74 | + | else ("-" + newWinAddressStr) | |
75 | + | WriteSet([DataEntry(getRoundDataKeyOrFail(round), ((((newWinHeightStr + "_") + newWinPubKeyStr) + "_") + leasingId58)), DataEntry("CommonState", ((newWinHeightStr + "_") + newCommonStLastPlayersAddr))]) | |
76 | + | } | |
77 | + | else if ((type == "LEASING")) | |
78 | + | then WriteSet([DataEntry(getRoundDataKeyOrFail(round), ((((newWinHeightStr + "_") + newWinPubKeyStr) + "_") + leasingId58))]) | |
79 | + | else throw(("Unsupported type in writeSetOfRoundData method: " + type)) | |
80 | + | } | |
81 | + | ||
82 | + | ||
83 | + | let offset = (height - blocksOnGameStart) | |
84 | + | ||
85 | + | let currRoundNum = if ((offset >= 0)) | |
86 | + | then (offset / blocksPerRound) | |
87 | + | else throw(("Please do not hurry. MRT party will start on " + toString(blocksOnGameStart))) | |
88 | + | ||
89 | + | let currRoundHeight = (offset % blocksPerRound) | |
90 | + | ||
91 | + | let currRoundHeightStart = ((currRoundNum * blocksPerRound) + blocksOnGameStart) | |
92 | + | ||
93 | + | let currRoundCompetitionEnd = (currRoundHeightStart + blocksPerCompetition) | |
94 | + | ||
95 | + | let currRoundDataList = readRoundDataListOrFail(currRoundNum) | |
96 | + | ||
97 | + | let currWinHeight = parseIntValue(currRoundDataList[IdxWinHeight]) | |
98 | + | ||
99 | + | let currMinPmtAmt = pmtOnStart | |
100 | + | ||
101 | + | let isPauseByWin = if ((height >= currWinHeight)) | |
102 | + | then (currWinHeight > currRoundHeightStart) | |
103 | + | else false | |
104 | + | ||
105 | + | let isPauseByTime = (currRoundHeight > blocksPerCompetition) | |
106 | + | ||
107 | + | let isPause = if (isPauseByWin) | |
108 | + | then true | |
109 | + | else isPauseByTime | |
110 | + | ||
111 | + | let isCompetition = !(isPause) | |
112 | + | ||
113 | + | @Callable(inv) | |
114 | + | func move (newWinHeight) = { | |
115 | + | let minNewWinHeight = (height + minHeightDiff) | |
116 | + | let maxNewWinHeight = (height + maxHeightDiff) | |
117 | + | let newWinHeightValid = if ((minNewWinHeight >= currRoundCompetitionEnd)) | |
118 | + | then (newWinHeight == currRoundCompetitionEnd) | |
119 | + | else if ((newWinHeight >= minNewWinHeight)) | |
120 | + | then (maxNewWinHeight >= newWinHeight) | |
121 | + | else false | |
122 | + | let payment = if (isDefined(inv.payment)) | |
123 | + | then extract(inv.payment) | |
124 | + | else throw("Please attach payment with MRT to participate in MRT party") | |
125 | + | if ((payment.assetId != MRT)) | |
126 | + | then throw("Please use MRT as a payment asset to participate in MRT party") | |
127 | + | else if ((currMinPmtAmt > payment.amount)) | |
128 | + | then throw(("Sorry my friend but your payment is to small. Current min payment is " + toString(currMinPmtAmt))) | |
129 | + | else if (!(newWinHeightValid)) | |
130 | + | then throw((((((("Sorry, newWinHeight= " + toString(newWinHeight)) + "is out of [") + toString(minNewWinHeight)) + ", ") + toString(maxNewWinHeight)) + "] range")) | |
131 | + | else if (isPause) | |
132 | + | then throw((("Sorry but round #" + toString(currRoundNum)) + " is finished.")) | |
133 | + | else writeSetOfRoundData("MOVE", currRoundNum, newWinHeight, toBase58String(inv.callerPublicKey), inv.callerPublicKey, "UNDEFINED") | |
134 | + | } | |
135 | + | ||
136 | + | ||
137 | + | ||
138 | + | @Callable(inv) | |
139 | + | func registerLeasingTx (round,leasingId58) = { | |
140 | + | let leasingId = fromBase58String(leasingId58) | |
141 | + | let roundDataList = readRoundDataListOrFail(round) | |
142 | + | let winnerPubKey = fromBase58String(roundDataList[IdxWinPubKey]) | |
143 | + | if ((round > currRoundNum)) | |
144 | + | then throw("Impossible to register leasing transaction for round in future") | |
145 | + | else if (if ((round == currRoundNum)) | |
146 | + | then isCompetition | |
147 | + | else false) | |
148 | + | then throw("Impossible to register leasing transaction - winner has not been determined yet") | |
149 | + | else if ((size(leasingId58) != 44)) | |
150 | + | then throw("Invalid leasing transaction id length") | |
151 | + | else if ((0 >= size(leasingId))) | |
152 | + | then throw("Leasing transaction id is not encoded as Base58 format") | |
153 | + | else if (isDefined(transactionHeightById(leasingId))) | |
154 | + | then throw("Passed leasingId58 has already existed in blockchain") | |
155 | + | else if ((roundDataList[IdxLeasingId] != "UNDEFINED")) | |
156 | + | then throw(("Leasing tx id has already registrered for round " + toString(round))) | |
157 | + | else if ((inv.callerPublicKey != winnerPubKey)) | |
158 | + | then throw("Leasing tx can be registered by round winner only") | |
159 | + | else { | |
160 | + | let roundWinHeight = parseIntValue(roundDataList[IdxWinHeight]) | |
161 | + | writeSetOfRoundData("LEASING", round, roundWinHeight, roundDataList[IdxWinPubKey], toBytes(""), leasingId58) | |
162 | + | } | |
163 | + | } | |
164 | + | ||
165 | + | ||
166 | + | @Verifier(tx) | |
167 | + | func verify () = { | |
168 | + | let leasingPeriodEnded = (height > (blocksOnGameStart + leasingPeriod)) | |
169 | + | match tx { | |
170 | + | case ltx: LeaseTransaction => | |
171 | + | let sig = ltx.proofs[0] | |
172 | + | let round = toInt(ltx.proofs[1]) | |
173 | + | let roundDataList = readRoundDataListOrFail(round) | |
174 | + | let roundWinPubKey = fromBase58String(roundDataList[IdxWinPubKey]) | |
175 | + | let registeredLeasingId = fromBase58String(roundDataList[IdxLeasingId]) | |
176 | + | if (leasingPeriodEnded) | |
177 | + | then throw("Sorry but leasing period has been ended") | |
178 | + | else if (!(sigVerify(ltx.bodyBytes, sig, roundWinPubKey))) | |
179 | + | then throw("Invalid leasing transaction signature. Leasing is allowed for winner only.") | |
180 | + | else if ((ltx.id != registeredLeasingId)) | |
181 | + | then throw("Leasing transaction id doesn't match with registered leasing id") | |
182 | + | else if ((ltx.amount != winAmt)) | |
183 | + | then throw(("Impossible to lease less or greater than " + toString(winAmt))) | |
184 | + | else if ((ltx.fee != MinFEE)) | |
185 | + | then throw(("Impossible to lease with fee less or greater than " + toString(MinFEE))) | |
186 | + | else true | |
187 | + | case cltx: LeaseCancelTransaction => | |
188 | + | if (!(leasingPeriodEnded)) | |
189 | + | then throw("MRT party has not finished yet. Leasing Cancel is not allowed.") | |
190 | + | else if (!(sigVerify(tx.bodyBytes, tx.proofs[0], partyOwnerPubKey))) | |
191 | + | then throw("Leasing Cancel is allowed to Party Owner only") | |
192 | + | else if ((cltx.fee != MinFEE)) | |
193 | + | then throw(("Impossible to cancle leasing with fee less or greater than " + toString(MinFEE))) | |
194 | + | else true | |
195 | + | case ttx: TransferTransaction => | |
196 | + | if (!(leasingPeriodEnded)) | |
197 | + | then throw("MRT party has not finished yet. Transfer is not allowed.") | |
198 | + | else if ((addressFromRecipient(ttx.recipient).bytes != partyOwnerAddress.bytes)) | |
199 | + | then throw("Transfer is allowed to Party Owner address only") | |
200 | + | else if (!(sigVerify(ttx.bodyBytes, ttx.proofs[0], partyOwnerPubKey))) | |
201 | + | then throw("Transfer is allowed for Party Owner only.") | |
202 | + | else true | |
203 | + | case stx: SetScriptTransaction => | |
204 | + | sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey) | |
205 | + | case _ => | |
206 | + | false | |
207 | + | } | |
208 | + | } | |
209 | + |
github/deemru/w8io/169f3d6 27.78 ms ◑