DotFilters¶
Methods to handle DotFilters. Dot filters are filters that filter in or out ERSDots.
type TRSDotFilter¶
TRSDotFilter = record
Bounds: TPointArray;
Circle: TCircle;
Inside: Boolean;
Timeout: Boolean;
Timer: TCountDown;
end;
Type used to filter minimap dots.
TRSDotFilter.Create¶
function TRSDotFilter.Create(const bounds: TPolygon; const circle: TCircle; inside: Boolean; time: Integer = -1): TRSDotFilter; static;
Static method to create a TRSDotFilter.
TRSDotFilter.IsExpired¶
function TRSDotFilter.IsExpired(): Boolean;
Checks if a TRSDotFilter is already expired by checking it’s timer.
TRSDotFilter.IsValid¶
function TRSDotFilter.IsValid(const pt: TPoint): Boolean;
Checks if pt is valid accordint to the current TRSDotFilter;
type TRSDotFilterArray¶
Type used to manage and interact with arrays of TRSDotFilters.
TRSDotFilterArray.Setup¶
procedure TRSDotFilterArray.Setup(const bounds: TPolygon; const circle: TCircle; inside: Boolean; time: Integer = -1);
procedure TRSDotFilterArray.SetupBounds(const bounds: TPolygon; inside: Boolean; time: Integer = -1);
procedure TRSDotFilterArray.SetupCircle(const circle: TCircle; inside: Boolean; time: Integer = -1);
Creates and adds a TRSDotFilter to the current TRSDotFilterArray.
TRSDotFilterArray.ClearExpired¶
procedure TRSDotFilterArray.ClearExpired();
Clears expired TRSDotFilter from the current TRSDotFilterArray. You usually don’t need to call this directly, but you can if you want. Other methods already take care of this by default for you regardless.
TRSDotFilterArray.IsValid¶
function TRSDotFilterArray.IsValid(const pt: TPoint; clearExpired: Boolean = True): Boolean;
Checks if a pt is valid in any of the TRSDotFilters in the current array.
By default, expired TRSDotFilters are cleared from the array while this runs.
TRSDotFilterArray.FilterDots¶
function TRSDotFilterArray.FilterDots(dots: TPointArray; clearExpired: Boolean): TPointArray;
Filter the dots/points passed into this according to our current TRSDotFilters.
TRSMinimap.GetFilteredDot¶
function TRSMinimap.GetFilteredDotArray(dots: ERSDots; dotFilters: TRSDotFilterArray; clearExpired: Boolean): TPointArray;
function TRSMinimap.GetFilteredDot(dots: ERSDots; dotFilters: TRSDotFilterArray; clearExpired: Boolean): TPoint;
Retrieves and filters minimap dots according to the specified TRSDotFilters.