Blue Eye Logo

Blue Eye Macro

Automation is freedom
It is currently Sat Nov 23, 2024 9:58 am

All times are UTC




Post new topic Reply to topic  [ 10 posts ] 
Author Message
 Post subject: Need help with my roulette macro...
Thanked: 0 time(s)  Unread post Posted: Thu Aug 29, 2013 12:01 am 
New User
New User



Joined: Wed Aug 28, 2013 5:12 am
Posts: 6
Been thanked: 0 time(s)
Has thanked: 0 time(s)
Contribution Points: 16
Hi guys, I'm in the process of customizing a macro I found on this forum.
The macro was originally designed for use with PKR casino using the Martingale system. I'm trying to get it to work with 32red's Online Casino. "Premier Roulette" game.

Image

The process I'm trying to get to work is:

1. Reset window location
2. Click $2.00 chip
3. Bet on both red and black
4. Click .25c chip
5. Bet on Black
6. Click "PLAY"
7. Check all black squares on board for marker
8. If there is no marker on any black squares, this means I lost
9. If any black square has a marker on it, this means I won.
10. If I lost, put $2.00 on Red and Black again and double .25c bet.
11. If I won, place original bet again.
12. Repeat

The reason for the $2.00 on Red and Black is because this particular casino has a minimum $2.00 bet on outside bets. Putting $2.00 on Red and Black means I get that money back regardless of whether it lands on Red or Black, cancelling out the minimum bet. (except if it's green obviously)

Anyway, here's the code. So far I can get steps 1 to 6 to work, but that's as far as I can get. If anyone can help me figure this out that would be great. Thankyou.

Code:
 begin
     Variable.Set("bet", "{MinimumBet}")
     Function.Execute("Reset window location")
     begin loop()
          Function.Execute("default bet")
          Function.Execute("Place bet")
          Function.Execute("Check if we won")
          if  Variable.Is equal to("won", "yes")
               begin
                    Macro.Report progress("We won! Resetting bet")
                    Variable.Set("bet", "{MinimumBet}")
               end
          if  Variable.Is equal to("won", "no")
               begin
                    Macro.Report progress("We lost! Doubling bet")
                    Variable.Multiply (Math)("bet", "2")
                    if  Variable.Is greater than (Math)("bet", "{MaximumBet}")
                         begin
                              Macro.Report progress("Giving up and resetting bet")
                              Variable.Set("bet", "{MinimumBet}")
                         end
               end
     end
 end

function("Reset window location")
     begin
          Window.Set location("32Red Flash Casino - Mozilla Firefox: IBM Edition", "yes", "1", "1")
          Window.Bring to front("32Red Flash Casino - Mozilla Firefox: IBM Edition", "yes")
          Macro.Pause("1000")
     end
function

function("default bet")
     begin
          Mouse.Click at coordinate("425", "726", "left")
     end
     begin
          Mouse.Click at coordinate("494", "666", "left")
     end
     begin
          Mouse.Click at coordinate("581", "662", "left")
     end
function

function("Place bet")
     begin
          Mouse.Click at coordinate("265", "725", "left")
     end
     begin
          Mouse.Click at coordinate("590", "665", "left")
     end
     begin
          Mouse.Click at coordinate("926", "702", "left")
          Macro.Pause("500")
          Color.Wait for color at coordinate to be (RGB)("0", "199", "0", "138", "286")
          Macro.Pause("500")
     end
function

function("Check if we won")
     begin
          Variable.Set("won", "no")
          if  Color.At coordinate is (RGB)("0", "0", "0", "305", "522")
               begin
                    if  Color.At coordinate is (RGB)("0", "0", "0", "347", "475")
                         begin
                              if  Color.At coordinate is (RGB)("0", "0", "0", "348", "575")
                                   begin
                                        if  Color.At coordinate is (RGB)("0", "0", "0", "390", "524")
                                             begin
                                                  if  Color.At coordinate is (RGB)("0", "0", "0", "433", "519")
                                                       begin
                                                            if  Color.At coordinate is (RGB)("0", "0", "0", "434", "566")
                                                                 begin
                                                                      if  Color.At coordinate is (RGB)("0", "0", "0", "476", "464")
                                                                           begin
                                                                                if  Color.At coordinate is (RGB)("0", "0", "0", "475", "572")
                                                                                     begin
                                                                                          if  Color.At coordinate is (RGB)("0", "0", "0", "520", "519")
                                                                                               begin
                                                                                                    if  Color.At coordinate is (RGB)("0", "0", "0", "561", "524")
                                                                                                         begin
                                                                                                              if  Color.At coordinate is (RGB)("0", "0", "0", "606", "472")
                                                                                                                   begin
                                                                                                                        if  Color.At coordinate is (RGB)("0", "0", "0", "605", "568")
                                                                                                                             begin
                                                                                                                                  if  Color.At coordinate is (RGB)("0", "0", "0", "649", "522")
                                                                                                                                       begin
                                                                                                                                            if  Color.At coordinate is (RGB)("0", "0", "0", "690", "522")
                                                                                                                                                 begin
                                                                                                                                                      if  Color.At coordinate is (RGB)("0", "0", "0", "690", "572")
                                                                                                                                                           begin
                                                                                                                                                                if  Color.At coordinate is (RGB)("0", "0", "0", "732", "463")
                                                                                                                                                                     begin
                                                                                                                                                                          if  Color.At coordinate is (RGB)("0", "0", "0", "733", "568")
                                                                                                                                                                               begin
                                                                                                                                                                                    if  Color.At coordinate is (RGB)("0", "0", "0", "774", "522")
                                                                                                                                                                                         begin
                                                                                                                                                                                              Variable.Set("won", "yes")
                                                                                                                                                                                         end
                                                                                                                                                                               end
                                                                                                                                                                     end
                                                                                                                                                           end
                                                                                                                                                 end
                                                                                                                                       end
                                                                                                                             end
                                                                                                                   end
                                                                                                         end
                                                                                               end
                                                                                     end
                                                                           end
                                                                 end
                                                       end
                                             end
                                   end
                         end
               end
     end
function
 


Code:
Variables:
{MinimumBet} 0.25
{MaximumBet} 64
{DefaultBet} 2


Top
 Profile  
Reply with quote  
 Post subject: Re: Need help with my roulette macro...
Thanked: 0 time(s)  Unread post Posted: Thu Aug 29, 2013 2:08 pm 
New User
New User



Joined: Wed Sep 05, 2012 12:37 pm
Posts: 21
Been thanked: 2 time(s)
Has thanked: 6 time(s)
Contribution Points: 15
Do you have a screenshot of marker on a wining number?


Top
 Profile  
Reply with quote  
 Post subject: Re: Need help with my roulette macro...
Thanked: 0 time(s)  Unread post Posted: Thu Aug 29, 2013 11:01 pm 
New User
New User



Joined: Wed Aug 28, 2013 5:12 am
Posts: 6
Been thanked: 0 time(s)
Has thanked: 0 time(s)
Contribution Points: 16
aberdon wrote:
Do you have a screenshot of marker on a wining number?


Here we go:

Image


Top
 Profile  
Reply with quote  
 Post subject: Re: Need help with my roulette macro...
Thanked: 0 time(s)  Unread post Posted: Fri Aug 30, 2013 12:40 pm 
New User
New User



Joined: Wed Sep 05, 2012 12:37 pm
Posts: 21
Been thanked: 2 time(s)
Has thanked: 6 time(s)
Contribution Points: 15
Edited


Last edited by aberdon on Fri Sep 27, 2013 2:35 pm, edited 1 time in total.

Top
 Profile  
Reply with quote  
 Post subject: Re: Need help with my roulette macro...
Thanked: 0 time(s)  Unread post Posted: Fri Aug 30, 2013 2:43 pm 
New User
New User



Joined: Wed Aug 28, 2013 5:12 am
Posts: 6
Been thanked: 0 time(s)
Has thanked: 0 time(s)
Contribution Points: 16
aberdon wrote:
Thanks for screenshot. Did you use exactly the same pixel from the marker on each winning number to get the black (RGB 0,0,0) that blue eye is looking for in the function("Check if we won")?


No problem. I took pixels from the centre of all of the black numbers, so if one of those pixels is covered by the marker, I know that I've won. If all black numbers are clear and no pixels are covered, that means the marker is on a red number, meaning I've lost. Hope that makes sense.


Top
 Profile  
Reply with quote  
 Post subject: Re: Need help with my roulette macro...
Thanked: 0 time(s)  Unread post Posted: Sat Aug 31, 2013 6:52 pm 
New User
New User



Joined: Wed Sep 05, 2012 12:37 pm
Posts: 21
Been thanked: 2 time(s)
Has thanked: 6 time(s)
Contribution Points: 15
Edited


Last edited by aberdon on Fri Sep 27, 2013 2:34 pm, edited 1 time in total.

Top
 Profile  
Reply with quote  
 Post subject: Re: Need help with my roulette macro...
Thanked: 0 time(s)  Unread post Posted: Mon Sep 02, 2013 10:53 pm 
Partner / Developer
Partner / Developer
User avatar



Joined: Mon Jan 18, 2010 11:51 am
Posts: 4525
Been thanked: 1346 time(s)
Has thanked: 133 time(s)
Contribution Points: 33209
If you want to check if it was red or black, you could just have a pixel pattern for each, one for red and one for black.
The pattern should include a pixel from each black field (for the black pattern).

Get the idea? That would simplify things quite a bit.

_________________
Blue Eye - Developer / Moderator
Code:
Gigus


Please read the rules about contribution points - click here

Do you know everything about BE, the forum, licenses and contribution points?
Please take a minute to read this introduction & guidelines.


Top
 Profile  
Reply with quote  
 Post subject: Re: Need help with my roulette macro...
Thanked: 0 time(s)  Unread post Posted: Mon Sep 02, 2013 11:22 pm 
New User
New User



Joined: Wed Aug 28, 2013 5:12 am
Posts: 6
Been thanked: 0 time(s)
Has thanked: 0 time(s)
Contribution Points: 16
Gigus wrote:
If you want to check if it was red or black, you could just have a pixel pattern for each, one for red and one for black.
The pattern should include a pixel from each black field (for the black pattern).

Get the idea? That would simplify things quite a bit.


Hi mate, I'm new to this program, could you please explain how the pixel pattern function works?

The way I'm trying to set it up, there will be a $2.00 bet on both red and black, which effectively cancels out the mandatory minimum bet for this particular casino, as I will win my $2.00 minimum bet back regardless of which color it lands on. On top of this, I'll be placing a .25c bet on black, then begin doubling it when I lose (martingale). I hope that makes sense.


Top
 Profile  
Reply with quote  
 Post subject: Re: Need help with my roulette macro...
Thanked: 0 time(s)  Unread post Posted: Thu Sep 05, 2013 7:55 pm 
Partner / Developer
Partner / Developer
User avatar



Joined: Mon Jan 18, 2010 11:51 am
Posts: 4525
Been thanked: 1346 time(s)
Has thanked: 133 time(s)
Contribution Points: 33209
A pixel pattern allows you to select the pixels that are of importance to a recognition, so if you for instance make 1 pattern which includes 1 pixel from each red field, that should be 18 pixels in total. 1 of these pixels will not be visible if it landed on red, because the "winning number piece" will be covering for it.

You can do the same for all the black ones.

Attachment:
pixelPattern.PNG
pixelPattern.PNG [ 1.6 MiB | Viewed 5662 times ]

_________________
Blue Eye - Developer / Moderator
Code:
Gigus


Please read the rules about contribution points - click here

Do you know everything about BE, the forum, licenses and contribution points?
Please take a minute to read this introduction & guidelines.


Top
 Profile  
Reply with quote  
 Post subject: Re: Need help with my roulette macro...
Thanked: 0 time(s)  Unread post Posted: Sat Oct 19, 2013 1:23 am 
New User
New User



Joined: Sat Oct 19, 2013 1:14 am
Posts: 16
Been thanked: 1 time(s)
Has thanked: 0 time(s)
Contribution Points: 32
i think the same


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 10 posts ] 

All times are UTC


You cannot post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  


Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group