1
0
Fork 0
mirror of https://github.com/Luzifer/sii.git synced 2024-10-18 05:14:19 +00:00
sii/block_police_ctrl.go
Knut Ahlers a26d79eefb
Add new blocks
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2019-12-11 18:24:35 +01:00

21 lines
440 B
Go

package sii
func init() {
RegisterBlock(&PoliceCtrl{})
}
type PoliceCtrl struct {
OffenceTimer []float32 `sii:"offence_timer"`
OffenceCounter []int64 `sii:"offence_counter"`
OffenceValid []bool `sii:"offence_valid"`
blockName string
}
func (PoliceCtrl) Class() string { return "police_ctrl" }
func (p *PoliceCtrl) Init(class, name string) {
p.blockName = name
}
func (p PoliceCtrl) Name() string { return p.blockName }