v1

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 16, 2026 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MatchService_CreateMatch_FullMethodName        = "/codearena.v1.MatchService/CreateMatch"
	MatchService_ListActiveMatches_FullMethodName  = "/codearena.v1.MatchService/ListActiveMatches"
	MatchService_ListMatches_FullMethodName        = "/codearena.v1.MatchService/ListMatches"
	MatchService_WatchMatch_FullMethodName         = "/codearena.v1.MatchService/WatchMatch"
	MatchService_RegisterBot_FullMethodName        = "/codearena.v1.MatchService/RegisterBot"
	MatchService_GetMatchReplay_FullMethodName     = "/codearena.v1.MatchService/GetMatchReplay"
	MatchService_GetMatchHighlights_FullMethodName = "/codearena.v1.MatchService/GetMatchHighlights"
)
View Source
const (
	SimulationService_StartSimulation_FullMethodName = "/codearena.v1.SimulationService/StartSimulation"
	SimulationService_StopSimulation_FullMethodName  = "/codearena.v1.SimulationService/StopSimulation"
)
View Source
const (
	RuntimeService_StartBot_FullMethodName        = "/codearena.v1.RuntimeService/StartBot"
	RuntimeService_StopBot_FullMethodName         = "/codearena.v1.RuntimeService/StopBot"
	RuntimeService_GetRuntimeStats_FullMethodName = "/codearena.v1.RuntimeService/GetRuntimeStats"
)
View Source
const (
	BotService_Connect_FullMethodName = "/codearena.v1.BotService/Connect"
)

Variables

View Source
var (
	MatchStatus_name = map[int32]string{
		0: "MATCH_STATUS_UNSPECIFIED",
		1: "WAITING",
		2: "RUNNING",
		3: "FINISHED",
	}
	MatchStatus_value = map[string]int32{
		"MATCH_STATUS_UNSPECIFIED": 0,
		"WAITING":                  1,
		"RUNNING":                  2,
		"FINISHED":                 3,
	}
)

Enum value maps for MatchStatus.

View Source
var (
	PowerType_name = map[int32]string{
		0: "POWER_NONE",
		1: "SHIELD",
		2: "OVERCLOCK",
		3: "STEALTH",
	}
	PowerType_value = map[string]int32{
		"POWER_NONE": 0,
		"SHIELD":     1,
		"OVERCLOCK":  2,
		"STEALTH":    3,
	}
)

Enum value maps for PowerType.

View Source
var BotService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "codearena.v1.BotService",
	HandlerType: (*BotServiceServer)(nil),
	Methods:     []grpc.MethodDesc{},
	Streams: []grpc.StreamDesc{
		{
			StreamName:    "Connect",
			Handler:       _BotService_Connect_Handler,
			ServerStreams: true,
			ClientStreams: true,
		},
	},
	Metadata: "bot_api.proto",
}

BotService_ServiceDesc is the grpc.ServiceDesc for BotService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var File_arena_proto protoreflect.FileDescriptor
View Source
var File_bot_api_proto protoreflect.FileDescriptor
View Source
var File_runtime_proto protoreflect.FileDescriptor
View Source
var MatchService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "codearena.v1.MatchService",
	HandlerType: (*MatchServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "CreateMatch",
			Handler:    _MatchService_CreateMatch_Handler,
		},
		{
			MethodName: "ListActiveMatches",
			Handler:    _MatchService_ListActiveMatches_Handler,
		},
		{
			MethodName: "ListMatches",
			Handler:    _MatchService_ListMatches_Handler,
		},
		{
			MethodName: "RegisterBot",
			Handler:    _MatchService_RegisterBot_Handler,
		},
		{
			MethodName: "GetMatchReplay",
			Handler:    _MatchService_GetMatchReplay_Handler,
		},
		{
			MethodName: "GetMatchHighlights",
			Handler:    _MatchService_GetMatchHighlights_Handler,
		},
	},
	Streams: []grpc.StreamDesc{
		{
			StreamName:    "WatchMatch",
			Handler:       _MatchService_WatchMatch_Handler,
			ServerStreams: true,
		},
	},
	Metadata: "arena.proto",
}

MatchService_ServiceDesc is the grpc.ServiceDesc for MatchService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var RuntimeService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "codearena.v1.RuntimeService",
	HandlerType: (*RuntimeServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "StartBot",
			Handler:    _RuntimeService_StartBot_Handler,
		},
		{
			MethodName: "StopBot",
			Handler:    _RuntimeService_StopBot_Handler,
		},
		{
			MethodName: "GetRuntimeStats",
			Handler:    _RuntimeService_GetRuntimeStats_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "runtime.proto",
}

RuntimeService_ServiceDesc is the grpc.ServiceDesc for RuntimeService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var SimulationService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "codearena.v1.SimulationService",
	HandlerType: (*SimulationServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "StartSimulation",
			Handler:    _SimulationService_StartSimulation_Handler,
		},
		{
			MethodName: "StopSimulation",
			Handler:    _SimulationService_StopSimulation_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "arena.proto",
}

SimulationService_ServiceDesc is the grpc.ServiceDesc for SimulationService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterBotServiceServer

func RegisterBotServiceServer(s grpc.ServiceRegistrar, srv BotServiceServer)

func RegisterMatchServiceServer

func RegisterMatchServiceServer(s grpc.ServiceRegistrar, srv MatchServiceServer)

func RegisterRuntimeServiceServer

func RegisterRuntimeServiceServer(s grpc.ServiceRegistrar, srv RuntimeServiceServer)

func RegisterSimulationServiceServer

func RegisterSimulationServiceServer(s grpc.ServiceRegistrar, srv SimulationServiceServer)

Types

type ArenaConfig

type ArenaConfig struct {
	Id                 string      `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Name               string      `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	Width              float32     `protobuf:"fixed32,3,opt,name=width,proto3" json:"width,omitempty"`
	Height             float32     `protobuf:"fixed32,4,opt,name=height,proto3" json:"height,omitempty"`
	Obstacles          []*Obstacle `protobuf:"bytes,5,rep,name=obstacles,proto3" json:"obstacles,omitempty"`
	Zones              []*Zone     `protobuf:"bytes,6,rep,name=zones,proto3" json:"zones,omitempty"`
	MaxBots            int32       `protobuf:"varint,7,opt,name=max_bots,json=maxBots,proto3" json:"max_bots,omitempty"`
	MatchDurationTicks int64       `protobuf:"varint,8,opt,name=match_duration_ticks,json=matchDurationTicks,proto3" json:"match_duration_ticks,omitempty"`
	// contains filtered or unexported fields
}

func (*ArenaConfig) Descriptor deprecated

func (*ArenaConfig) Descriptor() ([]byte, []int)

Deprecated: Use ArenaConfig.ProtoReflect.Descriptor instead.

func (*ArenaConfig) GetHeight

func (x *ArenaConfig) GetHeight() float32

func (*ArenaConfig) GetId

func (x *ArenaConfig) GetId() string

func (*ArenaConfig) GetMatchDurationTicks

func (x *ArenaConfig) GetMatchDurationTicks() int64

func (*ArenaConfig) GetMaxBots

func (x *ArenaConfig) GetMaxBots() int32

func (*ArenaConfig) GetName

func (x *ArenaConfig) GetName() string

func (*ArenaConfig) GetObstacles

func (x *ArenaConfig) GetObstacles() []*Obstacle

func (*ArenaConfig) GetWidth

func (x *ArenaConfig) GetWidth() float32

func (*ArenaConfig) GetZones

func (x *ArenaConfig) GetZones() []*Zone

func (*ArenaConfig) ProtoMessage

func (*ArenaConfig) ProtoMessage()

func (*ArenaConfig) ProtoReflect

func (x *ArenaConfig) ProtoReflect() protoreflect.Message

func (*ArenaConfig) Reset

func (x *ArenaConfig) Reset()

func (*ArenaConfig) String

func (x *ArenaConfig) String() string

type BotIntent

