tx · CnH9ZLeojYMkxUTd3n57rWbjzCqCuxZaTimXHeTwSmRQ

3NAnRuBVqxLCPnNiypVVsEamCuGWkG3itwK:  -0.01000000 Waves

2019.06.22 20:58 [553582] smart account 3NAnRuBVqxLCPnNiypVVsEamCuGWkG3itwK > SELF 0.00000000 Waves

{ "type": 13, "id": "CnH9ZLeojYMkxUTd3n57rWbjzCqCuxZaTimXHeTwSmRQ", "fee": 1000000, "feeAssetId": null, "timestamp": 1561226368020, "version": 1, "sender": "3NAnRuBVqxLCPnNiypVVsEamCuGWkG3itwK", "senderPublicKey": "HUjT7EDCnpKhRYEcwyEudn1ccHVByxDzp541WnqrnzQy", "proofs": [ "3Mw1wMjvHoco94kx7k8FpRgNPbTLEUUiBmFzVeDEHW3zYr8zpCpA8myQhTFy3kBU8euggfUMfFAae3Aaogm1nX9u" ], "script": "base64:AAIDAAAAAAAAAAAAAAARAAAAAAhJZHhQcmljZQAAAAAAAAAAAAAAAAAJSWR4QW1vdW50AAAAAAAAAAABAAAAAAxJZHhUcmFkZVBhaXIAAAAAAAAAAAIAAAAADElkeE9yZGVyVHlwZQAAAAAAAAAAAwAAAAAJSWR4U2VuZGVyAAAAAAAAAAAEAAAAAApJZHhBc3NldElkAAAAAAAAAAAFAAAAAANCVVkCAAAAA0JVWQAAAAAEU0VMTAIAAAAEU0VMTAEAAAAQcmV0YWluTWF0Y2hlckZlZQAAAAEAAAAGYW1vdW50CQAAawAAAAMFAAAABmFtb3VudAAAAAAAAAAD5wAAAAAAAAAD6AEAAAAKbWF0Y2hlckZlZQAAAAEAAAAGYW1vdW50CQAAZQAAAAIFAAAABmFtb3VudAkAAGsAAAADBQAAAAZhbW91bnQAAAAAAAAAA+cAAAAAAAAAA+gBAAAAGVJlbW92ZVVuZGVyc2NvcmVJZlByZXNlbnQAAAABAAAACXJlbWFpbmluZwMJAABmAAAAAgkAATEAAAABBQAAAAlyZW1haW5pbmcAAAAAAAAAAAAJAAEwAAAAAgUAAAAJcmVtYWluaW5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2hlckZlZQAAAAEFAAAAEHByaWNlQXNzZXRBbW91bnQJAQAAABFhc3NldElkRnJvbVN0cmluZwAAAAEJAAGRAAAAAgUAAAAJc2VsbE9yZGVyBQAAAApJZHhBc3NldElkCQAETAAAAAIJAQAAAA5TY3JpcHRUcmFuc2ZlcgAAAAMIBQAAAAFpAAAABmNhbGxlcgkBAAAACm1hdGNoZXJGZWUAAAABBQAAABFhbW91bnRBc3NldEFtb3VudAkBAAAAEWFzc2V0SWRGcm9tU3RyaW5nAAAAAQkAAZEAAAACBQAAAAhidXlPcmRlcgUAAAAKSWR4QXNzZXRJZAkABEwAAAACCQEAAAAOU2NyaXB0VHJhbnNmZXIAAAADCAUAAAABaQAAAAZjYWxsZXIJAQAAAAptYXRjaGVyRmVlAAAAAQUAAAAQcHJpY2VBc3NldEFtb3VudAkBAAAAEWFzc2V0SWRGcm9tU3RyaW5nAAAAAQkAAZEAAAACBQAAAAlzZWxsT3JkZXIFAAAACklkeEFzc2V0SWQFAAAAA25pbAAAAAFpAQAAABFyZWdpc3RlclRyYWlkUGFpcgAAAAMAAAAGYXNzZXQxAAAACnByaWNlQXNzZXQAAAAJdHJhaWRQYWlyCQEAAAAIV3JpdGVTZXQAAAABCQAETAAAAAIJAQAAAAlEYXRhRW50cnkAAAACCQABLAAAAAIJAAEsAAAAAgUAAAAGYXNzZXQxAgAAAAEvBQAAAApwcmljZUFzc2V0BQAAAAl0cmFpZFBhaXIFAAAAA25pbAAAAABt2o8M", "chainId": 84, "height": 553582, "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 a = 0
5+
6+let b = 1
7+
8+let c = 2
9+
10+let d = 3
11+
12+let e = 4
13+
14+let f = 5
15+
16+let g = "BUY"
17+
18+let h = "SELL"
19+
20+func i (j) = fraction(j, 999, 1000)
21+
22+
23+func k (j) = (j - fraction(j, 999, 1000))
24+
25+
26+func l (m) = if ((size(m) > 0))
27+ then drop(m, 1)
28+ else m
29+
30+
31+func n (o) = {
32+ let p = size(o)
33+ if ((p == 0))
34+ then throw("Parameter size must be greater then 0")
35+ else if ((p > 99))
36+ then throw("Parameter size must be less then 100")
37+ else if ((10 > p))
38+ then (("0" + toString(p)) + o)
39+ else (toString(p) + o)
40+ }
41+
42+
43+func q (m) = {
44+ let p = size(m)
45+ if ((p > 0))
46+ then {
47+ let r = parseIntValue(take(m, 2))
48+ let s = take(drop(m, 2), r)
49+ let t = drop(m, (r + 2))
50+ let u = l(t)
51+[s, u]
52+ }
53+ else throw("Empty string was passed into parseNextAttribute func")
54+ }
55+
56+
57+func v (w,x,y,z,j,A) = {
58+ let B = ((((((((((n(w) + "_") + n(x)) + "_") + n(y)) + "_") + n(toString(z))) + "_") + n(toString(j))) + "_") + n(A))
59+ B
60+ }
61+
62+
63+func C (D) = {
64+ let E = q(D)
65+ let x = q(E[1])
66+ let y = q(x[1])
67+ let z = q(y[1])
68+ let j = q(z[1])
69+ let A = q(j[1])
70+[z[0], j[0], E[0], y[0], x[0], A[0]]
71+ }
72+
73+
74+func F (G) = if ((G == 0))
75+ then 1
76+ else if ((G == 1))
77+ then 10
78+ else if ((G == 2))
79+ then 100
80+ else if ((G == 3))
81+ then 1000
82+ else if ((G == 4))
83+ then 10000
84+ else if ((G == 5))
85+ then 100000
86+ else if ((G == 6))
87+ then 1000000
88+ else if ((G == 7))
89+ then 10000000
90+ else if ((G == 8))
91+ then 100000000
92+ else if ((G == 9))
93+ then 1000000000
94+ else if ((G == 10))
95+ then 10000000000
96+ else if ((G == 11))
97+ then 100000000000
98+ else if ((G == 12))
99+ then 1000000000000
100+ else throw("Pow10 more then 12 is not supported")
101+
102+
103+func H (A) = if (if ((A == "WAVES"))
104+ then true
105+ else (A == ""))
106+ then unit
107+ else fromBase58String(A)
108+
109+
110+@Callable(I)
111+func order (A,z) = {
112+ let J = extract(I.payment)
113+ let K = if (isDefined(J.assetId))
114+ then toBase58String(value(J.assetId))
115+ else "WAVES"
116+ let L = getString(this, ((A + "/") + K))
117+ let M = getString(this, ((K + "/") + A))
118+ let w = if (isDefined(L))
119+ then value(L)
120+ else if (isDefined(M))
121+ then value(M)
122+ else throw("Traiding for that assets is not supported")
123+ let y = if (isDefined(L))
124+ then g
125+ else h
126+ let N = v(w, toBase58String(I.caller.bytes), y, z, J.amount, A)
127+ WriteSet([DataEntry(toBase58String(I.transactionId), N)])
128+ }
129+
130+
131+
132+@Callable(I)
133+func matchOrders (O,P) = {
134+ let Q = C(getStringValue(this, O))
135+ let R = C(getStringValue(this, P))
136+ if ((Q[c] != R[c]))
137+ then throw("Trying to match orders from different trading pairs")
138+ else if ((Q[d] == R[d]))
139+ then throw("Trying to match orders of the same type")
140+ else {
141+ let S = (Q[d] == h)
142+ let T = if (S)
143+ then Q
144+ else R
145+ let U = if (!(S))
146+ then Q
147+ else R
148+ let V = parseIntValue(T[a])
149+ let W = parseIntValue(U[a])
150+ let X = parseIntValue(T[b])
151+ let Y = parseIntValue(U[b])
152+ if ((V > W))
153+ then throw("Orders are not match by price")
154+ else {
155+ let Z = V
156+ let aa = if ((U[f] == "WAVES"))
157+ then 8
158+ else value(assetInfo(value(H(U[f])))).decimals
159+ let ab = if ((T[f] == "WAVES"))
160+ then 8
161+ else value(assetInfo(value(H(T[f])))).decimals
162+ let ac = ((Y * F(aa)) / Z)
163+ let ad = X
164+ let ae = if ((ac >= ad))
165+ then ad
166+ else ac
167+ let af = ((ae * Z) / F(aa))
168+ let ag = v(U[c], U[e], U[d], W, (Y - af), U[f])
169+ let ah = v(T[c], T[e], T[d], V, (X - ae), T[f])
170+ ScriptResult(WriteSet([DataEntry(if (!(S))
171+ then O
172+ else P, ag), DataEntry(if (S)
173+ then O
174+ else P, ah)]), TransferSet([ScriptTransfer(addressFromStringValue(U[e]), i(ae), H(U[f])), ScriptTransfer(addressFromStringValue(T[e]), i(af), H(T[f])), ScriptTransfer(I.caller, k(ae), H(U[f])), ScriptTransfer(I.caller, k(af), H(T[f]))]))
175+ }
176+ }
177+ }
178+
179+
180+
181+@Callable(I)
182+func registerTraidPair (ai,aj,w) = WriteSet([DataEntry(((ai + "/") + aj), w)])
183+
184+

github/deemru/w8io/026f985 
24.38 ms