Bitcoin Forum
October 18, 2017, 11:50:43 AM *
News: Latest stable version of Bitcoin Core: 0.15.0.1  [Torrent]. (New!)
 
   Home   Help Search Donate Login Register  
Pages: « 1 2 3 4 [5] 6 7 8 »  All
  Print  
Author Topic: PHP martingale bot for satoshiDICE  (Read 32406 times)
chrcoe01
Full Member
***
Offline Offline

Activity: 147


View Profile
October 10, 2012, 01:29:23 PM
 #81

I posted that and I KNEW someone would quote just that part

"You may delay, but time will not, and lost time is never found again." -Benjamin Franklin
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
1508327443
Hero Member
*
Offline Offline

Posts: 1508327443

View Profile Personal Message (Offline)

Ignore
1508327443
Reply with quote  #2

1508327443
Report to moderator
1508327443
Hero Member
*
Offline Offline

Posts: 1508327443

View Profile Personal Message (Offline)

Ignore
1508327443
Reply with quote  #2

1508327443
Report to moderator
dooglus
Legendary
*
Offline Offline

Activity: 2310



View Profile
October 11, 2012, 04:12:12 AM
 #82

I posted that and I KNEW someone would quote just that part

I tried not to, but something compelled me to do it.

Just-Dice                 ██             
          ██████████         
      ██████████████████     
  ██████████████████████████ 
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
    ██████████████████████   
        ██████████████       
            ██████           
   Play or Invest                 ██             
          ██████████         
      ██████████████████     
  ██████████████████████████ 
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
    ██████████████████████   
        ██████████████       
            ██████           
   1% House Edge
dstruct2k
Jr. Member
*
Offline Offline

Activity: 48


View Profile
January 19, 2013, 08:05:10 PM
 #83

A PowerShell Version:

Code:
--snipped--

If someone thinks this is worth a donation... 1J66vZHf1oFPHFhjFBtbEqxkJahdF3vetu

Thanks payb.tc for your nice PHP Script :0) Donation on the way
I've made a few changes to the PowerShell script just to make it a bit nicer on the end-user, all the configurable variables are in the first chunk of code. I also bet on a different payout rate, but that's configurable too.
http://pastebin.com/dS1FqjpA

1LFuotBujG44YeLskhivdy9MbpMyuCnCoA
and
1J66vZHf1oFPHFhjFBtbEqxkJahdF3vetu
if this helped you make some decent coin. Smiley
constitution
Newbie
*
Offline Offline

Activity: 28



View Profile
January 26, 2013, 12:48:30 AM
 #84

Awesome!

Droid!
Sovereign108
Jr. Member
*
Offline Offline

Activity: 56


View Profile
January 26, 2013, 01:55:29 PM
 #85

This is the best way to go bankrupt!

