Game.UI.InGame.CompanyProfitabilityKey
Assembly: Assembly-CSharp
Namespace: Game.UI.InGame
Type: enum
Base: System.Enum
Summary:
Represents discrete profitability states used by the in-game UI to indicate a company's financial condition. Typically used by UI components to choose icons, colors, tooltips or other visual indicators that convey whether an entity (company) is operating at a loss, breaking even, or making a profit. {{ This enum contains five ordered states from worst (Bankrupt) to best (Profitable). Values are the default enum integer values 0–4 unless otherwise overridden in the game assembly. }}
Fields
-
Bankrupt
{{ Value = 0. Indicates the company is insolvent or effectively out of business; UI should show a severe negative indicator. }} -
LosingMoney
{{ Value = 1. Indicates the company is operating at a loss; UI should show a negative indicator. }} -
BreakingEven
{{ Value = 2. Indicates revenue roughly equals expenses; UI should show a neutral indicator. }} -
GettingBy
{{ Value = 3. Indicates a small or modest profit; UI should show a slightly positive indicator. }} -
Profitable
{{ Value = 4. Indicates the company is in healthy profit; UI should show a strong positive indicator. }}
Properties
- None.
{{ This is a plain enum type and does not expose properties. }}
Constructors
- None (the enum has the implicit private constructor).
{{ Enums do not define public constructors. Use cast or assignment from the enum values. }}
Methods
- None (no instance or static methods defined on this enum).
{{ Use standard System.Enum methods if needed (e.g., ToString(), Enum.GetValues(), Enum.IsDefined()). }}
Usage Example
// Example: map CompanyProfitabilityKey to a UI sprite name or color
private string GetProfitabilityIconName(Game.UI.InGame.CompanyProfitabilityKey key)
{
switch (key)
{
case Game.UI.InGame.CompanyProfitabilityKey.Bankrupt:
return "icon_profit_bankrupt";
case Game.UI.InGame.CompanyProfitabilityKey.LosingMoney:
return "icon_profit_negative";
case Game.UI.InGame.CompanyProfitabilityKey.BreakingEven:
return "icon_profit_neutral";
case Game.UI.InGame.CompanyProfitabilityKey.GettingBy:
return "icon_profit_small_positive";
case Game.UI.InGame.CompanyProfitabilityKey.Profitable:
return "icon_profit_positive";
default:
return "icon_profit_unknown";
}
}
{{ TIPS: Use this enum to drive UI logic (icons, colors, tooltips). If you need thresholds (percent profit/loss) map your numeric calculations to these enum values in your simulation or presentation layer. Verify actual assembly name in your mod context — common decompiled location is Assembly-CSharp.dll. }}