/// <summary> /// /// </summary> /// <param name="whichFarm"></param> public void LoadCustomFarm(int whichFarm) { Canon = FarmManager.Load(whichFarm); if (!Canon) { GreenhouseManager.LinkToFarm(FarmManager.LoadedFarm); } }
/// <summary> /// Populates the List<CustomFarm> FarmList variable with all the Content Packs /// registered to MTN. /// </summary> /// <param name="helper">SMAPI's IModHelper, to load in the Content Packs</param> /// <param name="monitor">SMAPI's IMonitor, to print useful information</param> public void Populate(IModHelper helper, IMonitor monitor) { foreach (IContentPack contentPack in helper.ContentPacks.GetOwned()) { monitor.Log($"Reading content pack: {contentPack.Manifest.Name} {contentPack.Manifest.Version}."); FarmManager.Populate(helper, contentPack, monitor); GreenhouseManager.Populate(contentPack, monitor); } return; }
/// <summary> /// Gets the Asset Key of the Base Farm Map. Only does work on the base /// farm map of any custom map. /// </summary> /// <param name="map">The base farm map, loaded.</param> /// <returns>The Actual Asset Key</returns> public string GetAssetKey(out Map map, string type) { switch (type) { case "Farm": return(FarmManager.GetAssetKey(out map)); case "Greenhouse": return(GreenhouseManager.GetAssetKey(out map)); default: map = null; return(null); } }
public float GreenHouseLayerDepth() { return(GreenhouseManager.GreenHouseLayerDepth(Canon)); }
public Vector2 GreenHouseCoords() { return(GreenhouseManager.GreenHouseCoords(Canon)); }