1. Hi there.
    Then I try to get float value from config I getting this error:
    InvalidCastException: Cannot cast from source type to destination type.
    Code:
    CraftTimeDecreasePerLevel = (float) Config["CraftDecrease"];
    That happens only to float values.
    Thanks in advance.
     
  2. Config.Get<float>("CraftDecrease");
     
  3. Thanks! But really, what is wrong with that cast?
     
  4. If you did: float floatN =(float) (int) ConfigVariable; it would of worked too. Atleast if it was represented internally as an int.

    I don't have the time to explain how cast works from a mobile phone so that is my simple explanation.
     
  5. Thanks!)
     
  6. Wouldn't that strip the digits?