Blue Eye Logo

Blue Eye Macro

Automation is freedom
It is currently Thu Jan 21, 2021 9:40 pm

All times are UTC




Post new topic Reply to topic  [ 10 posts ] 
Author Message
 Post subject: Ragnarok Script for Dual Client Auto Farming
Thanked: 0 time(s)  Unread post Posted: Sun Apr 19, 2020 8:03 am 
Active User
Active User
User avatar



Joined: Tue Apr 07, 2020 11:23 am
Posts: 43
Been thanked: 20 time(s)
Has thanked: 2 time(s)
Contribution Points: 602
Ragnarok Script for Dual Client Auto Farming

This script is for users with advance knowledge:
If you don't know what you are doing, kindly see and make this work first: https://www.blueeye-macro.com/viewtopic.php?f=437&p=198717

This script is not perfect, and I do not know what problems you might encounter (do it at your own risk)

Requirements:
-2 clients with 800x600 resolution that will fit horizontally in your screen
-Level 40+ characters, or character that will not easily die in the mobs

CONS:
1. Random Walking is Disabled, you should have teleport skill or unlimited fly wing
2. It will not avoid going to a portal to another map
3. It will attempt kill steal and loot steal
4. Potion use is not fast and reliable.
5. This script does not use keyboard press, it will double click on the fly wing (since keyboard press doesn't work in my case)
6. It will not auto storage the loots, so being overweight is bad unless you have Sky Deleter Card, your character can go up to 90% weight
7. It will click on the GM global chat because the color yellow is the same with the monster to attack. If you want you can change the monster to attack color.

Note:
-When I use this macro, I maxed zoom-in so it will only see nearby monsters, this will be helpful on a map with lots of walls and obstacles.
-Slot 1 is for Potion, Slot 2 is for Fly Wing, Slot 3 is for awakening, Slot 4 is for Potion2, Slot 5 is for Potion3
-If you want to use the teleport skill, you need to add a mouse click or keyboard enter after using the skill.
-I have used it with Knight, Rogue, and Blacksmith and it works fine.

So to make this work: You need to change the spr (Sprite) of all monster you want to attack with the yellow color attached sprite, change the monster you want to avoid to the orange color attached sprite, and changed the item you want to pick-up to the blue color attached sprite using the GRF Editor. (Please see my attached files)

Version 0.2
Code:
 begin
     Window.Rename("Ragnarok", "yes", "Ragnarok1")
     Window.Set location("Ragnarok1", "yes", "0", "0")
     Window.Rename("Ragnarok", "yes", "Ragnarok2")
     Window.Set location("Ragnarok2", "yes", "810", "0")
     // Settings
     // Change to 0 if you have no awakes or potion
     Variable.Set("IsAwakeAvailable", "1")
     Variable.Set("R2IsAwakeAvailable", "1")
     Variable.Set("IsPotionAvailable", "1")
     Variable.Set("R2IsPotionAvailable", "1")
     // Potion to use when HP is 2/3
     Variable.Set("HowManyPotionToUse", "5")
     Variable.Set("HowManyAttackAttempt", "5")
     // Coordinates
     Variable.Set("ShortCutBarY", "42")
     Variable.Set("FlyWingX", "277")
     Variable.Set("PotionX", "249")
     Variable.Set("Potion2X", "335")
     Variable.Set("Potion3X", "365")
     Variable.Set("AwakeningX", "307")
     // CoordinatesR2
     Variable.Set("R2ShortCutBarY", "42")
     Variable.Set("R2FlyWingX", "1080")
     Variable.Set("R2PotionX", "1051")
     Variable.Set("R2Potion2X", "1138")
     Variable.Set("R2Potion3X", "1166")
     Variable.Set("R2AwakeningX", "1109")
     // Start a timer
     Macro.Start stopwatch("checkTime")
     Macro.Start stopwatch("R2checkTime")
     Macro.Start stopwatch("checkAttackTime")
     Macro.Start stopwatch("R2checkAttackTime")
     // Check Initialize every 5 minutes
     Variable.Set("MinutesToCheck", "1860000")
     Variable.Set("MinutesToAttack", "10000")
     Variable.Set("R2MinutesToAttack", "10000")
     // Start Up
     Variable.Set("IsWhatClient", "1")
     Function.Execute("Initialize")
     Variable.Set("IsWhatClient", "2")
     Function.Execute("Initialize")
     Variable.Set("IsWhatClient", "1")
     begin loop()
          // Macro.Pause("500")
          Function.Execute("MoveClient")
     end
 end

function("CheckItemTimer")
     begin
          if  Variable.Is equal to("IsWhatClient", "1")
               begin
                    Macro.Read stopwatch("checkTime", "waitTime")
                    if  Variable.Is greater than (Math)("waitTime", "{MinutesToCheck}")
                         begin
                              Function.Execute("Initialize")
                         end
               end
          if  Variable.Is equal to("IsWhatClient", "2")
               begin
                    Macro.Read stopwatch("R2checkTime", "R2waitTime")
                    if  Variable.Is greater than (Math)("R2waitTime", "{MinutesToCheck}")
                         begin
                              Function.Execute("Initialize")
                         end
               end
     end
function

function("Initialize")
     begin
          if  Variable.Is equal to("IsWhatClient", "1")
               begin
                    if  Variable.Is equal to("IsAwakeAvailable", "1")
                         begin
                              Color.Limit area of interest to window("Ragnarok1", "yes")
                              Function.Execute("Awakening")
                         end
                    Macro.Restart stopwatch("checkTime")
               end
          if  Variable.Is equal to("IsWhatClient", "2")
               begin
                    if  Variable.Is equal to("R2IsAwakeAvailable", "1")
                         begin
                              Color.Limit area of interest to window("Ragnarok2", "yes")
                              Function.Execute("Awakening")
                         end
                    Macro.Restart stopwatch("R2checkTime")
               end
     end
function

function("Awakening")
     begin
          if  Color.Pixel pattern can not be located on screen("203,254,51,-2,-2,203,254,51,1,1,203,254,51,-1,2,203,254,51,1,-1,203,254,51,1,-1,203,254,51,1,-1,203,254,51,0,3,203,254,51,2,0,203,254,51,4,1,203,254,51,-4,0,203,254,51,3,0,203,254,51,-2,0,203,254,51,1,0,203,254,51,-1,-2,203,254,51,1,-1,203,254,51,1,-1,203,254,51,1,-1,203,254,51,0,-1,203,254,51,-1,-1,203,254,51,-1,0,203,254,51,-1,0,203,254,51,-1,1,203,254,51", "10")
               begin
                    if  Variable.Is equal to("IsWhatClient", "1")
                         begin
                              Mouse.Double click at coordinate("{AwakeningX}", "{ShortCutBarY}", "left")
                         end
                    if  Variable.Is equal to("IsWhatClient", "2")
                         begin
                              Mouse.Double click at coordinate("{R2AwakeningX}", "{R2ShortCutBarY}", "left")
                         end
               end
     end
function

function("MoveClient")
     begin loop()
          // What client to move
          if  Variable.Is equal to("IsWhatClient", "1")
               begin
                    Function.Execute("CheckItemTimer")
                    Function.Execute("MoveFirstClient")
               end
          if  Variable.Is equal to("IsWhatClient", "2")
               begin
                    Function.Execute("CheckItemTimer")
                    Function.Execute("MoveSecondClient")
               end
     end
function

function("MoveOppositeClient")
     begin
          // Move Opposite Client
          if  Variable.Is equal to("IsWhatClient", "1")
               begin
                    Function.Execute("MoveSecondClient")
               end
          if  Variable.Is equal to("IsWhatClient", "2")
               begin
                    Function.Execute("MoveFirstClient")
               end
     end
function

function("MoveFirstClient")
     begin
          Color.Limit area of interest to window("Ragnarok1", "yes")
          Variable.Set("IsWhatClient", "1")
          Function.Execute("CheckItemTimer")
          // Humanly.Pause("300","500")
          Function.Execute("IfNeedToPotion")
          Function.Execute("IsLooting")
          Macro.Pause("500")
          Function.Execute("IsLooting")
          Function.Execute("IsAttacking")
          Function.Execute("IsLooting")
          Function.Execute("IsFlyWing")
          Variable.Set("IsWhatClient", "2")
          Color.Limit area of interest to window("Ragnarok2", "yes")
          // Macro.Pause("500")
     end
function

function("MoveSecondClient")
     begin
          Humanly.Pause("100", "300")
          Color.Limit area of interest to window("Ragnarok2", "yes")
          Variable.Set("IsWhatClient", "2")
          Function.Execute("CheckItemTimer")
          // Humanly.Pause("300","500")
          Function.Execute("IfNeedToPotion")
          Function.Execute("IsLooting")
          Macro.Pause("500")
          Function.Execute("IsLooting")
          Function.Execute("IsAttacking")
          Function.Execute("IsLooting")
          Function.Execute("IsFlyWing")
          Variable.Set("IsWhatClient", "1")
          Color.Limit area of interest to window("Ragnarok1", "yes")
          // Macro.Pause("500")
     end
function

function("IsLooting")
     begin
          if  Color.Can be located on screen (RGB)("0", "0", "255", "0")
               begin
                    if  Variable.Is equal to("IsWhatClient", "1")
                         begin
                              Mouse.Click at color closest to coordinate (RGB)("0", "0", "255", "0", "403", "326", "left")
                              Macro.Break from loop("yes")
                              Function.Execute("MoveOppositeClient")
                         end
                    if  Variable.Is equal to("IsWhatClient", "2")
                         begin
                              Mouse.Click at color closest to coordinate (RGB)("0", "0", "255", "0", "400", "314", "left")
                              Macro.Break from loop("yes")
                              Function.Execute("MoveOppositeClient")
                         end
               end
          // Humanly.Pause("300", "500")
     end
function

function("IsAttacking")
     begin
          // Teleport if Monster to avoid is found
          Function.Execute("EmergencyFlyWing")
          // Check if killing monster is too long, if yes, teleport
          if  Color.Pixel pattern can be located on screen("255,198,198,0,-1,255,198,198,0,2,255,198,198", "4")
               begin
                    if  Variable.Is equal to("IsWhatClient", "1")
                         begin
                              Macro.Read stopwatch("checkAttackTime", "waitAttackTime")
                              if  Variable.Is greater than (Math)("waitAttackTime", "{MinutesToAttack}")
                                   begin
                                        Function.Execute("FlyWithoutCondition")
                                        Macro.Restart stopwatch("checkAttackTime")
                                   end
                         end
                    if  Variable.Is equal to("IsWhatClient", "2")
                         begin
                              Macro.Read stopwatch("R2checkAttackTime", "R2waitAttackTime")
                              if  Variable.Is greater than (Math)("R2waitAttackTime", "{R2MinutesToAttack}")
                                   begin
                                        Function.Execute("FlyWithoutCondition")
                                        Macro.Restart stopwatch("R2checkAttackTime")
                                   end
                         end
               end
          // If Monster Name is not Visible
          if  Color.Pixel pattern can not be located on screen("255,198,198,0,-1,255,198,198,0,2,255,198,198", "4")
               begin
                    // Find Monster to Attack
                    if  Color.Can be located on screen (RGB)("255", "255", "0", "0")
                         begin
                              // Attack Monster
                              if  Variable.Is equal to("IsWhatClient", "1")
                                   begin
                                        Mouse.Click at color closest to coordinate (RGB)("255", "255", "0", "0", "403", "332", "left")
                                        Mouse.Move to coordinate("800", "0")
                                   end
                              if  Variable.Is equal to("IsWhatClient", "2")
                                   begin
                                        Mouse.Click at color closest to coordinate (RGB)("255", "255", "0", "0", "400", "332", "left")
                                        Mouse.Move to coordinate("800", "0")
                                   end
                              // Macro.Pause("500")
                              if  Color.Pixel pattern can be located on screen("255,198,198,0,-1,255,198,198,0,2,255,198,198", "4")
                                   begin
                                        if  Variable.Is equal to("IsWhatClient", "1")
                                             begin
                                                  Macro.Restart stopwatch("checkAttackTime")
                                                  Function.Execute("MoveOppositeClient")
                                             end
                                        if  Variable.Is equal to("IsWhatClient", "2")
                                             begin
                                                  Macro.Restart stopwatch("R2checkAttackTime")
                                                  Function.Execute("MoveOppositeClient")
                                             end
                                        Macro.Break from loop("yes")
                                   end
                         end
               end
     end
function

function("IsFlyWing")
     begin
          // Teleport if Monster to avoid is found
          Function.Execute("EmergencyFlyWing")
          if  Color.Can not be located on screen (RGB)("255", "255", "0", "0")
               begin
                    // Second Monster
                    // if  Color.Can not be located on screen (RGB)("250", "69", "0", "0")
                    // begin
                    if  Color.Can not be located on screen (RGB)("0", "0", "255", "0")
                         begin
                              Function.Execute("FlyWithoutCondition")
                         end
                    // end
               end
     end
function

function("FlyWithoutCondition")
     begin
          if  Variable.Is equal to("IsWhatClient", "1")
               begin
                    Function.Execute("IsLooting")
                    Mouse.Double click at coordinate("{FlyWingX}", "{ShortCutBarY}", "left")
               end
          if  Variable.Is equal to("IsWhatClient", "2")
               begin
                    Function.Execute("IsLooting")
                    Mouse.Double click at coordinate("{R2FlyWingX}", "{R2ShortCutBarY}", "left")
               end
          Function.Execute("MoveOppositeClient")
     end
function

function("EmergencyFlyWing")
     begin
          if  Color.Can be located on screen (RGB)("255", "181", "82", "0")
               begin
                    Function.Execute("FlyWithoutCondition")
               end
     end
function

function("IfNeedToPotion")
     Begin
          // If HP Bar become 2/3
          if  Variable.Is equal to("IsPotionAvailable","1")
               begin
                    if  Variable.Is equal to("IsWhatClient", "1")
                         begin
                              if  Color.Pixel pattern can be located on screen near coordinate("66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66", "0", "402", "348", "100")
                                   begin
                                        Function.Execute("Potion")
                                        if  Color.Pixel pattern can be located on screen near coordinate("66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66", "0", "402", "348", "100")
                                             begin
                                                  Function.Execute("Potion2")
                                                  if  Color.Pixel pattern can be located on screen near coordinate("66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66", "0", "402", "348", "100")
                                                       begin
                                                            Function.Execute("Potion3")
                                                            if  Color.Pixel pattern can be located on screen near coordinate("66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66", "0", "402", "348", "100")
                                                                 begin
                                                                      Variable.Set("IsPotionAvailable", "0")
                                                                 end
                                                       end
                                             end
                                   end
                         end
               end
          if  Variable.Is equal to("R2IsPotionAvailable","1")
               begin
                    if  Variable.Is equal to("IsWhatClient", "2")
                         begin
                              if  Color.Pixel pattern can be located on screen near coordinate("66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66", "0", "1225", "347", "100")
                                   begin
                                        Function.Execute("Potion")
                                        if  Color.Pixel pattern can be located on screen near coordinate("66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66", "0", "1225", "347", "100")
                                             begin
                                                  Function.Execute("Potion2")
                                                  if  Color.Pixel pattern can be located on screen near coordinate("66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66", "0", "1225", "347", "100")
                                                       begin
                                                            Function.Execute("Potion3")
                                                            if  Color.Pixel pattern can be located on screen near coordinate("66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66,3,0,66,66,66", "0", "1225", "347", "1000")
                                                                 begin
                                                                      Variable.Set("R2IsPotionAvailable", "0")
                                                                 end
                                                       end
                                             end
                                   end
                         end
               end
     end
function

function("Potion")
     begin loop("{HowManyPotionToUse}")
          // Teleport if Monster to avoid is found
          Function.Execute("EmergencyFlyWing")
          if  Variable.Is equal to("IsWhatClient", "1")
               begin
                    Mouse.Double click at coordinate("{PotionX}", "{ShortCutBarY}", "left")
               end
          if  Variable.Is equal to("IsWhatClient", "2")
               begin
                    Mouse.Double click at coordinate("{R2PotionX}", "{R2ShortCutBarY}", "left")
               end
          Humanly.Pause("100", "300")
     end
function

function("Potion2")
     begin loop("{HowManyPotionToUse}")
          // Teleport if Monster to avoid is found
          Function.Execute("EmergencyFlyWing")
          if  Variable.Is equal to("IsWhatClient", "1")
               begin
                    Mouse.Double click at coordinate("{Potion2X}", "{ShortCutBarY}", "left")
               end
          if  Variable.Is equal to("IsWhatClient", "2")
               begin
                    Mouse.Double click at coordinate("{R2Potion2X}", "{R2ShortCutBarY}", "left")
               end
          Humanly.Pause("100", "300")
     end
function

function("Potion3")
     begin loop("{HowManyPotionToUse}")
          // Teleport if Monster to avoid is found
          Function.Execute("EmergencyFlyWing")
          if  Variable.Is equal to("IsWhatClient", "1")
               begin
                    Mouse.Double click at coordinate("{Potion3X}", "{ShortCutBarY}", "left")
               end
          if  Variable.Is equal to("IsWhatClient", "2")
               begin
                    Mouse.Double click at coordinate("{R2Potion3X}", "{R2ShortCutBarY}", "left")
               end
          Humanly.Pause("100", "300")
     end
function

function("NotUsing")
     // Second Monster
     if  Color.Can not be located on screen (RGB)("250", "69", "0", "10")
          begin
               // Attack Monster
               if  Variable.Is equal to("IsWhatClient", "1")
                    begin
                         Mouse.Click at color closest to coordinate (RGB)("250", "69", "0", "10", "640", "375", "left")
                    end
               if  Variable.Is equal to("IsWhatClient", "2")
                    begin
                         Mouse.Click at color closest to coordinate (RGB)("250", "69", "0", "10", "1213", "314", "left")
                    end
               // Macro.Pause("300")
               if  Color.Pixel pattern can be located on screen("255,198,198,0,-1,255,198,198,0,2,255,198,198", "4")
                    begin
                         if  Variable.Is equal to("IsWhatClient", "1")
                              begin
                                   Macro.Restart stopwatch("checkAttackTime")
                              end
                         if  Variable.Is equal to("IsWhatClient", "2")
                              begin
                                   Macro.Restart stopwatch("R2checkAttackTime")
                              end
                         Macro.Break from loop("yes")
                    end
          end
function


Attachments:
File comment: BEM Script
multiclient;ragnarok.rar [17.61 KiB]
Downloaded 225 times
File comment: Actual Screen shot
dual.png
dual.png [ 1.46 MiB | Viewed 4505 times ]

_________________
If you like my posts, please login and click Thank You. It will help me a lot.
I apologize if I can't reply to your PM and inquiries. I do game development so I get really busy sometimes.

My Ragnarok Macro Script
https://www.blueeye-macro.com/viewtopic.php?f=437&p=198717

My Ragnarok Macro Script Dual Client
https://www.blueeye-macro.com/viewtopic.php?f=437&t=35263

Macroblitz
Top
 Profile  
Reply with quote  
 Post subject: Re: Ragnarok Script for Dual Client Auto Farming
Thanked: 1 time(s)  Unread post Posted: Mon Apr 20, 2020 10:22 pm 
Contributor
Contributor



Joined: Mon Mar 30, 2020 12:58 pm
Posts: 71
Been thanked: 6 time(s)
Has thanked: 4 time(s)
Contribution Points: 127
Wow , what a great contribution. im gonna test it now.

Just tried it, kinda slow, and sometimes it wont move .

sometimes only the other windows initiate attack.

I hope this would be amazing soon.


Top
 Profile  
Reply with quote  
 Post subject: Re: Ragnarok Script for Dual Client Auto Farming
Thanked: 0 time(s)  Unread post Posted: Sun Apr 26, 2020 9:55 am 
New User
New User



Joined: Wed Apr 22, 2020 1:22 pm
Posts: 1
Been thanked: 0 time(s)
Has thanked: 2 time(s)
Contribution Points: 10
I was trying my first try on doing 3 clients for auto casting skill only. Why i get errors? can correct me? Thanks. Still Newbie.

Image

Code:
 begin
     Window.Rename("Ragnarok", "yes", "Ragnarok1")
     Window.Set location("Ragnarok1", "yes", "0", "0")
     Window.Rename("Ragnarok", "yes", "Ragnarok2")
     Window.Set location("Ragnarok2", "yes", "810", "0")
     Window.Rename("Ragnarok", "yes", "Ragnarok3")
     Window.Set location("Ragnarok3", "yes", "1620", "0")
     // Settings
     // Start a timer
     Macro.Start stopwatch("checkTime")
     Macro.Start stopwatch("R2checkTime")
     Macro.Start stopwatch("R3checkTime")
     Macro.Start stopwatch("checkSkillTime")
     Macro.Start stopwatch("R2checkSkillTime")
     Macro.Start stopwatch("R3checkSkillTime")
     // Check Initialize every 5 minutes
     Variable.Set("MinutesToCheck", "5000")
     Variable.Set("MinutesToCheck1", "60000")
     Variable.Set("MinutesToSkill", "5000")
     Variable.Set("R2MinutesToSkill", "60000")
     Variable.Set("R3MinutesToSkill", "60000")
     // Start Up
     Variable.Set("IsWhatClient", "1")
     Function.Execute("Initialize")
     Variable.Set("IsWhatClient", "2")
     Function.Execute("Initialize")
     Variable.Set("IsWhatClient", "3")
     Function.Execute("Initialize")
     begin loop()
          // Macro.Pause("500")
          Function.Execute("MoveClient")
     end
 end

function("CheckSkillTimer")
     begin
          if  Variable.Is equal to("IsWhatClient", "1")
               begin
                    Macro.Read stopwatch("checkTime", "waitTime")
                    if  Variable.Is greater than (Math)("waitTime", "{MinutesToCheck}")
                         begin
                              Function.Execute("Initialize")
                         end
               end
          if  Variable.Is equal to("IsWhatClient", "2")
               begin
                    Macro.Read stopwatch("R2checkTime", "R2waitTime")
                    if  Variable.Is greater than (Math)("R2waitTime", "{MinutesToCheck1}")
                         begin
                              Function.Execute("Initialize")
                         end
               end
          if  Variable.Is equal to("IsWhatClient", "3")
               begin
                    Macro.Read stopwatch("R3checkTime", "R3waitTime")
                    if  Variable.Is greater than (Math)("R3waitTime", "{MinutesToCheck1}")
                         begin
                              Function.Execute("Initialize")
                         end
               end
     end
function

function("Initialize")
     begin
          if  Variable.Is equal to("IsWhatClient", "1")
               begin
                    Color.Limit area of interest to window("Ragnarok1", "yes")
                    Function.Execute("Skill")
               end
          Macro.Restart stopwatch("checkSkillTime")
     end
         if  Variable.Is equal to("IsWhatClient", "2")
             begin
               Color.Limit area of interest to window("Ragnarok2", "yes")
               Function.Execute("Skill")
          end
               Macro.Restart stopwatch("R2checkSkillTime")
          end
          if  Variable.Is equal to("IsWhatClient", "3")
               begin
                    Color.Limit area of interest to window("Ragnarok3", "yes")
                    Function.Execute("Skill")
               end
                    Macro.Restart stopwatch("R3checkSkillTime")
         end
     end
function

function("Skill")
     begin
          if  Variable.Is equal to("IsWhatClient", "1")
               begin
                    Keyboard.Press key("<f2>")
                    Mouse.Click at coordinate("403", "403", "left")
               end
          if  Variable.Is equal to("IsWhatClient", "2")
               begin
                    Keyboard.Press key("<f2>")
               end
          if  Variable.Is equal to("IsWhatClient", "3")
               begin
                    Keyboard.Press key("<f2>")
               end
     end
 end
function

function("MoveClient")
     begin loop()
          // What client to move
          if  Variable.Is equal to("IsWhatClient", "1")
               begin
                    Function.Execute("CheckSkillTimer")
                    Function.Execute("MoveFirstClient")
               end
          if  Variable.Is equal to("IsWhatClient", "2")
               begin
                    Function.Execute("CheckSkillTimer")
                    Function.Execute("MoveThirdClient")
               end
          if  Variable.Is equal to("IsWhatClient", "3")
               begin
                    Function.Execute("CheckSkillTimer")
                    Function.Execute("MoveFirstClient")
               end
function

function("MoveOppositeClient")
          begin
               // Move Opposite Client
               if  Variable.Is equal to("IsWhatClient", "1")
                    begin
                         Function.Execute("MoveSecondClient")
                    end
               if  Variable.Is equal to("IsWhatClient", "2")
                    begin
                         Function.Execute("MoveThirdClient")
                    end
               if  Variable.Is equal to("IsWhatClient", "3")
                    begin
                         Function.Execute("MoveFirstClient")
                    end
          end
function

function("MoveFirstClient")
          begin
               Color.Limit area of interest to window("Ragnarok1", "yes")
               Variable.Set("IsWhatClient", "1")
               Function.Execute("CheckItemTimer")
               // Humanly.Pause("300","500")
               Function.Execute("IsSkilling")
               Macro.Pause("500")
               Function.Execute("IsSkilling")
               Variable.Set("IsWhatClient", "2")
               Color.Limit area of interest to window("Ragnarok2", "yes")
               // Macro.Pause("500")
          end
function

function("MoveSecondClient")
     begin
          Humanly.Pause("100", "300")
          Color.Limit area of interest to window("Ragnarok2", "yes")
          Variable.Set("IsWhatClient", "2")
          Function.Execute("CheckItemTimer")
          // Humanly.Pause("300","500")
          Function.Execute("IsSkilling")
          Macro.Pause("500")
          Variable.Set("IsWhatClient", "3")
          Color.Limit area of interest to window("Ragnarok3", "yes")
          // Macro.Pause("500")
     end
function

function("MoveThirdClient")
     begin
          Humanly.Pause("100", "300")
          Color.Limit area of interest to window("Ragnarok3", "yes")
          Variable.Set("IsWhatClient", "3")
          Function.Execute("CheckItemTimer")
          // Humanly.Pause("300","500")
          Function.Execute("IsSkilling")
          Macro.Pause("500")
          Variable.Set("IsWhatClient", "1")
          Color.Limit area of interest to window("Ragnarok1", "yes")
          // Macro.Pause("500")
     end
function

function("IsSkilling")
     begin
                    if  Variable.Is equal to("IsWhatClient", "1")
                         begin
                              Macro.Read stopwatch("checkSkillTime", "waitSkillTime")
                              if  Variable.Is greater than (Math)("waitSkillTime", "{MinutesToSkill}")
                                   begin
                                        Function.Execute("Skill")
                                        Macro.Restart stopwatch("checkSkillTime")
                                        Function.Execute("MoveOppositeClient")
                                   end
                         end
                    if  Variable.Is equal to("IsWhatClient", "2")
                         begin
                              Macro.Read stopwatch("R2checkSkillTime", "R2waitSkillTime")
                              if  Variable.Is greater than (Math)("R2waitSkillTime", "{R2MinutesToSkill}")
                                   begin
                                        Function.Execute("Skill")
                                        Macro.Restart stopwatch("R2checkSkillTime")
                                        Function.Execute("MoveOppositeClient")
                                   end
                         end
                    if  Variable.Is equal to("IsWhatClient", "3")
                         begin
                              Macro.Read stopwatch("R3checkSkillTime", "R3waitSkillTime")
                              if  Variable.Is greater than (Math)("R3waitSkillTime", "{R3MinutesToSkill}")
                                   begin
                                        Function.Execute("Skill")
                                        Macro.Restart stopwatch("R3checkSkillTime")
                                        Function.Execute("MoveOppositeClient")
                                   end
                                        Macro.Break from loop("yes")
                                   end
                         end
               end
function


Top
 Profile  
Reply with quote  
 Post subject: Re: Ragnarok Script for Dual Client Auto Farming
Thanked: 0 time(s)  Unread post Posted: Thu Apr 30, 2020 1:06 pm 
Contributor
Contributor



Joined: Mon Mar 30, 2020 12:58 pm
Posts: 71
Been thanked: 6 time(s)
Has thanked: 4 time(s)
Contribution Points: 127
any improvements?

Are you using same color for the monster of the 1st client and for the 2nd client?


Top
 Profile  
Reply with quote  
 Post subject: Re: Ragnarok Script for Dual Client Auto Farming
Thanked: 1 time(s)  Unread post Posted: Fri May 01, 2020 2:12 am 
VIP Contributor
VIP Contributor



Joined: Thu Nov 24, 2016 12:55 am
Posts: 500
Been thanked: 155 time(s)
Has thanked: 13 time(s)
Contribution Points: 247
I have tried doing this before and got a lot of bug running it.
Also tried running 2 macro at the same time still got prob.. since you can have 1 active window.

but I think it is not impossible I think it just need advance knowledge in programming.

_________________
Ragnarok Online

Bot4You ROPH (will also work on other servers but you need to make your own bypass)
http://www.blueeye-macro.com/viewtopic.php?f=437&t=30450

Creating .spr file or sprite for Pixel bot
http://www.blueeye-macro.com/viewtopic.php?f=435&t=30445

Changing monster sprite and items sprite
http://www.blueeye-macro.com/viewtopic.php?f=435&t=30516


Top
 Profile  
Reply with quote  
 Post subject: Re: Ragnarok Script for Dual Client Auto Farming
Thanked: 0 time(s)  Unread post Posted: Fri May 01, 2020 2:50 pm 
Contributor
Contributor



Joined: Mon Mar 30, 2020 12:58 pm
Posts: 71
Been thanked: 6 time(s)
Has thanked: 4 time(s)
Contribution Points: 127
Well it attacks, it teleport, im using same color monster sprite for both client, but i dont know if its correct.

But some times it wont do something, both the client just standing still.


Top
 Profile  
Reply with quote  
 Post subject: Re: Ragnarok Script for Dual Client Auto Farming
Thanked: 1 time(s)  Unread post Posted: Mon May 04, 2020 3:11 am 
Active User
Active User
User avatar



Joined: Tue Apr 07, 2020 11:23 am
Posts: 43
Been thanked: 20 time(s)
Has thanked: 2 time(s)
Contribution Points: 602
senjeru wrote:
Well it attacks, it teleport, im using same color monster sprite for both client, but i dont know if its correct.

But some times it wont do something, both the client just standing still.


Did the macro stop? Or it is still clicking?

_________________
If you like my posts, please login and click Thank You. It will help me a lot.
I apologize if I can't reply to your PM and inquiries. I do game development so I get really busy sometimes.

My Ragnarok Macro Script
https://www.blueeye-macro.com/viewtopic.php?f=437&p=198717

My Ragnarok Macro Script Dual Client
https://www.blueeye-macro.com/viewtopic.php?f=437&t=35263

Macroblitz


Top
 Profile  
Reply with quote  
 Post subject: Re: Ragnarok Script for Dual Client Auto Farming
Thanked: 0 time(s)  Unread post Posted: Sat Jun 20, 2020 4:38 am 


It works but the bem get error message, if 1 client was able to run smoothly. Is there a fix?


Top
  
Reply with quote  
 Post subject: Re: Ragnarok Script for Dual Client Auto Farming
Thanked: 0 time(s)  Unread post Posted: Tue Dec 01, 2020 5:58 pm 
Contributor
Contributor
User avatar



Joined: Fri Dec 19, 2014 8:55 pm
Posts: 91
Location: philippines
Been thanked: 10 time(s)
Has thanked: 8 time(s)
Contribution Points: 106
senjeru wrote:
Well it attacks, it teleport, im using same color monster sprite for both client, but i dont know if its correct.

But some times it wont do something, both the client just standing still.



there is some delay because you are using one macro only on both screens


Top
 Profile  
Reply with quote  
 Post subject: Re: Ragnarok Script for Dual Client Auto Farming
Thanked: 0 time(s)  Unread post Posted: Tue Dec 01, 2020 5:59 pm 
Contributor
Contributor
User avatar



Joined: Fri Dec 19, 2014 8:55 pm
Posts: 91
Location: philippines
Been thanked: 10 time(s)
Has thanked: 8 time(s)
Contribution Points: 106
Tokikaze wrote:
It works but the bem get error message, if 1 client was able to run smoothly. Is there a fix?


i think its a hardware issue

how many cores is your processor?


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