Documentation ¶
Index ¶
- type Point
- type Radar
- func (r *Radar) AddPoint(loc Point, c color.Color)
- func (r *Radar) AddTrackedPoint(loc Point, id int, c color.Color)
- func (r *Radar) Draw(buff draw.Image, xOff, yOff float64)
- func (r *Radar) GetRGBA() *image.RGBA
- func (r *Radar) LookupPoint(id int) (*Point, bool)
- func (r *Radar) RemovePointByLookup(id int) error
- func (r *Radar) SetOutline(outline *render.Sprite)
- func (r *Radar) SetPos(x, y float64)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Radar ¶
type Radar struct { render.LayeredPoint sync.Mutex // contains filtered or unexported fields }
Radar displays points of interest on a radar map
func NewRadar ¶
NewRadar creates a radar that will display at 0,0 with the given dimensions. The points given will be displayed on the radar relative to the center point, With the absolute distance reduced by the given ratio
func (*Radar) AddTrackedPoint ¶
AddTrackedPoint to the radar. Enables display and later lookup by id (usually the CID of the caller).
func (*Radar) LookupPoint ¶
LookupPoint by the provided id. This only works if the point was tracked on creation.
func (*Radar) RemovePointByLookup ¶
RemovePointByLookup removes a point if it is present. If it is not, it does nothing.
func (*Radar) SetOutline ¶
SetOutline of the radar to be the provided outline
Click to show internal directories.
Click to hide internal directories.