Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ;
- ; AutoHotkey Version: 1.x
- ; Language: English
- ; Platform: Win9x/NT
- ; Author: A.N.Other <myemail@nowhere.com>
- ;
- ; Script Function:
- ; Template script (you can customize this template by editing "ShellNew\Template.ahk" in your Windows folder)
- ;
- #NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
- SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
- SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
- ; For Darkfall: Rise of Agon
- #InstallKeybdHook
- ;-------------Disable when mouse is visible-------------
- #Persistent
- SetScrollLockState, on
- OnExit, ExitScript
- Return
- ExitScript:
- SetScrollLockState, off
- ExitApp
- isMouseShown()
- {
- StructSize := A_PtrSize + 16
- VarSetCapacity(InfoStruct, StructSize)
- NumPut(StructSize, InfoStruct)
- DllCall("GetCursorInfo", UInt, &InfoStruct)
- Result := NumGet(InfoStruct, 8)
- if Result
- return 1
- else
- return 0
- }
- F8::
- Suspend, Permit
- GetKeyState, state, ScrollLock, T
- If state = D
- {
- Suspend
- SetScrollLockState, off
- }
- Else if state = U
- {
- Suspend
- SetScrollLockState, on
- }
- Return
- ScrollLock::Return
- ;-----------------------AutoLoot------------------------
- IniFile := "C:\loot.txt"
- FileGetSize, size, %IniFile%
- if (size = "") {
- MsgBox Setting up
- IniWrite, 1300, %IniFile%, Loot, xdest ; --- destination x pos
- IniWrite, 700, %IniFile%, Loot, ydest ; --- destination y pos
- } else {
- IniRead, xdest, %IniFile%, Loot, xdest ; --- destination x pos
- IniRead, ydest, %IniFile%, Loot, ydest ; --- destination y pos
- }
- CoordMode, Pixel
- $^Lbutton:: ;quick loot -------------------------
- MouseGetPos, x1, y1
- MouseClickDrag, left, x1, y1, xdest, ydest, 0 ;0 is mouse speed, 0 is instant
- MouseMove, x1, y1, 0 ;0 is mouse speed, 0 is instant
- return
- $^Rbutton:: ;loot destination ------------------------->
- MouseGetPos, xdest, ydest
- IniWrite, %xdest%, %IniFile%, Loot, xdest
- IniWrite, %ydest%, %IniFile%, Loot, ydest
- return
- ;------------- Two Hander ---------------
- *!4::
- #If !isMouseShown() and WinActive("Darkfall: Rise of Agon")
- {
- combatType = melee
- send {NUMPAD3};
- Send {F3};
- Sleep, 10
- Send {0};
- }
- Return
- ;------------- Bow ---------------
- *!5::
- #If !isMouseShown() and WinActive("Darkfall: Rise of Agon")
- {
- combatType = archery
- Send {NUMPAD3};
- Send {F3};
- Sleep, 10
- Send {9};
- }
- Return
- ;------------- Staff ---------------
- *!6::
- #If !isMouseShown() and WinActive("Darkfall: Rise of Agon")
- {
- combatType = magic
- Send {NUMPAD3};
- Send {F1};
- Sleep, 10
- Send, {0}
- Send {L};
- }
- Return
- ;------------- Second staff ---------------
- #If !isMouseShown() and WinActive("Darkfall: Rise of Agon")
- *WheelDown::
- {
- Send {F11};
- }
- Return
- ;------------- Blind cycle ---------------
- {
- Reset_time:=1000*5 ;5= 5 secs so change to what ever
- return
- Reset_keyblind:
- Keyblind := 0
- return
- {
- *TAB::
- settimer, reset_keyblind, %reset_time%
- keyblind++
- if keyblind = 1
- SendInput, {Numpad1}
- else if keyblind = 2
- {
- SendInput, {Numpad2}
- keyblind = 0
- }
- Return
- }
- }
- ;------------- PotTimer ---------------
- *!0::
- send {Numpad4}
- if (potion_toggle != "cooling") {
- potion_toggle := "cooling"
- settimer drink_alert, -62000
- }
- return
- *!+::
- send {Numpad5}
- if (potion_toggle != "cooling") {
- potion_toggle := "cooling"
- settimer drink_alert, -62000
- }
- return
- *!'::
- send {Numpad6}
- if (potion_toggle != "cooling") {
- potion_toggle := "cooling"
- settimer drink_alert, -62000
- }
- return
- *^0::
- send {Numpad7}
- if (potion_toggle != "cooling") {
- potion_toggle := "cooling"
- settimer drink_alert, -62000
- }
- return
- *^+::
- send {Numpad8}
- if (potion_toggle != "cooling") {
- potion_toggle := "cooling"
- settimer drink_alert, -62000
- }
- return
- *^'::
- send {Numpad9}
- if (potion_toggle != "cooling") {
- potion_toggle := "cooling"
- settimer drink_alert, -62000
- }
- return
- drink_alert:
- potion_toggle := "notcooling"
- loop 5 {
- soundbeep
- sleep 250
- }
- return
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement