tx · GuehQb4KtHnTumtjEpqVsN2hcT5zSywkU2aCZiCwoB2H 3NC3ZeZYDpDR72ngL6CoC19ygSD9uGBW3fX: -0.01000000 Waves 2023.07.02 02:57 [2647520] smart account 3NC3ZeZYDpDR72ngL6CoC19ygSD9uGBW3fX > SELF 0.00000000 Waves
{ "type": 13, "id": "GuehQb4KtHnTumtjEpqVsN2hcT5zSywkU2aCZiCwoB2H", "fee": 1000000, "feeAssetId": null, "timestamp": 1688255948469, "version": 2, "chainId": 84, "sender": "3NC3ZeZYDpDR72ngL6CoC19ygSD9uGBW3fX", "senderPublicKey": "8jH62ceUHZbFsEBSPohAjv3Rzc8mw3QhZaUKhGHngY2J", "proofs": [ "8tovvUXVSxjx9j3ZkEmM26Auoh8g2LWEJQzMzGHeiFcmFzVp57ddHmQTr4grv1et2HrDxem9a4FU8XtaVXxTrNb" ], "script": "base64:BgIQCAISABIAEgASBgoEEQEICAMADnRvdGFsTWF0Y2hzS2V5Ag50b3RhbE1hdGNoc0tleQEQdHJ5R2V0SW50ZWdlckV4dAIHYWRkcmVzcwNrZXkEByRtYXRjaDAJAJoIAgUHYWRkcmVzcwUDa2V5AwkAAQIFByRtYXRjaDACA0ludAQBYQUHJG1hdGNoMAUBYQAAAQl0cnlHZXRJbnQBA2tleQkBEHRyeUdldEludGVnZXJFeHQCBQR0aGlzBQNrZXkEAWkBB215VG9rZW4ACQCUCgIJAMwIAgkAwggFCQCsAgICBlRfdGNjXwkArwICCQDYBAEICAUBaQZjYWxsZXIFYnl0ZXMABgIAAKCNBgACBgUDbmlsBQR1bml0AWkBCmNsYWltVG9rZW4ABAlyZWNpcGllbnQIBQFpBmNhbGxlcgQFdG9rZW4JANkEAQIsQlRQaUNlQUVkNEVLa0N5eVJUakROdzNmeW1EN1B2b3I2UFFBeVZQTjMyWlMJAMwIAgkBDlNjcmlwdFRyYW5zZmVyAwUJcmVjaXBpZW50AOgHBQV0b2tlbgUDbmlsAWkBDGRlcG9zaXRUb2tlbgAECXJl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QW1ib3MCBkVtcGF0ZQUDbmlsAI4PN/4=", "height": 2647520, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: HJJiaqQdhQy9DsyRkF4uBp8gVthdgMtNH9SFRbY32pjA Next: none Diff:
Old | New | Differences | |
---|---|---|---|
45 | 45 | then { | |
46 | 46 | let qtd = (tryGetInt(totalMatchsKey) + 1) | |
47 | 47 | let amountMatches = ("Partida-" + toString(qtd)) | |
48 | - | let infos = (((((("Vencedor: " + toBase58String(i.caller.bytes)) + " ; ") + "Oponente: ") + opponent) + "Tabuleiro: ") + board) | |
49 | - | [IntegerEntry(totalMatchsKey, qtd), StringEntry(amountMatches, infos), ScriptTransfer(recipient, | |
48 | + | let infos = ((((((("Vencedor: " + toBase58String(i.caller.bytes)) + " ; ") + "Oponente: ") + opponent) + " ; ") + "Tabuleiro: ") + board) | |
49 | + | [IntegerEntry(totalMatchsKey, qtd), StringEntry(amountMatches, infos), ScriptTransfer(recipient, 190, token)] | |
50 | 50 | } | |
51 | 51 | else if (if (containsElement(solucoes, 3)) | |
52 | 52 | then true |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let totalMatchsKey = "totalMatchsKey" | |
5 | 5 | ||
6 | 6 | func tryGetIntegerExt (address,key) = match getInteger(address, key) { | |
7 | 7 | case a: Int => | |
8 | 8 | a | |
9 | 9 | case _ => | |
10 | 10 | 0 | |
11 | 11 | } | |
12 | 12 | ||
13 | 13 | ||
14 | 14 | func tryGetInt (key) = tryGetIntegerExt(this, key) | |
15 | 15 | ||
16 | 16 | ||
17 | 17 | @Callable(i) | |
18 | 18 | func myToken () = $Tuple2([Issue(("T_tcc_" + take(toBase58String(i.caller.bytes), 6)), "", 100000, 2, true)], unit) | |
19 | 19 | ||
20 | 20 | ||
21 | 21 | ||
22 | 22 | @Callable(i) | |
23 | 23 | func claimToken () = { | |
24 | 24 | let recipient = i.caller | |
25 | 25 | let token = fromBase58String("BTPiCeAEd4EKkCyyRTjDNw3fymD7Pvor6PQAyVPN32ZS") | |
26 | 26 | [ScriptTransfer(recipient, 1000, token)] | |
27 | 27 | } | |
28 | 28 | ||
29 | 29 | ||
30 | 30 | ||
31 | 31 | @Callable(i) | |
32 | 32 | func depositToken () = { | |
33 | 33 | let recipient = toBase58String(i.caller.bytes) | |
34 | 34 | let token = fromBase58String("BTPiCeAEd4EKkCyyRTjDNw3fymD7Pvor6PQAyVPN32ZS") | |
35 | 35 | [StringEntry(recipient, "100")] | |
36 | 36 | } | |
37 | 37 | ||
38 | 38 | ||
39 | 39 | ||
40 | 40 | @Callable(i) | |
41 | 41 | func verificarVencedor (solucoes,numPlayer,opponent,board) = { | |
42 | 42 | let recipient = i.caller | |
43 | 43 | let token = fromBase58String("BTPiCeAEd4EKkCyyRTjDNw3fymD7Pvor6PQAyVPN32ZS") | |
44 | 44 | if (containsElement(solucoes, (3 * (numPlayer + 1)))) | |
45 | 45 | then { | |
46 | 46 | let qtd = (tryGetInt(totalMatchsKey) + 1) | |
47 | 47 | let amountMatches = ("Partida-" + toString(qtd)) | |
48 | - | let infos = (((((("Vencedor: " + toBase58String(i.caller.bytes)) + " ; ") + "Oponente: ") + opponent) + "Tabuleiro: ") + board) | |
49 | - | [IntegerEntry(totalMatchsKey, qtd), StringEntry(amountMatches, infos), ScriptTransfer(recipient, | |
48 | + | let infos = ((((((("Vencedor: " + toBase58String(i.caller.bytes)) + " ; ") + "Oponente: ") + opponent) + " ; ") + "Tabuleiro: ") + board) | |
49 | + | [IntegerEntry(totalMatchsKey, qtd), StringEntry(amountMatches, infos), ScriptTransfer(recipient, 190, token)] | |
50 | 50 | } | |
51 | 51 | else if (if (containsElement(solucoes, 3)) | |
52 | 52 | then true | |
53 | 53 | else containsElement(solucoes, 6)) | |
54 | 54 | then [StringEntry("Jogador", "Perdeu")] | |
55 | 55 | else [StringEntry("Ambos", "Empate")] | |
56 | 56 | } | |
57 | 57 | ||
58 | 58 |
github/deemru/w8io/169f3d6 53.67 ms ◑