mirror of
https://github.com/moparisthebest/Simba
synced 2024-11-25 02:32:19 -05:00
Merge ssh://villavu.com:54367/simba
This commit is contained in:
commit
21286973fd
@ -361,7 +361,7 @@ begin
|
||||
Includes.Add(path);
|
||||
|
||||
try
|
||||
f:= TFileStream.Create(UTF8ToSys(Path), fmOpenRead or fmShareDenyWrite);
|
||||
f:= TFileStream.Create(UTF8ToSys(Path), fmOpenRead);
|
||||
SetLength(contents, f.Size);
|
||||
f.Read(contents[1], Length(contents));
|
||||
result:= true;
|
||||
|
@ -75,8 +75,8 @@ var
|
||||
angle : extended;
|
||||
begin
|
||||
angle := ArcTan2(pt.y-my,pt.x-mx);
|
||||
result.y := round(sin(angle) * newdist) + mx;
|
||||
result.x := round(cos(angle) * newdist) + my;
|
||||
result.x := round(cos(angle) * newdist) + mx;
|
||||
result.y := round(sin(angle) * newdist) + my;
|
||||
end;
|
||||
|
||||
function ChangeDistTPA(var TPA : TPointArray; mx,my : integer; newdist : extended) : boolean;
|
||||
@ -92,8 +92,8 @@ begin
|
||||
for i := high(TPA) downto 0 do
|
||||
begin
|
||||
angle := ArcTan2(TPA[i].y-my,TPA[i].x-mx);
|
||||
TPA[i].y := round(sin(angle) * newdist) + mx;
|
||||
TPA[i].x := round(cos(angle) * newdist) + my;
|
||||
TPA[i].x := round(cos(angle) * newdist) + mx;
|
||||
TPA[i].y := round(sin(angle) * newdist) + my;
|
||||
end;
|
||||
except
|
||||
result := false;
|
||||
|
Loading…
Reference in New Issue
Block a user