tx · 7Jibi6PwQYbnjLc22B49PiCURZnSwycn1DMETTcDQ7u5

3N4ynz2uyA7cErymQd46zgwVJEEfXYDRXtA:  -0.02000000 Waves

2023.08.10 07:49 [2704030] smart account 3N4ynz2uyA7cErymQd46zgwVJEEfXYDRXtA > SELF 0.00000000 Waves

{ "type": 13, "id": "7Jibi6PwQYbnjLc22B49PiCURZnSwycn1DMETTcDQ7u5", "fee": 2000000, "feeAssetId": null, "timestamp": 1691643002246, "version": 2, "chainId": 84, "sender": "3N4ynz2uyA7cErymQd46zgwVJEEfXYDRXtA", "senderPublicKey": "CiRX9ubobzbD36ZwTyuBFiPnPkmzMQ7GDsF3hMoVbcVR", "proofs": [ "cAH2MHALjuGQAXg93mdw4ggT7eRnLNMni3UFCNxtjvqBN7XRBQuQvB2g1zfLQUJhq1pF3pNCGp8ffVQB5rxJTxo" ], "script": "base64:AAIFAAAAAAAAABYIAhIICgYBAQEBAQQSAwoBARIDCgEBAAAADwAAAAAjcHJlc2FsZV90aW1lc3RhbXBfY29udHJvbGxlcl9wdWJrZXkBAAAAIOOt17LUijbWojwDE5tgFkw1Y8cwIr3jselcewpp7rwjAAAAABJjb250cm9sbGVyX2FkZHJlc3MJAQAAABRhZGRyZXNzRnJvbVB1YmxpY0tleQAAAAEFAAAAI3ByZXNhbGVfdGltZXN0YW1wX2NvbnRyb2xsZXJfcHVia2V5AAAAAAd0c2Vycm9yAgAAADxFbmQgVGltZXN0YW1wIGNhbid0IGJlIGxlc3MgdGhhbiBvciBlcXVhbCB0byBTdGFydCBUaW1lc3RhbXAAAAAACnByaWNlZXJyb3ICAAAAJlRva2VuIFByaWNlIGNhbid0IGJlIGxlc3MgdGhhbiBvciBaZXJvAAAAAAhjYXBlcnJvcgIAAAAzU29mdCBDYXAgQW1vdW50IGNhbid0IGJlIG1vcmUgdGhhbiBIYXJkIENhcCBBbW91bnQuAAAAAAhvcmRlcm1zZwIAAAAqPGgxPk9yZGVyIFN1Ym1pdHRlZCBTdWNjZXNz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SGFyZCBBbHJlYWR5IFJlYWNoZWQgZm9yIHRoaXMgUm91bmQuIFBsZWFzZSBDbGljayBvbiBDbGFpbSB0byBSZWNlaXZlIFlvdXIgVG9rZW5zLgkAAAIAAAABAgAAABFXcm9uZyBFdHJ5IEZvdW5kLgAAAAEAAAACdHgBAAAABnZlcmlmeQAAAAAJAAH0AAAAAwgFAAAAAnR4AAAACWJvZHlCeXRlcwkAAZEAAAACCAUAAAACdHgAAAAGcHJvb2ZzAAAAAAAAAAAACAUAAAACdHgAAAAPc2VuZGVyUHVibGljS2V5oWV9DQ==", "height": 2704030, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 9yRGktn9YvxTe56Pw1EtAxoRueg1FPKiCbqguNuwuBh9 Next: D8zMTsJX6ZyWM9q7hPUXYQ6un31czypbDTTDxXxv8w14 Diff:
OldNewDifferences
1515
1616 let g = "<h1>PreSale Parameters Submitted Successfully!</h1><br>"
1717
18-let h = "DApp Need WAVES Token as Attach payment[1]."
18+let h = "<h1>Refund Received Successfully!.</h1><br>"
1919
20-let i = "Attached payment[1] is less than token price "
20+let i = "DApp Need WAVES Token as Attach payment[1]."
2121
22-let j = "Dapp will start Pre-Sale at Timestamp "
22+let j = "Attached payment[1] is less than token price "
2323
24-let k = "Minimum 0.1 WAVES required on Your Address, Please hold min. 0.1 WAVES on your Address to place order."
24+let k = "Dapp will start Pre-Sale at Timestamp "
2525
26-let l = "Pre-Sale is over for this Round."
26+let l = "Minimum 0.1 WAVES required on Your Address, Please hold min. 0.1 WAVES on your Address to place order."
2727
28-@Callable(m)
29-func SetPreSaleParameters (n,o,p,q,r,s) = {
30- let t = n
31- let u = o
32- let v = {
33- let w = getInteger(this, "Current_Funding_Round")
34- if ($isInstanceOf(w, "Int"))
28+let m = "Pre-Sale is over for this Round."
29+
30+let n = "Pre-Sale is not over for this Round."
31+
32+let o = "PreSale was Set with False to Refund, so no Refund allowed for this Round."
33+
34+@Callable(p)
35+func SetPreSaleParameters (q,r,s,t,u,v) = {
36+ let w = q
37+ let x = r
38+ let y = {
39+ let z = getInteger(this, "Current_Funding_Round")
40+ if ($isInstanceOf(z, "Int"))
3541 then {
36- let x = w
37- x
42+ let A = z
43+ A
3844 }
3945 else 0
4046 }
41- let y = (v + 1)
42- if ((m.caller != b))
47+ let B = (y + 1)
48+ if ((p.caller != b))
4349 then throw((("This Address is not Authorized. Only " + toString(b)) + " is Authorized Address to Sign it."))
44- else if ((size(toString(n)) != 13))
50+ else if ((size(toString(q)) != 13))
4551 then throw("Start Timestamp is Wrong. Please Enter a Valid Timestamp. Probably you entered an Timestamp less than 13 Chars.")
46- else if ((size(toString(o)) != 13))
52+ else if ((size(toString(r)) != 13))
4753 then throw("End Timestamp is Wrong. Please Enter a Valid Timestamp. Probably you entered an Timestamp less than 13 Chars.")
48- else if ((1 > p))
54+ else if ((1 > s))
4955 then throw(d)
50- else if ((t >= u))
56+ else if ((w >= x))
5157 then throw(c)
52- else if ((q > r))
58+ else if ((t > u))
5359 then throw(e)
54- else [IntegerEntry("Current_Funding_Round", y), IntegerEntry((toString(y) + "_Presale_Start_TimeStamp"), t), IntegerEntry((toString(y) + "_Presale_End_TimeStamp"), u), IntegerEntry((toString(y) + "_Token_Price"), p), IntegerEntry((toString(y) + "_Soft_Cap_Amount"), q), IntegerEntry((toString(y) + "_Hard_Cap_Amount"), r), IntegerEntry((toString(y) + "_Initiated_Height"), height), BooleanEntry((toString(y) + "_Allow_Refund"), s), StringEntry("message", g)]
60+ else [IntegerEntry("Current_Funding_Round", B), IntegerEntry((toString(B) + "_Presale_Start_TimeStamp"), w), IntegerEntry((toString(B) + "_Presale_End_TimeStamp"), x), IntegerEntry((toString(B) + "_Token_Price"), s), IntegerEntry((toString(B) + "_Soft_Cap_Amount"), t), IntegerEntry((toString(B) + "_Hard_Cap_Amount"), u), IntegerEntry((toString(B) + "_Initiated_Height"), height), BooleanEntry((toString(B) + "_Allow_Refund"), v), StringEntry("message", g)]
5561 }
5662
5763
5864
59-@Callable(m)
60-func PlacePresaleOrder (z) = {
61- let A = valueOrErrorMessage(getInteger(this, (toString(z) + "_Token_Price")), "Token Price not Found for this Presale Round.")
62- let B = valueOrErrorMessage(getInteger(this, (toString(z) + "_Presale_Start_TimeStamp")), "Start Timestamp not Found for this Presale Round.")
63- let C = valueOrErrorMessage(getInteger(this, (toString(z) + "_Presale_End_TimeStamp")), "End Timestamp not Found for this Presale Round.")
64- let D = valueOrErrorMessage(getInteger(this, (toString(z) + "_Soft_Cap_Amount")), "Soft Cap Amount not Found for this Presale Round.")
65- let E = valueOrErrorMessage(getInteger(this, (toString(z) + "_Hard_Cap_Amount")), "Hard Cap Amount not Found for this Presale Round.")
66- let F = valueOrErrorMessage(getBoolean(this, (toString(z) + "_Allow_Refund")), "Refund is not set for this Presale Round.")
67- let G = unit
68- let H = toBase58String(m.caller.bytes)
69- let I = if ((size(m.payments) == 1))
70- then m.payments[0]
71- else throw(h)
72- let J = {
73- let w = getInteger(this, (toString(z) + "_Funds_Collection"))
74- if ($isInstanceOf(w, "Int"))
65+@Callable(p)
66+func PlacePresaleOrder (C) = {
67+ let D = valueOrErrorMessage(getInteger(this, (toString(C) + "_Token_Price")), "Token Price not Found for this Presale Round.")
68+ let E = valueOrErrorMessage(getInteger(this, (toString(C) + "_Presale_Start_TimeStamp")), "Start Timestamp not Found for this Presale Round.")
69+ let F = valueOrErrorMessage(getInteger(this, (toString(C) + "_Presale_End_TimeStamp")), "End Timestamp not Found for this Presale Round.")
70+ let G = valueOrErrorMessage(getInteger(this, (toString(C) + "_Soft_Cap_Amount")), "Soft Cap Amount not Found for this Presale Round.")
71+ let H = valueOrErrorMessage(getInteger(this, (toString(C) + "_Hard_Cap_Amount")), "Hard Cap Amount not Found for this Presale Round.")
72+ let I = valueOrErrorMessage(getBoolean(this, (toString(C) + "_Allow_Refund")), "Refund is not set for this Presale Round.")
73+ let J = unit
74+ let K = toBase58String(p.caller.bytes)
75+ let L = if ((size(p.payments) == 1))
76+ then p.payments[0]
77+ else throw(i)
78+ let M = {
79+ let z = getInteger(this, (toString(C) + "_Funds_Collection"))
80+ if ($isInstanceOf(z, "Int"))
7581 then {
76- let x = w
77- x
82+ let A = z
83+ A
7884 }
7985 else 0
8086 }
81- let K = (J + I.amount)
82- let L = {
83- let w = getInteger(this, (toString(z) + "_total_txns"))
84- if ($isInstanceOf(w, "Int"))
87+ let N = (M + L.amount)
88+ let O = {
89+ let z = getInteger(this, (toString(C) + "_total_txns"))
90+ if ($isInstanceOf(z, "Int"))
8591 then {
86- let x = w
87- x
92+ let A = z
93+ A
8894 }
8995 else 0
9096 }
91- let M = (L + 1)
92- let N = {
93- let w = getInteger(this, ((toString(z) + "_") + H))
94- if ($isInstanceOf(w, "Int"))
97+ let P = (O + 1)
98+ let Q = {
99+ let z = getInteger(this, ((toString(C) + "_") + K))
100+ if ($isInstanceOf(z, "Int"))
95101 then {
96- let x = w
97- x
102+ let A = z
103+ A
98104 }
99105 else 0
100106 }
101- let O = (N + I.amount)
102- let P = (D - K)
103- let Q = (E - K)
104- if (isDefined(I.assetId))
105- then throw(h)
106- else if ((A > I.amount))
107- then throw((((i + "[") + toString(A)) + "/10^8.]"))
108- else if ((B > lastBlock.timestamp))
109- then throw((j + toString(B)))
110- else if ((lastBlock.timestamp > C))
111- then throw(l)
112- else if (if ((P > 0))
113- then (Q > 0)
107+ let R = (Q + L.amount)
108+ let S = (G - N)
109+ let T = (H - N)
110+ if (isDefined(L.assetId))
111+ then throw(i)
112+ else if ((D > L.amount))
113+ then throw((((j + "[") + toString(D)) + "/10^8.]"))
114+ else if ((E > lastBlock.timestamp))
115+ then throw((k + toString(E)))
116+ else if ((lastBlock.timestamp > F))
117+ then throw(m)
118+ else if (if ((S > 0))
119+ then (T > 0)
114120 else false)
115- then [IntegerEntry((toString(z) + "_Funds_Collection"), K), IntegerEntry(((toString(z) + "_") + H), O), IntegerEntry((toString(z) + "_total_txns"), M), IntegerEntry((toString(z) + "_pending_softcap_status"), P), IntegerEntry((toString(z) + "_pending_hardcap_status"), Q), StringEntry((toString(z) + "_softcap_status"), "No"), StringEntry((toString(z) + "_hardcap_status"), "No"), BooleanEntry((toString(z) + "_Allow_Refund"), F), StringEntry("message", f)]
116- else if (if ((0 >= P))
117- then (Q > 0)
121+ then [IntegerEntry((toString(C) + "_Funds_Collection"), N), IntegerEntry(((toString(C) + "_") + K), R), IntegerEntry((toString(C) + "_total_txns"), P), IntegerEntry((toString(C) + "_pending_softcap_status"), S), IntegerEntry((toString(C) + "_pending_hardcap_status"), T), StringEntry((toString(C) + "_softcap_status"), "No"), StringEntry((toString(C) + "_hardcap_status"), "No"), BooleanEntry((toString(C) + "_Allow_Refund"), I), StringEntry("message", f)]
122+ else if (if ((0 >= S))
123+ then (T > 0)
118124 else false)
119- then [IntegerEntry((toString(z) + "_Funds_Collection"), K), IntegerEntry(((toString(z) + "_") + H), O), IntegerEntry((toString(z) + "_total_txns"), M), IntegerEntry((toString(z) + "_pending_softcap_status"), P), IntegerEntry((toString(z) + "_pending_hardcap_status"), Q), StringEntry((toString(z) + "_softcap_status"), "Yes"), StringEntry((toString(z) + "_hardcap_status"), "No"), BooleanEntry((toString(z) + "_Allow_Refund"), false), StringEntry("message", f)]
120- else if (if ((0 >= P))
121- then (0 >= Q)
125+ then [IntegerEntry((toString(C) + "_Funds_Collection"), N), IntegerEntry(((toString(C) + "_") + K), R), IntegerEntry((toString(C) + "_total_txns"), P), IntegerEntry((toString(C) + "_pending_softcap_status"), S), IntegerEntry((toString(C) + "_pending_hardcap_status"), T), StringEntry((toString(C) + "_softcap_status"), "Yes"), StringEntry((toString(C) + "_hardcap_status"), "No"), BooleanEntry((toString(C) + "_Allow_Refund"), false), StringEntry("message", f)]
126+ else if (if ((0 >= S))
127+ then (0 >= T)
122128 else false)
123- then [IntegerEntry((toString(z) + "_Funds_Collection"), K), IntegerEntry(((toString(z) + "_") + H), O), IntegerEntry((toString(z) + "_total_txns"), M), IntegerEntry((toString(z) + "_pending_softcap_status"), P), IntegerEntry((toString(z) + "_pending_hardcap_status"), Q), StringEntry((toString(z) + "_softcap_status"), "Yes"), StringEntry((toString(z) + "_hardcap_status"), "Yes"), BooleanEntry((toString(z) + "_Allow_Refund"), false), StringEntry("message", f)]
129+ then [IntegerEntry((toString(C) + "_Funds_Collection"), N), IntegerEntry(((toString(C) + "_") + K), R), IntegerEntry((toString(C) + "_total_txns"), P), IntegerEntry((toString(C) + "_pending_softcap_status"), S), IntegerEntry((toString(C) + "_pending_hardcap_status"), T), StringEntry((toString(C) + "_softcap_status"), "Yes"), StringEntry((toString(C) + "_hardcap_status"), "Yes"), BooleanEntry((toString(C) + "_Allow_Refund"), false), StringEntry("message", f)]
124130 else throw("Error.")
125131 }
126132
127133
128-@Verifier(R)
129-func S () = sigVerify(R.bodyBytes, R.proofs[0], R.senderPublicKey)
134+
135+@Callable(p)
136+func Refund (C) = {
137+ let K = toBase58String(p.caller.bytes)
138+ let D = valueOrErrorMessage(getInteger(this, (toString(C) + "_Token_Price")), "Token Price not Found for this Presale Round.")
139+ let E = valueOrErrorMessage(getInteger(this, (toString(C) + "_Presale_Start_TimeStamp")), "Start Timestamp not Found for this Presale Round.")
140+ let F = valueOrErrorMessage(getInteger(this, (toString(C) + "_Presale_End_TimeStamp")), "End Timestamp not Found for this Presale Round.")
141+ let G = valueOrErrorMessage(getInteger(this, (toString(C) + "_Soft_Cap_Amount")), "Soft Cap Amount not Found for this Presale Round.")
142+ let H = valueOrErrorMessage(getInteger(this, (toString(C) + "_Hard_Cap_Amount")), "Hard Cap Amount not Found for this Presale Round.")
143+ let U = valueOrErrorMessage(getInteger(this, (toString(C) + "_Funds_Collection")), "Total Funds Collection not Found for this Presale Round.")
144+ let Q = valueOrErrorMessage(getInteger(this, ((toString(C) + "_") + K)), "No Deposit was made by this Address for this Presale Round.")
145+ let I = valueOrErrorMessage(getBoolean(this, (toString(C) + "_Allow_Refund")), "Allow_Refund has no Boolen Entry for this Presale Round.")
146+ let S = (G - U)
147+ let T = (H - U)
148+ if ((F > lastBlock.timestamp))
149+ then throw(n)
150+ else if ((I == false))
151+ then throw(o)
152+ else if (if ((S > 0))
153+ then (T > 0)
154+ else false)
155+ then [ScriptTransfer(addressFromStringValue(K), Q, unit), IntegerEntry(((toString(C) + "_") + K), 0), StringEntry("message", h)]
156+ else if (if ((0 >= S))
157+ then (T > 0)
158+ else false)
159+ then throw("SoftCap Already Reached for this Round. Please Click on Claim to Receive Your Tokens.")
160+ else if (if ((0 >= S))
161+ then (0 >= T)
162+ else false)
163+ then throw("SoftCap and Hard Already Reached for this Round. Please Click on Claim to Receive Your Tokens.")
164+ else throw("Wrong Etry Found.")
165+ }
166+
167+
168+@Verifier(V)
169+func W () = sigVerify(V.bodyBytes, V.proofs[0], V.senderPublicKey)
130170
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let a = base58'GKmJ6BchUgQfwKp4mp5eX8Y9xLioYRm6e1gDfFgdAcCr'
55
66 let b = addressFromPublicKey(a)
77
88 let c = "End Timestamp can't be less than or equal to Start Timestamp"
99
1010 let d = "Token Price can't be less than or Zero"
1111
1212 let e = "Soft Cap Amount can't be more than Hard Cap Amount."
1313
1414 let f = "<h1>Order Submitted Successfully!</h1><br>"
1515
1616 let g = "<h1>PreSale Parameters Submitted Successfully!</h1><br>"
1717
18-let h = "DApp Need WAVES Token as Attach payment[1]."
18+let h = "<h1>Refund Received Successfully!.</h1><br>"
1919
20-let i = "Attached payment[1] is less than token price "
20+let i = "DApp Need WAVES Token as Attach payment[1]."
2121
22-let j = "Dapp will start Pre-Sale at Timestamp "
22+let j = "Attached payment[1] is less than token price "
2323
24-let k = "Minimum 0.1 WAVES required on Your Address, Please hold min. 0.1 WAVES on your Address to place order."
24+let k = "Dapp will start Pre-Sale at Timestamp "
2525
26-let l = "Pre-Sale is over for this Round."
26+let l = "Minimum 0.1 WAVES required on Your Address, Please hold min. 0.1 WAVES on your Address to place order."
2727
28-@Callable(m)
29-func SetPreSaleParameters (n,o,p,q,r,s) = {
30- let t = n
31- let u = o
32- let v = {
33- let w = getInteger(this, "Current_Funding_Round")
34- if ($isInstanceOf(w, "Int"))
28+let m = "Pre-Sale is over for this Round."
29+
30+let n = "Pre-Sale is not over for this Round."
31+
32+let o = "PreSale was Set with False to Refund, so no Refund allowed for this Round."
33+
34+@Callable(p)
35+func SetPreSaleParameters (q,r,s,t,u,v) = {
36+ let w = q
37+ let x = r
38+ let y = {
39+ let z = getInteger(this, "Current_Funding_Round")
40+ if ($isInstanceOf(z, "Int"))
3541 then {
36- let x = w
37- x
42+ let A = z
43+ A
3844 }
3945 else 0
4046 }
41- let y = (v + 1)
42- if ((m.caller != b))
47+ let B = (y + 1)
48+ if ((p.caller != b))
4349 then throw((("This Address is not Authorized. Only " + toString(b)) + " is Authorized Address to Sign it."))
44- else if ((size(toString(n)) != 13))
50+ else if ((size(toString(q)) != 13))
4551 then throw("Start Timestamp is Wrong. Please Enter a Valid Timestamp. Probably you entered an Timestamp less than 13 Chars.")
46- else if ((size(toString(o)) != 13))
52+ else if ((size(toString(r)) != 13))
4753 then throw("End Timestamp is Wrong. Please Enter a Valid Timestamp. Probably you entered an Timestamp less than 13 Chars.")
48- else if ((1 > p))
54+ else if ((1 > s))
4955 then throw(d)
50- else if ((t >= u))
56+ else if ((w >= x))
5157 then throw(c)
52- else if ((q > r))
58+ else if ((t > u))
5359 then throw(e)
54- else [IntegerEntry("Current_Funding_Round", y), IntegerEntry((toString(y) + "_Presale_Start_TimeStamp"), t), IntegerEntry((toString(y) + "_Presale_End_TimeStamp"), u), IntegerEntry((toString(y) + "_Token_Price"), p), IntegerEntry((toString(y) + "_Soft_Cap_Amount"), q), IntegerEntry((toString(y) + "_Hard_Cap_Amount"), r), IntegerEntry((toString(y) + "_Initiated_Height"), height), BooleanEntry((toString(y) + "_Allow_Refund"), s), StringEntry("message", g)]
60+ else [IntegerEntry("Current_Funding_Round", B), IntegerEntry((toString(B) + "_Presale_Start_TimeStamp"), w), IntegerEntry((toString(B) + "_Presale_End_TimeStamp"), x), IntegerEntry((toString(B) + "_Token_Price"), s), IntegerEntry((toString(B) + "_Soft_Cap_Amount"), t), IntegerEntry((toString(B) + "_Hard_Cap_Amount"), u), IntegerEntry((toString(B) + "_Initiated_Height"), height), BooleanEntry((toString(B) + "_Allow_Refund"), v), StringEntry("message", g)]
5561 }
5662
5763
5864
59-@Callable(m)
60-func PlacePresaleOrder (z) = {
61- let A = valueOrErrorMessage(getInteger(this, (toString(z) + "_Token_Price")), "Token Price not Found for this Presale Round.")
62- let B = valueOrErrorMessage(getInteger(this, (toString(z) + "_Presale_Start_TimeStamp")), "Start Timestamp not Found for this Presale Round.")
63- let C = valueOrErrorMessage(getInteger(this, (toString(z) + "_Presale_End_TimeStamp")), "End Timestamp not Found for this Presale Round.")
64- let D = valueOrErrorMessage(getInteger(this, (toString(z) + "_Soft_Cap_Amount")), "Soft Cap Amount not Found for this Presale Round.")
65- let E = valueOrErrorMessage(getInteger(this, (toString(z) + "_Hard_Cap_Amount")), "Hard Cap Amount not Found for this Presale Round.")
66- let F = valueOrErrorMessage(getBoolean(this, (toString(z) + "_Allow_Refund")), "Refund is not set for this Presale Round.")
67- let G = unit
68- let H = toBase58String(m.caller.bytes)
69- let I = if ((size(m.payments) == 1))
70- then m.payments[0]
71- else throw(h)
72- let J = {
73- let w = getInteger(this, (toString(z) + "_Funds_Collection"))
74- if ($isInstanceOf(w, "Int"))
65+@Callable(p)
66+func PlacePresaleOrder (C) = {
67+ let D = valueOrErrorMessage(getInteger(this, (toString(C) + "_Token_Price")), "Token Price not Found for this Presale Round.")
68+ let E = valueOrErrorMessage(getInteger(this, (toString(C) + "_Presale_Start_TimeStamp")), "Start Timestamp not Found for this Presale Round.")
69+ let F = valueOrErrorMessage(getInteger(this, (toString(C) + "_Presale_End_TimeStamp")), "End Timestamp not Found for this Presale Round.")
70+ let G = valueOrErrorMessage(getInteger(this, (toString(C) + "_Soft_Cap_Amount")), "Soft Cap Amount not Found for this Presale Round.")
71+ let H = valueOrErrorMessage(getInteger(this, (toString(C) + "_Hard_Cap_Amount")), "Hard Cap Amount not Found for this Presale Round.")
72+ let I = valueOrErrorMessage(getBoolean(this, (toString(C) + "_Allow_Refund")), "Refund is not set for this Presale Round.")
73+ let J = unit
74+ let K = toBase58String(p.caller.bytes)
75+ let L = if ((size(p.payments) == 1))
76+ then p.payments[0]
77+ else throw(i)
78+ let M = {
79+ let z = getInteger(this, (toString(C) + "_Funds_Collection"))
80+ if ($isInstanceOf(z, "Int"))
7581 then {
76- let x = w
77- x
82+ let A = z
83+ A
7884 }
7985 else 0
8086 }
81- let K = (J + I.amount)
82- let L = {
83- let w = getInteger(this, (toString(z) + "_total_txns"))
84- if ($isInstanceOf(w, "Int"))
87+ let N = (M + L.amount)
88+ let O = {
89+ let z = getInteger(this, (toString(C) + "_total_txns"))
90+ if ($isInstanceOf(z, "Int"))
8591 then {
86- let x = w
87- x
92+ let A = z
93+ A
8894 }
8995 else 0
9096 }
91- let M = (L + 1)
92- let N = {
93- let w = getInteger(this, ((toString(z) + "_") + H))
94- if ($isInstanceOf(w, "Int"))
97+ let P = (O + 1)
98+ let Q = {
99+ let z = getInteger(this, ((toString(C) + "_") + K))
100+ if ($isInstanceOf(z, "Int"))
95101 then {
96- let x = w
97- x
102+ let A = z
103+ A
98104 }
99105 else 0
100106 }
101- let O = (N + I.amount)
102- let P = (D - K)
103- let Q = (E - K)
104- if (isDefined(I.assetId))
105- then throw(h)
106- else if ((A > I.amount))
107- then throw((((i + "[") + toString(A)) + "/10^8.]"))
108- else if ((B > lastBlock.timestamp))
109- then throw((j + toString(B)))
110- else if ((lastBlock.timestamp > C))
111- then throw(l)
112- else if (if ((P > 0))
113- then (Q > 0)
107+ let R = (Q + L.amount)
108+ let S = (G - N)
109+ let T = (H - N)
110+ if (isDefined(L.assetId))
111+ then throw(i)
112+ else if ((D > L.amount))
113+ then throw((((j + "[") + toString(D)) + "/10^8.]"))
114+ else if ((E > lastBlock.timestamp))
115+ then throw((k + toString(E)))
116+ else if ((lastBlock.timestamp > F))
117+ then throw(m)
118+ else if (if ((S > 0))
119+ then (T > 0)
114120 else false)
115- then [IntegerEntry((toString(z) + "_Funds_Collection"), K), IntegerEntry(((toString(z) + "_") + H), O), IntegerEntry((toString(z) + "_total_txns"), M), IntegerEntry((toString(z) + "_pending_softcap_status"), P), IntegerEntry((toString(z) + "_pending_hardcap_status"), Q), StringEntry((toString(z) + "_softcap_status"), "No"), StringEntry((toString(z) + "_hardcap_status"), "No"), BooleanEntry((toString(z) + "_Allow_Refund"), F), StringEntry("message", f)]
116- else if (if ((0 >= P))
117- then (Q > 0)
121+ then [IntegerEntry((toString(C) + "_Funds_Collection"), N), IntegerEntry(((toString(C) + "_") + K), R), IntegerEntry((toString(C) + "_total_txns"), P), IntegerEntry((toString(C) + "_pending_softcap_status"), S), IntegerEntry((toString(C) + "_pending_hardcap_status"), T), StringEntry((toString(C) + "_softcap_status"), "No"), StringEntry((toString(C) + "_hardcap_status"), "No"), BooleanEntry((toString(C) + "_Allow_Refund"), I), StringEntry("message", f)]
122+ else if (if ((0 >= S))
123+ then (T > 0)
118124 else false)
119- then [IntegerEntry((toString(z) + "_Funds_Collection"), K), IntegerEntry(((toString(z) + "_") + H), O), IntegerEntry((toString(z) + "_total_txns"), M), IntegerEntry((toString(z) + "_pending_softcap_status"), P), IntegerEntry((toString(z) + "_pending_hardcap_status"), Q), StringEntry((toString(z) + "_softcap_status"), "Yes"), StringEntry((toString(z) + "_hardcap_status"), "No"), BooleanEntry((toString(z) + "_Allow_Refund"), false), StringEntry("message", f)]
120- else if (if ((0 >= P))
121- then (0 >= Q)
125+ then [IntegerEntry((toString(C) + "_Funds_Collection"), N), IntegerEntry(((toString(C) + "_") + K), R), IntegerEntry((toString(C) + "_total_txns"), P), IntegerEntry((toString(C) + "_pending_softcap_status"), S), IntegerEntry((toString(C) + "_pending_hardcap_status"), T), StringEntry((toString(C) + "_softcap_status"), "Yes"), StringEntry((toString(C) + "_hardcap_status"), "No"), BooleanEntry((toString(C) + "_Allow_Refund"), false), StringEntry("message", f)]
126+ else if (if ((0 >= S))
127+ then (0 >= T)
122128 else false)
123- then [IntegerEntry((toString(z) + "_Funds_Collection"), K), IntegerEntry(((toString(z) + "_") + H), O), IntegerEntry((toString(z) + "_total_txns"), M), IntegerEntry((toString(z) + "_pending_softcap_status"), P), IntegerEntry((toString(z) + "_pending_hardcap_status"), Q), StringEntry((toString(z) + "_softcap_status"), "Yes"), StringEntry((toString(z) + "_hardcap_status"), "Yes"), BooleanEntry((toString(z) + "_Allow_Refund"), false), StringEntry("message", f)]
129+ then [IntegerEntry((toString(C) + "_Funds_Collection"), N), IntegerEntry(((toString(C) + "_") + K), R), IntegerEntry((toString(C) + "_total_txns"), P), IntegerEntry((toString(C) + "_pending_softcap_status"), S), IntegerEntry((toString(C) + "_pending_hardcap_status"), T), StringEntry((toString(C) + "_softcap_status"), "Yes"), StringEntry((toString(C) + "_hardcap_status"), "Yes"), BooleanEntry((toString(C) + "_Allow_Refund"), false), StringEntry("message", f)]
124130 else throw("Error.")
125131 }
126132
127133
128-@Verifier(R)
129-func S () = sigVerify(R.bodyBytes, R.proofs[0], R.senderPublicKey)
134+
135+@Callable(p)
136+func Refund (C) = {
137+ let K = toBase58String(p.caller.bytes)
138+ let D = valueOrErrorMessage(getInteger(this, (toString(C) + "_Token_Price")), "Token Price not Found for this Presale Round.")
139+ let E = valueOrErrorMessage(getInteger(this, (toString(C) + "_Presale_Start_TimeStamp")), "Start Timestamp not Found for this Presale Round.")
140+ let F = valueOrErrorMessage(getInteger(this, (toString(C) + "_Presale_End_TimeStamp")), "End Timestamp not Found for this Presale Round.")
141+ let G = valueOrErrorMessage(getInteger(this, (toString(C) + "_Soft_Cap_Amount")), "Soft Cap Amount not Found for this Presale Round.")
142+ let H = valueOrErrorMessage(getInteger(this, (toString(C) + "_Hard_Cap_Amount")), "Hard Cap Amount not Found for this Presale Round.")
143+ let U = valueOrErrorMessage(getInteger(this, (toString(C) + "_Funds_Collection")), "Total Funds Collection not Found for this Presale Round.")
144+ let Q = valueOrErrorMessage(getInteger(this, ((toString(C) + "_") + K)), "No Deposit was made by this Address for this Presale Round.")
145+ let I = valueOrErrorMessage(getBoolean(this, (toString(C) + "_Allow_Refund")), "Allow_Refund has no Boolen Entry for this Presale Round.")
146+ let S = (G - U)
147+ let T = (H - U)
148+ if ((F > lastBlock.timestamp))
149+ then throw(n)
150+ else if ((I == false))
151+ then throw(o)
152+ else if (if ((S > 0))
153+ then (T > 0)
154+ else false)
155+ then [ScriptTransfer(addressFromStringValue(K), Q, unit), IntegerEntry(((toString(C) + "_") + K), 0), StringEntry("message", h)]
156+ else if (if ((0 >= S))
157+ then (T > 0)
158+ else false)
159+ then throw("SoftCap Already Reached for this Round. Please Click on Claim to Receive Your Tokens.")
160+ else if (if ((0 >= S))
161+ then (0 >= T)
162+ else false)
163+ then throw("SoftCap and Hard Already Reached for this Round. Please Click on Claim to Receive Your Tokens.")
164+ else throw("Wrong Etry Found.")
165+ }
166+
167+
168+@Verifier(V)
169+func W () = sigVerify(V.bodyBytes, V.proofs[0], V.senderPublicKey)
130170

github/deemru/w8io/169f3d6 
82.93 ms