use geom::{Angle, Distance, PolyLine, Pt2D};
use map_model::{BuildingID, ParkingLotID, Traversable, TurnID};
use crate::{AgentID, CarID, PedestrianID, PersonID};
#[derive(Clone)]
pub struct DrawPedestrianInput {
pub id: PedestrianID,
pub pos: Pt2D,
pub facing: Angle,
pub waiting_for_turn: Option<TurnID>,
pub intent: Option<Intent>,
pub preparing_bike: bool,
pub waiting_for_bus: bool,
pub on: Traversable,
pub person: PersonID,
}
pub struct DrawPedCrowdInput {
pub low: Distance,
pub high: Distance,
pub members: Vec<PedestrianID>,
pub location: PedCrowdLocation,
}
#[derive(Clone)]
pub enum PedCrowdLocation {
Sidewalk(Traversable, bool),
BldgDriveway(BuildingID),
LotDriveway(ParkingLotID),
}
#[derive(Clone)]
pub struct DrawCarInput {
pub id: CarID,
pub waiting_for_turn: Option<TurnID>,
pub status: CarStatus,
pub intent: Option<Intent>,
pub on: Traversable,
pub partly_on: Vec<Traversable>,
pub label: Option<String>,
pub person: Option<PersonID>,
pub body: PolyLine,
}
#[derive(Clone, Copy, PartialEq, Eq)]
pub enum CarStatus {
Moving,
Parked,
}
#[derive(Clone, PartialEq)]
pub enum Intent {
Parking,
SteepUphill,
}
pub struct UnzoomedAgent {
pub id: AgentID,
pub pos: Pt2D,
pub person: Option<PersonID>,
pub parking: bool,
}