Bitcoin Forum
May 06, 2024, 12:55:05 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1] 2 »  All
  Print  
Author Topic: smart contract (btc) that pays out winning bet in price prediction game?  (Read 353 times)
600watt (OP)
Legendary
*
Offline Offline

Activity: 2338
Merit: 2106



View Profile
March 31, 2019, 06:46:54 AM
Last edit: March 31, 2019, 10:05:28 AM by 600watt
 #1

dear forum members,


I would like to start a betting game within this forum. a simple price prediction game about the price of btc end of the year. whoever wants to participate needs to pay some fraction of btc. winning bet takes it all. usually an escrow would be needed to collect the btc of the participants and later pays out to the winner. but since btc is programmable money I rather not rely on an escrow but on a smart contract that:

-controls the btc address that the betting game participants are using to pay their fee
-recognizes what the price is on a certain exchange at a certain time (bitstamp $ price on dec 31st 2019)
-recognizes which bet is closest to actual price
-transfers the btc to the winner automatically


is that possible? if yes, how complicated? whom can i ask to write it? how can I be sure the programmer is not scamming me/us?

plan is to make it as expensive as 0.1 btc to place a bet. for those who don´t want to risk that much it is allowed to for a pool (for example 10 members pay 0.01 and form a pool that can place a bet) my aim is 50 bets minimum, so the winner will collect 5 btc.


thank you  Smiley


edit:

some think that an entry price of 0.1 btc to too high. the idea is that members could team up and form a pool.  a team devides the entry price within themselves. if 10 members form a pool it lowers their individual entry for a bet 10x. they would only invest 0.01 btc. if that is still too much they can find more members to form an even bigger pool.

1714956905
Hero Member
*
Offline Offline

Posts: 1714956905

View Profile Personal Message (Offline)

Ignore
1714956905
Reply with quote  #2

1714956905
Report to moderator
1714956905
Hero Member
*
Offline Offline

Posts: 1714956905

View Profile Personal Message (Offline)

Ignore
1714956905
Reply with quote  #2

1714956905
Report to moderator
1714956905
Hero Member
*
Offline Offline

Posts: 1714956905

View Profile Personal Message (Offline)

Ignore
1714956905
Reply with quote  #2

1714956905
Report to moderator
"In a nutshell, the network works like a distributed timestamp server, stamping the first transaction to spend a coin. It takes advantage of the nature of information being easy to spread but hard to stifle." -- Satoshi
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1714956905
Hero Member
*
Offline Offline

Posts: 1714956905

View Profile Personal Message (Offline)

Ignore
1714956905
Reply with quote  #2

1714956905
Report to moderator
1714956905
Hero Member
*
Offline Offline

Posts: 1714956905

View Profile Personal Message (Offline)

Ignore
1714956905
Reply with quote  #2

1714956905
Report to moderator
machasm
Hero Member
*****
Offline Offline

Activity: 784
Merit: 796



View Profile
March 31, 2019, 07:58:53 AM
 #2

I can't help with the smart contract but would suggest that the number of participants be increased and the entry price lowered. So it appeals to more people.

Carolina
bc1qtm5d24nycxqfqzdtj33zh9m9wn2cdek6v4kkck
600watt (OP)
Legendary
*
Offline Offline

Activity: 2338
Merit: 2106



View Profile
March 31, 2019, 08:07:52 AM
 #3

I can't help with the smart contract but would suggest that the number of participants be increased and the entry price lowered. So it appeals to more people.


entry price can be lowered by participants themselves. you can team up with as many members as you wish and form a pool. if, for example 2 participants form a pool then their entry is not 0.1, but 0.05 for each. when 10 members form a team then it is only 0.01 btc.
Pmalek
Legendary
*
Offline Offline

Activity: 2758
Merit: 7132



View Profile
March 31, 2019, 08:14:04 AM
 #4

Smart contracts are a thing of Ethereum. Bitcoin can work with smart contracts only on a side chain. RSK is a smart contract network created for the Bitcoin network. https://www.rsk.co/
Not sure what else is available when it comes to smart contracts and bitcoin.

.
.BLACKJACK ♠ FUN.
█████████
██████████████
████████████
█████████████████
████████████████▄▄
░█████████████▀░▀▀
██████████████████
░██████████████
████████████████
░██████████████
████████████
███████████████░██
██████████
CRYPTO CASINO &
SPORTS BETTING
▄▄███████▄▄
▄███████████████▄
███████████████████
█████████████████████
███████████████████████
█████████████████████████
█████████████████████████
█████████████████████████
███████████████████████
█████████████████████
███████████████████
▀███████████████▀
█████████
.
Globb0
Legendary
*
Offline Offline