type BotIntent struct {
	MoveDistance     float32   `protobuf:"fixed32,1,opt,name=move_distance,json=moveDistance,proto3" json:"move_distance,omitempty"` // + forward, - backward
	TurnDegrees      float32   `protobuf:"fixed32,2,opt,name=turn_degrees,json=turnDegrees,proto3" json:"turn_degrees,omitempty"`    // rotation
	GunTurnDegrees   float32   `protobuf:"fixed32,3,opt,name=gun_turn_degrees,json=gunTurnDegrees,proto3" json:"gun_turn_degrees,omitempty"`
	RadarTurnDegrees float32   `protobuf:"fixed32,4,opt,name=radar_turn_degrees,json=radarTurnDegrees,proto3" json:"radar_turn_degrees,omitempty"`
	FirePower        float32   `protobuf:"fixed32,5,opt,name=fire_power,json=firePower,proto3" json:"fire_power,omitempty"` // 0.1 to 3.0
	UsePower         PowerType `protobuf:"varint,6,opt,name=use_power,json=usePower,proto3,enum=codearena.v1.PowerType" json:"use_power,omitempty"`
	// contains filtered or unexported fields
}

Command intent from a bot for the next tick

func (*BotIntent) Descriptor deprecated

func (*BotIntent) Descriptor() ([]byte, []int)

Deprecated: Use BotIntent.ProtoReflect.Descriptor instead.

func (*BotIntent) GetFirePower

func (x *BotIntent) GetFirePower() float32

func (*BotIntent) GetGunTurnDegrees

func (x *BotIntent) GetGunTurnDegrees() float32

func (*BotIntent) GetMoveDistance

func (x *BotIntent) GetMoveDistance() float32

func (*BotIntent) GetRadarTurnDegrees

func (x *BotIntent) GetRadarTurnDegrees() float32

func (*BotIntent) GetTurnDegrees

func (x *BotIntent) GetTurnDegrees() float32

func (*BotIntent) GetUsePower

func (x *BotIntent) GetUsePower() PowerType

func (*BotIntent) ProtoMessage

func (*BotIntent) ProtoMessage()

func (*BotIntent) ProtoReflect

func (x *BotIntent) ProtoReflect() protoreflect.Message

func (*BotIntent) Reset

func (x *BotIntent) Reset()

func (*BotIntent) String

func (x *BotIntent) String() string

type BotServiceClient

type BotServiceClient interface {
	// Real-time stream of state updates
	Connect(ctx context.Context, opts ...grpc.CallOption) (grpc.BidiStreamingClient[BotIntent, WorldState], error)
}

BotServiceClient is the client API for BotService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewBotServiceClient

func NewBotServiceClient(cc grpc.ClientConnInterface) BotServiceClient

type BotServiceServer

type BotServiceServer interface {
	// Real-time stream of state updates
	Connect(grpc.BidiStreamingServer[BotIntent, WorldState]) error
	// contains filtered or unexported methods
}

BotServiceServer is the server API for BotService service. All implementations must embed UnimplementedBotServiceServer for forward compatibility.

type BotService_ConnectClient

type BotService_ConnectClient = grpc.BidiStreamingClient[BotIntent, WorldState]

This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name.

type BotService_ConnectServer

type BotService_ConnectServer = grpc.BidiStreamingServer[BotIntent, WorldState]

This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name.

type BotState

type BotState struct {
	Id           string           `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Name         string           `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	Position     *Vector3         `protobuf:"bytes,3,opt,name=position,proto3" json:"position,omitempty"`
	Heading      float32          `protobuf:"fixed32,4,opt,name=heading,proto3" json:"heading,omitempty"`
	GunHeading   float32          `protobuf:"fixed32,5,opt,name=gun_heading,json=gunHeading,proto3" json:"gun_heading,omitempty"`
	RadarHeading float32          `protobuf:"fixed32,6,opt,name=radar_heading,json=radarHeading,proto3" json:"radar_heading,omitempty"`
	Velocity     float32          `protobuf:"fixed32,7,opt,name=velocity,proto3" json:"velocity,omitempty"`
	Energy       float32          `protobuf:"fixed32,8,opt,name=energy,proto3" json:"energy,omitempty"`
	Hull         float32          `protobuf:"fixed32,9,opt,name=hull,proto3" json:"hull,omitempty"`
	Heat         float32          `protobuf:"fixed32,10,opt,name=heat,proto3" json:"heat,omitempty"`
	ShieldHp     float32          `protobuf:"fixed32,11,opt,name=shield_hp,json=shieldHp,proto3" json:"shield_hp,omitempty"`         // Remaining Shield points
	IsStealthed  bool             `protobuf:"varint,12,opt,name=is_stealthed,json=isStealthed,proto3" json:"is_stealthed,omitempty"` // If active stealth module
	Cooldowns    map[string]int32 ``                                                                                                 // Power-id to remaining ticks
	/* 147-byte string literal not displayed */
	Class  string `protobuf:"bytes,14,opt,name=class,proto3" json:"class,omitempty"` // Tank, Scout, Sniper
	TeamId string `protobuf:"bytes,15,opt,name=team_id,json=teamId,proto3" json:"team_id,omitempty"`
	// contains filtered or unexported fields
}

Information about a bot in the arena

func (*BotState) Descriptor deprecated

func (*BotState) Descriptor() ([]byte, []int)

Deprecated: Use BotState.ProtoReflect.Descriptor instead.

func (*BotState) GetClass

func (x *BotState) GetClass() string

func (*BotState) GetCooldowns

func (x *BotState) GetCooldowns() map[string]int32

func (*BotState) GetEnergy

func (x *BotState) GetEnergy() float32

func (*BotState) GetGunHeading

func (x *BotState) GetGunHeading() float32

func (*BotState) GetHeading

func (x *BotState) GetHeading() float32

func (*BotState) GetHeat

func (x *BotState) GetHeat() float32

func (*BotState) GetHull

func (x *BotState) GetHull() float32

func (*BotState) GetId

func (x *BotState) GetId() string

func (*BotState) GetIsStealthed

func (x *BotState) GetIsStealthed() bool

func (*BotState) GetName

func (x *BotState) GetName() string

func (*BotState) GetPosition

func (x *BotState) GetPosition() *Vector3

func (*BotState) GetRadarHeading

func (x *BotState) GetRadarHeading() float32

func (*BotState) GetShieldHp

func (x *BotState) GetShieldHp() float32

func (*BotState) GetTeamId

func (x *BotState) GetTeamId() string

func (*BotState) GetVelocity

func (x *BotState) GetVelocity() float32

func (*BotState) ProtoMessage

func (*BotState) ProtoMessage()

func (*BotState) ProtoReflect

func (x *BotState) ProtoReflect() protoreflect.Message

func (*BotState) Reset

func (x *BotState) Reset()

func (*BotState) String

func (x *BotState) String() string

type BulletHitTargetEvent

type BulletHitTargetEvent struct {
	BulletId string `protobuf:"bytes,1,opt,name=bullet_id,json=bulletId,proto3" json:"bullet_id,omitempty"`
	TargetId string `protobuf:"bytes,2,opt,name=target_id,json=targetId,proto3" json:"target_id,omitempty"`
	// contains filtered or unexported fields
}

func (*BulletHitTargetEvent) Descriptor deprecated

func (*BulletHitTargetEvent) Descriptor() ([]byte, []int)

Deprecated: Use BulletHitTargetEvent.ProtoReflect.Descriptor instead.

func (*BulletHitTargetEvent) GetBulletId

func (x *BulletHitTargetEvent) GetBulletId() string

func (*BulletHitTargetEvent) GetTargetId

func (x *BulletHitTargetEvent) GetTargetId() string

func (*BulletHitTargetEvent) ProtoMessage

func (*BulletHitTargetEvent) ProtoMessage()

func (*BulletHitTargetEvent) ProtoReflect

func (x *BulletHitTargetEvent) ProtoReflect() protoreflect.Message

func (*BulletHitTargetEvent) Reset

func (x *BulletHitTargetEvent) Reset()

func (*BulletHitTargetEvent) String

