[HELP] direct input - controlclick

07/08/2010 13:40 syron198#1
Hey guys,

I'm actually working on a bot for league of legends, what I've done so far is the following:

Code:
Func startGame()
	$title = "PVP.net Client"
	$full = WinGetTitle($title)
	$hwnd = WinGetHandle($full)

	WinMove($title, "", 0, 0)
	Sleep(1000)

	ControlClick($title, "", "", "LEFT", 1, 256, 62) ; click on Play
	Sleep(6000)
	ControlClick($title, "", "", "LEFT", 1, 550, 450) ; click on Practice
	Sleep(6000)
	ControlClick($title, "", "", "LEFT", 1, 311, 582) ; click on Create Game
	sleep(6000)
	ControlSend($title, "", "", "{TAB}")
	ControlSend($title, "", "", "{TAB}")
	ControlSend($title, "", "", "{TAB}")
	ControlSend($title, "", "", "{TAB}")
	ControlSend($title, "", "", "{TAB}")
	Sleep(1000)
	ControlSend($title, "", "", "abcdefgh")
	sleep(2000)
	ControlSend($title, "", "", "{TAB}")
	sleep(2000)
	ControlSend($title, "", "", "abcdefgh")
	sleep(5000)
	ControlClick($title, "", "", "LEFT", 1, 248, 591) ; click on Create Game

	; time to add bots!

	; add bots to your team!
	Sleep(3000)
	ControlClick($title, "", "", "LEFT", 1, 468, 378)
	Sleep(3000)
	ControlClick($title, "", "", "LEFT", 1, 468, 378)
	Sleep(3000)
	ControlClick($title, "", "", "LEFT", 1, 468, 378)
	Sleep(3000)
	ControlClick($title, "", "", "LEFT", 1, 468, 378)

	; add bots to other team!
	Sleep(3000)
	ControlClick($title, "", "", "LEFT", 1, 896, 375)
	Sleep(3000)
	ControlClick($title, "", "", "LEFT", 1, 896, 375)
	Sleep(3000)
	ControlClick($title, "", "", "LEFT", 1, 896, 375)
	Sleep(3000)
	ControlClick($title, "", "", "LEFT", 1, 896, 375)
	Sleep(3000)
	ControlClick($title, "", "", "LEFT", 1, 896, 375)
	Sleep(3000)

	; click on start game
	ControlClick($title, "", "", "LEFT", 1, 832, 589)
EndFunc
which is a function, which creates a bot game. (I'm using that bot game shit, because I don't want to test it in normal game!)


This creates a game, even if it is not open with ControlClick() & ControlSend()

this works perfectly on 2 comps, but the thing is, I want to make it work ingame as well, like the bot shall rightclick on 2 coordinates to not be inactive & get dc'd.

I found out that the game uses directinput, my question is, if there is a way to hook directinput via autoit? I want the game to run in background to watch movies while it levels.

Hope some1 can help.
07/08/2010 13:59 Centaro#2
i thinks bots are not good for games like LoL, they destroy the normal gameplay!
07/08/2010 14:23 Geilomat#3
Mhm what about separate all the sections into different Func`s.

ControlClick & ControlSend not working for you ingame?

The Windows Title is not the same you know that ? Ingame it changes to:

""League of Legends (TM) Client""
07/08/2010 14:26 syron198#4
yeah I know, that the ingame windowname is different.

And yeah "Centaro", bots are not good for those games. Well, the idea of this is just to use practice games as bot games, since I totally hate it when people are afk on base and just leeching xp... so this is just a practice game bots for the 4 games u can play a day.


Your advantage of using a bot is still too low to make profit with it ingame, since what counts is not ip or xp, it's still your experience u have in playing this game. Even if people are level 30 just by leveling with bot, they still do not have the experience they need to win.
07/11/2010 18:35 shizzles#5
Quote:
Originally Posted by Centaro View Post
i thinks bots are not good for games like LoL, they destroy the normal gameplay!
AMEN!!!! this is a game of skills, nothin further
07/11/2010 20:05 Atheuz#6
Quote:
Originally Posted by shizzles View Post
AMEN!!!! this is a game of skills, nothin further
You'll get banned for idling and sort anyway.