pointer fixes for kcontext and settings

This commit is contained in:
2023-07-05 22:05:48 +02:00
parent 5425e0036b
commit 5e4f63aecc
7 changed files with 33 additions and 33 deletions

View File

@@ -5,17 +5,6 @@ import (
"github.com/hajimehoshi/ebiten/text"
)
func (e *Engine) DialogDraw(screen *ebiten.Image) {
dialog := e.Domain.GetDialog(e.KContext.ScreenValue)
face := GetFontFace(dialog.Layout.ChoiceFont)
for i, choice := range dialog.Choices {
offset := int(dialog.Layout.ChoiceFont.Size) * (i + 1)
text.Draw(screen, choice.Label+"\n", face, 8, offset, dialog.GetChoiceColor(i))
}
}
func (e *Engine) DialogUpdate() {
dialog := e.Domain.GetDialog(e.KContext.ScreenValue)
@@ -32,3 +21,14 @@ func (e *Engine) DialogUpdate() {
}
e.Domain.SetDialog(e.KContext.ScreenValue, dialog)
}
func (e *Engine) DialogDraw(screen *ebiten.Image) {
dialog := e.Domain.GetDialog(e.KContext.ScreenValue)
face := GetFontFace(dialog.Layout.ChoiceFont)
for i, choice := range dialog.Choices {
offset := int(dialog.Layout.ChoiceFont.Size) * (i + 1)
text.Draw(screen, choice.Label+"\n", face, 8, offset, dialog.GetChoiceColor(i))
}
}