func (x *BulletHitTargetEvent) String() string

type BulletState

type BulletState struct {
	Id       string   `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	OwnerId  string   `protobuf:"bytes,2,opt,name=owner_id,json=ownerId,proto3" json:"owner_id,omitempty"`
	Position *Vector3 `protobuf:"bytes,3,opt,name=position,proto3" json:"position,omitempty"`
	Heading  float32  `protobuf:"fixed32,4,opt,name=heading,proto3" json:"heading,omitempty"`
	Velocity float32  `protobuf:"fixed32,5,opt,name=velocity,proto3" json:"velocity,omitempty"`
	Power    float32  `protobuf:"fixed32,6,opt,name=power,proto3" json:"power,omitempty"`
	// contains filtered or unexported fields
}

func (*BulletState) Descriptor deprecated

func (*BulletState) Descriptor() ([]byte, []int)

Deprecated: Use BulletState.ProtoReflect.Descriptor instead.

func (*BulletState) GetHeading

func (x *BulletState) GetHeading() float32

func (*BulletState) GetId

func (x *BulletState) GetId() string

func (*BulletState) GetOwnerId

func (x *BulletState) GetOwnerId() string

func (*BulletState) GetPosition

func (x *BulletState) GetPosition() *Vector3

func (*BulletState) GetPower

func (x *BulletState) GetPower() float32

func (*BulletState) GetVelocity

func (x *BulletState) GetVelocity() float32

func (*BulletState) ProtoMessage

func (*BulletState) ProtoMessage()

func (*BulletState) ProtoReflect

func (x *BulletState) ProtoReflect() protoreflect.Message

func (*BulletState) Reset

func (x *BulletState) Reset()

func (*BulletState) String

func (x *BulletState) String() string

type DeathEvent

type DeathEvent struct {
	BotId    string `protobuf:"bytes,1,opt,name=bot_id,json=botId,proto3" json:"bot_id,omitempty"`
	KillerId string `protobuf:"bytes,2,opt,name=killer_id,json=killerId,proto3" json:"killer_id,omitempty"`
	// contains filtered or unexported fields
}

func (*DeathEvent) Descriptor deprecated

func (*DeathEvent) Descriptor() ([]byte, []int)

Deprecated: Use DeathEvent.ProtoReflect.Descriptor instead.

func (*DeathEvent) GetBotId

func (x *DeathEvent) GetBotId() string

func (*DeathEvent) GetKillerId

func (x *DeathEvent) GetKillerId() string

func (*DeathEvent) ProtoMessage

func (*DeathEvent) ProtoMessage()

func (*DeathEvent) ProtoReflect

func (x *DeathEvent) ProtoReflect() protoreflect.Message

func (*DeathEvent) Reset

func (x *DeathEvent) Reset()

func (*DeathEvent) String

func (x *DeathEvent) String() string

type Empty

type Empty struct {
	// contains filtered or unexported fields
}

func (*Empty) Descriptor deprecated

func (*Empty) Descriptor() ([]byte, []int)

Deprecated: Use Empty.ProtoReflect.Descriptor instead.

func (*Empty) ProtoMessage

func (*Empty) ProtoMessage()

func (*Empty) ProtoReflect

func (x *Empty) ProtoReflect() protoreflect.Message

func (*Empty) Reset

func (x *Empty) Reset()

func (*Empty) String

func (x *Empty) String() string

type HighlightMoment

type HighlightMoment struct {
	Tick        int64  `protobuf:"varint,1,opt,name=tick,proto3" json:"tick,omitempty"`
	Type        string `protobuf:"bytes,2,opt,name=type,proto3" json:"type,omitempty"` // DEATH, KILL, DAMAGE
	Description string `protobuf:"bytes,3,opt,name=description,proto3" json:"description,omitempty"`
	// contains filtered or unexported fields
}

func (*HighlightMoment) Descriptor deprecated

func (*HighlightMoment) Descriptor() ([]byte, []int)

Deprecated: Use HighlightMoment.ProtoReflect.Descriptor instead.

func (*HighlightMoment) GetDescription

func (x *HighlightMoment) GetDescription() string

func (*HighlightMoment) GetTick

func (x *HighlightMoment) GetTick() int64

func (*HighlightMoment) GetType

func (x *HighlightMoment) GetType() string

func (*HighlightMoment) ProtoMessage

func (*HighlightMoment) ProtoMessage()

func (*HighlightMoment) ProtoReflect

func (x *HighlightMoment) ProtoReflect() protoreflect.Message

func (*HighlightMoment) Reset

func (x *HighlightMoment) Reset()

func (*HighlightMoment) String

func (x *HighlightMoment) String() string

type HighlightsData

type HighlightsData struct {
	MatchId string             `protobuf:"bytes,1,opt,name=match_id,json=matchId,proto3" json:"match_id,omitempty"`
	Moments []*HighlightMoment `protobuf:"bytes,2,rep,name=moments,proto3" json:"moments,omitempty"`
	// contains filtered or unexported fields
}

func (*HighlightsData) Descriptor deprecated

func (*HighlightsData) Descriptor() ([]byte, []int)

Deprecated: Use HighlightsData.ProtoReflect.Descriptor instead.

func (*HighlightsData) GetMatchId

func (x *HighlightsData) GetMatchId() string

func (*HighlightsData) GetMoments

func (x *HighlightsData) GetMoments() []*HighlightMoment

func (*HighlightsData) ProtoMessage

func (*HighlightsData) ProtoMessage()

func (*HighlightsData) ProtoReflect

func (x *HighlightsData) ProtoReflect() protoreflect.Message

func (*HighlightsData) Reset

func (x *HighlightsData) Reset()

func (*HighlightsData) String

func (x *HighlightsData) String() string

type HitByBulletEvent

type HitByBulletEvent struct {
	VictimId string  `protobuf:"bytes,1,opt,name=victim_id,json=victimId,proto3" json:"victim_id,omitempty"`
	BulletId string  `protobuf:"bytes,2,opt,name=bullet_id,json=bulletId,proto3" json:"bullet_id,omitempty"`
	Damage   float32 `protobuf:"fixed32,3,opt,name=damage,proto3" json:"damage,omitempty"`
	// contains filtered or unexported fields
}

func (*HitByBulletEvent) Descriptor deprecated

func (*HitByBulletEvent) Descriptor() ([]byte, []int)

Deprecated: Use HitByBulletEvent.ProtoReflect.Descriptor instead.

func (*HitByBulletEvent) GetBulletId

func (x *HitByBulletEvent) GetBulletId() string

func (*HitByBulletEvent) GetDamage

func (x *HitByBulletEvent) GetDamage() float32

func (*HitByBulletEvent) GetVictimId

func (x *HitByBulletEvent) GetVictimId() string

func (*HitByBulletEvent) ProtoMessage

func (*HitByBulletEvent) ProtoMessage()

func (*HitByBulletEvent) ProtoReflect

func (x *HitByBulletEvent) ProtoReflect() protoreflect.Message

func (*HitByBulletEvent) Reset

func (x *HitByBulletEvent) Reset()

func (*HitByBulletEvent) String

func (x *HitByBulletEvent) String() string

type HitRobotEvent

type HitRobotEvent struct {
	BotId   string `protobuf:"bytes,1,opt,name=bot_id,json=botId,proto3" json:"bot_id,omitempty"`
	OtherId string `protobuf:"bytes,2,opt,name=other_id,json=otherId,proto3" json:"other_id,omitempty"`
	// contains filtered or unexported fields
}

func (*HitRobotEvent) Descriptor deprecated

func (*HitRobotEvent) Descriptor() ([]byte, []int)

Deprecated: Use HitRobotEvent.ProtoReflect.Descriptor instead.

func (*HitRobotEvent) GetBotId

func (x *HitRobotEvent) GetBotId() string

func (*HitRobotEvent) GetOtherId

func (x *HitRobotEvent) GetOtherId() string

func (*HitRobotEvent) ProtoMessage

func (*HitRobotEvent) ProtoMessage()

func (*HitRobotEvent) ProtoReflect

func (x *HitRobotEvent) ProtoReflect() protoreflect.Message

func (*HitRobotEvent) Reset

func (x *HitRobotEvent) Reset()

func (*HitRobotEvent) String

func (x *HitRobotEvent) String() string

type HitWallEvent

type HitWallEvent struct {
	BotId string `protobuf:"bytes,1,opt,name=bot_id,json=botId,proto3" json:"bot_id,omitempty"`
	// contains filtered or unexported fields
}

func (*HitWallEvent) Descriptor deprecated

func (*HitWallEvent) Descriptor() ([]byte, []int)

Deprecated: Use HitWallEvent.ProtoReflect.Descriptor instead.

func (*HitWallEvent) GetBotId

func (x *HitWallEvent) GetBotId() string

func (*HitWallEvent) ProtoMessage

func (*HitWallEvent) ProtoMessage()

func (*HitWallEvent) ProtoReflect

func (x *HitWallEvent) ProtoReflect() protoreflect.Message

func (*HitWallEvent) Reset

func (x *HitWallEvent) Reset()

func (*HitWallEvent) String

func (x *HitWallEvent) String() string

type MatchFinishedEvent

type MatchFinishedEvent struct {
	WinnerId string `protobuf:"bytes,1,opt,name=winner_id,json=winnerId,proto3" json:"winner_id,omitempty"`
	// contains filtered or unexported fields
}

func (*MatchFinishedEvent) Descriptor deprecated

func (*MatchFinishedEvent) Descriptor() ([]byte, []int)

Deprecated: Use MatchFinishedEvent.ProtoReflect.Descriptor instead.

func (*MatchFinishedEvent) GetWinnerId

func (x *MatchFinishedEvent) GetWinnerId() string

func (*MatchFinishedEvent) ProtoMessage

func (*MatchFinishedEvent) ProtoMessage()

func (*MatchFinishedEvent) ProtoReflect

func (x *MatchFinishedEvent) ProtoReflect() protoreflect.Message

func (*MatchFinishedEvent) Reset

func (x *MatchFinishedEvent) Reset()

func (*MatchFinishedEvent) String

func (x *MatchFinishedEvent) String() string

type MatchList

type MatchList struct {
	Matches []*MatchResponse `protobuf:"bytes,1,rep,name=matches,proto3" json:"matches,omitempty"`
	// contains filtered or unexported fields
}

func (*MatchList) Descriptor deprecated

func (*MatchList) Descriptor() ([]byte, []int)

Deprecated: Use MatchList.ProtoReflect.Descriptor instead.

func (*MatchList) GetMatches

func (x *MatchList) GetMatches() []*MatchResponse

func (*MatchList) ProtoMessage

func (*MatchList) ProtoMessage()

func (*MatchList) ProtoReflect

func (x *MatchList) ProtoReflect() protoreflect.Message

func (*MatchList) Reset

func (x *MatchList) Reset()

func (*MatchList) String

func (x *MatchList) String() string

type MatchRequest

type MatchRequest struct {
	MatchId string `protobuf:"bytes,1,opt,name=match_id,json=matchId,proto3" json:"match_id,omitempty"`
	// contains filtered or unexported fields
}

func (*MatchRequest) Descriptor deprecated

func (*MatchRequest) Descriptor() ([]byte, []int)

Deprecated: Use MatchRequest.ProtoReflect.Descriptor instead.

func (*MatchRequest) GetMatchId

func (x *MatchRequest) GetMatchId() string

func (*MatchRequest) ProtoMessage

func (*MatchRequest) ProtoMessage()

func (*MatchRequest) ProtoReflect

func (x *MatchRequest) ProtoReflect() protoreflect.Message

func (*MatchRequest) Reset

func (x *MatchRequest) Reset()

func (*MatchRequest) String

func (x *MatchRequest) String() string

type MatchResponse

type MatchResponse struct {
	MatchId string      `protobuf:"bytes,2,opt,name=match_id,json=matchId,proto3" json:"match_id,omitempty"`
	Status  MatchStatus `protobuf:"varint,3,opt,name=status,proto3,enum=codearena.v1.MatchStatus" json:"status,omitempty"`
	// contains filtered or unexported fields
}

func (*MatchResponse) Descriptor deprecated

func (*MatchResponse) Descriptor() ([]byte, []int)

Deprecated: Use MatchResponse.ProtoReflect.Descriptor instead.

func (*MatchResponse) GetMatchId

func (x *MatchResponse) GetMatchId() string

func (*MatchResponse) GetStatus

func (x *MatchResponse) GetStatus() MatchStatus

func (*MatchResponse) ProtoMessage

func (*MatchResponse) ProtoMessage()

func (*MatchResponse) ProtoReflect

func (x *MatchResponse) ProtoReflect() protoreflect.Message

func (*MatchResponse) Reset

func (x *MatchResponse) Reset()

func (*MatchResponse) String

func (x *MatchResponse) String() string

type MatchServiceClient

type MatchServiceClient interface {
	CreateMatch(ctx context.Context, in *ArenaConfig, opts ...grpc.CallOption) (*MatchResponse, error)
	ListActiveMatches(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*MatchList, error)
	ListMatches(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*MatchList, error)
	WatchMatch(ctx context.Context, in *MatchRequest, opts ...grpc.CallOption) (grpc.ServerStreamingClient[WorldState], error)
	RegisterBot(ctx context.Context, in *RegisterBotRequest, opts ...grpc.CallOption) (*RegisterBotResponse, error)
	GetMatchReplay(ctx context.Context, in *ReplayRequest, opts ...grpc.CallOption) (*ReplayData, error)
	GetMatchHighlights(ctx context.Context, in *ReplayRequest, opts ...grpc.CallOption) (*HighlightsData, error)
}

MatchServiceClient is the client API for MatchService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

type MatchServiceServer

type MatchServiceServer interface {
	CreateMatch(context.Context, *ArenaConfig) (*MatchResponse, error)
	ListActiveMatches(context.Context, *Empty) (*MatchList, error)
	ListMatches(context.Context, *Empty) (*MatchList, error)
	WatchMatch(*MatchRequest, grpc.ServerStreamingServer[WorldState]) error
	RegisterBot(context.Context, *RegisterBotRequest) (*RegisterBotResponse, error)
	GetMatchReplay(context.Context, *ReplayRequest) (*ReplayData, error)
	GetMatchHighlights(context.Context, *ReplayRequest) (*HighlightsData, error)
	// contains filtered or unexported methods
}

MatchServiceServer is the server API for MatchService service. All implementations must embed UnimplementedMatchServiceServer for forward compatibility.

type MatchService_WatchMatchClient

type MatchService_WatchMatchClient = grpc.ServerStreamingClient[WorldState]

This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name.

type MatchService_WatchMatchServer

type MatchService_WatchMatchServer = grpc.ServerStreamingServer[WorldState]

This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name.

type MatchStatus

type MatchStatus int32

Global match status

const (
	MatchStatus_MATCH_STATUS_UNSPECIFIED MatchStatus = 0
	MatchStatus_WAITING                  MatchStatus = 1
	MatchStatus_RUNNING                  MatchStatus = 2
	MatchStatus_FINISHED                 MatchStatus = 3
)

func (MatchStatus) Descriptor

func (MatchStatus) Enum

func (x MatchStatus) Enum() *MatchStatus

func (MatchStatus) EnumDescriptor deprecated

func (MatchStatus) EnumDescriptor() ([]byte, []int)

Deprecated: Use MatchStatus.Descriptor instead.

func (MatchStatus) Number

func (x MatchStatus) Number() protoreflect.EnumNumber

func (MatchStatus) String

func (x MatchStatus) String() string

func (MatchStatus) Type

type Obstacle

type Obstacle struct {
	Id             string   `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Position       *Vector3 `protobuf:"bytes,2,opt,name=position,proto3" json:"position,omitempty"`
	Radius         float32  `protobuf:"fixed32,3,opt,name=radius,proto3" json:"radius,omitempty"` // All obstacles are circular in v1
	Indestructible bool     `protobuf:"varint,4,opt,name=indestructible,proto3" json:"indestructible,omitempty"`
	// contains filtered or unexported fields
}

