Skip to content

Game.Prefabs.LandValueParameterData

Assembly: Assembly-CSharp.dll
Namespace: Game.Prefabs

Type: struct

Base: Implements Unity.Entities.IComponentData, Unity.Entities.IQueryTypeParameter

Summary:
Data container used by the game's ECS to configure how land value is calculated and presented. Holds a prefab reference for the land value info view, a baseline land value, a set of multipliers used to compute bonuses from coverage/services/transport/attractiveness, and penalty multipliers for various pollution types. This struct is intended to be attached to entities (or used as a query parameter) so systems can read configuration values for land-value-related calculations and UI.


Fields

  • public Entity m_LandValueInfoViewPrefab
    Reference to an Entity prefab used to display land value information (e.g., UI or world view). Typically set to a prefab that will be instantiated or referenced by UI systems.

  • public float m_LandValueBaseline
    Base land value used as the starting point for calculations before applying bonuses and penalties.

  • public float m_HealthCoverageBonusMultiplier
    Multiplier applied to the health coverage contribution when computing land value bonuses from healthcare availability.

  • public float m_EducationCoverageBonusMultiplier
    Multiplier applied to the education coverage contribution when computing land value bonuses from education services.

  • public float m_PoliceCoverageBonusMultiplier
    Multiplier applied to the police coverage contribution when computing land value bonuses from police presence/coverage.

  • public float m_AttractivenessBonusMultiplier
    Multiplier applied to attractiveness-related contributions (scenery, parks, lot attractiveness) when computing land value.

  • public float m_TelecomCoverageBonusMultiplier
    Multiplier applied to telecom/internet coverage contributions to land value.

  • public float m_CommercialServiceBonusMultiplier
    Multiplier applied to commercial service availability when computing land value bonuses for commercial zones or areas.

  • public float m_TramSubwayBonusMultiplier
    Multiplier for public-transport access via tram/subway; increases land value where tram or subway coverage is present.

  • public float m_BusBonusMultiplier
    Multiplier for bus service coverage; contributes to land value where bus service is available.

  • public float m_CommonFactorMaxBonus
    Maximum cap for combined common bonuses (prevents bonuses from growing unbounded when multiple sources overlap). Use to clamp the aggregate bonus contribution.

  • public float m_GroundPollutionPenaltyMultiplier
    Penalty multiplier applied to land value for ground pollution (e.g., soil contamination, industrial ground pollution).

  • public float m_AirPollutionPenaltyMultiplier
    Penalty multiplier applied to land value for air pollution levels.

  • public float m_NoisePollutionPenaltyMultiplier
    Penalty multiplier applied to land value for noise pollution.

Properties

  • This struct does not define any properties. It exposes public fields only.

Constructors

  • public LandValueParameterData()
    Default value-type constructor (auto-generated). When instantiated without explicit values, numeric fields will be 0 and the Entity field will be Entity.Null. Typical usage is to populate fields explicitly or assign this struct via authoring/conversion code or a configuration system.

Methods

  • This struct does not define any methods. It is a pure data container used by systems that read these fields during land-value calculations and UI updates.

Usage Example

// Example: create and assign LandValueParameterData to an entity with EntityManager
var landValueData = new Game.Prefabs.LandValueParameterData
{
    m_LandValueInfoViewPrefab = myLandValuePrefabEntity,
    m_LandValueBaseline = 50f,
    m_HealthCoverageBonusMultiplier = 1.2f,
    m_EducationCoverageBonusMultiplier = 1.1f,
    m_PoliceCoverageBonusMultiplier = 1.05f,
    m_AttractivenessBonusMultiplier = 1.3f,
    m_TelecomCoverageBonusMultiplier = 1.0f,
    m_CommercialServiceBonusMultiplier = 1.0f,
    m_TramSubwayBonusMultiplier = 1.15f,
    m_BusBonusMultiplier = 1.05f,
    m_CommonFactorMaxBonus = 2.0f,
    m_GroundPollutionPenaltyMultiplier = 0.8f,
    m_AirPollutionPenaltyMultiplier = 0.75f,
    m_NoisePollutionPenaltyMultiplier = 0.85f
};

Entity configEntity = entityManager.CreateEntity();
entityManager.AddComponentData(configEntity, landValueData);

// Systems can now query for LandValueParameterData to apply these values