1
0
Fork 0
mirror of https://github.com/Luzifer/sii.git synced 2024-12-21 00:21:15 +00:00
sii/block_vehicle_accessory.go
Knut Ahlers 6b9c7c1493
Add VehicleAccessory
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2019-12-23 16:16:47 +01:00

20 lines
397 B
Go

package sii
func init() {
RegisterBlock(&VehicleAccessory{})
}
type VehicleAccessory struct {
Wear float32 `sii:"wear"`
DataPath string `sii:"data_path"`
blockName string
}
func (VehicleAccessory) Class() string { return "vehicle_accessory" }
func (v *VehicleAccessory) Init(class, name string) {
v.blockName = name
}
func (v VehicleAccessory) Name() string { return v.blockName }