blob: fc0c2de1aaf1cf625d821428ded394aefea11162 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
package descriptors
import ui "github.com/DegustatorPonos/RuinesOfRafdolon/UI"
type MenuDescriptor struct {
PaddingX float32
PaddingY float32
Contents UIElementDescriptor
}
func (base *MenuDescriptor) Parse() (*ui.Menu, error) {
var contents, contentsErr = base.Contents.Parse()
if contentsErr != nil {
return nil, contentsErr
}
return &ui.Menu {
PaddingX: base.PaddingX,
PaddingY: base.PaddingY,
Contents: contents,
}, nil
}
|