Game.Simulation.TaxiRequestType
Assembly: Assembly-CSharp (game code)
Namespace: Game.Simulation
Type: enum (byte)
Base: System.Enum (underlying type: System.Byte)
Summary:
Represents the different origins/types of a taxi request in the simulation. The enum uses a byte-sized underlying type and includes a sentinel value (None) set to byte.MaxValue to represent an invalid/absent request type. Typical uses: categorizing requests coming from taxi stands, in-map customers, or outside the map for routing, pricing, or dispatch logic.
Fields
-
Stand = 0
Represents a taxi request originating from a taxi stand. -
Customer = 1
Represents a taxi request made by an in-map customer (individual passengers requesting pickup). -
Outside = 2
Represents a taxi request coming from outside the map (external sources, e.g., visitors entering the city). -
None = byte.MaxValue
Sentinel/invalid value indicating no request or an uninitialized/unknown type. Implementations commonly check for this value to detect the absence of a valid request type.
Properties
- This enum type does not define properties. It only provides the named constant values listed above.
Constructors
- Enums do not define public constructors. Instances are represented by their underlying byte value; e.g., (TaxiRequestType)0 == TaxiRequestType.Stand.
Methods
- This enum does not define methods. Standard System.Enum operations (ToString, HasFlag, etc.) are available.
Usage Example
// Determine behavior based on request type
TaxiRequestType reqType = TaxiRequestType.Customer;
switch (reqType)
{
case TaxiRequestType.Stand:
// dispatch taxi from stand pool
break;
case TaxiRequestType.Customer:
// send nearest available taxi to customer position
break;
case TaxiRequestType.Outside:
// handle arrival logistics for outside pick-ups
break;
case TaxiRequestType.None:
default:
// ignore or log invalid/unset request type
break;
}