Jagex_Fagex
2006-03-14 05:21:34
Tutorial on Bitmaps
Ok, so first up, what’s a bitmap? Well a bitmap is a picture, or image that the SCAR can search for, this makes finding and locating stuff.
WHAT DOES A BITMAP LOOK LIKE?
Well a bitmap as a picture may look like this:

While a bitmap in scar may look like this:
36 := BitmapFromString(9, 16, 'z78DA3330A02670030352D56302E' +
'2D5638AE3528FE942FC3612EF2AFAEB25CF5FF8C38DD49027CF5F' +
'B44E51830D00007EA6B6A1');HOW DO I USE A BITMAP IN SCAR?
To use a bitmap in Scar you need to get it into the state of code, such as above… To get it to that stage you first need to get the bitmap. You can get bitmaps by pressing the Prt Scr key, which is generally located above insert on your keyboard. Then by pasting it into paint or other photo editing software.
Click Here To Find where the Key is
HOW DO I PREPARE A BITMAP?
To prepare a bit map, cut on crop the print screen down to the whole object, then cut it down to a piece that is unique to that object, taking just a little bit (couple of pixels*Couple of pixels).
Change this
Into This
Because colors change, you need to change the background, just change all the background to black, so that scar searches only for the bitmap, and not the background aswell.
NOW TIME TO IMPORT THE BITMAP!
To import the bitmap, go to Script –> Picture to string, hit open, and locate the bitmap, hit ok, ok. Now down the bottom of scar, inside the debug box you should see something like:
fallycastle1 := BitmapFromString(28, 25, 'z78DADD96C10E0221' +
'0C447F69D918C25E75E3FF7F92173524D2E94C29C678697A58CA6' +
'39896DDEE653FCE8D89B7528E8B9C83D8886FDE5FF29C01128FB0' +
'5EEB5E0B75962C3D43B43E6740CF7EED24E14B49C4D9BBA22DE71' +
'9EC4872BAF79E4838C349EAB9A06B7A4FCA7A1AB7FCAC1098305E' +
'CE720EF584B442578A84B23F618E2ACF2939E6B4EA780EB4EAABC' +
'C9A9E80969E782A2DBB16CC04A99747DDCA30F39C110F7BEFF237' +
'E3BF71EAAE43BE559D6FADE5A70D7E5F949ED5CEE851B1519F27A' +
'C3E193E8CEFC87920DFEDED9CFF2FFDACBC969363D6BAC9CE594E' +
'5DC988025CCC52953DB5D5A151C2559EFF6DC29EF3016A42802D');now you need to create a variable, since this bmp is called fallycastle1 we write
var fallycastle1:Integer; at the start of the script…This code can now be used in a Script, Just hit f1 in scar and scroll down to the bitmap section, to find out all the procedures and functions.