Hello, I am wondering, how can I create script for Roblox, where AHK would count for me in chat, in all caps, like-
ONE
TWO
THREE
I need script that would open chat using "/" then type ONE and click enter, then the AHK would do the same thing, opening chat with "/" then post this time TWO and then sending message with enter, this would go up to 800, and there would be 1.5 second of space between each number. I beg for help.
Script that would count Topic is solved
-
- Posts: 4
- Joined: 28 Sep 2021, 11:44
Re: Script that would count Topic is solved
Code: Select all
Loop, 800 {
Sleep, 1500 * (A_Index > 1)
Send /
Sleep, 100
SendInput % "{Text}" words(A_Index) "`n"
}
words(num) {
Static ones := ["ONE" , "TWO" , "THREE" , "FOUR" , "FIVE" , "SIX" , "SEVEN" , "EIGHT"
, "NINE"]
, tens := ["TWENTY" , "THIRTY" , "FORTY" , "FIFTY" , "SIXTY" , "SEVENTY", "EIGHTY" , "NINETY"]
, teens := ["TEN" , "ELEVEN" , "TWELVE" , "THIRTEEN", "FOURTEEN", "FIFTEEN", "SIXTEEN"
, "SEVENTEEN", "EIGHTEEN", "NINETEEN"]
text .= (hundreds := num // 100) ? ones[hundreds] " HUNDRED" : "", num -= hundreds * 100
If num between 10 and 19
text .= " " teens[num - 9]
Else t := num // 10, text .= " " tens[t - 1], num -= t * 10, text .= num ? (t ? "-" : "") ones[num] : ""
Return Trim(text)
}
-
- Posts: 4
- Joined: 28 Sep 2021, 11:44
Re: Script that would count
One more question, how can I add a little delay between writing number, and space? Because for now, the space is hitting too early, not leaving time for AHK to write a number. Also, it would be perfect if there would be "jump action" after sucessfully writing an number and sending it.
So-
open chat by "/" - write number - wait 0.5 seconds to give it time to write and then send it using enter - then jump using space - then next number.
So-
open chat by "/" - write number - wait 0.5 seconds to give it time to write and then send it using enter - then jump using space - then next number.
Re: Script that would count
Code: Select all
Loop, 800 {
Sleep, 1500 * (A_Index > 1)
Send /
Sleep, 100
Send % "{Text}" words(A_Index)
Sleep, 500
Send `n `
}
-
- Posts: 4
- Joined: 28 Sep 2021, 11:44
Re: Script that would count
It is beautiful, and whoremost, working. Although, I need to ask you for one more thing:
How can I add something like pause button? Because it is unstoppable, and sometimes I'll need to pause it. Another thing is, that can you add space tap between numbers? So after writing and sending a number script would press spacebar and making character in-game jump?
How can I add something like pause button? Because it is unstoppable, and sometimes I'll need to pause it. Another thing is, that can you add space tap between numbers? So after writing and sending a number script would press spacebar and making character in-game jump?
Re: Script that would count
Below your loop:
Space is already sent after each Enter. Test in Notepad.
Code: Select all
F3::Pause
-
- Posts: 4
- Joined: 28 Sep 2021, 11:44
Re: Script that would count
What does Send ' n ' do?
How can I disable space sending? Because it is not working and I decided I am able to tap space manually.
How can I disable space sending? Because it is not working and I decided I am able to tap space manually.
Who is online
Users browsing this forum: Bing [Bot] and 32 guests