Class CarRacingEnv.RoadTile
- Namespace
- Gym.Environments.Envs.Box2D
- Assembly
- Gym.Environments.dll
A track tile: its static sensor body and the attributes Gymnasium hangs on it (color, road_visited,
road_friction, idx). The body's user data is this object, as Python's t.userData = t lets the
FrictionDetector recognize a tile.
public sealed class CarRacingEnv.RoadTile
- Inheritance
-
CarRacingEnv.RoadTile
- Inherited Members
- Extension Methods
Properties
Body
The tile's static body.
public b2Body Body { get; }
Property Value
Color
Python's color: the road colour plus the tile's shade, a float64 array the env's road_poly shares;
the contact listener overwrites it in place with the road colour when anything touches the tile.
public double[] Color { get; }
Property Value
- double[]
Idx
Python's idx: the tile's position on the track (0 is the start).
public long Idx { get; set; }
Property Value
RoadFriction
Python's road_friction: the friction factor a wheel on the tile gets (1.0).
public double RoadFriction { get; set; }
Property Value
RoadVisited
Python's road_visited: whether a wheel has touched the tile this episode.
public bool RoadVisited { get; set; }