tx · 6DkjxYmASek8Pu8JbpKL8aXYkM6skaqiCvxjamtxXh7q

3Mx3ydmQ9xKSvAaDC6Ef5wd6dWj8wcCVqBf:  -0.01000000 Waves

2019.10.16 17:49 [722681] smart account 3Mx3ydmQ9xKSvAaDC6Ef5wd6dWj8wcCVqBf > SELF 0.00000000 Waves

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

github/deemru/w8io/169f3d6 
43.89 ms