Activity: 2674
Merit: 2053


Free spirit


View Profile
March 31, 2019, 08:47:27 AM
Last edit: March 31, 2019, 09:08:01 AM by Globb0
Merited by 600watt (1)
 #5

Yeah I was thinking the idea through. Some thoughts, not about the contracts bit.

Cost
0.1 might limit participants
0.01 if you get 10 times the people will be the same prize.
Community thoughts on this advised to be sought


Price guesses
The should probably a guess at fixed range instead of a set price say 3500 to 3549   (preset slots)


Other thoughts
Allowing multiple entries would enable someone who wanted to bet 0.1 to have the same odds as in the higher roller version

Rules set and guidance notes
Need some rules and guidance around what if a blank space wins, how do you determine the winner and when etc.
Perhaps on a blank, it goes to the next highest entrant, that might encourage a few extra higher bets with a big "luck" range


I was only thinking escrow tbh, I don't know much about smart contract except my million nothing tokens on ether somewhere.
djhomeschool
Full Member
***
Offline Offline

Activity: 340
Merit: 164


View Profile
March 31, 2019, 08:55:12 AM
 #6

Yeah I was thinking the idea through. Some thoughts, not about the contracts bit.

Cost
A - 0.1 might limit participants
0.01 if you get 10 times the people will be the same prize.
Community thoughts on this advised to be sought


Price guesses
B - The should probably a guess at fixed range instead of a set price say 3500 to 3549


Other thoughts
Allowing multiple entries would enable someone who wanted to bet 0.1 to have the same odds as in the higher roller version

Rules set and guidance notes
Need some rules and guidance around what if a blank space wins, how do you determine the winner and when etc.
Perhaps on a blank, it goes to the next highest entrant, that might encourage a few extra higher bets with a big "luck" range


I was only thinking escrow tbh, I don't know much about smart contract except my million nothing tokens on ether somewhere.


A - Uh no....
B - Maybe it's better to go for set price or closest to it.
El duderino_
Legendary
*
Offline Offline

Activity: 2506
Merit: 12041


BTC + Crossfit, living life.


View Profile
March 31, 2019, 09:05:36 AM
Merited by 600watt (1)
 #7

Yeah I was thinking the idea through. Some thoughts, not about the contracts bit.

Cost
0.1 might limit participants
0.01 if you get 10 times the people will be the same prize.
Community thoughts on this advised to be sought


Price guesses
The should probably a guess at fixed range instead of a set price say 3500 to 3549


Other thoughts
Allowing multiple entries would enable someone who wanted to bet 0.1 to have the same odds as in the higher roller version

Rules set and guidance notes
Need some rules and guidance around what if a blank space wins, how do you determine the winner and when etc.
Perhaps on a blank, it goes to the next highest entrant, that might encourage a few extra higher bets with a big "luck" range


I was only thinking escrow tbh, I don't know much about smart contract except my million nothing tokens on ether somewhere.


I also thought of the range but we are still thinking for best rules etc

I maybe would think closest to a price like for example I choose  7000 than between a determined number let us say 20 "still thinking what would be good" nobody can choose anything between 6980 and 7020 or so, maybe higher number?

cause of-course many chose later on because its not fun to get someone a dollar above your price, certainly not when there is some @stake from your own pocket.

and a blank never can win if the closest to it wins...

if 0.1 is to high then maybe 0.05 or so? cause the option to make a pool is still their and its the same thing ...

also I don't know is it best one player one guess or could we allow more guesses from a single person? its stays the same and its better for the price pool of-course ...

still everybody keep the idea's coming

THX and sure its a good idea from 600watt


also we can ask a good forum member to HOLD the send BTC, maybe for a game like this one will do it for free, cause its all that goes in goes to the winner 



XhomerX10 designed my nice avatar HATs!!!!!  Thanks Bro
LoyceV
Legendary
*
Offline Offline

Activity: 3304
Merit: 16600


Thick-Skinned Gang Leader and Golden Feather 2021


View Profile WWW
March 31, 2019, 09:13:46 AM
 #8

I tried something similar with a 0.001BTC buy-in, and nobody joined.
Micgoossens runs free prediction games, and got 155 entries in the most recent one.

