Jump to content

Sky Slate Blueberry Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate
Photo

Can you help me for this wow script



  • Please log in to reply
20 replies to this topic
Joleco
  • Members
  • 10 posts
  • Last active: Dec 09 2013 03:06 PM
  • Joined: 03 Dec 2013
First sorry for my english. This script works well, but I need a few things. 
1: How can add to this binds Mouse Button 4 and 5? 
2: How to made 1,2,3,4,5 to work when I press 2 buttons together(at once). For example, when I press 1 and 2, one from these stops, and when the spell(on this bind/button) available I need to press it again to be activated. Every time works only the 2nd button pressed. I need two to work together, is it possible?
3: how to add "enable/disable" button for this script to work when I am ingame. resolved
Please if someone can help me, or link me better script, thanks.
edit: The whole idea is to make a script which will allow me to accelerate some binds. "Spam a spell or macro by holding down a single key" or why not two keys ? But how ?

 

#ifWinActive World of Warcraft

 
keys = 123456xvcrf``zgbqe                        ; all the keys you want to accelarate
 
Loop Parse, keys
 
   Hotkey *%A_LoopField%, KEY
 
Return
 
 
 
KEY:
 
   StringRight key, A_ThisHotKey, 1
 
   t := 0.01                       ; initial delay [seconds]
 
   Loop {
 
      Send {BLIND}{RAW}%key%
 
      KeyWait %key%, T%t%
 
      If ErrorLevel = 0
 
         Break
 
      t := t > 0.02 ? t*0.8 : 0.02 ; delay *= 0.80, while delay > 0.02
 
   }
 


Masonjar13
  • Members
  • 1517 posts
  • Last active:
  • Joined: 16 Sep 2012

I'm not sure what the 4th and 5th mouse keys are, but this might work, test it out. I set the enable/disable to Esc, since you didn't specify.

#ifWinActive World of Warcraft
#MaxThreadsPerHotkey 3
keys = 123456xvcrf``zgbqe                        ; all the keys you want to accelarate
Loop Parse, keys
   Hotkey *%A_LoopField%, KEY
Hotkey *XButton1, KEY
Hotkey *XButton2, KEY
Return
 
KEY:
   StringRight key, A_ThisHotKey, 1
   t := 0.01                       ; initial delay [seconds]
   Loop {
      Send {BLIND}{RAW}%key%
      KeyWait %key%, T%t%
      If ErrorLevel = 0
         Break
      t := t > 0.02 ? t*0.8 : 0.02 ; delay *= 0.80, while delay > 0.02
   }
Esc::Suspend

OS: Windows 7 Ultimate / Windows 8.1 Pro | Editor: Notepad++


Joleco
  • Members
  • 10 posts
  • Last active: Dec 09 2013 03:06 PM
  • Joined: 03 Dec 2013
thanks for your reply. is this for my 2nd question? #MaxThreadsPerHotkey 3
didn't work, and don't know why :( when i press and hold 2 buttons(1,2,3,4,5 or 6) only one work.


Masonjar13
  • Members
  • 1517 posts
  • Last active:
  • Joined: 16 Sep 2012

My mistake! Try replacing it with #MaxThreads 5. You can increase the number up to 255, 5 should be enough though.


OS: Windows 7 Ultimate / Windows 8.1 Pro | Editor: Notepad++


Joleco
  • Members
  • 10 posts
  • Last active: Dec 09 2013 03:06 PM
  • Joined: 03 Dec 2013

I try it, after your first reply I find and this. Now I try again this #MaxThreads 5 or 10, but didnt work. If you understand me what I need? When I hold two keys(1,2,3,4,5 or 6) I need to happen this 121212121212 (if I hold down 1,2 :) )..... now when I hold, the first pressed stops, like this: 1222222222 . And the script spams only 22222, and I need to press again 1 to activate the spell.



Masonjar13
  • Members
  • 1517 posts
  • Last active:
  • Joined: 16 Sep 2012

#ifWinActive World of Warcraft
#MaxThreadsPerHotkey 3
keys = 123456xvcrf``zgbqe                        ; all the keys you want to accelarate
Loop Parse, keys
   Hotkey *%A_LoopField%, KEY
Hotkey *XButton1, KEY
Hotkey *XButton2, KEY
Hotkey *1 & 2, KEY
Return
 
KEY:
   StringRight key, A_ThisHotKey, 1
   t := 0.01                       ; initial delay [seconds]
   Loop {
      Send {BLIND}{RAW}%key%
      KeyWait %key%, T%t%
      If ErrorLevel = 0
         Break
      t := t > 0.02 ? t*0.8 : 0.02 ; delay *= 0.80, while delay > 0.02
   }
Esc::Suspend

OS: Windows 7 Ultimate / Windows 8.1 Pro | Editor: Notepad++


Joleco
  • Members
  • 10 posts
  • Last active: Dec 09 2013 03:06 PM
  • Joined: 03 Dec 2013
9tp9.png
 
Still Looking for Help. Any new idea will be welcome


Masonjar13
  • Members
  • 1517 posts
  • Last active:
  • Joined: 16 Sep 2012

Oh right, just take out the asterisk (*), should be fine.


OS: Windows 7 Ultimate / Windows 8.1 Pro | Editor: Notepad++


Joleco
  • Members
  • 10 posts
  • Last active: Dec 09 2013 03:06 PM
  • Joined: 03 Dec 2013
The error gone.
"1" work when I push and release it, if I hold it dont "spam" the script, don't do anything. "2" work like before, but still 2 keys don't works together.
Still looking for help. Any idea... thanks.


SikAxe
  • Members
  • 71 posts
  • Last active: Apr 03 2014 11:29 AM
  • Joined: 08 Oct 2013

You Know that AHK Scripts for automate spells or something are forbidden ?

AHK is only Allowed for Multiboxing without automate spell order



Masonjar13
  • Members
  • 1517 posts
  • Last active:
  • Joined: 16 Sep 2012

Alright, well I made a complete separate hotkey for it, should work just fine.

@SikAxe, it's just a game. Doesn't really matter. It's implied you use these at your own risk.

#ifWinActive World of Warcraft
#MaxThreadsPerHotkey 3
keys = 123456xvcrf``zgbqe                        ; all the keys you want to accelarate
Loop Parse, keys
   Hotkey *%A_LoopField%, KEY
Hotkey *XButton1, KEY
Hotkey *XButton2, KEY
Return
 
KEY:
   StringRight key, A_ThisHotKey, 1
   t := 0.01                       ; initial delay [seconds]
   Loop {
      Send {BLIND}{RAW}%key%
      KeyWait %key%, T%t%
      If ErrorLevel = 0
         Break
      t := t > 0.02 ? t*0.8 : 0.02 ; delay *= 0.80, while delay > 0.02
   }
7::
While GetKeyState("7","P")
    Send {BLIND}{RAW}12
Return
Esc::Suspend

OS: Windows 7 Ultimate / Windows 8.1 Pro | Editor: Notepad++


Joleco
  • Members
  • 10 posts
  • Last active: Dec 09 2013 03:06 PM
  • Joined: 03 Dec 2013
I give up. Didn't work. Is it at all possible or it is hardware limitation? You can test only this, without a game or some other thing of "my" script. We must start from here. You press 1 and 2 and hold this two keys: 12222222222222 ... this happen, is it possible at all to happen this: 12121212121212
Masonjar13 Thank you anyway, and sorry. Btw I try to find something in google about it, but no luck for now. Its look so simple thing...


Masonjar13
  • Members
  • 1517 posts
  • Last active:
  • Joined: 16 Sep 2012

I have it set to "7", so if you hold 7, it'll send "12" repeatedly.


OS: Windows 7 Ultimate / Windows 8.1 Pro | Editor: Notepad++


Joleco
  • Members
  • 10 posts
  • Last active: Dec 09 2013 03:06 PM
  • Joined: 03 Dec 2013

Yes, 7 spams exactly 12121212121212. But I can't use it in that way. This is one key spams two(you can't control separately in this case).. Is like this who said about "automate spell order". I don't need this. You can't know when you will need 1 or 2. In some situations you need to press faster the first available spell on 1 and 2, and because of that I want to hold this two keys. But in other situations I need only 1 (for example). And I release key "2" and hold only key "1".



Masonjar13
  • Members
  • 1517 posts
  • Last active:
  • Joined: 16 Sep 2012

*sigh* well that was a pain in the a**. Finally, I've gotten your wanted outcome.

#SingleInstance Force
#ifWinActive World of Warcraft
keys = 123456xvcrf``zgbqe                        ; all the keys you want to accelarate
Loop Parse, keys
    Hotkey *%A_LoopField%, KEY
Hotkey *XButton1, KEY
Hotkey *XButton2, KEY
Return
 
KEY:
StringTrimLeft key, A_ThisHotKey, 1
Loop
{
    GetKeyState, state1, 1, P
    GetKeyState, state2, 2, P
    GetKeyState, key1, %key%, P
    If (State1="D" && State2="D")
        Send {BLIND}{RAW}12
    Else If (key1="D")
        Send {BLIND}{RAW}%key%
    Else
        Break
}
Return
 
Esc::Suspend

The initial code was meant only for single-character keys, so I had to change it.


OS: Windows 7 Ultimate / Windows 8.1 Pro | Editor: Notepad++