ok i need help, how do i make it rotate and search for a colortolerance, dtmtolerace, or bitmaptolerance? or how come scar cant find the cursor?
i need it to find the mouse arrow as a dtm or bitmap? how can i do this?
thnx for ur help
ok i need help, how do i make it rotate and search for a colortolerance, dtmtolerace, or bitmaptolerance? or how come scar cant find the cursor?
i need it to find the mouse arrow as a dtm or bitmap? how can i do this?
thnx for ur help
FindDTMRotated???
Colors are individual pixels so no need to ever rotate them? But..
For DTMs there is a function in SRL called 'DTMRotated' in the 'DTM' include.
For BMPs there is a function in SCAR
function FindDeformedBitmapToleranceRotationIn(bitmap: Integer; var x, y: Integer; x1, y1, x2, y2: Integer; tolerance: Integer; Range: Integer; var accuracy: Extended; AngleIntervals: Extended; StartAngle, MaxAngle: Extended; var angle: Extended): Boolean;
Works similar to FindDeformedBitmapToleranceIn but allows searching for rotated bitmaps as well. Basically it rotates bitmap, searches in target image, then rotates again, searches again. AngleIntervals specifies by how much it rotates every time, StartAndge specifies initial rotation angle, MaxAngle specifies how far it rotates and angle returns angle of found image. All angles are specified in radians (Pi = 180˚)
Example:
FindDeformedBitmapToleranceRotationIn(minimaptree, x, y, 582, 37, 700, 117, 170, 0, acc, PI/10, 0, 2*PI, angle);
And what is it that you want to find a BMP of the mouse arrow for??
if you just are looking to find where the curser is you can useand it will put the location into the variables x and y.SCAR Code:GetMousePos(x, y);
thnx, thats half of wat i needed,i think.......wait by rotate do u mean degrees on screen? by roate i ment rotate camera ingame(arrow keys) and look for color, cuz things move..lol? dtm or bmp of cursor, which is for my own stuff(not rs) but i duno if scar can even do that, and rotate camera and look for color.. ?
The mousearrow is drawn in a different buffer that scar can't search, it'll see through the mouse cursor.
Rotate camera: KeyDown(VK_LEFT/VK_RIGHT/VK_DOWN/VK_UP); wait(sometimehere) KeyUp(whatever is in the keydown).
Instead of the wait you can do a loop like
KeyDown(blabla)
repeat
wait(10); //10 milliseconds = 0,001 second
until(FindColor(blablabla))
KeyUp(blablablablabla)
I made a new script, check it out!.
ahh well that explain alot mucho gracias..hmm wat it can look for is a pic of a pic lol, il just do that thnx
For any possible need of having the bitmap or a DTM of the cursor I can imagine, getMousePos does the job.
There are currently 1 users browsing this thread. (0 members and 1 guests)