Documentation
¶
Index ¶
- Constants
- Variables
- func BuffListView(buffs any) *furex.View
- func BuffView(buff *model.Buff) *furex.View
- func CheckBoxView(size int, multiple bool, value *bool, label string, clickHandler func(bool)) *furex.View
- func CommandView() *furex.View
- func CreateEnemyBarView(i int, enemy *donburi.Entry) *furex.View
- func DamageHistoryHeaderView() *furex.View
- func DamageHistoryItemView(damage model.DamageTaken) *furex.View
- func DamageHistoryView() *furex.View
- func DrawText(screen *ebiten.Image, content string, fontSize float64, x, y float64, ...)
- func EnemyBarsView() *furex.View
- func HotBarView(w, h int) *furex.View
- func HotbarItemView(item *HotBarItemConfig) *furex.View
- func InitializeFont()
- func InputView(prefix string, minWidth int, commitHandler func(string)) *furex.View
- func NewPartyList(players []*donburi.Entry) *furex.View
- func NewPlayerItem(playerEntry *donburi.Entry) *furex.View
- func ProgressBarView() *furex.View
- type Bar
- func (b *Bar) Draw(screen *ebiten.Image, frame image.Rectangle, view *furex.View)
- func (b *Bar) HandleJustPressedMouseButtonLeft(frame image.Rectangle, x, y int) bool
- func (b *Bar) HandleJustReleasedMouseButtonLeft(frame image.Rectangle, x, y int)
- func (b *Bar) HandleMouseEnter(x, y int) bool
- func (b *Bar) HandleMouseLeave()
- func (b *Bar) Handler() furex.ViewHandler
- type BuffListHandler
- type CheckBoxHandler
- type CommandHandler
- type FFUI
- type Focusable
- type HotBarItemConfig
- type InputHandler
- func (i *InputHandler) Content() string
- func (i *InputHandler) HandleJustPressedMouseButtonLeft(frame image.Rectangle, x int, y int) bool
- func (i *InputHandler) HandleJustReleasedMouseButtonLeft(frame image.Rectangle, x int, y int)
- func (i *InputHandler) HandleMouseEnter(x int, y int) bool
- func (i *InputHandler) HandleMouseLeave()
- func (i *InputHandler) Handler() furex.ViewHandler
- func (i *InputHandler) SetFocus(b bool)
- func (i *InputHandler) Update(v *furex.View)
- type LimitBreak
- type PlayerCommand
- type PlayerItem
- func (p *PlayerItem) HandleJustPressedMouseButtonLeft(_ image.Rectangle, x, y int) bool
- func (p *PlayerItem) HandleJustReleasedMouseButtonLeft(_ image.Rectangle, x, y int)
- func (p *PlayerItem) HandleMouseEnter(x, y int) bool
- func (p *PlayerItem) HandleMouseLeave()
- func (p *PlayerItem) Handler() furex.ViewHandler
- func (p *PlayerItem) Update(v *furex.View)
- type PlaygroundUI
- type ShadowOpt
- type Sprite
- type Text
- type UI
Constants ¶
View Source
const ( BuffWidth = 24 BuffHeight = 32 BuffStackFontSize = 13 BuffStackTop = 2 BuffStackLeft = 9 BuffStackShadow = 4 BuffRemainTop = -6 BuffRemainFontSize = 12 )
View Source
const ( InputHeight = 28 InputTextTop = 8 InputTextLeft = 6 InputTextHeight = 12 )
View Source
const ( SingleBarMaxValue = 10000 SingleBarWidth = 150 SingleBarHeight = 13 SingleBarPadding = 13 )
View Source
const ( PartyListWidth = 300 PartyListBGExtra = 20 )
View Source
const ( PlayerItemHeight = 48 StatusPartWidth = 210 JobIconSize = 38 HoverSpriteWidth = 275 HoverSpriteHeight = 40 HoverSpriteTop = 10 HoverSpriteLeft = 30 CastNameTextSize = 12 NameTextSize = 13 HMPTextSize = 14 CastBarWidth = 100 BarHeight = 12 HPBarWidth = 125 MPBarWidth = 75 HMPBarHeight = 8 BuffListOffsetY = 20 )
View Source
const ( UIHalf = 0.5 UIPadding = 20 )
Variables ¶
View Source
var ( ResultColor = color.NRGBA{24, 169, 248, 128} PromptColor = color.NRGBA{255, 255, 255, 128} ErrorColor = color.NRGBA{255, 0, 0, 128} )
View Source
var PartyListBGNineSliceConfig = [4]int{5, 14, 0, 0}
Functions ¶
func BuffListView ¶
BuffListView is a view for displaying a list of buffs. You can provide a model.BuffList to update buffs dynamically, or just a list of model.Buff to display static buffs.
func CheckBoxView ¶
func CommandView ¶
func DamageHistoryHeaderView ¶
func DamageHistoryItemView ¶
func DamageHistoryItemView(damage model.DamageTaken) *furex.View
func DamageHistoryView ¶
func EnemyBarsView ¶
func HotBarView ¶
func HotbarItemView ¶
func HotbarItemView(item *HotBarItemConfig) *furex.View
func InitializeFont ¶
func InitializeFont()
func ProgressBarView ¶
Types ¶
type Bar ¶
type Bar struct {
Progress any
BG *texture.NineSlice
FG *texture.NineSlice
Segments []float64
Interactable bool
ClickAt func(c float64, p float64)
// contains filtered or unexported fields
}
func (*Bar) HandleJustPressedMouseButtonLeft ¶
func (*Bar) HandleJustReleasedMouseButtonLeft ¶
func (*Bar) HandleMouseEnter ¶
func (*Bar) HandleMouseLeave ¶
func (b *Bar) HandleMouseLeave()
func (*Bar) Handler ¶
func (b *Bar) Handler() furex.ViewHandler
type BuffListHandler ¶
func (*BuffListHandler) Handler ¶
func (bl *BuffListHandler) Handler() furex.ViewHandler
type CheckBoxHandler ¶
type CheckBoxHandler struct {
Size int
Checked *bool
ClickHandler func(bool)
// contains filtered or unexported fields
}
func (*CheckBoxHandler) HandleJustPressedMouseButtonLeft ¶
func (c *CheckBoxHandler) HandleJustPressedMouseButtonLeft(frame image.Rectangle, x, y int) bool
func (*CheckBoxHandler) HandleJustReleasedMouseButtonLeft ¶
func (c *CheckBoxHandler) HandleJustReleasedMouseButtonLeft(frame image.Rectangle, x, y int)
func (*CheckBoxHandler) Handler ¶
func (c *CheckBoxHandler) Handler() furex.ViewHandler
func (*CheckBoxHandler) Update ¶
func (c *CheckBoxHandler) Update(v *furex.View)
type CommandHandler ¶
type CommandHandler struct {
// contains filtered or unexported fields
}
func (*CommandHandler) AddEcho ¶
func (c *CommandHandler) AddEcho(cmd string)
func (*CommandHandler) AddError ¶
func (c *CommandHandler) AddError(err string)
func (*CommandHandler) AddPrompt ¶
func (c *CommandHandler) AddPrompt(prompt string)
func (*CommandHandler) AddResult ¶
func (c *CommandHandler) AddResult(result string)
func (*CommandHandler) CommitCommand ¶
func (c *CommandHandler) CommitCommand(cmd string)
func (*CommandHandler) Execute ¶
func (c *CommandHandler) Execute(cmd string)
type HotBarItemConfig ¶
type InputHandler ¶
type InputHandler struct {
View *furex.View
MinWidth int
CommitHandler func(string)
// contains filtered or unexported fields
}
func (*InputHandler) Content ¶
func (i *InputHandler) Content() string
func (*InputHandler) HandleJustPressedMouseButtonLeft ¶
HandleJustPressedMouseButtonLeft implements furex.MouseLeftButtonHandler.
func (*InputHandler) HandleJustReleasedMouseButtonLeft ¶
func (i *InputHandler) HandleJustReleasedMouseButtonLeft(frame image.Rectangle, x int, y int)
HandleJustReleasedMouseButtonLeft implements furex.MouseLeftButtonHandler.
func (*InputHandler) HandleMouseEnter ¶
func (i *InputHandler) HandleMouseEnter(x int, y int) bool
HandleMouseEnter implements furex.MouseEnterLeaveHandler.
func (*InputHandler) HandleMouseLeave ¶
func (i *InputHandler) HandleMouseLeave()
HandleMouseLeave implements furex.MouseEnterLeaveHandler.
func (*InputHandler) Handler ¶
func (i *InputHandler) Handler() furex.ViewHandler
func (*InputHandler) SetFocus ¶
func (i *InputHandler) SetFocus(b bool)
SetFocus implements Focusable.
func (*InputHandler) Update ¶
func (i *InputHandler) Update(v *furex.View)
type LimitBreak ¶
func (*LimitBreak) Handler ¶
func (l *LimitBreak) Handler() furex.ViewHandler
func (*LimitBreak) RenderLimitbreakSingleBar ¶
func (l *LimitBreak) RenderLimitbreakSingleBar(canvas *ebiten.Image, x, y float64, value int)
type PlayerCommand ¶
type PlayerCommand struct {
// contains filtered or unexported fields
}
type PlayerItem ¶
type PlayerItem struct {
Player *donburi.Entry
Hovered bool
Selected bool
// contains filtered or unexported fields
}
func (*PlayerItem) HandleJustPressedMouseButtonLeft ¶
func (p *PlayerItem) HandleJustPressedMouseButtonLeft(_ image.Rectangle, x, y int) bool
func (*PlayerItem) HandleJustReleasedMouseButtonLeft ¶
func (p *PlayerItem) HandleJustReleasedMouseButtonLeft(_ image.Rectangle, x, y int)
func (*PlayerItem) HandleMouseEnter ¶
func (p *PlayerItem) HandleMouseEnter(x, y int) bool
func (*PlayerItem) HandleMouseLeave ¶
func (p *PlayerItem) HandleMouseLeave()
func (*PlayerItem) Handler ¶
func (p *PlayerItem) Handler() furex.ViewHandler
func (*PlayerItem) Update ¶
func (p *PlayerItem) Update(v *furex.View)
type PlaygroundUI ¶
type PlaygroundUI struct {
// contains filtered or unexported fields
}
func NewPlaygroundUI ¶
func NewPlaygroundUI(ecs *ecs.ECS) *PlaygroundUI
func (*PlaygroundUI) Draw ¶
func (p *PlaygroundUI) Draw(screen *ebiten.Image)
func (*PlaygroundUI) SetupHotBar ¶
func (p *PlaygroundUI) SetupHotBar(v *furex.View, w, h int)
func (*PlaygroundUI) Update ¶
func (p *PlaygroundUI) Update(w, h int)
type Sprite ¶
type Sprite struct {
NineSliceTexture *texture.NineSlice
Texture *ebiten.Image
BlendAlpha bool
Alpha float32
// contains filtered or unexported fields
}
func (*Sprite) Handler ¶
func (s *Sprite) Handler() furex.ViewHandler
Click to show internal directories.
Click to hide internal directories.