• Log in or sign up for an account here: https://www.sythe.org/login

My scripd dont want to work

  • Thread starter Thread starter ciffer
  • Start date Start date
C

ciffer

Guest
Hi. I am new user of SCAR but i readed tutorials and I think i know how to use it.
So I wanted to write Dofus script for auto barley farming. I made this script:
program New;
var
x, y, z: integer;

Procedure Kolor;
begin;
z:=100+random(100);
if FindColor(x, y, 2974, 6, 44, 1270, 778) then;
begin;
MoveMouseSmooth(x, y);
wait(z);
clickmouse(x,y,true);
ClickMouse(x+20, y-20, true);
wait(10400);
end;
end;
begin;
repeat;
wait(1000);
Kolor;
until(false);
end.
It is starting to work but i think it dont write the var x and y so it cant click in the place where i want to. Please help me and if you can suggest me any improvements i would be very happy ;]
 
Put it in a code box instead of a quote box.
 
Okie here you are:
Code:
program New;
var
x, y, z: integer;

Procedure Kolor;
begin;
 z:=100+random(100);
 if FindColor(x, y, 2974, 6, 44, 1270, 778) then;
  begin;
    MoveMouseSmooth(x, y);
    wait(z);
    clickmouse(x,y,true);
    ClickMouse(x+20, y-20, true);
    wait(10400);
  end;
end;
begin;
 repeat;
  wait(1000);
  Kolor;
 until(false);
end.
 
Don't put semi-colons after begin, repeat, or then.
 
Um ok i made it because of annoying error "Missing semicolon". I've got mad and i did put it everywhere

@Edit

Yay it works now but it still didnt got it-I wrote y-20 but i think he ignores it.
 
well im new on it too.... i made my scar to work.... well but it cannot load some points in script :S
 
Ok i made this script work fully. I didn't only tested bank function (i added it) but everything else is working just fine. If someone want to use this script ask for it and i will translate it to english and give you final version of it.
 
I don't recommend making full scripts without the SRL. The SRL has a whole lot of procedures that will help you with your script and will also make it less detectable. Good luck scripting :)
 
I would be very happy if you can provide me with some link or something ;]
 
Ok I have it and now I want to make class with bitmaps codes but I don't know how to make class. I want to use advanced mouse using and bitmap searching but i dont want to make it all in about 20 variables.
 
Sorry to bother you again but I have another problem. I read that article and made an include script with 20 bitmaps. Itself there is no problem-Bitmap.scar executes and compiles without errors but when i want to include it to Start.scar
it show this error:
[
Error] (4:1): 'BEGIN' expected in script C:\Program Files\SCAR 3.06\includes\Dofus\Bitmap.scar
I will show here also beginning of each file:
Start.scar
Code:
program Farmer;
{.include Dofus\Bitmapa.scar}

var
x, y, z, ile: integer;
end:boolean;
...

Bitmap.scar
Code:
program BitmapClass;

type
 bitmaps=record
 b1:integer;
 b2:integer;
 b3:integer;
 b4:integer;
 b5:integer;
 b6:integer;
 b7:integer;
 b8:integer;
 b9:integer;
 b10:integer;
 b11:integer;
 b12:integer;
 b13:integer;
 b14:integer;
 b15:integer;
 b16:integer;
 b17:integer;
 b18:integer;
 b19:integer;
 b20:integer;
end;

var
bitmap:bitmaps;

begin
 bitmap.b1:=BitmapFromString(51, 10, 'z78DAED9649B265370844B7A45E30' +
       '0435FB5F920FFAB7CA357038C273BFA8C8AFD2550349025297554' +
       'CB2D42C73CD9DFBE46F76F0942A4946D95244CB952A5A93579592' +
...
 
You are probably better off making that an array of integers. Then have Bitmap[1] := etc.
 
Yeah i wanted to make it first but i didn't know how to do that but i will search forum ^_^
 
Good example from Goblin Schredular:

Code:
var
  GoblinColors: array[1..16] of integer;

procedure SetupGoblinColors;
begin
 GoblinColors[1]  := 8635310;
 GoblinColors[2]  := 4372133;
 GoblinColors[3]  := 6269056;
 GoblinColors[4]  := 3058586;
 GoblinColors[5]  := 3058063;
 GoblinColors[6]  := 2595741;
 GoblinColors[7]  := 2129535;
 GoblinColors[8]  := 5075294;
 GoblinColors[9]  := 7050972;
 GoblinColors[10] := 7642334;
 GoblinColors[11] := 12832983;
 GoblinColors[12] := 7237495;
 GoblinColors[13] := 8700589;
 GoblinColors[14] := 6978694;
 GoblinColors[15] := 3844000;
 GoblinColors[16] := 7118991;
end;

Pretty much just like that except you have to declare the bitmaps first.
 
Man tnx you rule ;] You have helped me a lot but i dont see here any reputation points or + ;/
 
Runescape Gamblingrunescape gambling
Back
Top