smeagol (OP)
Legendary
Offline
Activity: 1008
Merit: 1005
|
|
October 20, 2013, 05:46:44 PM |
|
How do people make dice sites?
Is it just something like this:
<?php $client_choice = (user input) $number = rand(0,1000); if $number == $client_choice { send bitcoins!; } else { keep bitcoins for yourself!; } ?>
|
|
|
|
imrer
|
|
October 20, 2013, 09:08:15 PM |
|
I'll have a casino game wheel of fortune for sale. PM me in 4 days, if you are interested.
|
|
|
|
devthedev
Legendary
Offline
Activity: 1050
Merit: 1004
|
|
November 03, 2013, 06:03:03 PM |
|
smeagol, usually they're provably fair. rand( is not provably fair.
|
|
|
|
smeagol (OP)
Legendary
Offline
Activity: 1008
Merit: 1005
|
|
November 03, 2013, 08:06:15 PM |
|
smeagol, usually they're provably fair. rand( is not provably fair.
How?
|
|
|
|
trcjr
Newbie
Offline
Activity: 10
Merit: 0
|
|
November 03, 2013, 10:13:39 PM |
|
If srand is seeded with a known value then the random numbers it generates will be reproducible. After the random number is generated the seed to srand is published.
|
|
|
|
smeagol (OP)
Legendary
Offline
Activity: 1008
Merit: 1005
|
|
November 08, 2013, 10:25:28 PM |
|
How do you make a script which automatically either doubles or keeps a senders money?
I think that is easier to do.
|
|
|
|
EventualCoinMillionaire
Member
Offline
Activity: 83
Merit: 10
|
|
January 31, 2014, 06:48:09 PM |
|
I would definitely like to hear more about this.
|
BTC 1juX6F2mgRCMS6meMmH8yjtDXD16GwVfm DOGE DFznCPX2usMnxzVto2hmcMckhPGyXWVXrZ RDD RcCqrHqmVh1jF197psMBiYPGdtnoQwREVQ
|
|
|
roslinpl
Legendary
Offline
Activity: 2212
Merit: 1199
|
|
January 31, 2014, 06:58:53 PM |
|
True, if you want to make a good proffable game you need to use kryptography
|
|
|
|
Ins
|
|
January 31, 2014, 07:36:20 PM |
|
For example, I can explain how system works at satoshidice.com There are secret key for every day of year. If you play today - you see only sha256 hash of secret key. Secret key is random generated value of a-Z0-9. Most of dice websites using hmac_sha512 function. As you know, each transaction have it's transaction id (sha256 hash). Depending on tx id lucky number is generated. Satoshidice use's hmac sha 512 function like hmac_sha512(txid:nonce, secret_key_plain); On day after, you can see plain secret key and verify your yesterday bet Read http://php.net/manual/en/function.hash-hmac.php, if you use PHP
|
|
|
|
MakeBelieve
|
|
January 31, 2014, 07:42:35 PM |
|
Is it simple to make the dice game provably fair it doesn't make sense to me at the moment.
|
On a mission to make Bitcointalk.org Marketplace a safer place to Buy/Sell/Trade
|
|
|
RoooooR
Legendary
Offline
Activity: 1008
Merit: 1000
GigTricks.io | A CRYPTO ECOSYSTEM FOR ON-DEMAND EC
|
|
February 01, 2014, 10:04:52 PM |
|
How do people make dice sites?
Is it just something like this:
<?php $client_choice = (user input) $number = rand(0,1000); if $number == $client_choice { send bitcoins!; } else { keep bitcoins for yourself!; } ?>
The payout part for the dice game(just-dice etc..) (1/(chance/100)*((100-house_edge)/100))
|
|
|
|
smeagol (OP)
Legendary
Offline
Activity: 1008
Merit: 1005
|
|
February 02, 2014, 10:45:34 PM |
|
It's easy to make the game, the hard part is implementing bitcoin.
|
|
|
|
Ins
|
|
February 03, 2014, 01:50:22 PM |
|
It is not hard. It depends on your selection: Libraries OR Bitcoind JSONRPC if you want to use some libraries and work without bitcoind - it would be enough harder. It will be easier if you will use JSON RPC it is easy to create address, check transactions, send money
|
|
|
|
jontstaz
Member
Offline
Activity: 84
Merit: 10
|
|
February 03, 2014, 11:03:27 PM |
|
It is not hard. It depends on your selection: Libraries OR Bitcoind JSONRPC if you want to use some libraries and work without bitcoind - it would be enough harder. It will be easier if you will use JSON RPC it is easy to create address, check transactions, send money Exactly this. If you want you can even use the Block chain RPC API.
|
|
|
|
smeagol (OP)
Legendary
Offline
Activity: 1008
Merit: 1005
|
|
February 04, 2014, 02:31:31 AM |
|
It is not hard. It depends on your selection: Libraries OR Bitcoind JSONRPC if you want to use some libraries and work without bitcoind - it would be enough harder. It will be easier if you will use JSON RPC it is easy to create address, check transactions, send money Exactly this. If you want you can even use the Block chain RPC API. It's just that I don't want to hit the cap on the API and get blocked
|
|
|
|
jontstaz
Member
Offline
Activity: 84
Merit: 10
|
|
February 05, 2014, 03:35:28 AM |
|
It is not hard. It depends on your selection: Libraries OR Bitcoind JSONRPC if you want to use some libraries and work without bitcoind - it would be enough harder. It will be easier if you will use JSON RPC it is easy to create address, check transactions, send money Exactly this. If you want you can even use the Block chain RPC API. It's just that I don't want to hit the cap on the API and get blocked I wasn't aware of a cap. What is the cap out of interest?
|
|
|
|
smeagol (OP)
Legendary
Offline
Activity: 1008
Merit: 1005
|
|
February 05, 2014, 02:55:53 PM |
|
I wasn't aware of a cap. What is the cap out of interest?
Requests in 8 Hours: 3 (Soft Limit = 28800, Hard Limit = 28900) Requests in 5 minutes: 3 (Soft Limit = 700, Hard Limit = 725) (That is from their site)
|
|
|
|
|