Title: CoinDice modifications
Post by: Groc on March 17, 2014, 04:44:03 PM
Lets keep this thread for CoinDice modifications :)
Coindice can be purchased here: https://bitcointalk.org/index.php?topic=507515.msg5597989#msg5597989 (https://bitcointalk.org/index.php?topic=507515.msg5597989#msg5597989) or from johny1976
MAKE CHANGES AT YOUR OWN RISK
Title: Re: CoinDice modifications
Post by: Groc on March 17, 2014, 04:48:25 PM
Add a F.A.Q: Open index.php find: <a href="#" onclick="javascript:return account();">ACCOUNT</a> and add below it: <a href="#" onclick="javascript:return faq();">F.A.Q</a> Open up /js/includer.php and find: type:"info", opacity:0.8, buttons: [{ value: "Close" }], }); return false; }
and add below it: function faq() { $.msgBox({ title:"Frequently Asked Questions", content:"<div id='faircon'><br>1. <b>What is the house edge? </b><br>The house edge is only 2%. We deduct 2% from your multiplier <br><Br>2. <b>Can I play as soon as I deposit?</b> <br>Yes, we accept 0 confirmation deposits. Your deposit will appear as your balance within several seconds. <br><Br>3. <b>How long will it take to receieve my cashout</b><br>Cashouts are instant in most cases. However, please keep in mind your initial deposit has to reach 1 confirmation before it will be sent. <br/><br/>4. <b>What is Provably Fair?</b><br/>Provably Fair is a unique sha256 hash to prove each and every bet made on our website is 100% legit. <br/><Br/> 5. <b>What does the \"High Roller\" tab represent?</b><br/>This tab acts as a filter between smaller bets and larger risks for your viewing entertainment. Be sure to check out this tab to see all the recent big bets! </div>", type:"info", opacity:0.8, buttons: [{ value: "Close" }], }); return false; } That's for anyone who wants to add a F.A.Q to their site. Thanks for the HOW-TO for users who wants to add F.A.Q. Just for clarification, don't use <div id='faircon'> as it is the identificator div for other purpose. change ID "faircon" to something else, e.g. "faqid"
Title: Re: CoinDice modifications
Post by: Groc on March 17, 2014, 04:59:24 PM
This is a patch for double deposit bug. ... /var/www/content/cron/check_deposits.php if ($delExed==true) { + if (mysql_query("SELECT COUNT(*) FROM transactions WHERE txid = '$dp[txid]'") >= 1) { + echo "TXID already exists!"; + } + else { mysql_query("UPDATE `players` SET `balance`=TRUNCATE(ROUND((`balance`+$received),9),8) WHERE `id`=$dp[player_id] LIMIT 1"); mysql_query("INSERT INTO `transactions` (`player_id`,`amount`,`txid`) VALUES ($dp[player_id],$dp[amount],'$dp[txid]')"); + }
Note: This is a fix for Coindice 2, Coindice 3 implemented their own fix.
|