Aside: I had some recent exchanges with the operator of the site, and it seemed they were pretty okay with the idea of these bots. Obviously the cards are stacked against users of the bot and in their favor so it's in their interest, but in case there were concerns about this.
---
Here is another serious hack job of this bot which uses a very different strategy than martingale. Instead, this bot tries to make very small wins by being tuned to the 5x and/or 10x circle jackpots. Essentially it ramps up the bet to make up for losses IF the jackpot is hit, and then a little bit. The idea is to be able to stretch the runs out much further and minimize the case of catastrophe. Sorry this code is so ugly. Clearly I'm hacking around. BTW, to use this bot "as is", aside from putting your secret in, you must also have unlocked the 5x wheel. You should expect that this bot may run up to at least 120-150 iterations before hitting the jackpot. Losing 20+ times in a row will cause you some grief on the amounts it will want to bet, so as always, starting very small is a good idea.
I've also added a parameter to enable a bet as a percentage of your balance.
// Forum discussion at http://goo.gl/b4XsJ
//
// how to use:
//
// adjust parameters and bailout points appropriately below. You can change the "circle" you want to use
// or
// sign up at: https://satoshicircle.com/?aid=843
//
// donations greatly appreciated!
// BTC: 1LJ5qXEqveTvdFZFkvDk9MhpyDRCicLPT8
// LTC: LcdnGybqvgfTKSV4yCscbZoDTTQiicuVw9
//
//
date_default_timezone_set ('America/Los_Angeles');
$AcctInfo = array ();
// $AcctInfo ['CookieFile'] = '/tmp/sc-cookies-' . posix_getpid();
// first visit https://satoshicircle.com/?aid=843
// then you need to grab the secret out of your url and plaster it in here.
$secret = "YOUR-SECRET-HERE";
$jackpotwin = 3;
$startbetbalancepctg = 0.02; // set to -1 to use fixed bet
// $startbet = 0.0005; // use a fixed start bet
$minbet = $startbet;
$bailpctglessbalance = 0.7;
// if our balance drops to this percentage below the highest balance we have seen, then stop.
// YOU MUST HAVE UNLOCKED THE 5X CIRCLE FOR THIS BOT.
$idgame = 2;
// 1 is the "3x" circle. 9/17
// 2 is the "5x" circle. 7/17
// 3 is the "10x" circle. 5/17
// 4 is the "2x" circle. 8/17 NOT TESTED PROBABLY BAD DONT USE.
$idbet = "";
$clientseed = rand (); // stick whatever you like here; change it or random or whatever.
$iter = 1;
$consecerr = 0; // exit after this many consecutive errors.
$ttlbets = 0;
$minbalance = 0.0;
$maxbalance = 20.0;
$postdata = sprintf ("function=getBalance&secret=%s", $secret);
GetURL ($r, $AcctInfo, "https://satoshicircle.com/control.php", "", $postdata, 0);
if (strncasecmp ($r ['response'], '{"balance"', 10) == 0) {
$json = json_decode ($r ['response'], true);
$curbalance = $json ['balance'];
}
$startbalance = $curbalance;
$highestbalance = $curbalance;
if ($startbetbalancepctg > 0) $startbet = $curbalance * $startbetbalancepctg / 100;
$bet = $startbet;
$iter = 0;
if ($idgame == 1) $jackpotval = 3;
else if ($idgame == 2) $jackpotval = 5;
else if ($idgame == 3) $jackpotval = 10;
else if ($idgame == 4) $jackpotval = 2;
$wintarget = $startbet * $jackpotval;
$runstartbalance = $startbalance;
while (($curbalance - $bet > 0) &&
($curbalance > $minbalance) &&
($curbalance < $maxbalance) &&
($curbalance - $bet > $highestbalance * $bailpctglessbalance)) {
$postdata = sprintf ("function=getSpin&bet=%.8f&secret=%s&clientSeed=%s&idbet=%s&idgame=%s",
$bet, $secret, $clientseed, $idbet, $idgame);
GetURL ($r, $AcctInfo, "https://satoshicircle.com/control.php", "", $postdata, 0);
$winloss = '';
if (strncasecmp ($r ['response'], '{"spin":', 8) == 0) {
$json = json_decode ($r ['response'], true);
if ($json ['result'] >= 1) $winloss = "WIN";
else $winloss = "LOSE";
$curbalance = $json ['balance'];
if ($curbalance > $highestbalance) $highestbalance = $curbalance;
}
$delta = $curbalance - $startbalance;
if ($startbalance != 0) $deltapctg = $delta / $startbalance * 100;
else $deltapctg = 0;
$deltabalance = $curbalance - $runstartbalance;
$deltastartbalance = $curbalance - $startbalance;
// printf ("%s\t%s\t%s\t", date ('Y-m-d H:i:s'), ++$ttlbets, $iter);
printf ("%s\t%s\t", ++$ttlbets, $iter);
printf ("wt=%.8f\t", $wintarget);
printf ("%.8f (D=%.8f SD=%.8f) \t%s\t%s\t", $bet, $deltabalance, $deltastartbalance, $json ['result'], $winloss);
// printf ("%.8f (E=%.8f, D=%.8f/SD=%.8f) \t%s\t%s\t", $bet, $sumbets, $deltabalance, $deltastartbalance, $json ['result'], $winloss);
// printf ("%.8f\t%.4f%%\t", $delta, $deltapctg);
printf ("%.8f [%.8f] %.8f\t",
$highestbalance * $bailpctglessbalance,
$curbalance,
$highestbalance);
printf ("%.4f%%\n", $deltapctg);
$recalibrate = 0;
// if ($startbetbalancepctg > 0) $startbet = $curbalance * $startbetbalancepctg / 100;
if ($json ['result'] >= $jackpotwin) {
printf ("Jackpot! Resetting iter...\n\n");
if ($startbetbalancepctg > 0) $startbet = $curbalance * $startbetbalancepctg / 100;
$iter = 1;
$wintarget = $startbet * $jackpotval;
$bet = $startbet;
$runstartbalance = $curbalance;
} else {
if ($deltabalance >= 0) $bet = $startbet;
else {
$bet = $wintarget + (-1 * $deltabalance);
$bet /= $jackpotval;
}
$iter++;
}
if ($bet < $startbet) $bet = $startbet;
if (strcasecmp ($winloss, 'win') == 0) {
$consecerr = 0;
} else if (strcasecmp ($winloss, 'lose') == 0) {
$consecerr = 0;
} else {
$consecerr++;
$sleeptime = 5 << $consecerr;
printf ("consecerr=%d sleeping: [%d]\n", $consecerr, $sleeptime);
sleep ($sleeptime);
if ($consecerr > 5) exit();
}
sleep (6);
}
printf ("%s\tEXIT! startbalance=%.8f endingbalance=%.8f highestbalance=%.8f attemptedbet=%.8f bailpoint=%.8f\n", date ('Y-m-d'), $startbalance, $curbalance, $highestbalance, $bet, $highestbalance * $bailpctglessbalance);
printf ("Net return: %.4f%%\n", $deltapctg);
function GetURL (&$Response, &$AcctInfo, $url, $ref = NULL, $postdata = NULL, $header = 1)
{
$Response = array ();
$ch = curl_init();
curl_setopt ($ch, CURLOPT_URL, $url);
// curl_setopt ($ch, CURLOPT_USERAGENT, $AcctInfo ['UserAgent']);
// curl_setopt ($ch, CURLOPT_PROXY, $AcctInfo ['ProxyIPPort']);
// curl_setopt ($ch, CURLOPT_HTTPPROXYTUNNEL, 1);
// curl_setopt ($ch, CURLOPT_COOKIEFILE, $AcctInfo ['CookieFile']);
// curl_setopt ($ch, CURLOPT_COOKIEJAR, $AcctInfo ['CookieFile']);
curl_setopt ($ch, CURLOPT_REFERER, $ref);
curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt ($ch, CURLOPT_FOLLOWLOCATION, 1);
curl_setopt ($ch, CURLOPT_HEADER, $header);
curl_setopt ($ch, CURLOPT_SSL_VERIFYPEER, 0);
curl_setopt ($ch, CURLOPT_SSL_VERIFYHOST, 0);
curl_setopt ($ch, CURLOPT_VERBOSE, false);
curl_setopt ($ch, CURLOPT_CONNECTTIMEOUT, 10);
curl_setopt ($ch, CURLOPT_TIMEOUT, 30);
curl_setopt ($ch, CURLOPT_HTTPHEADER, array (
'Accept: */*',
'Accept-Language: en-us,en;q=0.5')
);
if ($postdata != NULL) curl_setopt ($ch, CURLOPT_POSTFIELDS, $postdata);
$Response ['response'] = curl_exec ($ch);
$Response ['info'] = curl_getinfo ($ch);
$Response ['error'] = curl_error ($ch);
// var_dump ($Response);
curl_close ($ch);
}
?>
Example output:
1 0 wt=0.00016439 0.00003288 (D=-0.00003288 SD=-0.00003288) 0 LOSE 0.11506972 [0.16435243] 0.16438531 -0.0200%
2 1 wt=0.00016439 0.00003945 (D=-0.00007233 SD=-0.00007233) 0 LOSE 0.11506972 [0.16431298] 0.16438531 -0.0440%
3 2 wt=0.00016439 0.00004734 (D=-0.00002499 SD=-0.00002499) 2 WIN 0.11506972 [0.16436032] 0.16438531 -0.0152%
4 3 wt=0.00016439 0.00003788 (D=-0.00006287 SD=-0.00006287) 0 LOSE 0.11506972 [0.16432244] 0.16438531 -0.0382%
5 4 wt=0.00016439 0.00004545 (D=-0.00002424 SD=-0.00002424) 1.85 WIN 0.11506972 [0.16436107] 0.16438531 -0.0147%
6 5 wt=0.00016439 0.00003773 (D=-0.00006197 SD=-0.00006197) 0 LOSE 0.11506972 [0.16432334] 0.16438531 -0.0377%
7 6 wt=0.00016439 0.00004527 (D=-0.00010724 SD=-0.00010724) 0 LOSE 0.11506972 [0.16427807] 0.16438531 -0.0652%
8 7 wt=0.00016439 0.00005433 (D=-0.00006106 SD=-0.00006106) 1.85 WIN 0.11506972 [0.16432425] 0.16438531 -0.0371%
9 8 wt=0.00016439 0.00004509 (D=-0.00002273 SD=-0.00002273) 1.85 WIN 0.11506972 [0.16436258] 0.16438531 -0.0138%
10 9 wt=0.00016439 0.00003742 (D=-0.00006015 SD=-0.00006015) 0 LOSE 0.11506972 [0.16432516] 0.16438531 -0.0366%
11 10 wt=0.00016439 0.00004491 (D=-0.00010506 SD=-0.00010506) 0 LOSE 0.11506972 [0.16428025] 0.16438531 -0.0639%
12 11 wt=0.00016439 0.00005389 (D=-0.00005117 SD=-0.00005117) 2 WIN 0.11506972 [0.16433414] 0.16438531 -0.0311%
13 12 wt=0.00016439 0.00004311 (D=0.00012127 SD=0.00012127) 5 WIN 0.11515461 [0.16450658] 0.16450658 0.0738%
Jackpot! Resetting iter...
14 1 wt=0.00016451 0.00003290 (D=-0.00003290 SD=0.00008837) 0 LOSE 0.11515461 [0.16447368] 0.16450658 0.0538%
15 2 wt=0.00016451 0.00003948 (D=-0.00007238 SD=0.00004889) 0 LOSE 0.11515461 [0.16443420] 0.16450658 0.0297%
16 3 wt=0.00016451 0.00004738 (D=-0.00011976 SD=0.00000151) 0 LOSE 0.11515461 [0.16438682] 0.16450658 0.0009%
17 4 wt=0.00016451 0.00005685 (D=-0.00017661 SD=-0.00005534) 0 LOSE 0.11515461 [0.16432997] 0.16450658 -0.0337%
18 5 wt=0.00016451 0.00006822 (D=-0.00024483 SD=-0.00012356) 0 LOSE 0.11515461 [0.16426175] 0.16450658 -0.0752%
19 6 wt=0.00016451 0.00008187 (D=-0.00032670 SD=-0.00020543) 0 LOSE 0.11515461 [0.16417988] 0.16450658 -0.1250%
20 7 wt=0.00016451 0.00009824 (D=-0.00022846 SD=-0.00010719) 2 WIN 0.11515461 [0.16427812] 0.16450658 -0.0652%
21 8 wt=0.00016451 0.00007859 (D=-0.00014987 SD=-0.00002860) 2 WIN 0.11515461 [0.16435671] 0.16450658 -0.0174%
22 9 wt=0.00016451 0.00006288 (D=-0.00021275 SD=-0.00009148) 0 LOSE 0.11515461 [0.16429383] 0.16450658 -0.0556%
23 10 wt=0.00016451 0.00007545 (D=-0.00028820 SD=-0.00016693) 0 LOSE 0.11515461 [0.16421838] 0.16450658 -0.1015%
24 11 wt=0.00016451 0.00009054 (D=-0.00021124 SD=-0.00008997) 1.85 WIN 0.11515461 [0.16429534] 0.16450658 -0.0547%
25 12 wt=0.00016451 0.00007515 (D=-0.00013609 SD=-0.00001482) 2 WIN 0.11515461 [0.16437049] 0.16450658 -0.0090%
26 13 wt=0.00016451 0.00006012 (D=-0.00019621 SD=-0.00007494) 0 LOSE 0.11515461 [0.16431037] 0.16450658 -0.0456%
27 14 wt=0.00016451 0.00007214 (D=-0.00026835 SD=-0.00014708) 0 LOSE 0.11515461 [0.16423823] 0.16450658 -0.0895%
28 15 wt=0.00016451 0.00008657 (D=0.00007793 SD=0.00019920) 5 WIN 0.11520916 [0.16458451] 0.16458451 0.1212%
Jackpot! Resetting iter...