mirror of
https://github.com/misternebula/quantum-space-buddies.git
synced 2025-01-30 03:32:47 +00:00
goodify config
This commit is contained in:
parent
b4c18c9e3d
commit
cf9d5a5529
@ -241,9 +241,9 @@ public class QSBCore : ModBehaviour
|
|||||||
|
|
||||||
public override void Configure(IModConfig config)
|
public override void Configure(IModConfig config)
|
||||||
{
|
{
|
||||||
DefaultServerIP = config.GetSettingsValue<string>("defaultServerIP");
|
DefaultServerIP = config.GetSettingsValue<string>("Default Server IP");
|
||||||
IncompatibleModsAllowed = config.GetSettingsValue<bool>("incompatibleModsAllowed");
|
IncompatibleModsAllowed = config.GetSettingsValue<bool>("Incompatible Mods Allowed");
|
||||||
ShipDamage = config.GetSettingsValue<bool>("shipDamage");
|
ShipDamage = config.GetSettingsValue<bool>("Ship Damage");
|
||||||
}
|
}
|
||||||
|
|
||||||
private void Update()
|
private void Update()
|
||||||
|
@ -270,7 +270,7 @@ public class QSBNetworkManager : NetworkManager, IAddComponentOnStart
|
|||||||
{
|
{
|
||||||
QSBCore.DefaultServerIP = networkAddress;
|
QSBCore.DefaultServerIP = networkAddress;
|
||||||
var config = QSBCore.Helper.Config;
|
var config = QSBCore.Helper.Config;
|
||||||
config.SetSettingsValue("defaultServerIP", networkAddress);
|
config.SetSettingsValue("Default Server IP", networkAddress);
|
||||||
QSBCore.Helper.Storage.Save(config, Constants.ModConfigFileName);
|
QSBCore.Helper.Storage.Save(config, Constants.ModConfigFileName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,8 +1,20 @@
|
|||||||
{
|
{
|
||||||
"enabled": true,
|
"enabled": true,
|
||||||
"settings": {
|
"settings": {
|
||||||
"defaultServerIP": "localhost",
|
"Default Server IP": {
|
||||||
"incompatibleModsAllowed": false,
|
"type": "text",
|
||||||
"shipDamage": true
|
"value": "localhost",
|
||||||
|
"tooltip": "The last entered IP/ID. Used if you leave the connect prompt blank."
|
||||||
|
},
|
||||||
|
"Incompatible Mods Allowed": {
|
||||||
|
"type": "toggle",
|
||||||
|
"value": false,
|
||||||
|
"tooltip": "Kicks players if they have certain mods."
|
||||||
|
},
|
||||||
|
"Ship Damage": {
|
||||||
|
"type": "toggle",
|
||||||
|
"value": true,
|
||||||
|
"tooltip": "Take impact damage when inside the ship."
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
x
Reference in New Issue
Block a user