Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ; This AHK script will type /players into the Chat Reader and Admin Commander.exe every 10 minutes.
- #NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
- #Warn ; Enable warnings to assist with detecting common errors.
- SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
- SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
- #singleinstance force ;Forces the script to be replaced by the new one if u try to re run a new instance
- #NoTrayIcon
- #Persistent
- SetTitleMatchMode, 2
- IP := "127.0.0.1"
- PORT := "4658"
- PASS := "YOURPASS"
- PROCESS := "ahk_exe Chat Reader and Admin Commander.exe"
- PROCESS_DIR := "C:\Misc\Programs\Chat Reader and Admin Commander"
- ADMIN_COMMAND := "/players"
- IfWinNotExist %PROCESS%
- {
- Start()
- Sleep 5000
- Command()
- }
- else
- {
- Command()
- }
- exit
- Start()
- {
- global
- Run, Chat Reader and Admin Commander.exe, %PROCESS_DIR%
- Sleep 5000
- ControlSend, Edit2, %IP%, %PROCESS%
- ControlSend, Edit3, %PORT%, %PROCESS%
- ControlSend, Edit4, %PASS%, %PROCESS%
- Sleep 2000
- ControlClick, Button1, %PROCESS%
- return
- }
- Command()
- {
- global
- PlayerList:
- IfWinExist %PROCESS%
- {
- Clipboard := ADMIN_COMMAND
- Sleep 100
- ControlSend, Edit6, ^v, %PROCESS%
- ControlClick, Button3, %PROCESS%
- }
- SetTimer, PlayerList, 600000
- return
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement