AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Compilation of Ragnarok Online Scripts!

 
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Ask for Help
View previous topic :: View next topic  
Author Message
ProFF7



Joined: 30 Jun 2008
Posts: 5

PostPosted: Mon Jun 30, 2008 5:12 pm    Post subject: Compilation of Ragnarok Online Scripts! Reply with quote

ok prepare for a long post. these are all the functions I want to incorporate into my AH macro. some are already solved, but some of them need your help to complete.




Code:
;General Use Bash/DoubleStrafe or any skill that needs targeting. this Macro
;casts a skill and clicks in the place the mouse is after a very short delay
;without the need to bash the keys continuosly

w::
Send, {F9}
Sleep 10
MouseClick, left
return

;this version of the macro works. however Im trying to configure it so I can use Alt+W instead of just W


Code:
;Activate Battlemode + Noshift
b::
Send, !6
Sleep 200
Send, !5
return

;This sends a Alt+5 followed with Alt+6 when pressing B. it works, but same problem as previous script, I would like to press ALT for it to work


Code:
;Drink White Potions x5
1::
Loop, 6
{
Send, {F1}
Sleep, 250
}
Return

;drinks about 5 or 6 potions, depending on lag.


Code:
;Drink SP Potions x3
4::

Loop, 3
{
Send, {F2}
Sleep, 250
}
Return

;Drinks Honey/Juices/BluePots x3. works good


Code:
;Heal Self/Pneuma Self

;Ok not sure how to make this macro. it should press a hotkey, and target the center of my Ragnarok Online window, just where my character is, or at screen coordinates if needed. this should work without moving the mouse if possible.


any hints?


Last edited by ProFF7 on Wed Jul 02, 2008 6:10 am; edited 4 times in total
Back to top
View user's profile Send private message
quicktest



Joined: 30 Jul 2004
Posts: 42

PostPosted: Mon Jun 30, 2008 6:21 pm    Post subject: Reply with quote

Hi, I don't play RO, although I'll take a stab at this issue below:

Quote:
;General Use Bash/DoubleStrafe or any skill that needs targeting. this Macro
;casts a skill and clicks in the place the mouse is after a very short delay
;without the need to bash the keys continuosly

!W::
Send, {F9}
Sleep 10
MouseClick, left
return

;this should work, but for some reason it doesnt. this example its supposed to go to alt+W, but when I press it, a target appears in the game, but nothing happens, it doesnt execute the click. it will work perfect if I remove the ! and just press W, but I want to use ALT key to trigger


Try !w instead of !W. If you are actually playing with capslock turned on, try add another line of MouseClick, left right below the first one. If that solves the issue, you are most likely playing the game in a window, and you should try sending another {Alt Down}{Alt Up} after {F9}.

Hope this helps.
Back to top
View user's profile Send private message
ProFF7



Joined: 30 Jun 2008
Posts: 5

PostPosted: Tue Jul 01, 2008 8:55 am    Post subject: Reply with quote

thanks for your reply. I tried that and still didnt work, but at least I noticed the cause of the error. the problem is, RO doesnt let me to target with a skill if I have ALT pressed. will have to find a way around that

btw any ideas for the other macros?
Back to top
View user's profile Send private message
Krogdor



Joined: 18 Apr 2008
Posts: 1145
Location: The Interwebs

PostPosted: Tue Jul 01, 2008 9:02 am    Post subject: Reply with quote

ProFF7 wrote:
thanks for your reply. I tried that and still didnt work, but at least I noticed the cause of the error. the problem is, RO doesnt let me to target with a skill if I have ALT pressed. will have to find a way around that

Just add Send, {Alt up}.

Quote:
!B::
Send, {!6}
Sleep 200
Send, {!5}
return

;This is supposed to send a Alt+5 followed with Alt+6 when pressing ALT+B. however its not working...

Should be !5 and !6, not {!6} and {!5}.



Quote:
;drinks about 5 or 6 potions, depending on lag. macro works but its erratic

Why not add longer delays to make it less erratic, as you did with the other potting script? Also, can be written much shorter by using loop:
Code:
1::
Loop, 25
{
Send, {F1}
Sleep, 50
}
Return


One final thing—in the future, please use code tags when posting code. It makes it easier to read, and collapses to make for shorter posts.
Back to top
View user's profile Send private message AIM Address
argneo



Joined: 14 Sep 2007
Posts: 136

PostPosted: Tue Jul 01, 2008 12:55 pm    Post subject: Reply with quote

You could also try to use ControlSend instead of send... I find it more reliable for games.
_________________
WoW
Back to top
View user's profile Send private message
ProFF7



Joined: 30 Jun 2008
Posts: 5

PostPosted: Wed Jul 02, 2008 5:12 am    Post subject: Reply with quote

I just edited it to include code tags. thanks for the tip, I didnt realize it. however, what you mean with "collapses" ?
Back to top
View user's profile Send private message
Krogdor



Joined: 18 Apr 2008
Posts: 1145
Location: The Interwebs

PostPosted: Wed Jul 02, 2008 5:24 am    Post subject: Reply with quote

When the code is long, it will make the little code box smaller and add a scrollbar to make the post not quite so long. This is demonstrated in the box with your white pot spam code.
Back to top
View user's profile Send private message AIM Address
ProFF7



Joined: 30 Jun 2008
Posts: 5

PostPosted: Wed Jul 02, 2008 6:07 am    Post subject: Reply with quote

EDITED the post with corrected scripts

pending things to perfect these macros:

1- what is the correct way of adding {Alt up} to the script? didnt undestand how does that work

Code:
;Bash
w::
Send, {Alt up}.
Send, {F9}
Sleep 10
MouseClick, left
return


it is like this or other way?



2- What does ControlSend do? how do I put that on my script, just replacing all "Send" by "ControlSend" ?



3- still waiting for some hints on how to do the Heal Self script that targets a coordinate in the screen
Back to top
View user's profile Send private message
Krogdor



Joined: 18 Apr 2008
Posts: 1145
Location: The Interwebs

PostPosted: Wed Jul 02, 2008 7:29 am    Post subject: Reply with quote

Code:
Send, {Alt up}

Should work. No period though; that was just the end of a sentence in my post.

For your second question, ControlSend will send the click directly to the window. Look in the help file for syntax, you will also need to include the window name of your ragnarok client. I believe the control parameter should be left blank, you'll know what I'm talking about if you look at the help file.

For your third question... Either use ControlClick at the specified coordinates, or just Click, x, y where x is the x-coord and y is the y-coord.
Back to top
View user's profile Send private message AIM Address
ProFF7



Joined: 30 Jun 2008
Posts: 5

PostPosted: Wed Jul 02, 2008 8:05 am    Post subject: Reply with quote

Ill test those things and update any changes, as this post could be useful for any Ragnarok Online user

the ControlClick location should use coordinates INSIDE the game window, regardless if I move that windows, right?
Back to top
View user's profile Send private message
Krogdor



Joined: 18 Apr 2008
Posts: 1145
Location: The Interwebs

PostPosted: Wed Jul 02, 2008 8:13 am    Post subject: Reply with quote

Yup!
Back to top
View user's profile Send private message AIM Address
Display posts from previous:   
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Ask for Help All times are GMT
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group