func (*Obstacle) Descriptor deprecated

func (*Obstacle) Descriptor() ([]byte, []int)

Deprecated: Use Obstacle.ProtoReflect.Descriptor instead.

func (*Obstacle) GetId

func (x *Obstacle) GetId() string

func (*Obstacle) GetIndestructible

func (x *Obstacle) GetIndestructible() bool

func (*Obstacle) GetPosition

func (x *Obstacle) GetPosition() *Vector3

func (*Obstacle) GetRadius

func (x *Obstacle) GetRadius() float32

func (*Obstacle) ProtoMessage

func (*Obstacle) ProtoMessage()

func (*Obstacle) ProtoReflect

func (x *Obstacle) ProtoReflect() protoreflect.Message

func (*Obstacle) Reset

func (x *Obstacle) Reset()

func (*Obstacle) String

func (x *Obstacle) String() string

type PowerType

type PowerType int32
const (
	PowerType_POWER_NONE PowerType = 0
	PowerType_SHIELD     PowerType = 1
	PowerType_OVERCLOCK  PowerType = 2
	PowerType_STEALTH    PowerType = 3
)

func (PowerType) Descriptor

func (PowerType) Descriptor() protoreflect.EnumDescriptor

func (PowerType) Enum

func (x PowerType) Enum() *PowerType

