feat: command api
This commit is contained in:
@@ -12,15 +12,15 @@ type CommandType string
|
||||
const (
|
||||
CommandTypeRaceQuit CommandType = "raceQuit"
|
||||
CommandTypeRaceVote CommandType = "raceVote"
|
||||
CommandTypeRaceRelation CommandType = "declarePeace"
|
||||
CommandTypeRaceRelation CommandType = "raceRelation"
|
||||
CommandTypeShipClassCreate CommandType = "shipClassCreate"
|
||||
CommandTypeShipClassMerge CommandType = "shipClassMerge"
|
||||
CommandTypeShipClassRemove CommandType = "shipClassRemove"
|
||||
CommandTypeShipGroupBreak CommandType = "shipGroupBreak"
|
||||
CommandTypeShipGroupLoad CommandType = "shipGroupLoad"
|
||||
CommandTypeShipGroupUnload CommandType = "shipGroupUnload"
|
||||
CommandTypeShipGroupSend CommandType = "shipGroupSend"
|
||||
CommandTypeShipGroupUpgrade CommandType = "shipGroupUpgrade"
|
||||
CommandTypeShipGroupBreak CommandType = "shipGroupBreak"
|
||||
CommandTypeShipGroupMerge CommandType = "shipGroupMerge"
|
||||
CommandTypeShipGroupDismantle CommandType = "shipGroupDismantle"
|
||||
CommandTypeShipGroupTransfer CommandType = "shipGroupTransfer"
|
||||
@@ -104,9 +104,9 @@ type CommandShipGroupSend struct {
|
||||
|
||||
type CommandShipGroupUpgrade struct {
|
||||
CommandMeta
|
||||
ID string `json:"id" binding:"required,uuid_rfc4122"`
|
||||
Tech string `json:"tech" binding:"oneof=ALL DRIVE WEAPONS SHIELDS CARGO"`
|
||||
Level int `json:"level" binding:"gte=1"`
|
||||
ID string `json:"id" binding:"required,uuid_rfc4122"`
|
||||
Tech string `json:"tech" binding:"oneof=ALL DRIVE WEAPONS SHIELDS CARGO"`
|
||||
Level float64 `json:"level" binding:"gte=1"`
|
||||
}
|
||||
|
||||
type CommandShipGroupMerge struct {
|
||||
@@ -116,6 +116,7 @@ type CommandShipGroupMerge struct {
|
||||
type CommandShipGroupBreak struct {
|
||||
CommandMeta
|
||||
ID string `json:"id" binding:"required,uuid_rfc4122"`
|
||||
NewID string `json:"newId" binding:"required,uuid_rfc4122"`
|
||||
Quantity int `json:"quantity" binding:"gte=0"`
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user