Jump to content

Warcraft 3 (Don't activate window)


Lal123
 Share

Recommended Posts

I need a code for my bot (For Warcraft 3). I need 2 things. I need the bot NOT to activate Warcraft 3 window when a game is found (It does that) I heard it is possible, I read the help file, I searched this forum, But I don't know these types of commands you need.

That's the one code I need. When the game is found, it turns into a loading screen, it is different from computer to computer, when the loading is finished (Depends on how good you computer/connection is). I have it only to do "Sleep(12000)", but that doesn't work on all computers.

Thanks for reading!

(I saw something like this posted by someone else but no one responded.)

Edited by Lal123
Link to comment
Share on other sites

I need a code for my bot (For Warcraft 3). I need 2 things. I need the bot NOT to activate Warcraft 3 window when a game is found (It does that) I heard it is possible, I read the help file, I searched this forum, But I don't know these types of commands you need.

That's the one code I need. When the game is found, it turns into a loading screen, it is different from computer to computer, when the loading is finished (Depends on how good you computer/connection is). I have it only to do "Sleep(12000)", but that doesn't work on all computers.

Thanks for reading!

(I saw something like this posted by someone else but no one responded.)

Lal123

I need $1M but asking for it is unlikely to get it. If you have some code to post, we'll try and help you.

Link to comment
Share on other sites

Lal123

I need $1M but asking for it is unlikely to get it. If you have some code to post, we'll try and help you.

Yes, here is my code:

HotKeySet('{F2}', 'ExFunc')
HotKeySet('{F1}', 'Start')

#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>

#Region ### START Koda GUI section ### Form=d:\program files\autoit3\scite\koda\forms\Form1.kxf
$Form1_1 = GUICreate("Form1", 291, 272, 193, 125)
$Label3 = GUICtrlCreateLabel("F2 = Close Bot", 184, 224, 73, 17)
$Label5 = GUICtrlCreateLabel("F1 = Start Bot", 24, 224, 69, 17)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###

While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit
    EndSwitch
WEnd

Func ExFunc()
    Exit
EndFunc

Func Start()
        ControlSend("Warcraft III", "",'', "{ALTDOWN}Q{ALTUP}", 0);Finds game
        Do
            Sleep(10)
        Until WinGetTitle('[ACTIVE]', '') = 'Warcraft III"  ;Here it activates window when wc3 finds game (I want it NOT to activate window)
        Sleep(10000)  ;I want to change this to make it wait until loading is finished
EndFunc
Edited by Lal123
Link to comment
Share on other sites

I don't have Warcraft, but your issue was activating a window. So I used Notepad as the opened program.

Open Notepad.exe and run the code below.

The code below does NOT activate notepad window, so not quite sure where the problem is.

HotKeySet('{F2}', 'ExFunc')
HotKeySet('{F1}', 'Start')

#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>

#Region ### START Koda GUI section ### Form=d:\program files\autoit3\scite\koda\forms\Form1.kxf
$Form1_1 = GUICreate("Form1", 291, 272, 193, 125)
$Label3 = GUICtrlCreateLabel("F2 = Close Bot", 184, 224, 73, 17)
$Label5 = GUICtrlCreateLabel("F1 = Start Bot", 24, 224, 69, 17)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###

While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit
    EndSwitch
WEnd

Func ExFunc()
    Exit
EndFunc

Func Start()
        ControlSend("Untitled - Notepad", "","Edit1", "Hello world 1.", 0);Finds game
        Msgbox(0+262144,"Debug","Pause")
        Do
            Sleep(10)
            Msgbox(0+262144,"Debug","Not sleeping", 1)
        Until WinGetTitle("Untitled - Notepad", "") = "Untitled - Notepad"  ;Here it activates window when wc3 finds game (I want it NOT to activate window)
        Msgbox(0+262144,"Debug","About to Sleep(10000)")
        Sleep(10000)  ;I want to change this to make it wait until loading is finished
EndFunc
Link to comment
Share on other sites

I don't have Warcraft, but your issue was activating a window. So I used Notepad as the opened program.

Open Notepad.exe and run the code below.

The code below does NOT activate notepad window, so not quite sure where the problem is.

HotKeySet('{F2}', 'ExFunc')
HotKeySet('{F1}', 'Start')

#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>

#Region ### START Koda GUI section ### Form=d:\program files\autoit3\scite\koda\forms\Form1.kxf
$Form1_1 = GUICreate("Form1", 291, 272, 193, 125)
$Label3 = GUICtrlCreateLabel("F2 = Close Bot", 184, 224, 73, 17)
$Label5 = GUICtrlCreateLabel("F1 = Start Bot", 24, 224, 69, 17)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###

While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit
    EndSwitch
WEnd

Func ExFunc()
    Exit
EndFunc

Func Start()
        ControlSend("Untitled - Notepad", "","Edit1", "Hello world 1.", 0);Finds game
        Msgbox(0+262144,"Debug","Pause")
        Do
            Sleep(10)
            Msgbox(0+262144,"Debug","Not sleeping", 1)
        Until WinGetTitle("Untitled - Notepad", "") = "Untitled - Notepad"  ;Here it activates window when wc3 finds game (I want it NOT to activate window)
        Msgbox(0+262144,"Debug","About to Sleep(10000)")
        Sleep(10000)  ;I want to change this to make it wait until loading is finished
EndFunc
It's not a code, that activates the window. It's the game itself, that has a code in it, that activates it. I want so it is blocked. I got help from a friend, and he told me to use this command, but I am not exactly sure, what he ment.

writeprocessmemory(war3process,offset,byte,size,0)

Link to comment
Share on other sites

If they are suggesting writeprocessmemory(war3process,offset,byte,size,0)

then they are mucking directly (hacking) with the code of the game. Unless this is some documented interface, I can't help you as it requires very detailed knowledge of the inner workings of the game code.

Link to comment
Share on other sites

There is another recent thread with the exact same M.O. This guy is trying to make a spambot.

Certifications: A+, Network+, Security+, Linux+, LPIC-1, MCSA | Languages: AutoIt, C, SQL, .NETBooks: AutoIt v3: Your Quick Guide - $7.99 - O'Reilly Media - September 2007-------->[u]AutoIt v3 Development - newbie to g33k[/u] - Coming Soon - Fate Publishing - Spring 2013UDF Libraries: SkypeCOM UDF Library | ADUC Computers OU Cleanup | Find PixelChecksumExamples: Skype COM Examples - Skype4COMLib Examples converted from VBS to AutoIt
Link to comment
Share on other sites

Check out this command.

Winsetstate ("WARCRAFT III","",@SW_HIDE)
Thanks, this is actually working.

And I said "There is almost the same thread like this one, but there isin't an answer because the person wants to create a spambot, but I need the same and I don't want that".

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