I don't think you'll find anything close to 50 participants willing to pay 0.1BTC.

El duderino_
Legendary
*
Offline Offline

Activity: 2506
Merit: 12041


BTC + Crossfit, living life.


View Profile
March 31, 2019, 09:37:53 AM
 #9

I tried something similar with a 0.001BTC buy-in, and nobody joined.
Micgoossens runs free prediction games, and got 155 entries in the most recent one.

I don't think you'll find anything close to 50 participants willing to pay 0.1BTC.

maybe, but also never know it maybe could intrest more other people... like they do a raffle for an item, there the host wins some, here the winner takes all and their is a chance to play with a small amount and maybe to win some FULL BTC, and if it wouldn't work then it was just a try Smiley
but i like the idea

XhomerX10 designed my nice avatar HATs!!!!!  Thanks Bro
600watt (OP)
Legendary
*
Offline Offline

Activity: 2338
Merit: 2106



View Profile
March 31, 2019, 10:08:58 AM
 #10

I tried something similar with a 0.001BTC buy-in, and nobody joined.
Micgoossens runs free prediction games, and got 155 entries in the most recent one.

I don't think you'll find anything close to 50 participants willing to pay 0.1BTC.


maybe if we team up and try again it will gain some traction. I plan to find some sponsors who are willing to spice up the amount that can be won. I already have one member who is willing to donate 1 btc for this game.
600watt (OP)
Legendary
*
Offline Offline

Activity: 2338
Merit: 2106



View Profile
March 31, 2019, 10:20:36 AM
 #11

Yeah I was thinking the idea through. Some thoughts, not about the contracts bit.

Cost
0.1 might limit participants
0.01 if you get 10 times the people will be the same prize.
Community thoughts on this advised to be sought


Price guesses
The should probably a guess at fixed range instead of a set price say 3500 to 3549


Other thoughts
Allowing multiple entries would enable someone who wanted to bet 0.1 to have the same odds as in the higher roller version

Rules set and guidance notes
Need some rules and guidance around what if a blank space wins, how do you determine the winner and when etc.
Perhaps on a blank, it goes to the next highest entrant, that might encourage a few extra higher bets with a big "luck" range


I was only thinking escrow tbh, I don't know much about smart contract except my million nothing tokens on ether somewhere.


I also thought of the range but we are still thinking for best rules etc

I maybe would think closest to a price like for example I choose  7000 than between a determined number let us say 20 "still thinking what would be good" nobody can choose anything between 6980 and 7020 or so, maybe higher number?

cause of-course many chose later on because its not fun to get someone a dollar above your price, certainly not when there is some @stake from your own pocket.

and a blank never can win if the closest to it wins...

if 0.1 is to high then maybe 0.05 or so? cause the option to make a pool is still their and its the same thing ...

also I don't know is it best one player one guess or could we allow more guesses from a single person? its stays the same and its better for the price pool of-course ...

still everybody keep the idea's coming

THX and sure its a good idea from 600watt


also we can ask a good forum member to HOLD the send BTC, maybe for a game like this one will do it for free, cause its all that goes in goes to the winner 





ranges seem a good idea.

how about $50 slots? if one wants to bet $6100 the bet would cover a range between 6100 and 6149.99 

if winning/actual price is not covered by bet then the closest one wins. it is possible that the actual price will be right in the middle of two bets. then both bets win 50% of price.
El duderino_
Legendary
*
Offline Offline

Activity: 2506
Merit: 12041


BTC + Crossfit, living life.


View Profile
March 31, 2019, 10:42:33 AM
 #12

I tried something similar with a 0.001BTC buy-in, and nobody joined.
Micgoossens runs free prediction games, and got 155 entries in the most recent one.

I don't think you'll find anything close to 50 participants willing to pay 0.1BTC.


maybe if we team up and try again it will gain some traction. I plan to find some sponsors who are willing to spice up the amount that can be won. I already have one member who is willing to donate 1 btc for this game.

WoW with free gifts it surely Will get Some traction
Then it get way more interesting for people to join with Some extra to win
Nicely done

And Maybe Some taking more than 1 slot as well.... etc

XhomerX10 designed my nice avatar HATs!!!!!  Thanks Bro
LoyceV
Legendary
*
Offline Offline

Activity: 3304
Merit: 16600


Thick-Skinned Gang Leader and Golden Feather 2021


View Profile WWW
March 31, 2019, 10:47:11 AM
 #13

