DatabaseService and other fixes
This commit is contained in:
@@ -63,4 +63,22 @@ public class Locations
|
||||
/** Holds a mapping of the linkages between locations on the UI */
|
||||
[JsonPropertyName("base")]
|
||||
public LocationsBase? Base { get; set; }
|
||||
|
||||
public Eft.Common.Location? this[string key]
|
||||
{
|
||||
get
|
||||
{
|
||||
return (Eft.Common.Location?) GetType()
|
||||
.GetProperties()
|
||||
.First(p => p.Name.ToLower() == key.ToLower()).GetGetMethod()?
|
||||
.Invoke(this, null) ?? null;
|
||||
}
|
||||
set
|
||||
{
|
||||
GetType()
|
||||
.GetProperties()
|
||||
.First(p => p.Name.ToLower() == key.ToLower()).GetSetMethod()?
|
||||
.Invoke(this, [value]);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -37,7 +37,7 @@ public class Templates
|
||||
|
||||
/** Flea prices of items - gathered from online flea market dump */
|
||||
[JsonPropertyName("prices")]
|
||||
public Dictionary<string, decimal> Prices { get; set; }
|
||||
public Dictionary<string, double> Prices { get; set; }
|
||||
|
||||
/** Default equipment loadouts that show on main inventory screen */
|
||||
[JsonPropertyName("defaultEquipmentPresets")]
|
||||
|
||||
Reference in New Issue
Block a user