SRL Archive - SRL Bugs

Ability Bar bugs


footballjds

2012-12-04 11:59:58

When the adrenaline bar is full IsActionBarOpen returns false.
GetAdrenalinePercent returns 100 before the adrenaline bar is full.

J J

2012-12-04 12:10:59

GetAdrenalinPercent returned -1 when it was full. Colors change slightly.

footballjds

2012-12-04 12:19:38

From: J J
GetAdrenalinPercent returned -1 when it was full. Colors change slightly.


The reason for that is because it returns -1 if action bar isn't open. see the code below and you'll realize why:
function GetAdrenalinePercent(): Integer;
var
BarX1,BarX2,BarY1,BarY2 : Integer;
tpa : TPointArray;
box : TBox;
begin
Result := -1;
if isActionBarOpen then
begin
Result := 100;
BarY1 := 334 - SRL_NAVBAR_INGAME_Y;
BarY2 := 337- SRL_NAVBAR_INGAME_Y;
BarX1 := 49;
BarX2 := 469;
if FindColorsTolerance(tpa,1776411,BarX1,BarY1,BarX2,BarY2,15) then
begin
box := GetTPABounds(tpa);
Result := Floor(100 - ((BarX2 - box.X1)*1.0 / (BarX2-BarX1) * 1.0) * 100);
end;
end;
end;
The check to see if the action bar is open will return false if adrenaline is full. Put a writeln in the function in gametab like so:
function IsActionBarOpen(): Boolean;
begin
Result := ((GetColor(45, 283) = 2697663) or (GetColor(473, 283) = 2697663));
writeln('Action Bar open: '+ToStr(Result));
end;
and you'll see what I mean.

GetAdrenalinePercent returns 100 when the adrenaline is almost 100% but not quite.

footballjds

2012-12-04 13:06:14

Ummm, aside from getting a pos software called git how else can I contribute to the include? I want to fix issues fast. I understand maybe no one cares if these functions got put in an include and they're not working but i dooo.

Gu3st...

2012-12-04 13:37:42

Why not use git? Everyone uses it and it's what we know how to handle. It's of course possible to just send the files to a dev if you don't want to or have the possibilities install anything.

Le Jingle

2012-12-04 13:39:19

short version: Make Git acc, fork SRL/SRL5, edit the file in yourGitName/SRL5, then try to merge with original SRL/SRL5. May take some time, depends.

footballjds

2012-12-04 13:40:26

From: Zyt3x
Why not use git? Everyone uses it and it's what we know how to handle. It's of course possible to just send the files to a dev if you don't want to or have the possibilities install anything.


Grrr, I don't like git. maybe I'll break down and start using it.

But I really want to know why these got put in the include without due testing? I mean I doubt they broke in a few days…

sorry guys I'm having a ****y day and nothing is seeming to work for me. creating my waterfiend script is so ****ing frustrating.

From: Le Jingle
short version: Make Git acc, fork SRL/SRL5, edit the file in yourGitName/SRL5, then try to merge with original SRL/SRL5. May take some time, depends.


Thank you le jingle, :)