SRL Archive - OSR Help

Any function to find if your character is stunned??


Mysickname

2013-03-27 09:23:31

hi guys, im currently working on a masterfarmer bot
just wondering if theres some kind of funtion to check if you are stunned
also, how do i get the bot to click somewhere on the minimap
any help i would love cheers,

xtrapsp

2013-03-27 09:27:30

I dunno if it's exactly possible. Stunned being the little yellow birds? You could do a check for that itself? Just for the colours.

Ian

2013-03-27 09:41:41

Yeah, look for the yellow in a box around your player's head. And to click on the mimimap you can look for colors in a box around the minimap and then move the mouse to those coordinates and click. :)

litoris

2013-03-27 09:41:48

Do a color count for yellow in the area above the character's head, where the birds appear.
Flight's thieving guild had a nice stun function for the live game, you might want to check that out.

Mysickname

2013-03-27 09:50:01

okay thanks, but how do i do a box with the colours?

Ian

2013-03-27 09:58:56

From: Mysickname
okay thanks, but how do i do a box with the colours?


if (CountColorTolerance(YellowBirdColor, xs, ys, xe, ye, Tolerance) > 20) then
WriteLn('Birds! We are stunned!')

Find YellowBirdColor by using the color picker tool and clicking the yellow birds.

Find xs and ys by using the color picker tool and clicking the top left corner of the box around your player's head.

Find xe and ye by using the color picker tool and clicking the bottom right corner of the box around your player's head.

Find Tolerance using guess and check. (Try 5 or 10, higher number means it will find more similar colors)

20 is the number of pixels that will have to be yellow for it to think it's stunned. You can find it out by counting the colors in the box, but you should go with a number that is less than the number that are yellow just to be safe.

Mysickname

2013-03-27 10:31:02

ok cheers