mirror of
https://github.com/Luzifer/sii.git
synced 2024-12-21 00:21:15 +00:00
Add CargoData and CompanyPermanent base data
Signed-off-by: Knut Ahlers <knut@ahlers.me>
This commit is contained in:
parent
a48a514570
commit
6202f0dedf
2 changed files with 47 additions and 0 deletions
26
block_cargo_data.go
Normal file
26
block_cargo_data.go
Normal file
|
@ -0,0 +1,26 @@
|
|||
package sii
|
||||
|
||||
func init() {
|
||||
RegisterBlock(&CargoData{})
|
||||
}
|
||||
|
||||
type CargoData struct {
|
||||
CargoName string `sii:"name"`
|
||||
Fragility float32 `sii:"fragility"`
|
||||
Groups []Ptr `sii:"group"`
|
||||
Volume float32 `sii:"volume"`
|
||||
Mass float32 `sii:"mass"`
|
||||
UnitRewardPerKM float32 `sii:"unit_reward_per_km"`
|
||||
UnitLoadTime int64 `sii:"unit_load_time"`
|
||||
BodyTypes []Ptr `sii:"body_types"`
|
||||
|
||||
blockName string
|
||||
}
|
||||
|
||||
func (CargoData) Class() string { return "cargo_data" }
|
||||
|
||||
func (c *CargoData) Init(class, name string) {
|
||||
c.blockName = name
|
||||
}
|
||||
|
||||
func (c CargoData) Name() string { return c.blockName }
|
21
block_company_permanent.go
Normal file
21
block_company_permanent.go
Normal file
|
@ -0,0 +1,21 @@
|
|||
package sii
|
||||
|
||||
func init() {
|
||||
RegisterBlock(&CompanyPermanent{})
|
||||
}
|
||||
|
||||
type CompanyPermanent struct {
|
||||
CompanyName string `sii:"name"`
|
||||
SortName string `sii:"sort_name"`
|
||||
TrailerLook Ptr `sii:"trailer_look"`
|
||||
|
||||
blockName string
|
||||
}
|
||||
|
||||
func (CompanyPermanent) Class() string { return "company_permanent" }
|
||||
|
||||
func (c *CompanyPermanent) Init(class, name string) {
|
||||
c.blockName = name
|
||||
}
|
||||
|
||||
func (c CompanyPermanent) Name() string { return c.blockName }
|
Loading…
Reference in a new issue