func (PowerType) EnumDescriptor deprecated

func (PowerType) EnumDescriptor() ([]byte, []int)

Deprecated: Use PowerType.Descriptor instead.

func (PowerType) Number

func (x PowerType) Number() protoreflect.EnumNumber

func (PowerType) String

func (x PowerType) String() string

func (PowerType) Type

type RegisterBotRequest

type RegisterBotRequest struct {
	UserId     string `protobuf:"bytes,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
	Name       string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	Version    string `protobuf:"bytes,3,opt,name=version,proto3" json:"version,omitempty"`
	SourceCode string `protobuf:"bytes,4,opt,name=source_code,json=sourceCode,proto3" json:"source_code,omitempty"` // Base64 encoded or raw string for v1
	Language   string `protobuf:"bytes,5,opt,name=language,proto3" json:"language,omitempty"`
	// contains filtered or unexported fields
}

func (*RegisterBotRequest) Descriptor deprecated

func (*RegisterBotRequest) Descriptor() ([]byte, []int)

Deprecated: Use RegisterBotRequest.ProtoReflect.Descriptor instead.

func (*RegisterBotRequest) GetLanguage

func (x *RegisterBotRequest) GetLanguage() string

func (*RegisterBotRequest) GetName

func (x *RegisterBotRequest) GetName() string

func (*RegisterBotRequest) GetSourceCode

func (x *RegisterBotRequest) GetSourceCode() string

func (*RegisterBotRequest) GetUserId

func (x *RegisterBotRequest) GetUserId() string

func (*RegisterBotRequest) GetVersion

func (x *RegisterBotRequest) GetVersion() string

func (*RegisterBotRequest) ProtoMessage

func (*RegisterBotRequest) ProtoMessage()

func (*RegisterBotRequest) ProtoReflect

func (x *RegisterBotRequest) ProtoReflect() protoreflect.Message

func (*RegisterBotRequest) Reset

func (x *RegisterBotRequest) Reset()

func (*RegisterBotRequest) String

func (x *RegisterBotRequest) String() string

type RegisterBotResponse

type RegisterBotResponse struct {
	BotId     string `protobuf:"bytes,1,opt,name=bot_id,json=botId,proto3" json:"bot_id,omitempty"`
	VersionId string `protobuf:"bytes,2,opt,name=version_id,json=versionId,proto3" json:"version_id,omitempty"`
	Success   bool   `protobuf:"varint,3,opt,name=success,proto3" json:"success,omitempty"`
	Message   string `protobuf:"bytes,4,opt,name=message,proto3" json:"message,omitempty"`
	// contains filtered or unexported fields
}

func (*RegisterBotResponse) Descriptor deprecated

func (*RegisterBotResponse) Descriptor() ([]byte, []int)

Deprecated: Use RegisterBotResponse.ProtoReflect.Descriptor instead.

func (*RegisterBotResponse) GetBotId

func (x *RegisterBotResponse) GetBotId() string

func (*RegisterBotResponse) GetMessage

func (x *RegisterBotResponse) GetMessage() string

func (*RegisterBotResponse) GetSuccess

func (x *RegisterBotResponse) GetSuccess() bool

func (*RegisterBotResponse) GetVersionId

func (x *RegisterBotResponse) GetVersionId() string

func (*RegisterBotResponse) ProtoMessage

func (*RegisterBotResponse) ProtoMessage()

func (*RegisterBotResponse) ProtoReflect

func (x *RegisterBotResponse) ProtoReflect() protoreflect.Message

func (*RegisterBotResponse) Reset

func (x *RegisterBotResponse) Reset()

func (*RegisterBotResponse) String

func (x *RegisterBotResponse) String() string

type ReplayData

type ReplayData struct {
	MatchId string             `protobuf:"bytes,1,opt,name=match_id,json=matchId,proto3" json:"match_id,omitempty"`
	Events  []*SimulationEvent `protobuf:"bytes,2,rep,name=events,proto3" json:"events,omitempty"`
	// contains filtered or unexported fields
}

func (*ReplayData) Descriptor deprecated

func (*ReplayData) Descriptor() ([]byte, []int)

Deprecated: Use ReplayData.ProtoReflect.Descriptor instead.

func (*ReplayData) GetEvents

func (x *ReplayData) GetEvents() []*SimulationEvent

func (*ReplayData) GetMatchId

func (x *ReplayData) GetMatchId() string

func (*ReplayData) ProtoMessage

func (*ReplayData) ProtoMessage()

func (*ReplayData) ProtoReflect

func (x *ReplayData) ProtoReflect() protoreflect.Message

func (*ReplayData) Reset

func (x *ReplayData) Reset()

func (*ReplayData) String

func (x *ReplayData) String() string

type ReplayRequest

type ReplayRequest struct {
	MatchId   string `protobuf:"bytes,1,opt,name=match_id,json=matchId,proto3" json:"match_id,omitempty"`
	StartTick int64  `protobuf:"varint,2,opt,name=start_tick,json=startTick,proto3" json:"start_tick,omitempty"`
	EndTick   int64  `protobuf:"varint,3,opt,name=end_tick,json=endTick,proto3" json:"end_tick,omitempty"`
	// contains filtered or unexported fields
}

func (*ReplayRequest) Descriptor deprecated

func (*ReplayRequest) Descriptor() ([]byte, []int)

Deprecated: Use ReplayRequest.ProtoReflect.Descriptor instead.

func (*ReplayRequest) GetEndTick

func (x *ReplayRequest) GetEndTick() int64

func (*ReplayRequest) GetMatchId

func (x *ReplayRequest) GetMatchId() string

func (*ReplayRequest) GetStartTick

func (x *ReplayRequest) GetStartTick() int64

func (*ReplayRequest) ProtoMessage

func (*ReplayRequest) ProtoMessage()

func (*ReplayRequest) ProtoReflect

func (x *ReplayRequest) ProtoReflect() protoreflect.Message

func (*ReplayRequest) Reset

func (x *ReplayRequest) Reset()

func (*ReplayRequest) String

func (x *ReplayRequest) String() string

type RuntimeServiceClient

type RuntimeServiceClient interface {
	// Request to start a bot container/process
	StartBot(ctx context.Context, in *StartBotRequest, opts ...grpc.CallOption) (*StartBotResponse, error)
	// Request to stop a bot
	StopBot(ctx context.Context, in *StopBotRequest, opts ...grpc.CallOption) (*StopBotResponse, error)
	// Health check for runtime stats
	GetRuntimeStats(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*RuntimeStats, error)
}

RuntimeServiceClient is the client API for RuntimeService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

Service specific to the Runtime environment (Sandboxing)

type RuntimeServiceServer

type RuntimeServiceServer interface {
	// Request to start a bot container/process
	StartBot(context.Context, *StartBotRequest) (*StartBotResponse, error)
	// Request to stop a bot
	StopBot(context.Context, *StopBotRequest) (*StopBotResponse, error)
	// Health check for runtime stats
	GetRuntimeStats(context.Context, *Empty) (*RuntimeStats, error)
	// contains filtered or unexported methods
}

RuntimeServiceServer is the server API for RuntimeService service. All implementations must embed UnimplementedRuntimeServiceServer for forward compatibility.

Service specific to the Runtime environment (Sandboxing)

type RuntimeStats

type RuntimeStats struct {
	ActiveContainers int32   `protobuf:"varint,1,opt,name=active_containers,json=activeContainers,proto3" json:"active_containers,omitempty"`
	MemoryUsageMb    int64   `protobuf:"varint,2,opt,name=memory_usage_mb,json=memoryUsageMb,proto3" json:"memory_usage_mb,omitempty"`
	CpuUsagePercent  float32 `protobuf:"fixed32,3,opt,name=cpu_usage_percent,json=cpuUsagePercent,proto3" json:"cpu_usage_percent,omitempty"`
	// contains filtered or unexported fields
}

func (*RuntimeStats) Descriptor deprecated

func (*RuntimeStats) Descriptor() ([]byte, []int)

Deprecated: Use RuntimeStats.ProtoReflect.Descriptor instead.

func (*RuntimeStats) GetActiveContainers

func (x *RuntimeStats) GetActiveContainers() int32

func (*RuntimeStats) GetCpuUsagePercent

func (x *RuntimeStats) GetCpuUsagePercent() float32

func (*RuntimeStats) GetMemoryUsageMb

func (x *RuntimeStats) GetMemoryUsageMb() int64

func (*RuntimeStats) ProtoMessage

func (*RuntimeStats) ProtoMessage()

func (*RuntimeStats) ProtoReflect

func (x *RuntimeStats) ProtoReflect() protoreflect.Message

func (*RuntimeStats) Reset

func (x *RuntimeStats) Reset()

func (*RuntimeStats) String

func (x *RuntimeStats) String() string

type SimulationEvent

type SimulationEvent struct {
	Tick int64 `protobuf:"varint,1,opt,name=tick,proto3" json:"tick,omitempty"`
	// Types that are valid to be assigned to Event:
	//
	//	*SimulationEvent_HitByBullet
	//	*SimulationEvent_BulletHitTarget
	//	*SimulationEvent_HitWall
	//	*SimulationEvent_HitRobot
	//	*SimulationEvent_ZoneEntered
	//	*SimulationEvent_Death
	//	*SimulationEvent_MatchFinished
	Event isSimulationEvent_Event `protobuf_oneof:"event"`
	// contains filtered or unexported fields
}

Event types emitted by the engine

func (*SimulationEvent) Descriptor deprecated

func (*SimulationEvent) Descriptor() ([]byte, []int)

Deprecated: Use SimulationEvent.ProtoReflect.Descriptor instead.

func (*SimulationEvent) GetBulletHitTarget

func (x *SimulationEvent) GetBulletHitTarget() *BulletHitTargetEvent

func (*SimulationEvent) GetDeath

func (x *SimulationEvent) GetDeath() *DeathEvent

func (*SimulationEvent) GetEvent

func (x *SimulationEvent) GetEvent() isSimulationEvent_Event

func (*SimulationEvent) GetHitByBullet

func (x *SimulationEvent) GetHitByBullet() *HitByBulletEvent

func (*SimulationEvent) GetHitRobot

func (x *SimulationEvent) GetHitRobot() *HitRobotEvent

func (*SimulationEvent) GetHitWall

func (x *SimulationEvent) GetHitWall() *HitWallEvent

func (*SimulationEvent) GetMatchFinished

func (x *SimulationEvent) GetMatchFinished() *MatchFinishedEvent

func (*SimulationEvent) GetTick

func (x *SimulationEvent) GetTick() int64

func (*SimulationEvent) GetZoneEntered

func (x *SimulationEvent) GetZoneEntered() *ZoneEnteredEvent

func (*SimulationEvent) ProtoMessage

func (*SimulationEvent) ProtoMessage()

func (*SimulationEvent) ProtoReflect

func (x *SimulationEvent) ProtoReflect() protoreflect.Message

func (*SimulationEvent) Reset

func (x *SimulationEvent) Reset()

func (*SimulationEvent) String

func (x *SimulationEvent) String() string

type SimulationEvent_BulletHitTarget

type SimulationEvent_BulletHitTarget struct {
	BulletHitTarget *BulletHitTargetEvent `protobuf:"bytes,3,opt,name=bullet_hit_target,json=bulletHitTarget,proto3,oneof"`
}

type SimulationEvent_Death

type SimulationEvent_Death struct {
	Death *DeathEvent `protobuf:"bytes,7,opt,name=death,proto3,oneof"`
}

type SimulationEvent_HitByBullet

type SimulationEvent_HitByBullet struct {
	HitByBullet *HitByBulletEvent `protobuf:"bytes,2,opt,name=hit_by_bullet,json=hitByBullet,proto3,oneof"`
}

type SimulationEvent_HitRobot

type SimulationEvent_HitRobot struct {
	HitRobot *HitRobotEvent `protobuf:"bytes,5,opt,name=hit_robot,json=hitRobot,proto3,oneof"`
}

type SimulationEvent_HitWall

type SimulationEvent_HitWall struct {
	HitWall *HitWallEvent `protobuf:"bytes,4,opt,name=hit_wall,json=hitWall,proto3,oneof"`
}

type SimulationEvent_MatchFinished

type SimulationEvent_MatchFinished struct {
	MatchFinished *MatchFinishedEvent `protobuf:"bytes,8,opt,name=match_finished,json=matchFinished,proto3,oneof"`
}

type SimulationEvent_ZoneEntered

type SimulationEvent_ZoneEntered struct {
	ZoneEntered *ZoneEnteredEvent `protobuf:"bytes,6,opt,name=zone_entered,json=zoneEntered,proto3,oneof"`
}

type SimulationResponse

type SimulationResponse struct {
	Status MatchStatus `protobuf:"varint,1,opt,name=status,proto3,enum=codearena.v1.MatchStatus" json:"status,omitempty"`
	// contains filtered or unexported fields
}

func (*SimulationResponse) Descriptor deprecated

func (*SimulationResponse) Descriptor() ([]byte, []int)

Deprecated: Use SimulationResponse.ProtoReflect.Descriptor instead.

func (*SimulationResponse) GetStatus

func (x *SimulationResponse) GetStatus() MatchStatus

func (*SimulationResponse) ProtoMessage

func (*SimulationResponse) ProtoMessage()

func (*SimulationResponse) ProtoReflect

func (x *SimulationResponse) ProtoReflect() protoreflect.Message

func (*SimulationResponse) Reset

func (x *SimulationResponse) Reset()

func (*SimulationResponse) String

func (x *SimulationResponse) String() string

type SimulationServiceClient

type SimulationServiceClient interface {
	// External control for starting/stopping the engine
	StartSimulation(ctx context.Context, in *ArenaConfig, opts ...grpc.CallOption) (*SimulationResponse, error)
	StopSimulation(ctx context.Context, in *StopSimulationRequest, opts ...grpc.CallOption) (*SimulationResponse, error)
}

SimulationServiceClient is the client API for SimulationService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

type SimulationServiceServer

type SimulationServiceServer interface {
	// External control for starting/stopping the engine
	StartSimulation(context.Context, *ArenaConfig) (*SimulationResponse, error)
	StopSimulation(context.Context, *StopSimulationRequest) (*SimulationResponse, error)
	// contains filtered or unexported methods
}

SimulationServiceServer is the server API for SimulationService service. All implementations must embed UnimplementedSimulationServiceServer for forward compatibility.

type StartBotRequest

type StartBotRequest struct {
	BotId           string `protobuf:"bytes,1,opt,name=bot_id,json=botId,proto3" json:"bot_id,omitempty"`
	Image           string `protobuf:"bytes,2,opt,name=image,proto3" json:"image,omitempty"`                                            // Docker image or runtime environment identifier
	SourceCode      string `protobuf:"bytes,3,opt,name=source_code,json=sourceCode,proto3" json:"source_code,omitempty"`                // Code to execute (if applicable)
	EnvironmentVars string `protobuf:"bytes,4,opt,name=environment_vars,json=environmentVars,proto3" json:"environment_vars,omitempty"` // JSON string of env vars
	MatchId         string `protobuf:"bytes,5,opt,name=match_id,json=matchId,proto3" json:"match_id,omitempty"`
	GameServerUrl   string `protobuf:"bytes,6,opt,name=game_server_url,json=gameServerUrl,proto3" json:"game_server_url,omitempty"` // Where the bot should connect to
	// contains filtered or unexported fields
}

func (*StartBotRequest) Descriptor deprecated

func (*StartBotRequest) Descriptor() ([]byte, []int)

Deprecated: Use StartBotRequest.ProtoReflect.Descriptor instead.

func (*StartBotRequest) GetBotId

func (x *StartBotRequest) GetBotId() string

func (*StartBotRequest) GetEnvironmentVars

func (x *StartBotRequest) GetEnvironmentVars() string

func (*StartBotRequest) GetGameServerUrl

func (x *StartBotRequest) GetGameServerUrl() string

func (*StartBotRequest) GetImage

func (x *StartBotRequest) GetImage() string

func (*StartBotRequest) GetMatchId

func (x *StartBotRequest) GetMatchId() string

func (*StartBotRequest) GetSourceCode

func (x *StartBotRequest) GetSourceCode() string

func (*StartBotRequest) ProtoMessage

func (*StartBotRequest) ProtoMessage()

func (*StartBotRequest) ProtoReflect

func (x *StartBotRequest) ProtoReflect() protoreflect.Message

func (*StartBotRequest) Reset

func (x *StartBotRequest) Reset()

func (*StartBotRequest) String

func (x *StartBotRequest) String() string

type StartBotResponse

type StartBotResponse struct {
	ContainerId   string `protobuf:"bytes,1,opt,name=container_id,json=containerId,proto3" json:"container_id,omitempty"`
	Success       bool   `protobuf:"varint,2,opt,name=success,proto3" json:"success,omitempty"`
	ErrorMessage  string `protobuf:"bytes,3,opt,name=error_message,json=errorMessage,proto3" json:"error_message,omitempty"`
	Queued        bool   `protobuf:"varint,4,opt,name=queued,proto3" json:"queued,omitempty"`
	QueuePosition int32  `protobuf:"varint,5,opt,name=queue_position,json=queuePosition,proto3" json:"queue_position,omitempty"`
	// contains filtered or unexported fields
}

func (*StartBotResponse) Descriptor deprecated

func (*StartBotResponse) Descriptor() ([]byte, []int)

Deprecated: Use StartBotResponse.ProtoReflect.Descriptor instead.

func (*StartBotResponse) GetContainerId

func (x *StartBotResponse) GetContainerId() string

func (*StartBotResponse) GetErrorMessage

func (x *StartBotResponse) GetErrorMessage() string

func (*StartBotResponse) GetQueuePosition

func (x *StartBotResponse) GetQueuePosition() int32

func (*StartBotResponse) GetQueued

func (x *StartBotResponse) GetQueued() bool

func (*StartBotResponse) GetSuccess

func (x *StartBotResponse) GetSuccess() bool

func (*StartBotResponse) ProtoMessage

func (*StartBotResponse) ProtoMessage()

func (*StartBotResponse) ProtoReflect

func (x *StartBotResponse) ProtoReflect() protoreflect.Message

func (*StartBotResponse) Reset

func (x *StartBotResponse) Reset()

func (*StartBotResponse) String

func (x *StartBotResponse) String() string

type StopBotRequest

type StopBotRequest struct {
	BotId       string `protobuf:"bytes,1,opt,name=bot_id,json=botId,proto3" json:"bot_id,omitempty"`
	ContainerId string `protobuf:"bytes,2,opt,name=container_id,json=containerId,proto3" json:"container_id,omitempty"`
	// contains filtered or unexported fields
}

func (*StopBotRequest) Descriptor deprecated

func (*StopBotRequest) Descriptor() ([]byte, []int)

Deprecated: Use StopBotRequest.ProtoReflect.Descriptor instead.

func (*StopBotRequest) GetBotId

func (x *StopBotRequest) GetBotId() string

func (*StopBotRequest) GetContainerId

func (x *StopBotRequest) GetContainerId() string

func (*StopBotRequest) ProtoMessage

func (*StopBotRequest) ProtoMessage()

func (*StopBotRequest) ProtoReflect

func (x *StopBotRequest) ProtoReflect() protoreflect.Message

func (*StopBotRequest) Reset

func (x *StopBotRequest) Reset()

func (*StopBotRequest) String

func (x *StopBotRequest) String() string

type StopBotResponse

type StopBotResponse struct {
	Success bool `protobuf:"varint,1,opt,name=success,proto3" json:"success,omitempty"`
	// contains filtered or unexported fields
}

func (*StopBotResponse) Descriptor deprecated

func (*StopBotResponse) Descriptor() ([]byte, []int)

Deprecated: Use StopBotResponse.ProtoReflect.Descriptor instead.

func (*StopBotResponse) GetSuccess

func (x *StopBotResponse) GetSuccess() bool

func (*StopBotResponse) ProtoMessage

func (*StopBotResponse) ProtoMessage()

func (*StopBotResponse) ProtoReflect

func (x *StopBotResponse) ProtoReflect() protoreflect.Message

func (*StopBotResponse) Reset

func (x *StopBotResponse) Reset()

func (*StopBotResponse) String

func (x *StopBotResponse) String() string

type StopSimulationRequest

type StopSimulationRequest struct {
	MatchId string `protobuf:"bytes,1,opt,name=match_id,json=matchId,proto3" json:"match_id,omitempty"`
	// contains filtered or unexported fields
}

func (*StopSimulationRequest) Descriptor deprecated

func (*StopSimulationRequest) Descriptor() ([]byte, []int)

Deprecated: Use StopSimulationRequest.ProtoReflect.Descriptor instead.

func (*StopSimulationRequest) GetMatchId

func (x *StopSimulationRequest) GetMatchId() string

func (*StopSimulationRequest) ProtoMessage

func (*StopSimulationRequest) ProtoMessage()

func (*StopSimulationRequest) ProtoReflect

func (x *StopSimulationRequest) ProtoReflect() protoreflect.Message

func (*StopSimulationRequest) Reset

func (x *StopSimulationRequest) Reset()

func (*StopSimulationRequest) String

func (x *StopSimulationRequest) String() string

type UnimplementedBotServiceServer

type UnimplementedBotServiceServer struct{}

UnimplementedBotServiceServer must be embedded to have forward compatible implementations.

NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.

func (UnimplementedBotServiceServer) Connect

type UnimplementedMatchServiceServer

type UnimplementedMatchServiceServer struct{}

UnimplementedMatchServiceServer must be embedded to have forward compatible implementations.

NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.

func (UnimplementedMatchServiceServer) CreateMatch

func (UnimplementedMatchServiceServer) GetMatchHighlights

func (UnimplementedMatchServiceServer) GetMatchReplay

func (UnimplementedMatchServiceServer) ListActiveMatches

func (UnimplementedMatchServiceServer) ListMatches

func (UnimplementedMatchServiceServer) RegisterBot

func (UnimplementedMatchServiceServer) WatchMatch

type UnimplementedRuntimeServiceServer

type UnimplementedRuntimeServiceServer struct{}

UnimplementedRuntimeServiceServer must be embedded to have forward compatible implementations.

NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.

func (UnimplementedRuntimeServiceServer) GetRuntimeStats

func (UnimplementedRuntimeServiceServer) StartBot

func (UnimplementedRuntimeServiceServer) StopBot

type UnimplementedSimulationServiceServer

type UnimplementedSimulationServiceServer struct{}

UnimplementedSimulationServiceServer must be embedded to have forward compatible implementations.

NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.

func (UnimplementedSimulationServiceServer) StartSimulation

func (UnimplementedSimulationServiceServer) StopSimulation

type UnsafeBotServiceServer

type UnsafeBotServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeBotServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to BotServiceServer will result in compilation errors.

type UnsafeMatchServiceServer

type UnsafeMatchServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeMatchServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to MatchServiceServer will result in compilation errors.

type UnsafeRuntimeServiceServer

type UnsafeRuntimeServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeRuntimeServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to RuntimeServiceServer will result in compilation errors.

type UnsafeSimulationServiceServer

type UnsafeSimulationServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeSimulationServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to SimulationServiceServer will result in compilation errors.

type Vector3

type Vector3 struct {
	X float32 `protobuf:"fixed32,1,opt,name=x,proto3" json:"x,omitempty"`
	Y float32 `protobuf:"fixed32,2,opt,name=y,proto3" json:"y,omitempty"`
	Z float32 `protobuf:"fixed32,3,opt,name=z,proto3" json:"z,omitempty"`
	// contains filtered or unexported fields
}

Generic vector for 3D coordinates

func (*Vector3) Descriptor deprecated

func (*Vector3) Descriptor() ([]byte, []int)

Deprecated: Use Vector3.ProtoReflect.Descriptor instead.

func (*Vector3) GetX

func (x *Vector3) GetX() float32

func (*Vector3) GetY

func (x *Vector3) GetY() float32

func (*Vector3) GetZ

func (x *Vector3) GetZ() float32

func (*Vector3) ProtoMessage

func (*Vector3) ProtoMessage()

func (*Vector3) ProtoReflect

func (x *Vector3) ProtoReflect() protoreflect.Message

func (*Vector3) Reset

func (x *Vector3) Reset()

func (*Vector3) String

func (x *Vector3) String() string

type WorldState

type WorldState struct {
	Tick    int64              `protobuf:"varint,1,opt,name=tick,proto3" json:"tick,omitempty"`
	Status  MatchStatus        `protobuf:"varint,2,opt,name=status,proto3,enum=codearena.v1.MatchStatus" json:"status,omitempty"`
	Bots    []*BotState        `protobuf:"bytes,3,rep,name=bots,proto3" json:"bots,omitempty"`
	Events  []*SimulationEvent `protobuf:"bytes,4,rep,name=events,proto3" json:"events,omitempty"`
	Bullets []*BulletState     `protobuf:"bytes,5,rep,name=bullets,proto3" json:"bullets,omitempty"`
	Zone    *ZoneState         `protobuf:"bytes,6,opt,name=zone,proto3" json:"zone,omitempty"`
	// contains filtered or unexported fields
}

A single tick of the world

func (*WorldState) Descriptor deprecated

func (*WorldState) Descriptor() ([]byte, []int)

Deprecated: Use WorldState.ProtoReflect.Descriptor instead.

func (*WorldState) GetBots

func (x *WorldState) GetBots() []*BotState

func (*WorldState) GetBullets

func (x *WorldState) GetBullets() []*BulletState

func (*WorldState) GetEvents

func (x *WorldState) GetEvents() []*SimulationEvent

func (*WorldState) GetStatus

func (x *WorldState) GetStatus() MatchStatus

func (*WorldState) GetTick

func (x *WorldState) GetTick() int64

func (*WorldState) GetZone

func (x *WorldState) GetZone() *ZoneState

func (*WorldState) ProtoMessage

func (*WorldState) ProtoMessage()

func (*WorldState) ProtoReflect

func (x *WorldState) ProtoReflect() protoreflect.Message

func (*WorldState) Reset

func (x *WorldState) Reset()

func (*WorldState) String

func (x *WorldState) String() string

type Zone

type Zone struct {
	Id        string   `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Position  *Vector3 `protobuf:"bytes,2,opt,name=position,proto3" json:"position,omitempty"`
	Radius    float32  `protobuf:"fixed32,3,opt,name=radius,proto3" json:"radius,omitempty"`
	Type      string   `protobuf:"bytes,4,opt,name=type,proto3" json:"type,omitempty"` // HEAL, ENERGY, HAZARD
	Intensity float32  `protobuf:"fixed32,5,opt,name=intensity,proto3" json:"intensity,omitempty"`
	// contains filtered or unexported fields
}

