tx · 8H1EEfuNBjMxXF7GdoWQ8CpWhzk7FMsTBArzvzCd54o2

3N69YR9dGN9tJnhxGrURt5cQycjAN1zbQ9t:  -0.05000000 Waves

2021.01.25 13:52 [1368932] smart account 3N69YR9dGN9tJnhxGrURt5cQycjAN1zbQ9t > SELF 0.00000000 Waves

{ "type": 13, "id": "8H1EEfuNBjMxXF7GdoWQ8CpWhzk7FMsTBArzvzCd54o2", "fee": 5000000, "feeAssetId": null, "timestamp": 1611571926518, "version": 2, "chainId": 84, "sender": "3N69YR9dGN9tJnhxGrURt5cQycjAN1zbQ9t", "senderPublicKey": "Bo16mjUNTGCeZDYvQc6gHh46P21B3DqYCHoDt9CyzxHf", "proofs": [ "45rfy8fHF1kmHcLHF1TYA6pWixtcKtJDhHVyMRRvfQWZjwKXut5t4Hbm96Kvirxe5L5dGZ46d2rnMx7hbhvWSZUM" ], "script": "base64:AAIEAAAAAAAAAAQIAhIAAAAACgAAAAABZQAAAAAAEDPE1gAAAAAOa3dvdGFyb3dub3dhZ2kAAAAAAAAAA+gAAAAABGJhemEJAABpAAAAAgUAAAAOa3dvdGFyb3dub3dhZ2kAAAAAAAAAAAIAAAAABnBvemlvbQAAAAAN+EdYAAAAAAAKYmFsYW5zVVNETgAAAAAAAAAD6AAAAAAKYmFsYW5zVVNEVAAAAAAAAAAD6AEAAAACbG4AAAABAAAAAXgJAABtAAAABgUAAAABeAAAAAAAAAAACAUAAAABZQAAAAAAAAAACAAAAAAAAAAACAUAAAAERE9XTgEAAAADZXhwAAAAAQAAAAF4CQAAbAAAAAYFAAAAAWUAAAAAAAAAAAgFAAAAAXgAAAAAAAAAAAgAAAAAAAAAAAgFAAAABERPV04BAAAACG1ub3plbmllAAAAAgAAAAF4AAAAAXkJAABrAAAAAwUAAAABeAUAAAABeQAAAAAABfXhAAEAAAAJZHppZWxlbmllAAAAAgAAAAF4AAAAAXkJAABrAAAAAwUAAAABeAAAAAAABfXhAAUAAAABeQAAAAEAAAABaQEAAAAHd3ltaWFuYQAAAAAEAAAACm5vd3lwb3ppb20JAABkAAAAAgUAAAAGcG96aW9tCQAAawAAAAMAAAAAAAX14QAAAAAAAAAAAGQAAAAAAAAAAAEEAAAADGt3b3Rhd3ltaWFueQAAAAAAdzWUAAQAAAABYQkBAAAAA2V4cAAAAAEJAQAAAAJsbgAAAAEAAAAAAACYloADBwQAAAAHd3lwbGF0YQkAAGsAAAADCQAAaAAAAAIFAAAABGJhemEJAABlAAAAAgkBAAAAAmxuAAAAAQUAAAAKbm93eXBvemlvbQkBAAAAAmxuAAAAAQUAAAAGcG96aW9tAAAAAAAAAAABAAAAAAAAAABkCQAETAAAAAIJAQAAAA5TY3JpcHRUcmFuc2ZlcgAAAAMIBQAAAAFpAAAABmNhbGxlcgUAAAAHd3lwbGF0YQEAAAAACQAETAAAAAIJAQAAAAxJbnRlZ2VyRW50cnkAAAACAgAAAAZQb3ppb20FAAAACm5vd3lwb3ppb20JAARMAAAAAgkBAAAADEludGVnZXJFbnRyeQAAAAICAAAAA2ludAUAAAAHd3lwbGF0YQUAAAADbmlsBAAAAAd3eXBsYXRhCQAAZQAAAAIFAAAABnBvemlvbQkBAAAACWR6aWVsZW5pZQAAAAIFAAAABnBvemlvbQkBAAAAA2V4cAAAAAEJAABpAAAAAgUAAAAMa3dvdGF3eW1pYW55BQAAAARiYXphCQAETAAAAAIJAQAAAAxJbnRlZ2VyRW50cnkAAAACAgAAAANpbnQFAAAAB3d5cGxhdGEFAAAAA25pbAAAAAACWzFm", "height": 1368932, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 3KP4m4bQ2gTStnR74GPPNN4E3Nv3Gr4SJwwtsTgoJmdp Next: 89q6Ydr7DwQXxrD718oP7J1MR3oZoDhSoDQzZAstm9ut Diff:
OldNewDifferences
1919 func exp (x) = pow(e, 8, x, 8, 8, DOWN)
2020
2121
22-func mnozenie (x,y) = fraction(x, y, 100000000000)
22+func mnozenie (x,y) = fraction(x, y, 100000000)
2323
2424
25-func dzielenie (x,y) = fraction(x, 100000000000, y)
25+func dzielenie (x,y) = fraction(x, 100000000, y)
2626
2727
2828 @Callable(i)
3636 [ScriptTransfer(i.caller, wyplata, base58''), IntegerEntry("Poziom", nowypoziom), IntegerEntry("int", wyplata)]
3737 }
3838 else {
39- let wyplata = exp((kwotawymiany / baza))
39+ let wyplata = (poziom - dzielenie(poziom, exp((kwotawymiany / baza))))
4040 [IntegerEntry("int", wyplata)]
4141 }
4242 }
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 4 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let e = 271828182
55
66 let kwotarownowagi = 1000
77
88 let baza = (kwotarownowagi / 2)
99
1010 let poziom = 60000000000
1111
1212 let balansUSDN = 1000
1313
1414 let balansUSDT = 1000
1515
1616 func ln (x) = log(x, 8, e, 8, 8, DOWN)
1717
1818
1919 func exp (x) = pow(e, 8, x, 8, 8, DOWN)
2020
2121
22-func mnozenie (x,y) = fraction(x, y, 100000000000)
22+func mnozenie (x,y) = fraction(x, y, 100000000)
2323
2424
25-func dzielenie (x,y) = fraction(x, 100000000000, y)
25+func dzielenie (x,y) = fraction(x, 100000000, y)
2626
2727
2828 @Callable(i)
2929 func wymiana () = {
3030 let nowypoziom = (poziom + fraction(100000000, 100, 1))
3131 let kwotawymiany = 2000000000
3232 let a = exp(ln(10000000))
3333 if (false)
3434 then {
3535 let wyplata = fraction((baza * (ln(nowypoziom) - ln(poziom))), 1, 100)
3636 [ScriptTransfer(i.caller, wyplata, base58''), IntegerEntry("Poziom", nowypoziom), IntegerEntry("int", wyplata)]
3737 }
3838 else {
39- let wyplata = exp((kwotawymiany / baza))
39+ let wyplata = (poziom - dzielenie(poziom, exp((kwotawymiany / baza))))
4040 [IntegerEntry("int", wyplata)]
4141 }
4242 }
4343
4444

github/deemru/w8io/169f3d6 
88.20 ms