Blue Eye Logo

Blue Eye Macro

Automation is freedom
It is currently Thu Nov 21, 2024 3:30 pm

All times are UTC




Post new topic Reply to topic  [ 8 posts ] 
Author Message
 Post subject: Weapon Changer Script
Thanked: 0 time(s)  Unread post Posted: Thu Feb 23, 2012 2:15 pm 
Silver Contributor
Silver Contributor
User avatar



Joined: Wed Feb 08, 2012 10:22 am
Posts: 117
Been thanked: 6 time(s)
Has thanked: 0 time(s)
Contribution Points: 393
So say you are botting and you want to make sure your char switches weapons and does not start punching mobs, use this macro.

Execute the script alongside any bot you have and it will switch weapons after the allotted time has passed.

I worked out the value for the Timer based on a 2k dura T-Bow. It takes around 45 minutes to use up all of the dura. So I set the Timer to 40 minutes, the bows usually end on 200 duraa at which point they are switched. This also depends on the area you hunt in, if there is not a constant stream of mobs then you can increase the time.

Other Macros should not be a problem as this script will pause and resume them.

One last thing, i've experienced a couple of crashes with this script, it could be something to do with the macro.pause and macro.resume instructions.

The macro is a constant loop. It will click every box in the inventory and then scroll down to click the next two rows of boxes. The macro does not stop, but with so many bows it would take along time to get through your inventory, in which time you should have checked up on the bot.

Enjoy!

Code:
 begin
     Macro.Start stopwatch("Timer")
     Variable.Set("WhichBow", "0")
 end
 begin loop()
     Macro.Read stopwatch("Timer", "Timer")
     if  Variable.Is greater than (Math)("Timer", "2400000")
          begin
               Macro.Restart stopwatch("Timer")
               Variable.Add (Math)("WhichBow", "1")
               Function.Execute("WhichBow")
          end
 end

function("WhichBow")
     begin
          if  Variable.Is equal to("WhichBow", "1")
               begin
                    Function.Execute setting 2 variables("BowChange", "CoordsX", "90", "CoordsY", "415")
               end
          if  Variable.Is equal to("WhichBow", "2")
               begin
                    Function.Execute setting 2 variables("BowChange", "CoordsX", "145", "CoordsY", "415")
               end
          if  Variable.Is equal to("WhichBow", "3")
               begin
                    Function.Execute setting 2 variables("BowChange", "CoordsX", "200", "CoordsY", "415")
               end
          if  Variable.Is equal to("WhichBow", "4")
               begin
                    Function.Execute setting 2 variables("BowChange", "CoordsX", "255", "CoordsY", "415")
               end
          if  Variable.Is equal to("WhichBow", "5")
               begin
                    Function.Execute setting 2 variables("BowChange", "CoordsX", "310", "CoordsY", "415")
               end
          if  Variable.Is equal to("WhichBow", "6")
               begin
                    Function.Execute setting 2 variables("BowChange", "CoordsX", "90", "CoordsY", "471")
               end
          if  Variable.Is equal to("WhichBow", "7")
               begin
                    Function.Execute setting 2 variables("BowChange", "CoordsX", "145", "CoordsY", "471")
               end
          if  Variable.Is equal to("WhichBow", "8")
               begin
                    Function.Execute setting 2 variables("BowChange", "CoordsX", "200", "CoordsY", "471")
               end
          if  Variable.Is equal to("WhichBow", "9")
               begin
                    Function.Execute setting 2 variables("BowChange", "CoordsX", "255", "CoordsY", "471")
               end
          if  Variable.Is equal to("WhichBow", "10")
               begin
                    Function.Execute setting 2 variables("BowChange", "CoordsX", "310", "CoordsY", "471")
               end
          if  Variable.Is equal to("WhichBow", "11")
               begin
                    Macro.Pause all other macros()
                    Keyboard.Press key("{<f10>}")
                    Macro.Pause("2000")
                    Window.Calculate absolute coordinates("Soma Mythological Biography", "yes", "350", "502", "ClickX", "ClickY")
                    Mouse.Click at coordinate("{ClickX}", "{ClickY}", "Left")
                    Macro.Pause("2000")
                    Mouse.Click at coordinate("{ClickX}", "{ClickY}", "Left")
                    Variable.Set("WhichBow", "0")
                    Macro.Pause("1000")
                    Keyboard.Press key("{<f10>}")
                    Macro.Pause("1000")
                    Macro.Resume all paused macros()
               end
     end
function

