Jump to content

New To AU3 Scripting


Recommended Posts

ok so i can do basic running a prog from specific loc. reading the ini. click/type so on so forth but some other trickier things have stopped me from the newest script I was hoping to piece together. its for Diablo II what I was wanting to end up with is a script that loads d2 / opens b.net on specified realm ( I can code all that with minor questions on some things like how would I make the Run command read the ini for the file path ) or make it so the compiled ending reads from the ini in same dir rather then needing exact path to the file.

in this the main difficulties I will have is:

A: randomising after a preffix'd name such as: silvermice- then it would be say 001 counting up to 010 or how ever many read in the ini

B: randomising character name

for that one thats about it.

I have another script I want to do a dclone killing bot. I need it to load d2, log in join game specified in the ini which I can do all that, the part I'll have issues with is getting the clone killed due to probably needing a form of detection idk I've seen some interesting things with mmbot which I know to be autoit. If anyone can help me in these writings I would greatly appreciate it as I said I can already do the clicks/delays setup the variables for the ini I just don't know the in depth coding for more complicated things >.<

Link to comment
Share on other sites

Please don't bump your thread within 24 hours of your last post/bump.

Someone will get to your topic when they can.

;) its been over 24 hours now and still no help :| can anyone atleast help me with the randomizing code? that can't be to horribly hard to put in is it?

it would be like:

run prog,

connect,

click a button,

type, this one would have like preffix -001 then preffix -002 going up with each round ( EDIT: preffix would be designated in the .ini )

type,

button/enter,

button,

button,

button,

random text a-z between 5-9 chars long

button.

I can do all but the randomizing :D

oh the other thing I wanted is a way for the .au3 or .exe to search for the .ini in parent dir of the .exe/.au3

Edited by silvermice
Link to comment
Share on other sites

;) its been over 24 hours now and still no help :| can anyone atleast help me with the randomizing code? that can't be to horribly hard to put in is it?

it would be like:

run prog,

connect,

click a button,

type, this one would have like preffix -001 then preffix -002 going up with each round ( EDIT: preffix would be designated in the .ini )

type,

button/enter,

button,

button,

button,

random text a-z between 5-9 chars long

button.

I can do all but the randomizing :D

oh the other thing I wanted is a way for the .au3 or .exe to search for the .ini in parent dir of the .exe/.au3

explain better this: "random text a-z between 5-9 chars long"

Link to comment
Share on other sites

; #FUNCTION# ==============================================================================================
; Name...........: _RandomStr
; Description....: Creates a random string
; Syntax.........: _RandomStr([$iLen = 10])
; Parameters ....: $iLen      - Length of string to return
; Return values .: Success    - Returns a string of random letters (a~z)
; Author ........: RazerM
; =========================================================================================================
Func _RandomStr($iLen = 10)
    Local $sTmp = ''
    For $i = 1 To $iLen
        $sTmp &= Chr(Random(97, 122, 1))
    Next
    Return $sTmp
EndFunc   ;==>_RandomStr

;) ludous

Link to comment
Share on other sites

explain better this: "random text a-z between 5-9 chars long"

um like. it gets in game and goes to create char, and doing that it types 5-9 chars so 5,6,7,8, or 9 total letters ( randomizing between 5 - 9 in length )

so it would be like:

go through 1 of script: woein ( 5 chars )

go through 2 of script: eoinslk ( 7 chars ) all random a-z

; #FUNCTION# ==============================================================================================
; Name...........: _RandomStr
; Description....: Creates a random string
; Syntax.........: _RandomStr([$iLen = 10])
; Parameters ....: $iLen      - Length of string to return
; Return values .: Success  - Returns a string of random letters (a~z)
; Author ........: RazerM
; ====================================================================================================


=====
Func _RandomStr($iLen = 10)
    Local $sTmp = ''
    For $i = 1 To $iLen
        $sTmp &= Chr(Random(97, 122, 1))
    Next
    Return $sTmp
EndFunc  ;==>_RandomStr

this I shal try to see if I can get this working right between now and my next look at these forums ;)

Link to comment
Share on other sites

um like. it gets in game and goes to create char, and doing that it types 5-9 chars so 5,6,7,8, or 9 total letters ( randomizing between 5 - 9 in length )

so it would be like:

go through 1 of script: woein ( 5 chars )

go through 2 of script: eoinslk ( 7 chars ) all random a-z

; #FUNCTION# ==============================================================================================
; Name...........: _RandomStr
; Description....: Creates a random string
; Syntax.........: _RandomStr([$iLen = 10])
; Parameters ....: $iLen      - Length of string to return
; Return values .: Success  - Returns a string of random letters (a~z)
; Author ........: RazerM
; ====================================================================================================



=====
Func _RandomStr($iLen = 10)
    Local $sTmp = ''
    For $i = 1 To $iLen
        $sTmp &= Chr(Random(97, 122, 1))
    Next
    Return $sTmp
EndFunc ;==>_RandomStr

this I shal try to see if I can get this working right between now and my next look at these forums ;)

You just fixup the line 1...

Func _RandomStr($iLen = Random(5, 9, 1))

Local $sTmp = ''

For $i = 1 To $iLen

$sTmp &= Chr(Random(97, 122, 1))

Next

Return $sTmp

EndFunc ;==>_RandomStr

-Everything are starting by the dreams.-Everybody is working with computer.-Everydays will auto because we need it. Come on..Let's doing...AUTOIT....^^"..just a little idea..a little A.D.

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...