tx · 4JAZrZeJ6BDKXU99bBXkcwG4ss36BbYyWNUqtRLBqifM

3N8YkRZsgDVNAxtmwU1F65EpcYMb8f7QPos:  -0.01500000 Waves

2024.06.03 17:05 [3134601] smart account 3N8YkRZsgDVNAxtmwU1F65EpcYMb8f7QPos > SELF 0.00000000 Waves

{ "type": 13, "id": "4JAZrZeJ6BDKXU99bBXkcwG4ss36BbYyWNUqtRLBqifM", "fee": 1500000, "feeAssetId": null, "timestamp": 1717423613716, "version": 2, "chainId": 84, "sender": "3N8YkRZsgDVNAxtmwU1F65EpcYMb8f7QPos", "senderPublicKey": "F7SLwr7RYVQpyocmVScFC6ooaAwewaGq6wNRDYvyiPj1", "proofs": [ "2WgM19zcWrPCKzNTekgjd4MRDUe4zgWj4mQXhC2SXVyJEJ98mSExhHoxCuopW44P2FoC6x87Wbo9ZbAmhWpXWgA2" ], "script": "base64:AAIFAAAAAAAAABIIAhIGCgQIGAgIEgQKAggIEgAAAAAPAAAAABRwcmVkaWN0aW9uTWF4Q291bnRlcgAAAAAAAAAAAwAAAAAKbWF4Q291bnRlcgAAAAAAAAAABgAAAAANZGVmYXVsdFJhdGluZwAAAAAAAAAAZAAAAAAOcmF0ZUFkanVzdG1lbnQAAAAAAAAAABQAAAAAB3Rva2VuSWQBAAAAIG33eiemmz/8i1OVqeOeBVscIi9bTehRMFsBoQapAMYYAAAAAAxwYXlvdXRBbW91bnQAAAAAAAX14QAAAAAADHJhdGluZ0N1dG9mZgAAAAAAAAAAMgAAAAAJcl9hdmVyYWdlAAAAAAAAAABkAQAAABFzZWFyY2hGb3JDb3VudGVycwAAAAIAAAAGaXRlbUlkAAAAB2NvdW50ZXIEAAAAEXNlYXJjaEZvckNvdW50ZXJzBAAAAAckbWF0Y2gwCQAEIgAAAAEJAAEsAAAAAgkAASwAAAACBQAAAAZpdGVtSWQCAAAAAV8JAAGkAAAAAQUAAAAHY291bnRlcgMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAAGU3RyaW5nBAAA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cmVzcwIAAAAHX3JhdGluZwUAAAANZGVmYXVsdFJhdGluZwUAAAADbmlsAAAAAQAAAAJ0eAEAAAAGdmVyaWZ5AAAAAAkAAfQAAAADCAUAAAACdHgAAAAJYm9keUJ5dGVzCQABkQAAAAIIBQAAAAJ0eAAAAAZwcm9vZnMAAAAAAAAAAAAIBQAAAAJ0eAAAAA9zZW5kZXJQdWJsaWNLZXnnCKtS", "height": 3134601, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: CG4LMwoRBTcQHvB95Nkr8qdzqZvHtDhShHnwfg2HLLwK Next: G5Dda9KrcBGYpRkjo7e7XMUa1yEp725mAzkrZzaEenia Diff:
OldNewDifferences
2929
3030
3131 func searchForRating (address) = {
32- let rating = match getInteger(address) {
32+ let rating = match getInteger((address + "_rating")) {
3333 case r: Int =>
3434 r
3535 case _ =>
158158 @Callable(i)
159159 func savePrediction (itemId,prediction) = {
160160 let clientAdress = toString(i.caller)
161- let searchForUser = match getInteger(clientAdress) {
161+ let searchForUser = match getInteger((clientAdress + "_rating")) {
162162 case s: Int =>
163163 s
164164 case _ =>
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let predictionMaxCounter = 3
55
66 let maxCounter = 6
77
88 let defaultRating = 100
99
1010 let rateAdjustment = 20
1111
1212 let tokenId = base58'8QGJvsXqJ43q5ksFymoPKF1NWWhwUfr2F7h52oeWgVhH'
1313
1414 let payoutAmount = 100000000
1515
1616 let ratingCutoff = 50
1717
1818 let r_average = 100
1919
2020 func searchForCounters (itemId,counter) = {
2121 let searchForCounters = match getString(((itemId + "_") + toString(counter))) {
2222 case s: String =>
2323 s
2424 case _ =>
2525 "No User"
2626 }
2727 searchForCounters
2828 }
2929
3030
3131 func searchForRating (address) = {
32- let rating = match getInteger(address) {
32+ let rating = match getInteger((address + "_rating")) {
3333 case r: Int =>
3434 r
3535 case _ =>
3636 defaultRating
3737 }
3838 rating
3939 }
4040
4141
4242 func searchForAddressPrediction (itemId,adress) = {
4343 let searchForPrediction = match getString(((itemId + "_") + adress)) {
4444 case s: String =>
4545 s
4646 case _ =>
4747 "Not Found"
4848 }
4949 searchForPrediction
5050 }
5151
5252
5353 func findPredictionAdresses (itemId,counter) = {
5454 let adressList = if ((counter >= 5))
5555 then {
5656 let adress1 = searchForCounters(itemId, 1)
5757 let adress2 = searchForCounters(itemId, 2)
5858 let adress3 = searchForCounters(itemId, 3)
5959 let adress4 = searchForCounters(itemId, 4)
6060 let adress5 = searchForCounters(itemId, 5)
6161 (((((nil :+ adress1) :+ adress2) :+ adress3) :+ adress4) :+ adress5)
6262 }
6363 else if ((counter >= 4))
6464 then {
6565 let adress1 = searchForCounters(itemId, 1)
6666 let adress2 = searchForCounters(itemId, 2)
6767 let adress3 = searchForCounters(itemId, 3)
6868 let adress4 = searchForCounters(itemId, 4)
6969 ((((nil :+ adress1) :+ adress2) :+ adress3) :+ adress4)
7070 }
7171 else if ((counter >= 3))
7272 then {
7373 let adress1 = searchForCounters(itemId, 1)
7474 let adress2 = searchForCounters(itemId, 2)
7575 let adress3 = searchForCounters(itemId, 3)
7676 (((nil :+ adress1) :+ adress2) :+ adress3)
7777 }
7878 else if ((counter >= 2))
7979 then {
8080 let adress1 = searchForCounters(itemId, 1)
8181 let adress2 = searchForCounters(itemId, 2)
8282 ((nil :+ adress1) :+ adress2)
8383 }
8484 else {
8585 let adress1 = searchForCounters(itemId, 1)
8686 (nil :+ adress1)
8787 }
8888 adressList
8989 }
9090
9191
9292 func calculateExpectedScore (r_player,r_average) = {
9393 let diff = (r_average - r_player)
9494 let exponent = (diff / r_average)
9595 let powerOfTen = pow(10, 0, exponent, 0, 0, HALFUP)
9696 let denominator = (1 + powerOfTen)
9797 (1 / denominator)
9898 }
9999
100100
101101 func calculatePayout (r_player,r_average) = {
102102 let ratio = ((r_player * 100) / r_average)
103103 let payout = ((payoutAmount * ratio) / 100)
104104 payout
105105 }
106106
107107
108108 func calculateNewRating (r_player,r_average,k,actualScore) = {
109109 let expectedScore = calculateExpectedScore(r_player, r_average)
110110 let delta_r = (k * (actualScore - expectedScore))
111111 (r_player + delta_r)
112112 }
113113
114114
115115 @Callable(i)
116116 func adjustRatingsAndPayoutParticipants (itemId,addressList,lastCallerAddress,finalPrediction) = {
117117 let caller = toString(i.caller)
118118 if ((caller != toString(this)))
119119 then throw("You are not allowed to call this function")
120120 else {
121121 func updateRatingsFunc (accum,address) = {
122122 let rating = searchForRating(address)
123123 let prediction = searchForAddressPrediction(itemId, address)
124124 let actualScore = if ((prediction == finalPrediction))
125125 then 1
126126 else 0
127127 let newRating = calculateNewRating(rating, r_average, rateAdjustment, actualScore)
128128 let payout = if ((prediction == finalPrediction))
129129 then true
130130 else false
131131 let updatedEntries = (accum :+ IntegerEntry((address + "_rating"), newRating))
132132 let calculatedAmount = calculatePayout(newRating, r_average)
133133 if (payout)
134134 then (updatedEntries :+ ScriptTransfer(Address(fromBase58String(address)), calculatedAmount, tokenId))
135135 else updatedEntries
136136 }
137137
138138 let updatedRatings = {
139139 let $l = addressList
140140 let $s = size($l)
141141 let $acc0 = nil
142142 func $f0_1 ($a,$i) = if (($i >= $s))
143143 then $a
144144 else updateRatingsFunc($a, $l[$i])
145145
146146 func $f0_2 ($a,$i) = if (($i >= $s))
147147 then $a
148148 else throw("List size exceeds 5")
149149
150150 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5)
151151 }
152152 (updatedRatings :+ BooleanEntry((itemId + "_adjusted"), true))
153153 }
154154 }
155155
156156
157157
158158 @Callable(i)
159159 func savePrediction (itemId,prediction) = {
160160 let clientAdress = toString(i.caller)
161- let searchForUser = match getInteger(clientAdress) {
161+ let searchForUser = match getInteger((clientAdress + "_rating")) {
162162 case s: Int =>
163163 s
164164 case _ =>
165165 "User does not exist"
166166 }
167167 if ((searchForUser == "User does not exist"))
168168 then throw("User does not exist")
169169 else {
170170 let isFinal = match getBoolean((itemId + "_final")) {
171171 case s: Boolean =>
172172 s
173173 case _ =>
174174 false
175175 }
176176 if (isFinal)
177177 then throw("Final prediction already made")
178178 else {
179179 let isCanceled = match getBoolean((itemId + "_cancelled")) {
180180 case s: Boolean =>
181181 s
182182 case _ =>
183183 false
184184 }
185185 if (isCanceled)
186186 then throw("Final prediction already made")
187187 else {
188188 let clientRating = searchForRating(clientAdress)
189189 if ((ratingCutoff >= clientRating))
190190 then throw("You are not allowed to participate anymore")
191191 else {
192192 let searchForCounter = match getInteger((itemId + "_counter")) {
193193 case s: Int =>
194194 s
195195 case _ =>
196196 -1
197197 }
198198 if ((searchForCounter >= 1))
199199 then {
200200 let adressList = findPredictionAdresses(itemId, searchForCounter)
201201 if (containsElement(adressList, clientAdress))
202202 then throw("This User already gave a Prediction")
203203 else {
204204 let predictionCounter = match getInteger((itemId + "_predictionCounter")) {
205205 case s: Int =>
206206 s
207207 case _ =>
208208 -1
209209 }
210210 let lastPredictionAdress = adressList[(size(adressList) - 1)]
211211 let lastPrediction = match getString(((itemId + "_") + lastPredictionAdress)) {
212212 case s: String =>
213213 s
214214 case _ =>
215215 "no Prediction Found"
216216 }
217217 let newCounter = (searchForCounter + 1)
218218 if ((lastPrediction == prediction))
219219 then if (((predictionCounter + 1) == predictionMaxCounter))
220220 then {
221221 let newRating = calculateNewRating(clientRating, r_average, rateAdjustment, 1)
222222 let calculatedAmount = calculatePayout(newRating, r_average)
223223 let invokeAdjustRating = invoke(this, "adjustRatingsAndPayoutParticipants", [itemId, adressList, clientAdress, prediction], nil)
224224 if ((invokeAdjustRating != invokeAdjustRating))
225225 then throw("Strict value is not equal to itself.")
226226 else [StringEntry(((itemId + "_") + toString(newCounter)), clientAdress), StringEntry(((itemId + "_") + clientAdress), prediction), IntegerEntry((itemId + "_counter"), newCounter), IntegerEntry((itemId + "_predictionCounter"), (predictionCounter + 1)), BooleanEntry((itemId + "_final"), true), BooleanEntry((itemId + "_cancelled"), false), ScriptTransfer(Address(fromBase58String(clientAdress)), calculatedAmount, tokenId), IntegerEntry((clientAdress + "_rating"), newRating)]
227227 }
228228 else [StringEntry(((itemId + "_") + toString(newCounter)), clientAdress), StringEntry(((itemId + "_") + clientAdress), prediction), IntegerEntry((itemId + "_counter"), newCounter), IntegerEntry((itemId + "_predictionCounter"), (predictionCounter + 1)), BooleanEntry((itemId + "_final"), false), BooleanEntry((itemId + "_cancelled"), false)]
229229 else if ((newCounter >= maxCounter))
230230 then [StringEntry(((itemId + "_") + toString(newCounter)), clientAdress), StringEntry(((itemId + "_") + clientAdress), prediction), IntegerEntry((itemId + "_counter"), newCounter), IntegerEntry((itemId + "_predictionCounter"), (predictionCounter - 1)), BooleanEntry((itemId + "_cancelled"), true), BooleanEntry((itemId + "_final"), false)]
231231 else if (((predictionCounter - 1) == 0))
232232 then [StringEntry(((itemId + "_") + toString(newCounter)), clientAdress), StringEntry(((itemId + "_") + clientAdress), prediction), IntegerEntry((itemId + "_counter"), newCounter), IntegerEntry((itemId + "_predictionCounter"), 1), BooleanEntry((itemId + "_cancelled"), false), BooleanEntry((itemId + "_final"), false), StringEntry("test", lastPrediction), IntegerEntry("test2", size(adressList))]
233233 else [StringEntry(((itemId + "_") + toString(newCounter)), clientAdress), StringEntry(((itemId + "_") + clientAdress), prediction), IntegerEntry((itemId + "_counter"), newCounter), IntegerEntry((itemId + "_predictionCounter"), (predictionCounter - 1)), BooleanEntry((itemId + "_cancelled"), false), BooleanEntry((itemId + "_final"), false), StringEntry("test", lastPrediction), IntegerEntry("test2", size(adressList))]
234234 }
235235 }
236236 else {
237237 let searchForNewItem = match getString(("new_" + itemId)) {
238238 case s: String =>
239239 s
240240 case _ =>
241241 "Item not Found"
242242 }
243243 if ((searchForNewItem == "Item not Found"))
244244 then throw("Item not found")
245245 else [StringEntry(((itemId + "_") + toString(1)), clientAdress), StringEntry(((itemId + "_") + clientAdress), prediction), IntegerEntry((itemId + "_counter"), 1), IntegerEntry((itemId + "_predictionCounter"), 1), DeleteEntry(("new_" + itemId)), StringEntry(("updated_" + itemId), itemId)]
246246 }
247247 }
248248 }
249249 }
250250 }
251251 }
252252
253253
254254
255255 @Callable(i)
256256 func registerUser () = {
257257 let clientAdress = toString(i.caller)
258258 let searchForUser = match getInteger((clientAdress + "_rating")) {
259259 case s: Int =>
260260 s
261261 case _ =>
262262 -1
263263 }
264264 if ((searchForUser != -1))
265265 then throw("User already exists")
266266 else [IntegerEntry((clientAdress + "_rating"), defaultRating)]
267267 }
268268
269269
270270 @Verifier(tx)
271271 func verify () = sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)
272272

github/deemru/w8io/026f985 
36.98 ms