function("BowChange")
     begin
          Macro.Pause all other macros()
          Keyboard.Press key("{<f10>}")
          Macro.Pause("1000")
          Window.Calculate absolute coordinates("Soma Mythological Biography", "yes", "{CoordsX}", "{CoordsY}", "ClickX", "ClickY")
          Mouse.Click at coordinate("{ClickX}", "{ClickY}", "Right")
          Macro.Pause("1000")
          Keyboard.Press key("{<f10>}")
          Macro.Pause("1000")
          Macro.Resume all paused macros()
     end
function
 


Top
 Profile  
Reply with quote  
 Post subject: Re: Weapon Changer Script
Thanked: 0 time(s)  Unread post Posted: Wed Feb 29, 2012 12:32 pm 
Contributor
Contributor



Joined: Tue Feb 28, 2012 11:21 am
Posts: 64
Been thanked: 0 time(s)
Has thanked: 1 time(s)
Contribution Points: 30
Excellent post m8!
heh I think it was last year, i was using this hunting bot that i had, and also using this very nice A+ 5k dura cp e - dex was flying and i was loving life... right up until the point where i came back to the game and noticed my car was erm PUNCHING THE DARN MOB, so yes the bow broke... whats worse is it was another players bow lol.
So this script will no doubt solve that situation, i guess one could alter this to work for Armour aswell?


Top
 Profile  
Reply with quote  
 Post subject: Re: Weapon Changer Script
Thanked: 0 time(s)  Unread post Posted: Fri Mar 02, 2012 4:22 pm 
Contributor
Contributor
User avatar



Joined: Fri Mar 02, 2012 1:39 pm
Posts: 90
Location: philippines
Been thanked: 0 time(s)
Has thanked: 0 time(s)
Contribution Points: 120
hey mate war game this bot for?


Top
 Profile  
Reply with quote  
 Post subject: Re: Weapon Changer Script
Thanked: 0 time(s)  Unread post Posted: Fri Mar 02, 2012 6:11 pm 
New User
New User



Joined: Wed Feb 29, 2012 7:48 pm
Posts: 5
Been thanked: 0 time(s)
Has thanked: 0 time(s)
Contribution Points: 40
renegadexter wrote:
hey mate war game this bot for?


Its for the game you went into on the forums, myth of soma

www.somadev.com


Top
 Profile  
Reply with quote  
 Post subject: Re: Weapon Changer Script
Thanked: 0 time(s)  Unread post Posted: Fri Mar 02, 2012 6:13 pm 
Silver Contributor
Silver Contributor
User avatar



Joined: Wed Feb 08, 2012 10:22 am
Posts: 117
Been thanked: 6 time(s)
Has thanked: 0 time(s)
Contribution Points: 393
donaldtrump wrote:
renegadexter wrote:
hey mate war game this bot for?


Its for the game you went into on the forums, myth of soma

http://www.somadev.com


Looks like a contribution point troll :/


Top
 Profile  
Reply with quote  
 Post subject: Re: Weapon Changer Script
Thanked: 0 time(s)  Unread post Posted: Fri Mar 02, 2012 6:14 pm 
Silver Contributor
Silver Contributor
User avatar



Joined: Wed Feb 08, 2012 10:22 am
Posts: 117
Been thanked: 6 time(s)
Has thanked: 0 time(s)
Contribution Points: 393
There's a few minor bugs in the script i've altered so when Gigus releases the bot to the repository i'll resubmit with changes.


Top
 Profile  
Reply with quote  
 Post subject: Re: Weapon Changer Script
Thanked: 0 time(s)  Unread post Posted: Tue Mar 06, 2012 2:47 pm 
New User
New User



Joined: Wed Feb 29, 2012 7:48 pm
Posts: 5
Been thanked: 0 time(s)
Has thanked: 0 time(s)
Contribution Points: 40
simba wrote:
There's a few minor bugs in the script i've altered so when Gigus releases the bot to the repository i'll resubmit with changes.


is this updated on the repository yet mate?


Top
 Profile  
Reply with quote  
 Post subject: Re: Weapon Changer Script
Thanked: 0 time(s)  Unread post Posted: Tue Mar 06, 2012 10:31 pm 
Silver Contributor
Silver Contributor
User avatar



Joined: Wed Feb 08, 2012 10:22 am
Posts: 117
Been thanked: 6 time(s)
Has thanked: 0 time(s)
Contribution Points: 393
donaldtrump wrote:
simba wrote:
There's a few minor bugs in the script i've altered so when Gigus releases the bot to the repository i'll resubmit with changes.


is this updated on the repository yet mate?


no sorry i'll do that now.


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 8 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