Jump to content

Stuck with INI read, and send..


Recommended Posts

Ok i got an ini file with the following in it:

send("{$StandStill down}")
MouseClick("Left")
send("{$StandStill up}")oÝ÷ Ù©Ý×bv{p¢¹?ªê-y«­¢+Ø)͹ ÅÕ½ÐíìÅÕ½ÐìµÀìÀÌØíMѹMÑ¥±°µÀìÅÕ½Ðì½Ý¹ôÅÕ½Ðì¤)5½ÕÍ
±¥¬ ÅÕ½Ðí1ÐÅÕ½Ðì¤)͹ ÅÕ½ÐíìÅÕ½ÐìµÀìÀÌØíMѹMÑ¥±°µÀìÅÕ½ÐìÕÁôÅÕ½Ðì¤
Link to comment
Share on other sites

Ahh the & symbols thanks, you must really detest me cos i know notghing

ive tryed it and still doesnt work...

;;;; Global Pause Start ;;;;
Global $Paused
;;;; Global Pause End ;;;;


;;;; Hotkey Settings Start ;;;;
HotKeySet("{HOME}", "TogglePause")
HotKeySet("{END}", "Terminate")
;;;; Hotkey Settings End ;;;;


;;;; Key Delay Options Start ;;;;
Opt('MouseClickDelay', 0)
;;;; Key Delay Options End ;;;;


$StandStill = IniRead("config\auto.ini", "Settings", "Stand Still Button")


;;;; Script Global Sleep Start ;;;;
While 1
    Sleep(100)
WEnd
;;;; Script Global Sleep End ;;;;


;;;; Toggle Pause and Splash On/Off Start ;;;;
Func TogglePause()
    $Paused = Not $Paused
    While $Paused
        SplashTextOn( "Auto Caster", "Starting Auto - - Home = Pause/Unpause - End = Exit Program", 640, 25, 320, 30, 1, "system", "", "")
        Sleep(100)
        Send("{" & $StandStill & " down}")
        MouseClick("Left")
        Send("{" & $StandStill & " up}")
        SplashOff()
    WEnd
EndFunc   ;==>TogglePause

;;;; Toggle Pause and Splash On/Off End ;;;;


;;;; End/Close/Terminate Function Start ;;;;
Func Terminate()
    Exit
EndFunc   ;==>Terminate
;;;; End/Close/Terminate Function End ;;;;
Edited by XxXGoD
Link to comment
Share on other sites

i duno why i used that :shocked:

