Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ; DETOX's REIGN OF KINGS AUTO BROADCASTER SCRIPT!!
- ; FOLLOW THE COMMENTS, SOME SETUP IS REQUIRED!!!
- #SingleInstance
- #UseHook On
- ; GLOBAL FKN VARS YO!
- ToggledOn := 0
- ; SET THE AMOUNT OF TIME BETWEEN A MESSAGE SPAM
- ; (MILISECONDS) (EQUAL TO 10 MINUTES)
- Global TimeBetween := 600000
- ; (PANIC EXIT BUTTON)
- ; INCASE YOU NEED TO STOP THE SCRIPT
- END::ExitApp
- ; (PANIC PAUSE BUTTON)
- ; INCASE YOU NEED TO PAUSE THE SCRIPT
- INS::Pause
- ; MAIN FUNCTION (START/STOP)
- HOME::
- ToggledOn := !ToggledOn ; IF ON, TURN OFF. IF OFF, TURN ON
- if (ToggledOn) {
- SendMessageToChat() ; INITIATE MESSAGE SPAM FUNCTION (BELOW)
- SetTimer, Timer_Spam, %TimeBetween% ; SET MESSAGE SPAM TO REPEAT AFTER CERTAIN AMOUNT OF TIME (SET THIS ABOVE)
- } else {
- SetTimer, Timer_Spam, Off ; TOGGLE OFF SCRIPT
- }
- return
- Timer_Spam:
- SendMessageToChat() ; INITIATE MESSAGE SPAM FUNCTION (BELOW)
- return
- SendMessageToChat() {
- ; Messages Array (Simply add another line to this if you want to have more messages
- Messages := []
- Messages.insert("This is my first auto-announced message!")
- Messages.insert("This is my second auto-announced message!")
- Messages.insert("This is my third auto-announced message!")
- Messages.insert("This is my fourth auto-announced message!")
- Messages.insert("This is my fifth auto-announced message!")
- Messages.insert("This is my sixth auto-announced message!")
- ; Get total amount of messages
- TotalMessages := Messages.MaxIndex()
- Loop %TotalMessages%
- {
- ; For this part... you will have to change the
- ; "ahk_class Sandbox:SteamSecond:UnityWndClass"
- ; To whatever your second reign of kings window class is.
- ; To get this.. Run "AutoIt3 Window Spy" (Comes with AutoHotKey)
- ; Then while its up on your screen, have the second reign of kings window ACTIVE/SELECTED
- ; The top box of the AutoIt3 Window Spy will have something like this:
- ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
- ;;;;;;;;;;;;;;;;;;;;;;;;; Reign of Kings
- ;;;;;;;;;;;;;;;;;;;;;;;;; ahk_class Sandbox:SteamSecond:UnityWndClass
- ;;;;;;;;;;;;;;;;;;;;;;;;; ahk_exe Reign of Kings.exe
- ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
- ;
- ; Copy and Paste the second line in that box
- ; Ex. "ahk_class Sandbox:SteamSecond:UnityWndClass"
- SetKeyDelay, 20, 20
- ControlSend,, {Enter}, ahk_class Sandbox:SteamSecond:UnityWndClass ; CHANGE THIS TO YOUR OWN. INFO ABOVE!
- sleep, 100
- ControlSend,, % Messages[A_Index], ahk_class Sandbox:SteamSecond:UnityWndClass ; CHANGE THIS TO YOUR OWN. INFO ABOVE!
- sleep, 100
- ControlSend,, {Enter}, ahk_class Sandbox:SteamSecond:UnityWndClass ; CHANGE THIS TO YOUR OWN. INFO ABOVE!
- sleep 2000
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment