Simple "hold to spam attacks" AHK script. menu

Shout-Out

User Tag List

Page 1 of 2 12 LastLast
Results 1 to 15 of 17
  1. #1
    Winsane's Avatar Contributor (ノಠ益ಠ)ノ彡ɹǝɥɔʇɐM
    Reputation
    216
    Join Date
    Oct 2010
    Posts
    378
    Thanks G/R
    3/3
    Trade Feedback
    12 (42%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Simple "hold to spam attacks" AHK script.

    I have allways used this in mmos to get rid of the button mashing, it's a really simple script that allows you to hold any hotkey (1-9) and it will spam that key until you release it.
    You toggle it on and off with numlock.

    [Autohotkey] Simple hotkey spam - Pastebin.com

    If you dont have autohotkey already, here is a link to the download:

    AutoHotkey Download

    Maybe someone will find this useful :)

    Simple "hold to spam attacks" AHK script.
  2. #2
    Hex00010's Avatar Master Sergeant
    Reputation
    45
    Join Date
    Feb 2010
    Posts
    98
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Im sorry but im still trying to learn the API for AutoHotKey

    Your script it doesnt define a process like ifWInDef process

    Do we have to modify your script to attach its self to the SWTOR process?

  3. #3
    Winsane's Avatar Contributor (ノಠ益ಠ)ノ彡ɹǝɥɔʇɐM
    Reputation
    216
    Join Date
    Oct 2010
    Posts
    378
    Thanks G/R
    3/3
    Trade Feedback
    12 (42%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by Hex00010 View Post
    Im sorry but im still trying to learn the API for AutoHotKey

    Your script it doesnt define a process like ifWInDef process

    Do we have to modify your script to attach its self to the SWTOR process?
    AHK doesn't need a defined process for a script to work, the script i posted works in any game (at least it should). If you only want it to be able to send keys to swtor you can add that line though.

  4. #4
    unclesam77's Avatar Member
    Reputation
    7
    Join Date
    Mar 2009
    Posts
    55
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    going home to test this out...if it works +rep to you sir..
    been trying to use the script i used for wow . but it never works...
    hopefully urs work

    cheers

    sorry this script didnt work.

    have u actually tried this or u assume it work as it works on other games?
    Last edited by unclesam77; 12-20-2011 at 09:01 PM.

  5. #5
    Winsane's Avatar Contributor (ノಠ益ಠ)ノ彡ɹǝɥɔʇɐM
    Reputation
    216
    Join Date
    Oct 2010
    Posts
    378
    Thanks G/R
    3/3
    Trade Feedback
    12 (42%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by unclesam77 View Post
    going home to test this out...if it works +rep to you sir..
    been trying to use the script i used for wow . but it never works...
    hopefully urs work

    cheers

    sorry this script didnt work.

    have u actually tried this or u assume it work as it works on other games?
    I haven't actually been able to try it yet, still waiting for my game to arrive in my mailbox.. Should have just bought it online and downloaded it..

    I really don't see why it wouldnt work in this game, i have used it in wow, aion, runes of magic, warhammer online, maplestory, dragon nest ect.

    Im sorry if it doesn't work, ill probably find a way to fix it when i just get my ****ing copy of the game..

    Yes i mad.

  6. #6
    Winsane's Avatar Contributor (ノಠ益ಠ)ノ彡ɹǝɥɔʇɐM
    Reputation
    216
    Join Date
    Oct 2010
    Posts
    378
    Thanks G/R
    3/3
    Trade Feedback
    12 (42%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    There, i got my copy..

    And this script works just fine for me, you must be doing something wrong.

  7. #7
    Genkaro's Avatar Private
    Reputation
    1
    Join Date
    Apr 2010
    Posts
    7
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I just tried this out and it works perfect, thanks.

    For those of you who are currently having problems, try to run it as administrator on the main AHK program.

  8. #8
    Mavrck48's Avatar Member
    Reputation
    1
    Join Date
    Jul 2009
    Posts
    7
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Winsane,

    First, thanks for the great script. However, I was trying to modify it to also include the ability to spam a shift + a key. For example, to spam shift + 5 by holding down shift + 5. I have attempted to modify your code to get this to work, but I can't seem to get it right. This is the code I'm trying. Any ideas?

    *5::
    Loop
    {
    GetKeyState, state, 5, p
    GetKeyState, shiftstate, Shift, p
    if (state = U)
    {
    break
    }
    else if (state = D) and (shiftstate = D)
    {
    Send, +{5}
    Sleep, 25
    }
    else
    {
    Send, {5}
    Sleep, 25
    }
    }

  9. #9
    sabletag's Avatar Private
    Reputation
    1
    Join Date
    Jan 2012
    Posts
    1
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    what exactly does this do i dont understand

  10. #10
    Winsane's Avatar Contributor (ノಠ益ಠ)ノ彡ɹǝɥɔʇɐM
    Reputation
    216
    Join Date
    Oct 2010
    Posts
    378
    Thanks G/R
    3/3
    Trade Feedback
    12 (42%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by Mavrck48 View Post
    Winsane,

    First, thanks for the great script. However, I was trying to modify it to also include the ability to spam a shift + a key. For example, to spam shift + 5 by holding down shift + 5. I have attempted to modify your code to get this to work, but I can't seem to get it right. This is the code I'm trying. Any ideas?

    *5::
    Loop
    {
    GetKeyState, state, 5, p
    GetKeyState, shiftstate, Shift, p
    if (state = U)
    {
    break
    }
    else if (state = D) and (shiftstate = D)
    {
    Send, +{5}
    Sleep, 25
    }
    else
    {
    Send, {5}
    Sleep, 25
    }
    }
    I can't seem to get it to work either, i'll post back if i find a solution for this!

    Originally Posted by sabletag View Post
    what exactly does this do i dont understand
    When you hold for example "1" it presses "1" automatically untill you release it.

  11. #11
    gilgalith's Avatar Member
    Reputation
    1
    Join Date
    Aug 2007
    Posts
    1
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Spam

    This:

    $1::
    IfWinActive, Star Wars: The Old Republic
    {
    getkeystate, KeyOut, 1
    if KeyOut = D
    Winactivate, Star Wars
    sendplay 1
    }
    else
    {
    send 1
    }
    return

  12. #12
    NewAgeRetroHippie's Avatar Private
    Reputation
    1
    Join Date
    Feb 2012
    Posts
    2
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    This is really helpful. I was looking to add a bit of functionality though. I want to toggle a button but I don't know how to map it. Specifically I want the '-' key on the numpad to spam continuously.
    I don't know how to differentiate between the numpad - and the key pad -...

  13. #13
    NewAgeRetroHippie's Avatar Private
    Reputation
    1
    Join Date
    Feb 2012
    Posts
    2
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Here's the script with the game window criteria.


    ; Simple key spam script by Winsane @ ownedcore. Edited by NewAgeRetroHippie
    ; Toggle on and off with numlock.

    ~NumLock::Suspend, Toggle

    *-::

    $1::
    IfWinActive, Star Wars: The Old Republic
    {
    Loop
    {
    GetKeyState, state, 1, p
    if state = U
    break
    ; Otherwise:
    Send, {1}
    Sleep, 25
    }
    }
    else
    {
    send 1
    }
    return


    $2::
    IfWinActive, Star Wars: The Old Republic
    {
    Loop
    {
    GetKeyState, state, 2, p
    if state = U
    break
    ; Otherwise:
    Send, {2}
    Sleep, 25
    }
    }
    else
    {
    send 2
    }
    return

    $3::
    IfWinActive, Star Wars: The Old Republic
    {
    Loop
    {
    GetKeyState, state, 3, p
    if state = U
    break
    ; Otherwise:
    Send, {3}
    Sleep, 25
    }
    }
    else
    {
    send 3
    }
    return

    $4::
    IfWinActive, Star Wars: The Old Republic
    {
    Loop
    {
    GetKeyState, state, 4, p
    if state = U
    break
    ; Otherwise:
    Send, {4}
    Sleep, 25
    }
    }
    else
    {
    send 4
    }
    return

    $5::
    IfWinActive, Star Wars: The Old Republic
    {
    Loop
    {
    GetKeyState, state, 5, p
    if state = U
    break
    ; Otherwise:
    Send, {5}
    Sleep, 25
    }
    }
    else
    {
    send 5
    }
    return

    $6::
    IfWinActive, Star Wars: The Old Republic
    {
    Loop
    {
    GetKeyState, state, 6, p
    if state = U
    break
    ; Otherwise:
    Send, {6}
    Sleep, 25
    }
    }
    else
    {
    send 6
    }
    return

    $7::
    IfWinActive, Star Wars: The Old Republic
    {
    Loop
    {
    GetKeyState, state, 7, p
    if state = U
    break
    ; Otherwise:
    Send, {7}
    Sleep, 25
    }
    }
    else
    {
    send 7
    }
    return

    $8::
    IfWinActive, Star Wars: The Old Republic
    {
    Loop
    {
    GetKeyState, state, 8, p
    if state = U
    break
    ; Otherwise:
    Send, {8}
    Sleep, 25
    }
    }
    else
    {
    send 8
    }
    return

    $9::
    IfWinActive, Star Wars: The Old Republic
    {
    Loop
    {
    GetKeyState, state, 9, p
    if state = U
    break
    ; Otherwise:
    Send, {9}
    Sleep, 25
    }
    }
    else
    {
    send 9
    }
    return

    $0::
    IfWinActive, Star Wars: The Old Republic
    {
    Loop
    {
    GetKeyState, state, 0, p
    if state = U
    break
    ; Otherwise:
    Send, {0}
    Sleep, 25
    }
    }
    else
    {
    send 0
    }
    return

  14. #14
    unclesam77's Avatar Member
    Reputation
    7
    Join Date
    Mar 2009
    Posts
    55
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    can anyone use this ?since the patch 1.2 i can't use it anymore.. i right click run as admin..
    thanks

  15. #15
    Angrybear's Avatar Member
    Reputation
    1
    Join Date
    Oct 2007
    Posts
    23
    Thanks G/R
    1/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    This is script I have used for a while. Its much more condensed though I am not sure how it will handle modifiers as I have never need to spam those keys anyways. This has worked for me since day one and has never stopped working due to a patch. I keep the window name out cause its not needed as you can hold keys down in normal windows operations anyways so it does not change the function of other programs besides games

    keys = 1,2,3,4,5,6,7,8,9,0,-,=,f,e,q ; key-names/scan-codes to accelarate
    Loop Parse, keys, `,
    Hotkey *%A_LoopField%, KEY
    Return

    KEY:
    StringTrimLeft key, A_ThisHotKey, 1
    t := 0.2 ; initial delay [seconds]
    Loop {
    SendInput {BLIND}{%key%}
    KeyWait %key%, T%t%
    If ErrorLevel = 0
    Break
    t := 0.1 ; delay *= 1, while delay > 0.2
    }

Page 1 of 2 12 LastLast

Similar Threads

  1. GW2 able to detect AHK scripts ?
    By taquito86 in forum Guild Wars 2
    Replies: 6
    Last Post: 10-27-2020, 01:29 PM
  2. AHK script for the ZK exploit (runs in background on VM's!)
    By seafunk in forum Diablo 3 Exploits
    Replies: 3
    Last Post: 06-25-2012, 01:10 PM
  3. need help with .ahk script for showing users input text
    By lovemymuffin in forum Programming
    Replies: 0
    Last Post: 03-21-2011, 02:11 AM
  4. [AHK Script] Multi-directional Hunter Disengage
    By CrazyCactuaR in forum World of Warcraft Bots and Programs
    Replies: 2
    Last Post: 04-03-2009, 09:11 AM
  5. Get the Ebon hold guards to attack you
    By Herleybob in forum World of Warcraft Exploits
    Replies: 20
    Last Post: 03-23-2009, 09:30 AM
All times are GMT -5. The time now is 06:44 PM. Powered by vBulletin® Version 4.2.3
Copyright © 2024 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search