Read my post two up from here i edited it, and still cant get it to work :(

Here is what i have... but there are a few things needin changed...

LSHIFT i want to make custimizable via the ini file, and $D2_Win i want to be able to change via the ini file...

also how can i get it do do after 3 mins to press $Switch (Customizable via ini file) and then press the button $BC(Customizable via ini file) and then press $BO (Customizable via ini file) and then press $Switch again, and carry on for another threee mins doing the basic clicking but minimized....

Also with the script below it works kind off, but doesnt click correctly when doing the click insolance made it doesnt hold shift down...

;;;; Click Script Start ;;;;

;;;; Minimized Mouse Clicking Script, Thanks Insolance Start ;;;;
;===============================================================================
;
; Function Name:  _MouseClickPlus()
; Version added:  0.1
; Description:    Sends a click to window, not entirely accurate, but works
;                 minimized.
; Parameter(s):   $Window     =  Title of the window to send click to
;                 $Button     =  "left" or "right" mouse button
;                 $X          =  X coordinate
;                 $Y          =  Y coordinate
;                 $Clicks     =  Number of clicks to send
; Remarks:        You MUST be in "MouseCoordMode" 0 to use this without bugs.
; Author(s):      Insolence <insolence_9@yahoo.com>
;
;===============================================================================

Func _MouseClickPlus($Window, $Button = "left", $X = "", $Y = "", $Clicks = 1)
  Local $MK_LBUTTON       =  0x0001
  Local $WM_LBUTTONDOWN   =  0x0201
  Local $WM_LBUTTONUP     =  0x0202
 
  Local $MK_RBUTTON       =  0x0002  
  Local $WM_RBUTTONDOWN   =  0x0204
  Local $WM_RBUTTONUP     =  0x0205

  Local $WM_MOUSEMOVE     =  0x0200
 
  Local $i                = 0
 
  Select
  Case $Button = "left"
     $Button     =  $MK_LBUTTON
     $ButtonDown =  $WM_LBUTTONDOWN
     $ButtonUp   =  $WM_LBUTTONUP
  Case $Button = "right"
     $Button     =  $MK_RBUTTON
     $ButtonDown =  $WM_RBUTTONDOWN
     $ButtonUp   =  $WM_RBUTTONUP
  EndSelect
 
  If $X = "" OR $Y = "" Then
     $MouseCoord = MouseGetPos()
     $X = $MouseCoord[0]
     $Y = $MouseCoord[1]
  EndIf
 
  For $i = 1 to $Clicks
     DllCall("user32.dll", "int", "SendMessage", _
        "hwnd",  WinGetHandle( $Window ), _
        "int",   $WM_MOUSEMOVE, _
        "int",   0, _
        "long",  _MakeLong($X, $Y))
       
     DllCall("user32.dll", "int", "SendMessage", _
        "hwnd",  WinGetHandle( $Window ), _
        "int",   $ButtonDown, _
        "int",   $Button, _
        "long",  _MakeLong($X, $Y))
       
     DllCall("user32.dll", "int", "SendMessage", _
        "hwnd",  WinGetHandle( $Window ), _
        "int",   $ButtonUp, _
        "int",   $Button, _
        "long",  _MakeLong($X, $Y))
  Next
EndFunc




Func _MakeLong($LoWord,$HiWord)
  Return BitOR($HiWord * 0x10000, BitAND($LoWord, 0xFFFF))
EndFunc

;;;; Minimized Mouse Clicking Script, Thanks Insolance End ;;;;


;;;; Global Pause Start ;;;;
Global $Paused
;;;; Global Pause End ;;;;


;;;; Hotkey Settings Start ;;;;
HotKeySet("{HOME}", "TogglePause")
HotKeySet("{END}", "Terminate")
;;;; Hotkey Settings End ;;;;


;;;; Key Delay Options Start ;;;;
Opt('MouseClickDelay', 0)
;;;; Key Delay Options End ;;;;



;;;; Script Global Sleep Start ;;;;
While 1
    Sleep(100)
WEnd
;;;; Script Global Sleep End ;;;;


;;;; Toggle Pause and Splash On/Off Start ;;;;
Func TogglePause()
    $Paused = NOT $Paused
    While $Paused
            SplashTextOn( "Diablo II Auto Hammerdin Caster", "Starting AutoHammering - - Home = Pause/Unpause - End = Exit Program", 640, 25, 320, 30, 1,"system", "14", "")
            sleep(100)
send("{LSHIFT down}")
_MouseClickPlus( "$D2_Win", "left" )
send("{LSHIFT up}")
        SplashOff()
    WEnd
EndFunc

;;;; Toggle Pause and Splash On/Off End ;;;;


;;;; End/Close/Terminate Function Start ;;;;
Func Terminate()
    Exit
EndFunc
;;;; End/Close/Terminate Function End ;;;;



;;;; AutoHammer Script End ;;;;
Edited by XxXGoD
Link to comment
Share on other sites

i'm not sure but i think u're doing this for diablo 2 and if it is so... then

the is a diablo 2 bot called mm.bot that is made with autoit and...

u can get it from www.newd2event.net

if it isn't for diablo 2 :shocked: the sry

P.S.:

$bc = IniRead("ini.ini" , "settings" , "settings" , "z")
While 1
    Send("{"&$bc&" UP}")
    Sleep(100)
    Send("{"&$bc&" DOWN}")
WEnd

it works i just tested it

Edited by alexmadman

Only two things are infinite, the universe and human stupidity, and i'm not sure about the former -Alber EinsteinPractice makes perfect! but nobody's perfect so why practice at all?http://forum.ambrozie.ro

Link to comment
Share on other sites

i'm not sure but i think u're doing this for diablo 2 and if it is so... then

the is a diablo 2 bot called mm.bot that is made with autoit and...

u can get it from www.newd2event.net

if it isn't for diablo 2 :shocked: the sry

im not trying to do a bot like that dude, ive used mmbot, i even modififed it so its made just for my account and i have the bosses, countress, summoner and nili, and many more also dont advertsise sites

This is only an example of what i need help with....

C:\Documents and Settings\User\Desktop\MTD

C:\Documents and Settings\User\Desktop\MTD\Scripts

C:\Documents and Settings\User\Desktop\MTD\Config

Right ther are them three folders how can i get a script in the script folder to read an ini file in config... without knowing the actual directory location....

Edited by XxXGoD
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...