[Guide] PickUp Bot

09/23/2009 21:46 Dark Raccoon#46
Quote:
Originally Posted by XDFACE View Post
Here be my First Script
after using AutoIT for 3 days

Any noticeable mistakes?
Code:
#include <ImageSearch.au3>


MsgBox(0, "MSG", "Press Ok to Start")
WinActivate("Mabinogi : Ancient Secrets of Irinid")
While (1)
	Send("{[B][COLOR="Red"]L[/COLOR][/B]ALT down}")
	Send("{Ctrl down}")
	$x1 = 0
	$y1 = 0
	;
	; finds the target monter
	$result = _ImageSearch("monster.bmp", 1, $x1, $y1, 0)

	If $result = 1 Then

		MouseMove($x1, $y1, 1)
		MouseClick("Left", $x1, $y1, 1, 1)
		MouseClick("Left", $x1, $y1, 1, 1)
		MouseClick("Left", $x1, $y1, 1, 1)
		MouseClick("Left", $x1, $y1, 1, 1)
		MouseClick("Left", $x1, $y1, 1, 1)
		Send ("{ctrl up}")
		Sleep(2000)
	EndIf
WEnd

While (1)
	; Picks up loot
	$result = _ImageSearch("gold.bmp", 0, $x1, $y1, 0)
	If $result = 1 Then
		MouseMove($x1, $y1, 3)
		MouseClick("Left")
		Sleep(2000)
	EndIf
WEnd
I noticed this after staring at it for 2 full seconds.

I'll take a closer look later.
09/24/2009 06:36 XDFACE#47
When i tested this it found the pictures in my folder..but then it came to mabi it was unresponsive. D:
09/29/2009 15:42 basic401k#48
Quote:
Originally Posted by Dark Raccoon View Post
I noticed this after staring at it for 2 full seconds.

I'll take a closer look later.

there is nothing wrong with the LALT
10/18/2009 20:41 icekenshin#49
ugh after trying these all out and attempting to make it work, it will hover over the gold, but then nothing, just goes back to hitting wolves...

I can't quite articulate what I am doing wrong. I guess i just wait for the day its complied into a .exe :/

I will continue to play around with it some more see if I can get it to do both but atm it won't work lol
10/18/2009 23:22 meral#50
hows this
Code:
#include <ImageSearch.au3>
MsgBox(0, "MSG", "Press Ok to Start")
WinActivate("Mabinogi : Ancient Secrets of Irinid")
While 1 = 1
	Send("{LALT down}")
	Send("{LCtrl down}")
	$x1 = 0
	$y1 = 0
	;
	; finds the target monter
	$result = _ImageSearch("monster.bmp", 1, $x1, $y1, 0)
	If $result = 1 Then
		MouseMove($x1, $y1, 0)
		MouseClick("Left", $x1, $y1, 5, 1)
		Send("{ctrl up}")
		Sleep(2000)
		Call("Loot")
	EndIf
WEnd


Func Loot()
	$gold = _ImageSearch("gold.bmp", 0, $x1, $y1, 0)
	If $gold = 1 Then
		MouseMove($x1, $y1, 0)
		MouseClick("Left")
		Sleep(2000)
	EndIf
EndFunc   ;==>Loot
10/18/2009 23:34 Dark Raccoon#51
[Only registered and activated users can see links. Click Here To Register...]

This one currently features a PickUp-Bot BETA that picks up Gold and FomorScrolls.
10/25/2009 02:43 icekenshin#52
So when i run it inside the script editor this is what i get in the window below the script code.

Code:
C:\Program Files\AutoIt3\Include\ImageSearch.au3 (40) : ==> Subscript used with non-Array variable.
which i think is whats giving me my line 1 variable array error what am i doing wrong. hate to have to ask but all input is valuable
10/25/2009 09:25 cloudkiller2006#53
do you actually have the bot in c:\program files\autoit3\include\ ?
10/25/2009 11:04 icekenshin#54
no should i have it there?

***EDIT***

so i put the bot in the image search folder the darn thing works not 1 problem cept it doesn't pic up stuff so i just gonna have to tweak around with it.
10/29/2009 06:23 pepole12#55
iv done everything you guys said but how do i get it to start up and work?
11/11/2009 01:29 tuxx95#56
hey ive been trying to get this to work for a while and nothing will work i cant even get it to find the source picture i used the same commands and even put it in the same folder any advice?
11/11/2009 02:21 ichigoyeh#57
Sorry for bumping this image search thread further, but I need to know how to make it so that it will keep searching for the image even if it's not there. Like for a fishing bot. THAT or my computer is a crappy win7 and it can't use this script because most of the time when I start it up, it closes itself.
11/11/2009 20:37 tuxx95#58
Quote:
Originally Posted by ichigoyeh View Post
Sorry for bumping this image search thread further, but I need to know how to make it so that it will keep searching for the image even if it's not there. Like for a fishing bot. THAT or my computer is a crappy win7 and it can't use this script because most of the time when I start it up, it closes itself.
try a loop without $result=0 or run as admin
11/12/2009 15:18 brokeback#59
i've been trying to find sheeps or wool but it wont seem to work... any help would do..


Quote:
#include <ImageSearch.au3>
MsgBox(0, "MSG", "Press Ok to Start")
WinActivate("Mabinogi : Dragon")
While 1 = 1
Send("{LALT down}")
$x1 = 0
$y1 = 0
$result = _ImageSearch("wool.jpg",1,$x1,$y1,100)
$result = _ImageSearch("sheep2.jpg",1,$x1,$y1,100)
if $result = 1 then
msgbox(0,"Result","Found!")
else
msgbox(0,"Result","Not Found!")
endif
WEnd

11/13/2009 00:11 Trismic#60
Quote:
Originally Posted by brokeback View Post
i've been trying to find sheeps or wool but it wont seem to work... any help would do..
You have 1 variable with 2 different value

$result = value 1
$result = value 2

it should be

$result = value 1
$result2 = value 2