feat: produce ships
This commit is contained in:
@@ -22,7 +22,7 @@ const (
|
||||
|
||||
type Production struct {
|
||||
Type ProductionType `json:"type"`
|
||||
SubjectID *uuid.UUID `json:"subjectId"`
|
||||
SubjectID *uuid.UUID `json:"subjectId"` // TODO: get rid of Nils?
|
||||
Progress *float64 `json:"progress"`
|
||||
}
|
||||
|
||||
|
||||
@@ -71,6 +71,7 @@ func (st ShipType) EmptyMass() float64 {
|
||||
}
|
||||
|
||||
// ProductionCost returns Material (MAT) and Population (POP) to produce this [ShipType]
|
||||
// TODO: do we need this?
|
||||
func (st ShipType) ProductionCost() (mat float64, pop float64) {
|
||||
mat = st.EmptyMass()
|
||||
pop = mat * 10
|
||||
|
||||
Reference in New Issue
Block a user