SRL Archive - Help and Support

findcolorellipse


weaselforce

2006-03-30 01:56:48

[Runtime Error] : Exception: Can't allocate the DIB handle in line 301 in script C:\Program Files\SCAR 2.03\includes\srl\srl\core\Color.scar

 line 301 : if FindColorSpiralTolerance(Cx, Cy, Color, 0, 0, W, H, Tol) then 


 My Code : findcolorellipse(x,y,241,50,588,62,598,86) 

function FindColorEllipse(var x, y: integer; Color, Tol, X1, Y1, X2, Y2: integer): boolean;

uhh so yea, i know for a fact this time i used "setupsrl" before the error, so anyone have any idea or know

Pwnd

2006-03-30 02:09:44

Maybe it's a problem with the function itself. I'll wait till I get a double from Fakawi and friends.

WhiteShadow

2006-03-30 02:27:21

Weird Runtimes Happen alot. Try replacing the procedure with something else. Move the script around or something. I had alot runtimes in the past. I just save it and run it again several times. Move some procedures around save it. Runagain. I don't know these things are weird.

Krazy_Meerkat

2006-03-30 03:50:00

Works fine for me.
Sometimes the runtime error is really on the line above eg. forgetting a close bracket or a ;

BenLand100

2006-03-30 08:50:36

I've gotten this error before for two reasons:
1) I had not set a client window or the client was minimized/closed
2) The size of the ellipse was bigger than the client
Tell me if you get it again since i'm more than likely the only person that understands it anyway ;)

weaselforce

2006-03-30 10:10:11

procedure gointocastle;

var RColor:integer;

begin
perfectnorth;
RColor := roadcolor;
repeat
writeln('omg')
RoadWalk(RColor,'W');
until (findcolorellipse(x,y,241,50,588,62,598,86));
end;

EDIT: GAH im sorry, i just notice roadwalk was what wasnt working…sorry to waste your time

Krazy_Meerkat

2006-04-01 01:31:26

Told ya ;)