Skip to main content
Verticopolis engineGitHub

FacilityEntry

Struct FacilityEntry 

Source
pub struct FacilityEntry {
Show 36 fields pub key: &'static str, pub name: &'static str, pub category: &'static str, pub width: i64, pub floors: i64, pub cost: f64, pub pays_for_floor: bool, pub min_star: i64, pub population: i64, pub max_household: Option<i64>, pub attendance: Option<i64>, pub modern_only: bool, pub transport: bool, pub staff_only: bool, pub basement: bool, pub no_basement: bool, pub available: bool, pub build_minutes: f64, pub resale_refund: f64, pub build_cap: Option<i64>, pub pool: Option<&'static str>, pub max_span: Option<i64>, pub fixed_span: bool, pub max_cars: Option<i64>, pub car_capacity: Option<f64>, pub subtypes: Option<Vec<&'static str>>, pub rent: Option<Rent>, pub daily_income: Option<f64>, pub spend_per_customer: Option<f64>, pub upkeep_monthly: Option<f64>, pub open_hours: Option<Vec<bool>>, pub own_household: bool, pub commercial: bool, pub hotel: bool, pub lease_amenity: bool, pub unmet_demand: bool,
}
Expand description

One facility kind, resolved for the catalog’s mode.

Fields§

§key: &'static str

The key saves and commands name the kind by.

§name: &'static str

The name a player sees, such as Fast Food.

§category: &'static str

structure, transport, office, residential, hotel, food, retail, entertainment, service or special.

§width: i64

Width in tiles. A transport’s width is its shaft’s.

§floors: i64

Height in floors (1 for an ordinary room, and 1 for a transport, whose height is its span).

§cost: f64

The build price. An elevator adds transportFloorCost for each floor past its first (top minus bottom). A room adds the floor’s price for every floor tile laid under it, and so does a kind that pays for its floor (paysForFloor) placed where there is no floor yet. With automatic bridging on, every gap tile bridged to the tower adds one substrate tile: the lobby’s price plus the floor’s when placing a lobby (on any floor), the floor’s price for a floor tile or a room.

§pays_for_floor: bool

Whether a tile of this kind placed where there is no floor yet also pays the floor’s price, for the floor it lays (the lobby). Over a floor tile it pays cost alone.

§min_star: i64

The star rating that unlocks it.

§population: i64

The people it holds (tenants, residents or customers at a time).

§max_household: Option<i64>

The largest generated household size for this kind, or null.

§attendance: Option<i64>

The audience an attendance venue seats, or null.

§modern_only: bool

Only Modern games build it.

§transport: bool

An elevator, stairs or an escalator.

§staff_only: bool

A staff-only transport (the service elevator).

§basement: bool

Built underground only.

§no_basement: bool

Never built underground.

§available: bool

Whether this mode can build it at all (the star gate aside).

§build_minutes: f64

In-game minutes of construction (0 for structure and for transports, which work as soon as they are placed).

§resale_refund: f64

What selling it refunds (a gutted unit refunds nothing).

§build_cap: Option<i64>

The most a tower may hold of this kind alone, or null when uncapped.

§pool: Option<&'static str>

The PoolEntry::key of the cap it shares, or null.

§max_span: Option<i64>

For a transport, the largest top floor minus bottom floor it may have, else null. It serves maxSpan + 1 floors: stairs and escalators have 1 and link two floors.

§fixed_span: bool

For a transport, whether it is a fixed two-floor unit placed with one tap and never resized (stairs, escalators).

§max_cars: Option<i64>

For an elevator, the most cars a shaft takes, else null.

§car_capacity: Option<f64>

For a transport, the passengers one car (or one flight) carries, else null.

§subtypes: Option<Vec<&'static str>>

The varieties a new unit draws from, in the engine’s order, or null.

§rent: Option<Rent>

How the player prices it in this mode, or null when its price is not player-set.

§daily_income: Option<f64>

A trading venue’s headline daily take in this mode, or null: the ceiling the money loop pays a sold-out venue.

§spend_per_customer: Option<f64>

The average ticket per customer the engine counts customers with, for the venues that track them in this mode (those with subtypes and a daily income), else null.

§upkeep_monthly: Option<f64>

A service facility’s monthly maintenance, or null.

§open_hours: Option<Vec<bool>>

Whether it is open in each hour of the day, 0 to 23, for a kind that keeps business hours (hasBusinessHours), else null (always open).

§own_household: bool

Whether a unit may carry its own household size (residents), which then stands in for population; a condo’s price scales with it against the condo’s population (householdPrice).

§commercial: bool

A foot-traffic trading kind: the one predicate the noise and lobby-proximity rules key off (isCommercial).

§hotel: bool

A hotel room of any size.

§lease_amenity: bool

A Modern lease amenity (fitness club, clinic): lease tenants that erode on unserved placement and an over-market rent.

§unmet_demand: bool

A demand tenant whose unmet coverage drains satisfaction.

Trait Implementations§

Source§

impl Clone for FacilityEntry

Source§

fn clone(&self) -> FacilityEntry

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for FacilityEntry

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl PartialEq for FacilityEntry

Source§

fn eq(&self, other: &FacilityEntry) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Serialize for FacilityEntry

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl StructuralPartialEq for FacilityEntry

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.