Random Number Generator Topic is solved

Ask gaming related questions (AHK v1.1 and older)
blubbr

Random Number Generator  Topic is solved

06 Mar 2018, 23:54

Hello, im new to AHK and i made a first script. Its a basic spamming script

Code: Select all

^NumPad1::

$stop := 0

Loop,

{

	Clipboard = I'm leveling up!! 
	sleep 450
	send ^v
	sleep 500
	send {Enter}
	Clipboard =
	if ($stop)
	{
		return
	}
}

End:: $stop := 1
Right now all it does is spam "I'm leveling up!!" in chat but i want to upgrade it so that it chooses random phrase out of 3 (or maybe more if possible) like this i guess, here's a kinda "sketch"

Code: Select all

^NumPad1::

Random, rand, 1,3

{
if %rand% := 1
Loop
(code)
}

{
if %rand% := 2
Loop
(code)
}

{
if %rand% := 3
Loops
(code)
this is what i think it will look like, but ive tired alot of stuff and the script isnt working. I'm sorry if i'm pretty dumb now XD. I basically want the same spam script but make it so that i chooses and random phrase each time. Some help on random number generators will be helpful :D . Generally, i just want to learn how to do this and some tips for me as a beginner. Thx for the help :thumbup:

- UnderwearDood
User avatar
SL5
Posts: 879
Joined: 12 May 2015, 02:10
Contact:

Re: Random Number Generator

07 Mar 2018, 03:24

could you please explain your problem with 1 sentense? that we dont need to read all. thaanks :)

Return to “Gaming Help (v1)”

Who is online

Users browsing this forum: No registered users and 78 guests