func (*Zone) Descriptor deprecated

func (*Zone) Descriptor() ([]byte, []int)

Deprecated: Use Zone.ProtoReflect.Descriptor instead.

func (*Zone) GetId

func (x *Zone) GetId() string

func (*Zone) GetIntensity

func (x *Zone) GetIntensity() float32

func (*Zone) GetPosition

func (x *Zone) GetPosition() *Vector3

func (*Zone) GetRadius

func (x *Zone) GetRadius() float32

func (*Zone) GetType

func (x *Zone) GetType() string

func (*Zone) ProtoMessage

func (*Zone) ProtoMessage()

func (*Zone) ProtoReflect

func (x *Zone) ProtoReflect() protoreflect.Message

func (*Zone) Reset

func (x *Zone) Reset()

func (*Zone) String

func (x *Zone) String() string

type ZoneEnteredEvent

type ZoneEnteredEvent struct {
	BotId  string `protobuf:"bytes,1,opt,name=bot_id,json=botId,proto3" json:"bot_id,omitempty"`
	ZoneId string `protobuf:"bytes,2,opt,name=zone_id,json=zoneId,proto3" json:"zone_id,omitempty"`
	Type   string `protobuf:"bytes,3,opt,name=type,proto3" json:"type,omitempty"`
	// contains filtered or unexported fields
}

