SRL Archive - OSR Help

GetTextAtExWrap Spacing


pitoms

2012-07-05 19:30:44

EDIT: In http://docs.wizzup.org/simba/scriptref/ocr.html#rs-setuptextfilter, how would I use a modified uptext filter? Like do I save it as a .pas file and put it in the same dir? How do I pass a modified uptext filter to rs_SetUpTextFilter?
EDIT 2: NVM. rs_GetUpTextAtEx(7,7,false); seems to work perfectly.

I'm trying to use simba for a private server and I'm trying to figure out a way to get uptext. Right now, I'm thinking of using GetTextAtExWrap to do this but I'm having some trouble with it.

function GetTextAtEx(const xs,ys,xe,ye, minvspacing, maxvspacing, hspacing,color, tol: integer;const font: string): string;

1) What exactly do the spacings represent?
2) I have

Writeln(GetTextAtExWrap(4,5,220,22,0,1,2,14475230,30,UpChars));

but it produces "U s e / 2 m o r e o p t i o n s"
How do I get rid of the unnecessary spacing and is there a way to allow other colors to be part of the OCR other than using GetTextAtExWrap twice? (It's supposed to be Use pot)

Wizzup?

2012-07-06 09:36:09

Did you have a look at http://docs.wizzup.org/simba/scriptref/ocr.html#gettextatex ?

pitoms

2012-07-06 11:14:48

Ok thanks. I fixed that problem now but now I just have to tweak the colors and tolerances.

I think that it might be better to use rs_GetUpText rather than do this. Right now I have
Writeln(GetTextAtExWrap(4,5,220,22,0,5,0,13817301,60,UpChars));
Writeln(GetUpText);
but the debug box results in
W.,thdraw 1 . / 5 more opt.,r
^^^^^^^^ ^ ^^^^^ ^ ^ ^^^^ ^^^^^^^

Would anyone know how I could fix the ^^^s? I clearly have a close enough font since GetTextAtExWrap sorta works.

edit: After looking at the docs, I think it might have something to do with the textfilters. Is there a way I can easily "update" the colors for whatever text filters rs_getuptext uses?
EDIT 2: In http://docs.wizzup.org/simba/scriptref/ocr.html#rs-setuptextfilter, how would I use a modified uptext filter? Like do I save it as a .pas file and put it in the same dir? How do I pass a modified uptext filter to rs_SetUpTextFilter?