|
Post by Izlude on Jan 22, 2005 23:04:56 GMT -5
ok i really need to get a voke bot goin i am a lvl 30 monk and i need some gil for armour, also i dont want this to be a afk bot i just want to out-voke the other nm campers i am currently trying to write a provoke script and don't understand at all heres what i have so far: Global $x = 10.090 ; X-coordinate for pixel Global $y = 7.285 ; Y-coordinate for pixel Global $PixelGetColor = ("$x, $y") Global $yellow = 15395522 ; Normal, unclaimed color. Most important. (RGB Decimal value) Global $red = 15242901 ; Color when player has claimed. (RGB Decimal value) Global $purple = (no screenshot) ; Color when claimed by another. (RGB Decimal value) Global $provoke = "!1" ; Provoke macro While 1=1 Func MyFunction() /ja "Provoke" <t> $yellow = 15395522 MyFunction() will it work? i am getting the pixel location using the good ole' dropper technique, and i am using autoit v3
|
|
Heffy
Junior Member
Posts: 62
|
Post by Heffy on Jan 23, 2005 1:36:59 GMT -5
Func MyFunction() /ja "Provoke" <t>
I dont quite know how to explain why, but I have an inkling that that function wont work. Something to do with the quotes...
|
|
|
Post by JavaTaru on Jan 23, 2005 5:16:13 GMT -5
Func MyFunction() /ja "Provoke" <t> $yellow = 15395522 MyFunction() first off thiis doesnt look right Seems to me you are trying to use recurrsion (when a method calls itself) however you have made an infinite recursive loop. Also , although im not sure what your trying to do here, im guessing it should be Func MyFunction() Send("/ja "Provoke" <t> {ENTER}" $yellow = 15395522 MyFunction() Endfunc not 100% sure what this is supposed to do because i havnt used pixel capturing yet. Oh well sorry i cant help any more
|
|
Heffy
Junior Member
Posts: 62
|
Post by Heffy on Jan 23, 2005 6:24:55 GMT -5
Send("/ja "Provoke" <t> {ENTER}"
This will NOT work. AutoIT will interpret the " before Provoke as the end of the send command. And as you could imagine that would mess things up. Why do you think bots use macros, silly?
|
|
|
Post by Izlude on Jan 23, 2005 15:16:00 GMT -5
well ya see this is all for a provoke bot i want to make, but how do i alter it so it only provokes a certain pixel colour and location? and repeatedly does it this is my first script every attempted also how could i make this bot use a alt 1 macro, it would be !1 right? ok so would this be any good?
Global $x = 10.090 ; X-coordinate for pixel Global $y = 7.285 ; Y-coordinate for pixel Global $PixelGetColor = ("$x, $y") Global $yellow = 15395522 ; Normal, unclaimed color. Most important. (RGB Decimal value) Global $red = 15242901 ; Color when player has claimed. (RGB Decimal value) Global $purple = (no screenshot) ; Color when claimed by another. (RGB Decimal value) Global $provoke = "!1" ; Provoke macro
While 1=1
Func MyFunction() $yellow = 15395522 Send ("!1")
so how does this look? also i want to add in a pause incase i ever get contacted by a gm and i can just turn it off with a simply floppy disk insert #nosmileys#nosmileys#nosmileys
|
|
|
Post by Izlude on Jan 24, 2005 17:48:54 GMT -5
ok i am not getting very far, so i am gunna try and use bits and pieces of other bots to configure mine, here it is so far:
Global $x = 10.090 ; X-coordinate for pixel Global $y = 7.285 ; Y-coordinate for pixel Global $PixelGetColor = ("$x, $y") Global $yellow = 15395522 ; Normal, unclaimed color. Most important. (RGB Decimal value) Global $red = 15242901 ; Color when player has claimed. (RGB Decimal value) Global $purple = (no screenshot) ; Color when claimed by another. (RGB Decimal value) Global $provoke = "!1" ; Provoke macro
WinWaitActive("FFXiApp")
While 1=1
FindTarget()
Provoke()
WEnd
WEnd
Func FindTarget() While 1=1 Send("!1") sleep(1) If PixelGetColor ($x,$y) = $15395522 Then ($provoke) WEnd EndFunc
how do i adjust the speed of this? i want it to check like every milisecond to see if he has spawned yet
|
|
|
Post by Izlude on Jan 24, 2005 17:49:26 GMT -5
will it work?
|
|
|
Post by Duke Newrise on Jan 24, 2005 21:20:06 GMT -5
That... won't even compile, I'm sorry. Your on the right track don't get me wrong but you have a call to a funtion that doesn't exist. Also the pixelget command uses whole numbers because you can't check half a pixel.
|
|
|
Post by TinyTerror on Jan 24, 2005 22:39:24 GMT -5
I think you might have an extra WEnd in there too.
|
|
|
Post by Izlude on Jan 24, 2005 23:00:37 GMT -5
ok can u guys help me get it all fixed up?? its an autoIt script if it matters please point out why it wont compile the x and y co-ords are from the dropper in abdobe photoshop, it gives a x, y location, i thought that was what the x, and y was. where do i get the x, and y from then?
|
|
|
Post by Duke Newrise on Jan 24, 2005 23:33:27 GMT -5
Another big goof up is:
Global $PixelGetColor = ("$x, $y")
I'll turn $x, $y into a string and make PixelGetColor a var.
Why should we fix it when you seem to be doing a fine job yourself!
|
|
|
Post by TinyTerror on Jan 25, 2005 8:18:57 GMT -5
I agree with duke. In the process of fixing this on your own, you are learning how to script. It might seem a little rough at first, but it will get alot better.
The X and Y value are the physical coordinates of the pixel on the screen. The dropper should give you an RGB value for the pixel. You can either convert this into an integer that AutoIT can use, of you can use this snippet of code to echo the correct pixel values to you in game:
AutoItSetOption("SendKeyDelay", 20); AutoItSetOption("SendKeyDownDelay", 50);
$MyColor=PixelGetColor($x,$y); //Gets the color of a pixel Send("/echo Pixel at ("); Send($x); Send(","); Send($y); Send(") has color code "); Send($MyColor); Send("{ENTER}");
Unless my autoIT skills have gotten a bit rusty, this should get the value of a pixel in-game and echo it to your FFXI console. I used to use this method when I just first started scripting for FFXI. It works pretty well, and can also be used to get pixel checksums. Make sure you have an non transparent menu background when you do this, or your results will be different every time. This applies to all pixel based scripts, so make sure you do it!
|
|
|
Post by Izlude on Jan 25, 2005 9:51:47 GMT -5
ok i have never had any luck with the /echo things that gimme pixel colours, how does the script know location for x and y to check? also could ya gimme instructions on how to use ur script with get pixel colour?
|
|
|
Post by TinyTerror on Jan 25, 2005 10:03:41 GMT -5
Well, you have to set it to check certain coords. This isnt a stand alone script, just a code segment that can be used as you see fit.
|
|
|
Post by Izlude on Jan 25, 2005 12:04:18 GMT -5
Global $PixelGetColor = ("$x, $y")
I'll turn $x, $y into a string and make PixelGetColor a var.
how can i make it check x and y without it being a goofed up?
|
|