Documentation
¶
Index ¶
- Constants
- Variables
- func GetAtlasRoundTex(name string) graph.Tex
- func GetAtlasTex(name string) graph.Tex
- func GetSlidingAtlasTex(name string) graph.Tex
- func InitFonts()
- func InitTexAtlas()
- func LowQualityCosmoPoint(v bool)
- func MarkAlpha(size float64, cam *graph.Camera) (alphaMark, alphaSprite float64)
- func MarkScaleLevel(level int) float64
- func NewAtlasFrame9HUD(atlasName string, w, h int, layer int) *graph.Frame9HUD
- func NewAtlasRoundSprite(atlasName string, params graph.CamParams) *graph.Sprite
- func NewAtlasSprite(atlasName string, params graph.CamParams) *graph.Sprite
- func NewAtlasSpriteHUD(atlasName string) *graph.Sprite
- func SignatureAttrF(sig commons.Signature, fstr string, koefName string) (res flow.AttrF)
- func SignatureVelSpawn(sig commons.Signature) (VelocityF func(pos v2.V2) v2.V2, SpawnPos func() (pos v2.V2))
- type AnnounceText
- type ButtonOpts
- type ButtonsPanel
- func (bp *ButtonsPanel) AddButton(opts ButtonOpts)
- func (bp *ButtonsPanel) ClearButtons()
- func (bp *ButtonsPanel) Disable()
- func (bp *ButtonsPanel) Enable()
- func (bp *ButtonsPanel) Highlight(tagPrefix string)
- func (bp *ButtonsPanel) ProcMouse(x, y int) (tags string, ok bool)
- func (bp *ButtonsPanel) Req(Q *graph.DrawQueue)
- func (bp *ButtonsPanel) SetActive(active bool)
- func (bp *ButtonsPanel) Update(dt float64)
- type ButtonsPanelOpts
- type CosmoPoint
- func (cp *CosmoPoint) GetCaption() string
- func (cp *CosmoPoint) GetCaptionTop() string
- func (cp *CosmoPoint) Req(Q *graph.DrawQueue)
- func (cp *CosmoPoint) SetCaption(caption string, clr color.Color)
- func (cp *CosmoPoint) SetCaptionTop(caption string, clr color.Color)
- func (cp *CosmoPoint) Update(dt float64)
- type GravityPredictorSource
- type OtherShip
- type SignaturePack
- type SlidingSphere
- type SonarHUD
- type TexAtlas
- type TexAtlasRec
- type TextInput
- type TrackPredictor
- type TrackPredictorOpts
- type WarpPredictor
- type WarpPredictorOpts
- type WayPoint
Constants ¶
View Source
const ( Face_cap = "caption" Face_stats = "stats" Face_list = "list" Face_mono = "mono" )
View Source
const (
Mark_size = 50
)
Variables ¶
View Source
var Fonts map[string]font.Face
Functions ¶
func GetAtlasRoundTex ¶
func GetAtlasTex ¶
return tex. if can't find return default tex panic on error
func GetSlidingAtlasTex ¶
func InitTexAtlas ¶
func InitTexAtlas()
func LowQualityCosmoPoint ¶
func LowQualityCosmoPoint(v bool)
must be set once before creating CosmoPoints
func MarkScaleLevel ¶
func NewAtlasFrame9HUD ¶
func NewAtlasRoundSprite ¶
func NewAtlasSpriteHUD ¶
func SignatureAttrF ¶
Types ¶
type AnnounceText ¶
type AnnounceText struct {
// contains filtered or unexported fields
}
func NewAnnounceText ¶
func (*AnnounceText) AddMsg ¶
func (at *AnnounceText) AddMsg(msg string, clr color.Color, dur float64)
func (*AnnounceText) Req ¶
func (at *AnnounceText) Req(Q *graph.DrawQueue)
func (*AnnounceText) Update ¶
func (at *AnnounceText) Update(dt float64)
type ButtonOpts ¶
type ButtonsPanel ¶
type ButtonsPanel struct {
// contains filtered or unexported fields
}
func NewButtonsPanel ¶
func NewButtonsPanel(opts ButtonsPanelOpts) *ButtonsPanel
func (*ButtonsPanel) AddButton ¶
func (bp *ButtonsPanel) AddButton(opts ButtonOpts)
func (*ButtonsPanel) ClearButtons ¶
func (bp *ButtonsPanel) ClearButtons()
remove old buttons and create new
func (*ButtonsPanel) Disable ¶
func (bp *ButtonsPanel) Disable()
func (*ButtonsPanel) Enable ¶
func (bp *ButtonsPanel) Enable()
func (*ButtonsPanel) Highlight ¶
func (bp *ButtonsPanel) Highlight(tagPrefix string)
func (*ButtonsPanel) Req ¶
func (bp *ButtonsPanel) Req(Q *graph.DrawQueue)
func (*ButtonsPanel) SetActive ¶
func (bp *ButtonsPanel) SetActive(active bool)
func (*ButtonsPanel) Update ¶
func (bp *ButtonsPanel) Update(dt float64)
type ButtonsPanelOpts ¶
type CosmoPoint ¶
type CosmoPoint struct { MarkGlowSprite *graph.Sprite MarkSprite *graph.CycledSprite //static sprite for lowQ SimpleSprite *graph.Sprite //for not-so-lowQ //we use sliding or cycling depends on Type SlidingSphere *SlidingSphere CycledSprite *graph.CycledSprite //warpRanges WarpInner *graph.Sprite WarpOuter *graph.Sprite WarpGreen *graph.WavedCircle WarpSize float64 ID string Pos v2.V2 Size float64 Type string EmiDist *graph.CircleLine // contains filtered or unexported fields }
func NewCosmoPoint ¶
func NewCosmoPoint(pd *GalaxyPoint, params graph.CamParams) *CosmoPoint
func (*CosmoPoint) GetCaption ¶
func (cp *CosmoPoint) GetCaption() string
func (*CosmoPoint) GetCaptionTop ¶
func (cp *CosmoPoint) GetCaptionTop() string
func (*CosmoPoint) Req ¶
func (cp *CosmoPoint) Req(Q *graph.DrawQueue)
func (*CosmoPoint) SetCaption ¶
func (cp *CosmoPoint) SetCaption(caption string, clr color.Color)
func (*CosmoPoint) SetCaptionTop ¶
func (cp *CosmoPoint) SetCaptionTop(caption string, clr color.Color)
func (*CosmoPoint) Update ¶
func (cp *CosmoPoint) Update(dt float64)
type GravityPredictorSource ¶
type GravityPredictorSource struct {
// contains filtered or unexported fields
}
func NewGravityPredictorSource ¶
func NewGravityPredictorSource(galaxy *Galaxy, gravDt float64, garantLen int) *GravityPredictorSource
type OtherShip ¶
type OtherShip struct {
// contains filtered or unexported fields
}
func NewOtherShip ¶
type SignaturePack ¶
type SignaturePack struct {
// contains filtered or unexported fields
}
func NewSignaturePack ¶
func NewSignaturePack(camParams graph.CamParams, baseLayer int) *SignaturePack
func (*SignaturePack) ActiveSignatures ¶
func (sp *SignaturePack) ActiveSignatures(sigs []Signature)
func (*SignaturePack) Req ¶
func (sp *SignaturePack) Req(Q *graph.DrawQueue)
func (*SignaturePack) Update ¶
func (sp *SignaturePack) Update(dt float64)
type SlidingSphere ¶
func NewAtlasSlidingSphere ¶
func NewAtlasSlidingSphere(atlasName string, params graph.CamParams, periodS float64) *SlidingSphere
func (*SlidingSphere) AddSlide ¶
func (ss *SlidingSphere) AddSlide(deltaSlide float64)
func (*SlidingSphere) SetSlide ¶
func (ss *SlidingSphere) SetSlide(slide float64)
func (*SlidingSphere) Update ¶
func (ss *SlidingSphere) Update(dt float64)
type SonarHUD ¶
type SonarHUD struct { *SignaturePack // contains filtered or unexported fields }
func NewSonarHUD ¶
type TexAtlas ¶
type TexAtlas map[string]TexAtlasRec
type TextInput ¶
type TextInput struct {
// contains filtered or unexported fields
}
func NewTextInput ¶
type TrackPredictor ¶
type TrackPredictor struct {
// contains filtered or unexported fields
}
func NewTrackPredictor ¶
func NewTrackPredictor(opts TrackPredictorOpts) *TrackPredictor
func (*TrackPredictor) Req ¶
func (tp *TrackPredictor) Req(Q *graph.DrawQueue)
func (*TrackPredictor) SetAccelSessionTimeShipPos ¶
func (tp *TrackPredictor) SetAccelSessionTimeShipPos(accel v2.V2, sessionTime float64, ship RBData)
type TrackPredictorOpts ¶
type WarpPredictor ¶
type WarpPredictor struct {
// contains filtered or unexported fields
}
func NewWarpPredictor ¶
func NewWarpPredictor(opts WarpPredictorOpts) *WarpPredictor
func (*WarpPredictor) Req ¶
func (wp *WarpPredictor) Req(Q *graph.DrawQueue)
func (*WarpPredictor) SetPosDistDir ¶
func (wp *WarpPredictor) SetPosDistDir(shipPos v2.V2, distortion, dir float64)
type WarpPredictorOpts ¶
type WayPoint ¶
type WayPoint struct {
// contains filtered or unexported fields
}
func (*WayPoint) SetShipPoint ¶
Source Files
¶
Click to show internal directories.
Click to hide internal directories.