Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 50 additions & 0 deletions NegativeRelations/IGenericModConfigMenuApi.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
using System;
using StardewModdingAPI;

namespace NegativeRelations
{
/// <summary>
/// Minimal GMCM API used by this mod.
/// </summary>
public interface IGenericModConfigMenuApi
{
void Register(IManifest mod, Action reset, Action save, bool titleScreenOnly = false);

void AddSectionTitle(IManifest mod, Func<string> text, Func<string> tooltip = null);

void AddNumberOption(
IManifest mod,
Func<int> getValue,
Action<int> setValue,
Func<string> name,
Func<string> tooltip = null,
int? min = null,
int? max = null,
int? interval = null,
Func<int, string> formatValue = null,
string fieldId = null
);

void AddBoolOption(
IManifest mod,
Func<bool> getValue,
Action<bool> setValue,
Func<string> name,
Func<string> tooltip = null,
string fieldId = null
);

void AddNumberOption(
IManifest mod,
Func<float> getValue,
Action<float> setValue,
Func<string> name,
Func<string> tooltip = null,
float? min = null,
float? max = null,
float? interval = null,
Func<float, string> formatValue = null,
string fieldId = null
);
}
}
21 changes: 21 additions & 0 deletions NegativeRelations/ModConfig.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
namespace NegativeRelations
{
public class ModConfig
{
public bool EnableMod { get; set; } = true;

public int RecoveryPerDay { get; set; } = 5;

public int BarkRadiusTiles { get; set; } = 3;

public float BarkChance { get; set; } = 0.08f;

public int BarkCooldownMinutes { get; set; } = 8;

public float TalkOverrideChance { get; set; } = 0.30f;

public bool EnableBarks { get; set; } = true;

public bool EnableTalkOverride { get; set; } = true;
}
}
Loading