23 lines
314 B
Go
23 lines
314 B
Go
package command
|
|
|
|
// List of keys supported by all entities
|
|
const (
|
|
MOVE_X int = iota
|
|
MOVE_Y
|
|
SET_SPEED
|
|
SET_POSITION
|
|
SET_ANIMATION
|
|
)
|
|
|
|
type EntityCommand struct {
|
|
key int
|
|
value float64
|
|
}
|
|
|
|
func NewEntityCommand(key int, value float64) EntityCommand {
|
|
return EntityCommand{
|
|
key: key,
|
|
value: value,
|
|
}
|
|
}
|