tx · 9QQT4ivj4637gfPh12oHSaAwMa15KAJjVUnCHZ7DTtAN

3MxedECbCgJzLLpPMm78Vhj8QnaAKGNkVe5:  -0.01000000 Waves

2021.08.11 17:00 [1653802] smart account 3MxedECbCgJzLLpPMm78Vhj8QnaAKGNkVe5 > SELF 0.00000000 Waves

{ "type": 13, "id": "9QQT4ivj4637gfPh12oHSaAwMa15KAJjVUnCHZ7DTtAN", "fee": 1000000, "feeAssetId": null, "timestamp": 1628690460829, "version": 2, "chainId": 84, "sender": "3MxedECbCgJzLLpPMm78Vhj8QnaAKGNkVe5", "senderPublicKey": "58UtpEU7kPv8rLxiE5pk4qYzpC7mVDaZUbDaP8CKV9pc", "proofs": [ "61GU1CiHkCAjZjaH2VQZph4AKXQ2s9pzD5eYgNpHbaQwsGJt1nHuct7ULo936m6R7XZQ8wX68UDWtAn4jdrEfcMn" ], "script": "base64:AAIFAAAAAAAAAIcIAhIDCgEBEgAaDwoCYTESCVBPU0lUSU9OUxoQCgJhMhIKcmFuZG9taXplchoJCgJhMxIDaW52GgoKAmE0EgRyYW5kGg4KAmE1EghzYXZlRGF0YRoJCgJhNhIDcG9zGgsKAmE3EgVzdGF0cxoLCgJhOBIFYXNzZXQaDQoCYTkSB2Fzc2V0SWQAAAADAAAAAAJhMQkABEwAAAACAgAAAAJHSwkABEwAAAACAgAAAAJMRAkABEwAAAACAgAAAAJDRAkABEwAAAACAgAAAAJSRAkABEwAAAACAgAAAAJETQkABEwAAAACAgAAAAJMTQkABEwAAAACAgAAAAJDTQkABEwAAAACAgAAAAJSTQkABEwAAAACAgAAAAJBTQkABEwAAAACAgAAAAJMRgkABEwAAAACAgAAAAJSRgkABEwAAAACAgAAAAJDRgUAAAADbmlsAQAAAAJhMgAAAAEAAAACYTMEAAAAAmE0CQAAywAAAAIJAADLAAAAAgkAAMsAAAACCQAAywAAAAIIBQAAAAJhMwAAAA10cmFuc2FjdGlvbklkCAUAAAACYTMAAAAPY2FsbGVyUHVibGljS2V5CAUAAA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, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: GahjL4JrHn51YGqhUt8P3wPuMt8Vm5VSn3zVwpoayfEC Next: none Diff:
OldNewDifferences
1010
1111
1212 func saveData (inv,pos) = {
13- let stats = (("{'position':" + POSITIONS[pos]) + ", 'stats': {'stamina': 200, 'speed': 120, 'shot': 12, 'offence': 1, 'defence': 1}, 'skills': {'horse_lungs': 1}, 'talents': {'hard_trainings': 1}, 'age': 32}")
14- let asset = Issue("Asset", "", 1000, 0, false, unit, 0)
13+ let stats = (("{position:" + POSITIONS[pos]) + ", stats: {'stamina': 200, 'speed': 120, 'shot': 12, 'offence': 1, 'defence': 1}, skills: {'horse_lungs': 1}, talents: {'hard_trainings': 1}, 'age': 32}")
14+ let asset = Issue("Named token", toBase64String(toBytes(stats)), 1, 0, false, unit, 0)
1515 let assetId = calculateAssetId(asset)
1616 [StringEntry(((toBase58String(inv.caller.bytes) + "_") + toString(toInt(randomizer(inv)))), toBase64String(toBytes(stats))), asset, ScriptTransfer(inv.caller, 1, assetId)]
1717 }
2121 func start (pos) = saveData(inv, pos)
2222
2323
24+
25+@Callable(inv)
26+func updateStats () = nil
27+
28+
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let POSITIONS = ["GK", "LD", "CD", "RD", "DM", "LM", "CM", "RM", "AM", "LF", "RF", "CF"]
55
66 func randomizer (inv) = {
77 let rand = ((((inv.transactionId + inv.callerPublicKey) + lastBlock.generationSignature) + toBytes(lastBlock.timestamp)) + toBytes(lastBlock.height))
88 sha256(rand)
99 }
1010
1111
1212 func saveData (inv,pos) = {
13- let stats = (("{'position':" + POSITIONS[pos]) + ", 'stats': {'stamina': 200, 'speed': 120, 'shot': 12, 'offence': 1, 'defence': 1}, 'skills': {'horse_lungs': 1}, 'talents': {'hard_trainings': 1}, 'age': 32}")
14- let asset = Issue("Asset", "", 1000, 0, false, unit, 0)
13+ let stats = (("{position:" + POSITIONS[pos]) + ", stats: {'stamina': 200, 'speed': 120, 'shot': 12, 'offence': 1, 'defence': 1}, skills: {'horse_lungs': 1}, talents: {'hard_trainings': 1}, 'age': 32}")
14+ let asset = Issue("Named token", toBase64String(toBytes(stats)), 1, 0, false, unit, 0)
1515 let assetId = calculateAssetId(asset)
1616 [StringEntry(((toBase58String(inv.caller.bytes) + "_") + toString(toInt(randomizer(inv)))), toBase64String(toBytes(stats))), asset, ScriptTransfer(inv.caller, 1, assetId)]
1717 }
1818
1919
2020 @Callable(inv)
2121 func start (pos) = saveData(inv, pos)
2222
2323
24+
25+@Callable(inv)
26+func updateStats () = nil
27+
28+

github/deemru/w8io/026f985 
27.84 ms