SRL Archive - General Botting Help

function TBox.getMiddle Error


Obquility

2014-12-17 03:11:57

Hey all,
I'm thinking this may be alike another error mentioned in a post before, but instead this is a tbox error. Could any of you get this working?
This is the error I get when running the script, it compiles fine-
Error: Access violation at line 145

It's probably just a simple fix, or something like that. Help would be appreciated,
Thanks.
~Josh

GRIM

2014-12-17 03:35:15

copy+paste line 145


is it this line? if yes then does it look just like mine?

result := point((self.x2 + self.x1) div 2, (self.y2 + self.y1) div 2);


if its not, do as i said above

Obquility

2014-12-17 03:39:56

From: GRIM
copy+paste line 145


Lel, can't you have a look ;)
function TBox.getMiddle(): TPoint;
begin
result := point((self.x2 + self.x1) div 2, (self.y2 + self.y1) div 2);
end;

Line 135 is where the result := is

EDIT: Use simba code, not normal code ;)
~Josh

akarigar

2014-12-17 05:50:03

What SRL version are you using? I can't seem to reproduce your error on version 1030. Plus, the code for getMiddle looks fine. Sounds like a problem with your code. Can you show us where you use getMiddle?

Obquility

2014-12-17 23:37:47

From: akarigar
What SRL version are you using? I can't seem to reproduce your error on version 1030. Plus, the code for getMiddle looks fine. Sounds like a problem with your code. Can you show us where you use getMiddle?


It was fixed with a new SRL update. Some people messed up banking/ inventory functions