public object this[string propertyName]
get { return this.GetType().GetProperty(propertyName).GetValue(this, null); }
set { this.GetType().GetProperty(propertyName).SetValue(this, value, null); }
public float Health { get; set; }
public static void Main()
Character my_character = new Character();
my_character["Health"] = 100.0f;
Console.WriteLine("Value of float is " + my_character["Health"]);