|
@@ -6,9 +6,9 @@ type YTConfig struct {
|
|
|
Sectors int `json:"sectors"`
|
|
|
Turns int `json:"turns"`
|
|
|
Holds int `json:"holds"`
|
|
|
- PortReset int `json:"reset"`
|
|
|
+ PortReset int `json:"reset"`
|
|
|
DaysExpire int `json:"expire"`
|
|
|
- Lottery int `json:"lotto"`
|
|
|
+ Lottery int `json:"lotto"`
|
|
|
}
|
|
|
|
|
|
type YTSectorType uint16
|
|
@@ -20,7 +20,7 @@ type YTSector struct {
|
|
|
Fighters uint `json:"fighters"`
|
|
|
FighterOwner int `json:"owner"`
|
|
|
Mines uint `json:"mines"`
|
|
|
- Sectors []YTSectorType `json:"sectors"`
|
|
|
+ Sectors []YTSectorType `json:"sectors"`
|
|
|
Players []int `json:"players`
|
|
|
}
|
|
|
|
|
@@ -39,13 +39,23 @@ func (sector YTSector) HasPort() bool {
|
|
|
var YTSectors []YTSector
|
|
|
|
|
|
type YTPlayer struct {
|
|
|
- Sector YTSectorType
|
|
|
- Name string `json:"name"`
|
|
|
- LastPlayed time.Time `json:"last"`
|
|
|
- Turns int `json:"turns"`
|
|
|
- Holds int `json:"holds"`
|
|
|
- Lotto int `json:"lotto`
|
|
|
- Cloak uint16 `json:"cloak`
|
|
|
+ Sector YTSectorType
|
|
|
+ Name string `json:"name"`
|
|
|
+ LastPlayed time.Time `json:"last"`
|
|
|
+ Turns int `json:"turns"`
|
|
|
+ Credits uint `json:"credits"`
|
|
|
+ Holds int `json:"holds"`
|
|
|
+ Amounts [3]uint `json:"holding"`
|
|
|
+ Lotto uint8 `json:"lotto`
|
|
|
+ Cloak uint16 `json:"cloak`
|
|
|
+ Fighters uint `json:"figs"`
|
|
|
+ Mines uint `json:"mines"`
|
|
|
+ Missiles uint `json:"missiles"`
|
|
|
+ Scanner bool `json:"scanner"`
|
|
|
+ Shields uint `json:"shields"`
|
|
|
+ Forces uint `json:"forces"`
|
|
|
+ PortsOwned uint `json:"ports"`
|
|
|
+ PlasmaBolts uint `json:"bolts"`
|
|
|
}
|
|
|
|
|
|
|
|
@@ -75,9 +85,24 @@ type YTPort struct {
|
|
|
|
|
|
var YTPortMap map[YTSectorType]YTPort
|
|
|
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
type YTPlanet struct {
|
|
|
- Name string `json:"name"`
|
|
|
- Owner int `json:"owner"`
|
|
|
+ Name string `json:"name"`
|
|
|
+ Owner int `json:"owner"`
|
|
|
+ Production [3]uint `json:"products"`
|
|
|
+ Amounts [3]uint `json:"amounts"`
|
|
|
+ Fighters [2]uint `json:"figs"`
|
|
|
+ Missiles [2]uint `json:"missiles"`
|
|
|
+ Mines [2]uint `json:"mines"`
|
|
|
+ Credits [2]uint `json:"credits"`
|
|
|
+ Forces [2]uint `json:"forces"`
|
|
|
+ PlasmaBolts [2]uint `json:"bolts"`
|
|
|
}
|
|
|
|
|
|
var YTPlanets map[YTSectorType]YTPlanet
|