some refinement and beginning of a table element
This commit is contained in:
@@ -3,14 +3,16 @@ package blocks
|
||||
import (
|
||||
"image/color"
|
||||
|
||||
"git.vezzani.net/ben/games/common/elements/v1"
|
||||
"git.vezzani.net/ben/games/common/elements/v1/core"
|
||||
)
|
||||
|
||||
type OptFunc func(*Block)
|
||||
|
||||
func Core(f elements.OptFunc) OptFunc {
|
||||
func Core(fs ...core.OptFunc) OptFunc {
|
||||
return func(b *Block) {
|
||||
f(&b.Core)
|
||||
for _, f := range fs {
|
||||
f(&b.Element)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user