func (*ZoneEnteredEvent) Descriptor deprecated

func (*ZoneEnteredEvent) Descriptor() ([]byte, []int)

Deprecated: Use ZoneEnteredEvent.ProtoReflect.Descriptor instead.

func (*ZoneEnteredEvent) GetBotId

func (x *ZoneEnteredEvent) GetBotId() string

func (*ZoneEnteredEvent) GetType

func (x *ZoneEnteredEvent) GetType() string

func (*ZoneEnteredEvent) GetZoneId

func (x *ZoneEnteredEvent) GetZoneId() string

func (*ZoneEnteredEvent) ProtoMessage

func (*ZoneEnteredEvent) ProtoMessage()

func (*ZoneEnteredEvent) ProtoReflect

func (x *ZoneEnteredEvent) ProtoReflect() protoreflect.Message

func (*ZoneEnteredEvent) Reset

func (x *ZoneEnteredEvent) Reset()

func (*ZoneEnteredEvent) String

func (x *ZoneEnteredEvent) String() string

type ZoneState

type ZoneState struct {
	X      float32 `protobuf:"fixed32,1,opt,name=x,proto3" json:"x,omitempty"`
	Y      float32 `protobuf:"fixed32,2,opt,name=y,proto3" json:"y,omitempty"`
	Radius float32 `protobuf:"fixed32,3,opt,name=radius,proto3" json:"radius,omitempty"`
	// contains filtered or unexported fields
}

func (*ZoneState) Descriptor deprecated

func (*ZoneState) Descriptor() ([]byte, []int)

Deprecated: Use ZoneState.ProtoReflect.Descriptor instead.

func (*ZoneState) GetRadius

func (x *ZoneState) GetRadius() float32

func (*ZoneState) GetX

func (x *ZoneState) GetX() float32

func (*ZoneState) GetY

func (x *ZoneState) GetY() float32

func (*ZoneState) ProtoMessage

func (*ZoneState) ProtoMessage()

func (*ZoneState) ProtoReflect

func (x *ZoneState) ProtoReflect() protoreflect.Message

func (*ZoneState) Reset

func (x *ZoneState) Reset()

func (*ZoneState) String

func (x *ZoneState) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL