PDA

View Full Version : Uptext fix



Awkwardsaw
08-08-2013, 01:07 AM
Simply copy and replace this function:
Function P07_GetUpText: String;
Var
WhiteT,BlueT,YellowT,OrangeT,FoundText: String;
Begin
WhiteT:=GetTextAtExWrap(8, 8, 80, 21, 0, 5, 1, 14541281, 55, 'UpChars07');
BlueT:=GetTextAtExWrap(35, 8, 210, 21, 0, 5, 1, 13423640, 65, 'UpChars07'); //line that changed
YellowT:=GetTextAtExWrap(35, 8, 150, 21, 0, 5, 1, 1235160, 40, 'UpChars07');
OrangeT:=GetTextAtExWrap(35, 8, 150, 21, 0, 5, 1, 4687583, 53, 'UpChars07');
FoundText:=WhiteT + ' ' + BlueT + YellowT + OrangeT;
FoundText:= ReplaceWrap(FoundText, '.', '',[rfReplaceAll]);
FoundText:= ReplaceWrap(FoundText, '/', '',[rfReplaceAll]);
FoundText:= ReplaceWrap(FoundText, '\', '',[rfReplaceAll]);
FoundText:= ReplaceWrap(FoundText, ',', '',[rfReplaceAll]);
FoundText:= ReplaceWrap(FoundText, '*', '',[rfReplaceAll]);
FoundText:= ReplaceWrap(FoundText, '^', '',[rfReplaceAll]);
FoundText:= ReplaceWrap(FoundText, '"', '',[rfReplaceAll]);
Result:=FoundText;
End;

Basically all I did was make the box bigger, so it could find all of the uptext. The old box wasn't even close to finding the blue text I needed ;)

Flight
08-08-2013, 01:15 AM
Have you seen this thread?:
http://villavu.com/forum/showthread.php?t=103865

Even in that order of the default uptext grabbing (WhiteT + ' ' + BlueT + YellowT + OrangeT) it's not complete. In the instance you were to use an item on an player/NPC/object a section of your text would never be seen simply because of that restrictive ordering. If you take a look at the thread I mentioned before you'll see there's no need for that at all, instead make a TPA of every bit of text printed at the top, combine all of the TPAs and let that handy little "GetTextATPA" do the rest of the work.

Awkwardsaw
08-08-2013, 01:30 AM
Have you seen this thread?:
http://villavu.com/forum/showthread.php?t=103865

Even in that order of the default uptext grabbing (WhiteT + ' ' + BlueT + YellowT + OrangeT) it's not complete. In the instance you were to use an item on an player/NPC/object a section of your text would never be seen simply because of that restrictive ordering. If you take a look at the thread I mentioned before you'll see there's no need for that at all, instead make a TPA of every bit of text printed at the top, combine all of the TPAs and let that handy little "GetTextATPA" do the rest of the work.

well then y u no add it to include? :p

DannyRS
08-08-2013, 05:30 PM
This will haunt me till the day I die ^^


Eh, uptext should be alot better when simba 994 gets released, since we can actually use simba's uptext finding.

are we still not there?

Olly
08-08-2013, 07:20 PM
No, iirc we will all move to 1000 soon. :)

Naveed123
09-05-2013, 11:43 AM
Should be sustained by the administraitor and am:norris:

samerdl
09-10-2013, 12:45 PM
needs to add..

GreenT := GetTextAtExWrap(8, 8, 400, 21, 0, 5, 1, 120577, 65, 'UpChars07');


The green text is when you have a spell ready to be Cast, 'Curse' will be green. :)