;(
frozenkai
Member
**
Offline Offline

Activity: 86



View Profile
January 26, 2013, 08:12:06 PM
 #86

How would I set this up?

My hard drive died and I lost all my bitcoins, help me out? 19BsFvdjtVDPHhdcYqBUi1bZ9xRopzbRjC
fcmatt
Legendary
*
Offline Offline

Activity: 1162



View Profile
January 26, 2013, 08:56:16 PM
 #87

How would I set this up?

Download the script then burn your usd or send bitcoins to a bad address to be lost forever.
That is the end result if you play long enough with this system. Mathematically proven to lose over time due to a run of bad luck.

██
█║█
║║║
║║║
█║█
██
'BTC MULTI-WALLET SOON'
▬▬▬▬ Download WHITEPAPER ▬▬▬▬

                    ▄██▄
                  ▄██████▄
                ▄██████████
              ▄██████████▀   ▄▄
            ▄██████████▀   ▄████▄
          ▄██████████▀    ████████▄
         ██████████▀      ▀████████
         ▀███████▀   ▄███▄  ▀████▀   ▄█▄
    ▄███▄  ▀███▀   ▄███████▄  ▀▀   ▄█████▄
  ▄███████▄      ▄██████████     ▄█████████
  █████████    ▄██████████▀    ▄██████████▀
   ▀█████▀   ▄██████████▀    ▄██████████▀
     ▀▀▀   ▄██████████▀    ▄██████████▀
          ██████████▀    ▄██████████▀
          ▀███████▀      █████████▀
            ▀███▀   ▄██▄  ▀█████▀
                  ▄██████▄  ▀▀▀
                  █████████
                   ▀█████▀
                     ▀▀▀
e i d o o
██

███▀▀
▐▐▌
▐▌
▐▌
▐▐▌
███▄▄
▀▀███
▐▌▌
▐▌
▐▌
▐▌▌
▄▄███
zvs
Legendary
*
Offline Offline

Activity: 1456


I have some bitcoins. Somewhere.


View Profile WWW
January 28, 2013, 12:45:31 AM
 #88

How would I set this up?

I guess that'd depend on your OS

Dacentec, best deals for US dedicated servers. They regularly restock $20-$25 Opterons with 8-16GB RAM & 2x1-2TB HDD's (ofc, usually lots of other good stuff to choose from).  I did a Serverbear benchmark of one of my $20/mo Opteron (June last year), it's here.  Have had about a half dozen different servers with Dacentec, & none have failed to sustain at least 40MB/s (burst higher). My favorite is a 12-month rent-to-own ZT Systems 2XL5520 16GB 2x2TB SATA for $40/month (got lucky with the 'off-brand', haven't seen a RTO 2xL5520 for under $50/mo since -- at least for monthly contracts).  wholesaleinternet.com has some ancient 2-core intel CPUs @ $10/mo sometimes (I got an Intel Core 2 6300 @ 1.86GHz, with a 250GB HDD with 46000 hours on it, LOL. $20 @ Dacentec is much better, if you can grab one). joesdatacenter.com (same location as Wholesale Internet) also occasionally has specials (or if you don't want to wait, it has an AMD Opteron 170 @ $16/mo).
frozenkai
Member
**
Offline Offline

Activity: 86



View Profile
January 28, 2013, 09:24:20 PM
 #89

How would I set this up?

I guess that'd depend on your OS
Windows 7

My hard drive died and I lost all my bitcoins, help me out? 19BsFvdjtVDPHhdcYqBUi1bZ9xRopzbRjC
payb.tc
Hero Member
*****
Offline Offline

Activity: 812



View Profile
January 28, 2013, 09:49:09 PM
 #90


http://bitcoin.org -> install bitcoin
http://www.apachefriends.org/en/xampp.html -> install xampp (which includes php)

have a read of https://en.bitcoin.it/wiki/PHP_developer_intro

http://jsonrpcphp.org -> get jsonRPCClient.php


the OP was aimed at coders who already have the basic dev environment set up.
tribalmind
Newbie
*
Offline Offline

Activity: 9



View Profile
February 02, 2013, 01:24:48 AM
 #91

I am no coder, but would like some advice in modding the phpbot to allow for a fraction of balance as MIN_BET and for it to recalculate after any win, same for MAX bet, also  if MAX_BET reached start over

i did try to modify the script by myself to allow this but received

Object of class jsonRPCClient could not be converted to int in XXXXX/bot2.php on line 14

Or

PHP Notice:  Object of class jsonRPCClient could not be converted to int in XXXXX/bot2.php on line 10

Or

PHP Fatal error:  Can't use method return value in write context in XXXXX/bot2.php on line 10

Any Advice would be appreciated
payb.tc
Hero Member
*****
Offline Offline

Activity: 812



View Profile
February 02, 2013, 01:49:57 AM
 #92

I am no coder, but would like some advice in modding the phpbot to allow for a fraction of balance as MIN_BET and for it to recalculate after any win, same for MAX bet, also  if MAX_BET reached start over

i did try to modify the script by myself to allow this but received

Object of class jsonRPCClient could not be converted to int in XXXXX/bot2.php on line 14

Or

PHP Notice:  Object of class jsonRPCClient could not be converted to int in XXXXX/bot2.php on line 10

Or

PHP Fatal error:  Can't use method return value in write context in XXXXX/bot2.php on line 10

Any Advice would be appreciated

maybe show us lines 10 & 14 in bot2.php, or paste the whole thing
tribalmind
Newbie
*
Offline Offline

Activity: 9



View Profile
February 02, 2013, 02:13:16 AM
 #93

<?php
require_once('jsonRPCClient.php');
/** BITCOIN **/
$btcu = array("user" => "xxx",             // RPC Username
            "pass" =>   "xxx",               // RPC Password
            "host" =>   "localhost",      // RPC Hostname/IP
            "port" =>   8332);            // RPC Port
$b = new jsonRPCClient("http://{$btcu['user']}:{$btcu['pass']}@{$btcu['host']}:{$btcu['port']}");

define('MIN_BET', 0.0633399);
define('MAX_BET', 2);
define('ADDRESS', '1dicec9k7KpmQaA8Uc8aCCxfWnwEWzpXE');

$bet = MIN_BET;
$total_fees = 0;
$count = 0;
$count_won = 0;
while (($bet <= MAX_BET) && ($count_won < 300))
{
        $balance_a = $b->getbalance('*', 0);
        if (!isset($starting_balance)) $starting_balance = $balance_a;
        if($b->getbalance('*', 1) < $bet) { // If we don't have enough confirmed bitcoins to send to satoshi dice...
            echo "Waiting for confirmed balance";
            while($b->getbalance('*', 1) < $bet)
            {
                echo ".";
                sleep(60); // Wait a full minute before checking the balance again.
            }
            echo "\n";
        }
       try // Wrapped in a try catch block just incase we run out of cash.
        {
            $b->sendtoaddress(ADDRESS, (float) $bet);
       }
        catch(Exception $e)
        {
            echo "Have: " . $b->getbalance('*', 1) . " Needed: " . $bet . "\n";
          die("Ran out of money?\n");
       }
        $balance_b = $b->getbalance('*', 0);
        $count++;
        $fee = $balance_a - $balance_b - $bet;
        $total_fees += $fee;
        $total_fees = number_format($total_fees,8,'.','')+0


the errors came with 3 different attempts at modifieng the bet amount for it to be a fraction of the balance,
KJTetc
Newbie
*
Offline Offline

Activity: 24


View Profile
February 03, 2013, 03:58:21 AM
 #94

So I've got a good understanding of PHP but never heard of JSON. I've got everything you said. How do I make it work?  Roll Eyes



http://bitcoin.org -> install bitcoin
http://www.apachefriends.org/en/xampp.html -> install xampp (which includes php)

have a read of https://en.bitcoin.it/wiki/PHP_developer_intro

http://jsonrpcphp.org -> get jsonRPCClient.php


the OP was aimed at coders who already have the basic dev environment set up.
TradeFortress
VIP
Legendary
*
Offline Offline

Activity: 910


View Profile
February 03, 2013, 04:13:03 AM
 #95

So I've got a good understanding of PHP but never heard of JSON. I've got everything you said. How do I make it work?  Roll Eyes



http://bitcoin.org -> install bitcoin
http://www.apachefriends.org/en/xampp.html -> install xampp (which includes php)

have a read of https://en.bitcoin.it/wiki/PHP_developer_intro

http://jsonrpcphp.org -> get jsonRPCClient.php


the OP was aimed at coders who already have the basic dev environment set up.
Download jsonRPCClient.php, place it in same directory.

But don't try martingale. I lost 100BTC  Embarrassed
KJTetc
Newbie
*
Offline Offline

Activity: 24


View Profile
February 03, 2013, 04:16:28 AM
 #96

What do I have near the top as the ip address? I get this error right now :

Warning: fopen(http://...@127.0.0.1:8332/): failed to open stream: No connection could be made because the target machine actively refused it. in C:\xampp\htdocs\jsonRPCClient.php on line 86
KJTetc
Newbie
*
Offline Offline

Activity: 24


View Profile
February 03, 2013, 04:19:13 AM
 #97

That website is down so I downloaded a different version off of github... Guessing that will mess it up..   (Check post above)
So I've got a good understanding of PHP but never heard of JSON. I've got everything you said. How do I make it work?  Roll Eyes



http://bitcoin.org -> install bitcoin
http://www.apachefriends.org/en/xampp.html -> install xampp (which includes php)

have a read of https://en.bitcoin.it/wiki/PHP_developer_intro

http://jsonrpcphp.org -> get jsonRPCClient.php


the OP was aimed at coders who already have the basic dev environment set up.
Download jsonRPCClient.php, place it in same directory.

But don't try martingale. I lost 100BTC  Embarrassed
tribalmind
Newbie
*
Offline Offline

Activity: 9



View Profile
February 03, 2013, 09:28:47 PM
 #98

    BTC2 Bounty for Modding the php bot to:


    • Make the MIN_BET and MAX_BET a percentage/fraction of the current balance

    • If LOSE! use this same amount multiplied until WIN! OR MAX_BET reached

    • If WIN! send a fraction of win amount to "1XYZ1" address

    • If MAX_BET Reached, start over

    • Stop after X amount sent to "1XYZ1" address

      • OR count_won grater than XYZ2
        • OR after a WIN! and the ratio of win loses is grater than XYZ3 and a minimum of XYZ bets have been played

      Always wait for confirmed balance to avoid the larger fees.(no rush to lose everything)

    fcmatt
    Legendary
    *
    Offline Offline

    Activity: 1162



    View Profile
    February 03, 2013, 09:43:35 PM
     #99

    What do I have near the top as the ip address? I get this error right now :

    Warning: fopen(http://...@127.0.0.1:8332/): failed to open stream: No connection could be made because the target machine actively refused it. in C:\xampp\htdocs\jsonRPCClient.php on line 86


    Your bitcoin client prob need to be in server mode and listening on 127.0.0.1 which is local loopback ip addy.

    ██
    █║█
    ║║║
    ║║║
    █║█
    ██
    'BTC MULTI-WALLET SOON'
    ▬▬▬▬ Download WHITEPAPER ▬▬▬▬

                        ▄██▄
                      ▄██████▄
                    ▄██████████
                  ▄██████████▀   ▄▄
                ▄██████████▀   ▄████▄
              ▄██████████▀    ████████▄
             ██████████▀      ▀████████
             ▀███████▀   ▄███▄  ▀████▀   ▄█▄
        ▄███▄  ▀███▀   ▄███████▄  ▀▀   ▄█████▄
      ▄███████▄      ▄██████████     ▄█████████
      █████████    ▄██████████▀    ▄██████████▀
       ▀█████▀   ▄██████████▀    ▄██████████▀
         ▀▀▀   ▄██████████▀    ▄██████████▀
              ██████████▀    ▄██████████▀
              ▀███████▀      █████████▀
                ▀███▀   ▄██▄  ▀█████▀
                      ▄██████▄  ▀▀▀
                      █████████
                       ▀█████▀
                         ▀▀▀
    e i d o o
    ██

    ███▀▀
    ▐▐▌
    ▐▌
    ▐▌
    ▐▐▌
    ███▄▄
    ▀▀███
    ▐▌▌
    ▐▌
    ▐▌
    ▐▌▌
    ▄▄███
    KJTetc
    Newbie
    *
    Offline Offline

    Activity: 24


    View Profile
    February 03, 2013, 11:34:03 PM
     #100

    What do I have near the top as the ip address? I get this error right now :

    Warning: fopen(http://...@127.0.0.1:8332/): failed to open stream: No connection could be made because the target machine actively refused it. in C:\xampp\htdocs\jsonRPCClient.php on line 86


    Your bitcoin client prob need to be in server mode and listening on 127.0.0.1 which is local loopback ip addy.

    How do I start it in server mode? I think I saw a script a while ago on it but I can't remember...
    Pages: « 1 2 3 4 [5] 6 7 8 »  All
      Print  
     
    Jump to:  

    Sponsored by , a Bitcoin-accepting VPN.
    Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!