Jump to content

Random Send (letters)


Recommended Posts

Can somebody make me a script so when i activate it, it will randomly send a letter. When I press esc it will turn off, thanks Please reply soon.

[left][sub]We're trapped in the belly of this horrible machine.[/sub][sup]And the machine is bleeding to death...[/sup][sup][/sup][/left]

Link to comment
Share on other sites

  • Developers

Can somebody make me a script so when i activate it, it will randomly send a letter. When I press esc it will turn off, thanks Please reply soon.

This is a joke right ?

What about trying to do it yourself since it sounds pretty simple?

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

I know how to do a random send, but not with using letters. Other wise I would do it myself.

Edited by Firestorm

[left][sub]We're trapped in the belly of this horrible machine.[/sub][sup]And the machine is bleeding to death...[/sup][sup][/sup][/left]

Link to comment
Share on other sites

  • Developers

I know how to do a random send, but not with using letters. Other wise I would do it myself.

Letters ascii values range from 65-90 for A-Z and 97-122 for a-z

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

Well how do you do your random send? That's a start.

Send(random)

Func Random()
Send(". " & Random(0, 99, 1) )
EndFunc

Letters ascii values range from 65-90 for A-Z and 97-122 for a-z

So how could I do that ^ with the code above? Edited by Firestorm

[left][sub]We're trapped in the belly of this horrible machine.[/sub][sup]And the machine is bleeding to death...[/sup][sup][/sup][/left]

Link to comment
Share on other sites

u could always make an array with the characters in it... and do something like send($Array[random(0, 50, 1)])

that will work...

example:

Dim $AlphaB[5]
$AlphaB[0] = "a"
$AlphaB[1] = "b"
$AlphaB[2] = "c"
$AlphaB[3] = "d"
$AlphaB[4] = "e"

Send($AlphaB[Random(0, 4, 1)])


;or


$Letter = Asc(random(67, 90, 1)); something like that
Edited by CHRIS95219
Link to comment
Share on other sites

  • Developers

Send(random)

Func Random()
Send(". " & Random(0, 99, 1) )
EndFunc

So how could I do that ^ with the code above?

Heres one way of doing it... by the way, you shouldn't give your Func that name of an existing internal function...

Func SendRandom()
    Do 
        $RandChar = Random(65, 122, 1)
    Until $RandChar < 91 Or $RandChar > 96
    Send(". " & Chr($RandChar))
EndFunc

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

Post #7 Worked

Post #8 (the one above) worked also

GOOD JOB AND THAT YOU PEOLE!

Edited by Firestorm

[left][sub]We're trapped in the belly of this horrible machine.[/sub][sup]And the machine is bleeding to death...[/sup][sup][/sup][/left]

Link to comment
Share on other sites

whats about:

For $i = 1 To 100 Step 1
    If Random() = 0 Then
        $letter = Random(65, 90)
    EndIf
    Else
        $letter = Random(97, 122)
    EndIf
    Send(Chr($letter))
Next

Sends 100 letters... if you want it to be run until you press ESC take this:

HotKeySet("{ESC}", "Exit1")

While 1
    If Random() = 0 Then
        $letter = Random(65, 90)
    EndIf
    Else
        $letter = Random(97, 122)
    EndIf
    Send(Chr($letter))
WEnd

Func Exit1()
    Exit
End Func
Edited by Lord_Doominik
Link to comment
Share on other sites

That one seems to work very well also. Thank you everybody I got it working

[left][sub]We're trapped in the belly of this horrible machine.[/sub][sup]And the machine is bleeding to death...[/sup][sup][/sup][/left]

Link to comment
Share on other sites

I don't see anything in that, that says anything about letters

[left][sub]We're trapped in the belly of this horrible machine.[/sub][sup]And the machine is bleeding to death...[/sup][sup][/sup][/left]

Link to comment
Share on other sites

Hmm, guess I missed that part. But anyway thanks to the people that helped. Now I won't fail Language arts. (Don't ask, it's for a project we are doing)

[left][sub]We're trapped in the belly of this horrible machine.[/sub][sup]And the machine is bleeding to death...[/sup][sup][/sup][/left]

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...