test: battle multiple non-crossing enemies

This commit is contained in:
IliaDenisov
2026-02-06 17:21:42 +03:00
parent ef10842dac
commit 449c3273bf
9 changed files with 129 additions and 41 deletions
+9
View File
@@ -39,6 +39,15 @@ func (ts TechSet) Set(t Tech, v float64) TechSet {
return m
}
func NewTechSet() TechSet {
return TechSet{
TechDrive: 1.,
TechWeapons: 1.,
TechShields: 1.,
TechCargo: 1.,
}
}
// TODO: turn's incremental Version
type Game struct {
ID uuid.UUID `json:"id"`
+6 -13
View File
@@ -16,21 +16,14 @@ type BattleReport struct {
}
type BattleReportGroup struct {
// OwnerID uuid.UUID `json:"-"` // make report: visible ship class
InBattle bool `json:"inBattle"`
Number uint `json:"num"`
NumberLeft uint `json:"numLeft"`
// ClassArmament uint `json:"-"` // make report: visible ship class
// ClassMass Float `json:"-"` // make report: visible ship class
InBattle bool `json:"inBattle"`
Number uint `json:"num"`
NumberLeft uint `json:"numLeft"`
LoadQuantity Float `json:"loadQuantity"`
Tech map[string]Float `json:"tech"`
// DriveTech Float `json:"drive"`
// WeaponsTech Float `json:"weapons"`
// ShieldsTech Float `json:"shields"`
// CargoTech Float `json:"cargo"`
Race string `json:"race"`
ClassName string `json:"className"`
LoadType string `json:"loadType"`
Race string `json:"race"`
ClassName string `json:"className"`
LoadType string `json:"loadType"`
}
type BattleActionReport struct {