I would like to create a hotkey where when I press "F3" it will send the message "Channel has X number of followers and only need Y more to hit 500k"
X value I can get from decapi. and Y value simply is 500,000 - X.
However, I can't figure out how to get the script to do that calculation.
I'm new to autohotkey but this is what I've made so far. So %OutputVar% gives me my X. But how do I subtract it from 500,000?
Any ideas/tips would be greatly appreciated.
Code: Select all
F3::
a := 500000
b := %OutputVar%
c := Func1(a,b)
Func1(x, y)
{
return x - y
}
urlsave=https decapi.me /twitch/followcount/twitchgaming Broken Link for safety
URLDownloadToFile, %urlsave%, %A_Desktop%\ahkdownload1.txt
Fileread, OutputVar, %A_Desktop%\ahkdownload1.txt
Send twitchgaming has %OutputVar% followers and only need %c% followers more to hit 500k
Return