This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
sci4me's profile picture

KLottery - A Krist Lottery!

Started by sci4me, 14 February 2016 - 09:11 PM
sci4me #1
Posted 14 February 2016 - 10:11 PM
KLottery
KLottery is a lottery for Krist.

A single lottery ticket costs 1 KST. To buy a ticket all you have to do is send Krist to the lottery purchase address, displayed on the lottery homepage.

KLottery also has a ComputerCraft program:

pastebin get dm3nu8hL klottery

Credits:
sci4me - writing the KLottery server and hosting it
Lemmmy - writing the KLottery frontend
3d6 - writing the ComputerCraft program
wojbie - writing the big letter API
Yevano - was sort of there
Edited on 15 February 2016 - 08:44 PM
Lemmmy #2
Posted 14 February 2016 - 10:12 PM
its good!!
Edited on 14 February 2016 - 09:15 PM
sci4me #3
Posted 14 February 2016 - 10:14 PM
its good!!

thanks!
Edited on 14 February 2016 - 09:14 PM
Lignum #4
Posted 14 February 2016 - 10:17 PM
I gave it a few tries before this was released and I loved the concept! It'll certainly help people acquire KST now that it's so hard to mine. Great job on this!
3d6 #5
Posted 14 February 2016 - 10:27 PM
Very happy that this has been released! Thanks wojbie, the CC program looks really nice with your api :)/>
bauen1 #6
Posted 15 February 2016 - 06:13 PM
I would suggest a static (no web socket, no fancy updating) page, because some devices / browsers don't support them.
LDDestroier #7
Posted 15 February 2016 - 07:11 PM
Ohh, who won? Who won? It should say that.
3d6 #8
Posted 15 February 2016 - 08:11 PM
Ohh, who won? Who won? It should say that.
It broadcasts the winner through Firefox notifications, I'm not sure if that works in Chrome
Lignum #9
Posted 15 February 2016 - 08:13 PM
It broadcasts the winner through Firefox notifications, I'm not sure if that works in Chrome

It does work in Chrome. Though I agree it should show the last winner on the page.
Luca_S #10
Posted 15 February 2016 - 08:59 PM
where is the warning that it is addictive :P/>
3d6 #11
Posted 15 February 2016 - 09:13 PM
Absolutely incredible, someone went all in with 1300 KST and won almost 100x that
minizbot2012 #12
Posted 15 February 2016 - 09:14 PM
Thanks Mate!
Luca_S #13
Posted 15 February 2016 - 09:15 PM
It was coz of a typo, I wanted to put 7000 and put 70000 :(/>
minizbot2012 #14
Posted 15 February 2016 - 09:16 PM
Well thanks for your krist tho, altho if you want the 63000 back just give me your krist address :)/>
Luca_S #15
Posted 15 February 2016 - 09:16 PM
klucaund08, thanks :D/>
minizbot2012 #16
Posted 15 February 2016 - 09:17 PM
Sent :)/>
Luca_S #17
Posted 15 February 2016 - 09:19 PM
Should've double checked that, thanks for giving me that back.
sci4me #18
Posted 15 February 2016 - 09:20 PM
I am planning a major rewrite of KLottery which will have lots of improvements and UI additions.
When I finish this rewrite I plan to make it open source so you can trust that I'm not stealing your Krist.
minizbot2012 #19
Posted 15 February 2016 - 09:20 PM
No problem mate, honestly, I wasn't expecting to win :|
Luca_S #20
Posted 15 February 2016 - 09:23 PM
I might wanna write an auto betting program like automatically put in 1KST per round, is there any documentation of the API. I mean I could painfully follow the path of the counter on the website, but if you would've a documentation that would be awesome.
3d6 #21
Posted 15 February 2016 - 09:25 PM
I might wanna write an auto betting program like automatically put in 1KST per round, is there any documentation of the API. I mean I could painfully follow the path of the counter on the website, but if you would've a documentation that would be awesome.
You could make a program place a 1 KST bet if the jackpot goes above 3 KST (at which point you would win more than 1 KST after the commission is taken out)

http://klottery.sci4me.com/pot
http://klottery.sci4me.com/address
Edited on 15 February 2016 - 08:26 PM
Luca_S #22
Posted 15 February 2016 - 09:29 PM
Ok, thanks :D/>
EDIT: I will make some quick thing in Java and then publish it for everyone who wants to do the same thing
Edited on 15 February 2016 - 08:30 PM
sci4me #23
Posted 15 February 2016 - 09:41 PM
API? For what?

(there is some API-like stuff that I will document…)
3d6 #24
Posted 15 February 2016 - 09:46 PM
Speaking of, an API for seconds left until the drawing would be cool ;)/>
sci4me #25
Posted 15 February 2016 - 09:48 PM
Right now all there is for an "API" is two GET requests:


/pot
/address

It's relatively obvious what they do.
minizbot2012 #26
Posted 15 February 2016 - 09:53 PM
Guys, I'm sorry…. I am the kst address kic4g00t0y…. I don't know why I keep winning D:
Edited on 15 February 2016 - 08:53 PM
3d6 #27
Posted 15 February 2016 - 09:55 PM
Guys, I'm sorry…. I am the kst address kic4g00t0y…. I don't know why I keep winning D:
It's because you keep placing large bets that give you good odds of winning :P/>
minizbot2012 #28
Posted 15 February 2016 - 09:56 PM
Now that I've won tho, its driving me mad D: I feel sorry now… IDK why….

also that massive jackpot someone did a 70000 kst bet…
Edited on 15 February 2016 - 08:57 PM
3d6 #29
Posted 15 February 2016 - 09:58 PM
Now that I've won tho, its driving me mad D: I feel sorry now… IDK why….
It's okay though! You went into the top 1% of addresses overnight fair and square. That was really lucky ;)/>
minizbot2012 #30
Posted 15 February 2016 - 10:00 PM
SNIP: Offtopic

Edit: I guess it is very much shell-shock of going to the top in a day.
Edited on 15 February 2016 - 09:02 PM
sci4me #31
Posted 15 February 2016 - 10:01 PM
Well when is kristscape going to be done? I want to make a web client for my chat app now (which is read-only right now)

This is kinda off topic. Should go in the Krist thread really.
Luca_S #32
Posted 15 February 2016 - 10:29 PM
Ok my program seems to work, gonna upload it.

EDIT: Here we go: https://www.dropbox.com/s/92m928tc9cabdd0/autobid.zip?dl=0

Also is there a way to see the winner without desktop notifications?
Edited on 15 February 2016 - 09:28 PM
3d6 #33
Posted 15 February 2016 - 10:30 PM
A list of historical winners and their prizes would be cool
Luca_S #34
Posted 15 February 2016 - 10:35 PM
my problem is I disabled desktop notification and now safari thinks I wanted to ban the site from asking me EVER again about desktop notifications.

would someone put 4 KST pls so I can check if it works.
Luca_S #35
Posted 15 February 2016 - 10:46 PM
k thanks everything worked perfectly
sci4me #36
Posted 15 February 2016 - 11:00 PM
Historical winners is something i intend to. add on the rewrite.
No promises on when this will happen though.
3d6 #37
Posted 15 February 2016 - 11:43 PM
Oh! A call for the datetime when the next drawing occurs would be better! :)/>
sci4me #38
Posted 15 February 2016 - 11:47 PM
Oh! A call for the datetime when the next drawing occurs would be better! :)/>

This will probably be added too.
Pyuu #39
Posted 16 February 2016 - 02:04 AM
Well, since I'm absolutely poor on kst because I gave away nearly 2k (which was all) of my kst to randoms so I could start over, I'm gonna bet 5kst for a while and see what happens….
minizbot2012 #40
Posted 16 February 2016 - 02:15 AM
Once again, I won 7000+ kst….
3d6 #41
Posted 16 February 2016 - 02:20 AM
Once again, I won 7000+ kst….
on a 1000 KST bet…
minizbot2012 #42
Posted 16 February 2016 - 02:21 AM
with a 7000 kst bet to go against

EDIT: Going in with a 250 kst bet

EDIT 2: GOING ALL IN!!
Edited on 16 February 2016 - 01:39 AM
3d6 #43
Posted 16 February 2016 - 02:40 AM
84,189 KST pot… let's see how this goes…

edit: 85K
Edited on 16 February 2016 - 01:43 AM
minizbot2012 #44
Posted 16 February 2016 - 02:41 AM
I'd suggest if you had even 1 kst put it in

Edit: Kristwallet is crashing on line 649 with attempt to compare nil with number…
Edited on 16 February 2016 - 01:44 AM
apemanzilla #45
Posted 16 February 2016 - 02:47 AM
I'd suggest if you had even 1 kst put it in

Edit: Kristwallet is crashing on line 649 with attempt to compare nil with number…

KWallet works although it's been a while since I've updated it.
minizbot2012 #46
Posted 16 February 2016 - 02:54 AM
Thanks!

damn, lost it :(/>
3d6 #47
Posted 16 February 2016 - 02:56 AM
Yevano himself took home the 239,428 KST jackpot just now!!
Edited on 16 February 2016 - 01:56 AM
minizbot2012 #48
Posted 16 February 2016 - 02:57 AM
Yevano himself took home the 239,428 KST jackpot just now!!
And the number 1 man who has kst
justync7 #49
Posted 16 February 2016 - 02:58 AM
Yevano himself took home the 239,428 KST jackpot just now!!
And the number 1 man who has kst
RIP miniz's small fortune (and mine too)
minizbot2012 #50
Posted 16 February 2016 - 02:58 AM
Hey its a nice end to the day :)/>

Had too much damn fun :D/>

Plus now I have a GTX 970 mining for me :)/>

WHAT HAVE I DONE??
Edited on 16 February 2016 - 02:02 AM
Pyuu #51
Posted 16 February 2016 - 03:03 AM
I have GT 930, only at 60MH/s on average. I suck.
3d6 #52
Posted 16 February 2016 - 03:05 AM
Hey its a nice end to the day :)/>

Had too much damn fun :D/>
lol yeah you're going down in cc history that's for sure
justync7 #53
Posted 16 February 2016 - 03:05 AM
I have GT 930, only at 60MH/s on average. I suck.
Uhh… My 940M gets 150MH/s… You might be doing something wrong?
minizbot2012 #54
Posted 16 February 2016 - 03:07 AM
I get 1 GH/s I like my GPU :)/>


Hey its a nice end to the day :)/>/>

Had too much damn fun :D/>/>
lol yeah you're going down in cc history that's for sure

Why would I be in history for cc?
3d6 #55
Posted 16 February 2016 - 03:11 AM
I get 1 GH/s I like my GPU :)/>


Hey its a nice end to the day :)/>/>

Had too much damn fun :D/>/>
lol yeah you're going down in cc history that's for sure

Why would I be in history for cc?

Because of your legendary winning streak ;)/>
apemanzilla #56
Posted 16 February 2016 - 03:12 AM
I get 1 GH/s I like my GPU :)/>


Hey its a nice end to the day :)/>/>

Had too much damn fun :D/>/>
lol yeah you're going down in cc history that's for sure

Why would I be in history for cc?

Because of your legendary winning streak ;)/>

And then the fatal fall…
minizbot2012 #57
Posted 16 February 2016 - 03:14 AM
I get 1 GH/s I like my GPU :)/>/>/>


Hey its a nice end to the day :)/>/>/>/>

Had too much damn fun :D/>/>/>/>
lol yeah you're going down in cc history that's for sure

Why would I be in history for cc?

Because of your legendary winning streak ;)/>/>/>

Hey I usually am very lucky but as engineers tell us "never trade luck for skill"

I think I am going to work on the chat thing again this was the BEST day I've had in a LONG time and for that I thank you. Goodnight everyone!
Edited on 16 February 2016 - 02:32 AM
FoxData #58
Posted 16 June 2016 - 07:33 PM
How do i know if i won or not?
apemanzilla #59
Posted 16 June 2016 - 09:46 PM
How do i know if i won or not?

You'll receive a bunch of Krist.
FoxData #60
Posted 16 June 2016 - 10:43 PM
How do i know if i won or not?

You'll receive a bunch of Krist.

I don't get it. I send 32kst and i get 32kst back.

I thought the whole point of this is to get double the kst back (32kst = 64kst)
Anavrins #61
Posted 16 June 2016 - 10:52 PM
I don't get it. I send 32kst and i get 32kst back.
Because that's definitely how lottery works, right?
The goal is that many people will pitch an amount, which will build up the pot.
At each payout, each people has a chance of winning the whole pot,
meaning that if you were playing alone, you will of course win back your 32kst.
Edited on 16 June 2016 - 08:52 PM
H4X0RZ #62
Posted 18 June 2016 - 12:11 PM
Is there an API call which gives you the time left?
ry00000 #63
Posted 18 June 2016 - 12:34 PM
GT 930, 64-ish MH/s. I suck at mining.
apemanzilla #64
Posted 18 June 2016 - 03:04 PM
GT 930, 64-ish MH/s. I suck at mining.

Why did you post this in the KLottery thread?

Is there an API call which gives you the time left?

http://klottery.sci4me.com/address and http://klottery.sci4me.com/pot
Edited on 18 June 2016 - 01:05 PM
ry00000 #65
Posted 18 June 2016 - 03:23 PM
- le snip -

Why did you post this in the KLottery thread?

-snippity snip-

I don't really know.
Edited on 18 June 2016 - 01:24 PM