cause of-course many chose later on because its not fun to get someone a dollar above your price, certainly not when there is some @stake from your own pocket.
I came up with the (rather complicated) system of signing a message, posting the signature, and keeping the message private until everybody has joined. That gives all participants equal opportunities and you can't choose a dollar above someone else's guess.

El duderino_
Legendary
*
Offline Offline

Activity: 2506
Merit: 12041


BTC + Crossfit, living life.


View Profile
March 31, 2019, 10:50:08 AM
 #14

Like also if someones friend is interested and wanna bid under a members name...?

Like i take my price and Maybe Some friend of me wanna participate as well and i take another guess for them or so....

I think it could gain Some traction but we Will see ofcourse and the donated BTc Will surely make it very appealing to participate imo

XhomerX10 designed my nice avatar HATs!!!!!  Thanks Bro
600watt (OP)
Legendary
*
Offline Offline

Activity: 2338
Merit: 2106



View Profile
March 31, 2019, 11:13:15 AM
 #15

cause of-course many chose later on because its not fun to get someone a dollar above your price, certainly not when there is some @stake from your own pocket.
I came up with the (rather complicated) system of signing a message, posting the signature, and keeping the message private until everybody has joined. That gives all participants equal opportunities and you can't choose a dollar above someone else's guess.

it would be indeed a good thing if participants would not know what others picked. i am afraid though that if we start to make signing messages mandatory we will lose participants who need/want it easy. how about that bets be set only through PM towards "game managers" (for example micgossens) who then publishes the bet but leaves out the picked value. it would look like

"april 24th 2019: member mr example has placed a valid bet on $xxxx. btc fee is paid."

if two bets want the same spot, the later incoming bet gets notified that slot was taken already and that he/they need to pick a different slot.  on a certain date AFTER the betting is closed, all real bet values get published.
Last of the V8s
Legendary
*
Offline Offline

Activity: 1652
Merit: 4392


Be a bank


View Profile
March 31, 2019, 11:21:56 AM
 #16

the slots are way too big as currently envisaged - $50. all the most sensible slots would get snapped up very quickly

smart contracts are not a thing in bitcoin.

600watt (OP)
Legendary
*
Offline Offline

Activity: 2338
Merit: 2106



View Profile
March 31, 2019, 11:30:30 AM
 #17

the slots are way too big as currently envisaged - $50. all the most sensible slots would get snapped up very quickly

smart contracts are not a thing in bitcoin.



can there be script that executes such a contract? if not then we would have to have an escrow or mic or me are doing this.
Last of the V8s
Legendary
*
Offline Offline

Activity: 1652
Merit: 4392


Be a bank


View Profile
March 31, 2019, 11:44:14 AM
 #18

the slots are way too big as currently envisaged - $50. all the most sensible slots would get snapped up very quickly

smart contracts are not a thing in bitcoin.

can there be script that executes such a contract? if not then we would have to have an escrow or mic or me are doing this.

no. it's totally unrealistic at this stage. maybe Augur or something is working on that sort of thing but it's not safe and not necessary.
escrow is fine and proven


further thoughts - you might have to pay the escrow
actually keep the number of entrants small, keep it down to known forum entities, otherwise you will have to have address signing.
people may be more willing to take part if a % of the pot goes to a charity

LoyceV
Legendary
*
Offline Offline

Activity: 3304
Merit: 16600


Thick-Skinned Gang Leader and Golden Feather 2021


View Profile WWW
March 31, 2019, 11:58:38 AM
Merited by 600watt (1)
 #19

it would be indeed a good thing if participants would not know what others picked. i am afraid though that if we start to make signing messages mandatory we will lose participants who need/want it easy. how about that bets be set only through PM towards "game managers" (for example micgossens) who then publishes the bet but leaves out the picked value. it would look like
I choose signed messages to make it provably fair: everyone is responsible for keeping his own guess safe. The problem with using a game manager is that it can't be verified he doesn't share the numbers in private, and even if he doesn't share them, he can never prove that he didn't. One way or another, it can lead to drama.

we would have to have an escrow or mic or me are doing this.
A multisig escrow could work too.

Last of the V8s
Legendary
*
Offline Offline

Activity: 1652
Merit: 4392


Be a bank


View Profile
March 31, 2019, 12:04:07 PM
 #20

random slots for entrants would solve some of the problems but create others  Undecided
just a thought

Pages: [1] 2 »  All
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!