Show / Hide Table of Contents

Class InitialPosition

Initial starting position containing a start coordinate (x,y) and angle.

The initial position is only used when debugging to request the server to let a bot start at a specific position. Note that initial starting positions must be enabled at the server-side; otherwise the initial starting position is ignored.

Inheritance
object
InitialPosition
Inherited Members
object.Equals(object, object)
object.GetType()
object.ReferenceEquals(object, object)
Namespace: Robocode.TankRoyale.BotApi
Assembly: api.dll
Syntax
[PublicAPI]
public sealed class InitialPosition

Constructors

| Edit this page View Source

InitialPosition(double?, double?, double?)

Initializes a new instance of the InitialPosition class.

Declaration
public InitialPosition(double? x, double? y, double? direction)
Parameters
Type Name Description
double? x

The x coordinate, where null means it is random.

double? y

The x coordinate, where null means it is random.

double? direction

The shared direction of the body, gun, and radar, where null means it is random.

Properties

| Edit this page View Source

Direction

The shared direction of the body, gun, and radar.

Declaration
public double? Direction { get; }
Property Value
Type Description
double?
| Edit this page View Source

X

The x coordinate.

Declaration
public double? X { get; }
Property Value
Type Description
double?
| Edit this page View Source

Y

The Y coordinate.

Declaration
public double? Y { get; }
Property Value
Type Description
double?

Methods

| Edit this page View Source

Equals(object)

Determines whether the specified object is equal to the current object.

Declaration
public override bool Equals(object obj)
Parameters
Type Name Description
object obj

The object to compare with the current object.

Returns
Type Description
bool

true if the specified object is equal to the current object; otherwise, false.

Overrides
object.Equals(object)
| Edit this page View Source

FromString(string)

Declaration
public static InitialPosition FromString(string initialPosition)
Parameters
Type Name Description
string initialPosition
Returns
Type Description
InitialPosition
| Edit this page View Source

GetHashCode()

Serves as the default hash function.

Declaration
public override int GetHashCode()
Returns
Type Description
int

A hash code for the current object.

Overrides
object.GetHashCode()
| Edit this page View Source

ToString()

Returns a string that represents the current object.

Declaration
public override string ToString()
Returns
Type Description
string

A string that represents the current object.

Overrides
object.ToString()
  • Edit this page
  • View Source
In this article
Back to top Generated by DocFX