1
0
mirror of https://github.com/soarqin/DSP_Mods.git synced 2025-12-09 00:53:39 +08:00

Auto-config logistic stations: Can set Max. Charging Power for Battlefield Analysis Base now.

This commit is contained in:
2025-05-04 00:52:42 +08:00
parent b060204d80
commit 586ce9a427
6 changed files with 69 additions and 32 deletions

View File

@@ -4,12 +4,15 @@
## Changlog ## Changlog
* 1.3.3 * 1.3.3
+ Starmap filter: Hide top overlaping windows while the filter UI is shown.
+ `Auto-config logistic stations`: Can set Max. Charging Power for Battlefield Analysis Base now.
+ `Re-initialize planet`: Fix a crash. + `Re-initialize planet`: Fix a crash.
+ `Auto navigation on sailings`: Do not auto-use Warper if required Tech is not researched. + `Auto navigation on sailings`: Do not auto-use Warper if required Tech is not researched.
+ Starmap filter: Hide top overlaping windows while the filter UI is shown.
+ `Dismantle blueprint selected buildings`: Fix an issue that belt connected buildings are dismantled unexpectly. + `Dismantle blueprint selected buildings`: Fix an issue that belt connected buildings are dismantled unexpectly.
+ `Mod manager profile based save folder`: Fix compatibility with [SaveTheWindows](https://thunderstore.io/c/dyson-sphere-program/p/starfi5h/SaveTheWindows/). + `Mod manager profile based save folder`: Fix compatibility with [SaveTheWindows](https://thunderstore.io/c/dyson-sphere-program/p/starfi5h/SaveTheWindows/).
+ `Allow overflow for Logistic Stations and Advanced Mining Machines`: Surpass maximum storage limit is not allowed on pasting blueprints. + `Enhanced control for logistic storage capacities` & `Allow overflow for Logistic Stations and Advanced Mining Machines`:
- Logistic storage capacities are not scaled on upgrading `Logistics Carrier Capacity`, if they are already greater than upgraded maximum capacity.
- Logistic storage capacities will be reduced to tech capacity limits on pasting blueprints.
+ `Real-time logistic stations info panel`: Support for mods that change slot count of logistic stations. + `Real-time logistic stations info panel`: Support for mods that change slot count of logistic stations.
* 1.3.2 * 1.3.2
+ New feature: `Disable battle-related techs in Peace mode` + New feature: `Disable battle-related techs in Peace mode`
@@ -68,7 +71,7 @@
+ Fix compatibility with game update 0.10.32.25779 + Fix compatibility with game update 0.10.32.25779
* 1.2.15 * 1.2.15
+ `Off-grid building and stepped rotation`: Fix compatibility with DSP 0.10.32.25682. (#57) + `Off-grid building and stepped rotation`: Fix compatibility with DSP 0.10.32.25682. (#57)
+ `Enhanced control for logistic storage limits`: Try to fix possible crash. (#54) + `Enhanced control for logistic storage capacities`: Try to fix possible crash. (#54)
* 1.2.14 * 1.2.14
+ Fix an issue that an unexpected menu icon is shown in the top-right corner of the config panel. + Fix an issue that an unexpected menu icon is shown in the top-right corner of the config panel.
+ `Stop ejectors when available nodes are all filled up`: Fix compatibility with `Dyson Sphere Program v0.10.32.25496`. + `Stop ejectors when available nodes are all filled up`: Fix compatibility with `Dyson Sphere Program v0.10.32.25496`.
@@ -199,8 +202,8 @@
+ New feature: `Drag building power poles in maximum connection range` + New feature: `Drag building power poles in maximum connection range`
+ New feature: `Allow overflow for Logistic Stations and Advanced Mining Machines` + New feature: `Allow overflow for Logistic Stations and Advanced Mining Machines`
- Allow overflow when trying to insert in-hand items - Allow overflow when trying to insert in-hand items
- Allow `Enhanced control for logistic storage limits` to exceed tech capacity limits - Allow `Enhanced control for logistic storage capacities` to exceed tech capacity limits
- Remove logistic strorage limit check on loading game - Remove logistic strorage capacity limit check on loading game
* 1.0.23 * 1.0.23
+ New features: + New features:
- `Do not render factory entities (except belts and sorters)` - `Do not render factory entities (except belts and sorters)`
@@ -261,13 +264,13 @@
+ Remove `Better auto-save mechanism` due to conflicts with DSPModSave and some other mods. + Remove `Better auto-save mechanism` due to conflicts with DSPModSave and some other mods.
* 1.0.10 * 1.0.10
+ Fix a button display bug + Fix a button display bug
+ Fix a possible crash while `Enhanced control for logistic storage limits` is enabled + Fix a possible crash while `Enhanced control for logistic storage capacities` is enabled
* 1.0.9 * 1.0.9
+ New function: `Better auto-save mechanism` + New function: `Better auto-save mechanism`
- Auto saves are stored in 'Save\AutoSaves' folder, filenames are combined with cluster address and date-time - Auto saves are stored in 'Save\AutoSaves' folder, filenames are combined with cluster address and date-time
- Note: this will sort gamesaves by modified time on save/load window, so you don't have to use [DSP_Save_Game_Sorter] anymore - Note: this will sort gamesaves by modified time on save/load window, so you don't have to use [DSP_Save_Game_Sorter] anymore
* 1.0.8 * 1.0.8
+ New function: `Enhanced control for logistic storage limits` + New function: `Enhanced control for logistic storage capacities`
* 1.0.7 * 1.0.7
+ Fix a crash issue on choosing language other than English and Chinese + Fix a crash issue on choosing language other than English and Chinese
+ Games saved in Peace-Mode after Dark-Fog update can also be loaded as Combat-Mode now. + Games saved in Peace-Mode after Dark-Fog update can also be loaded as Combat-Mode now.

View File

@@ -20,6 +20,8 @@ public static class LogisticsPatch
// Dispenser config // Dispenser config
public static ConfigEntry<int> AutoConfigDispenserChargePower; // 3~30, display as 300000.0 * value public static ConfigEntry<int> AutoConfigDispenserChargePower; // 3~30, display as 300000.0 * value
public static ConfigEntry<int> AutoConfigDispenserCourierCount; // 0~10 public static ConfigEntry<int> AutoConfigDispenserCourierCount; // 0~10
// Battlefield Analysis Base
public static ConfigEntry<int> AutoConfigBattleBaseChargePower; // 4~40, display as 300000.0 * value
// PLS config // PLS config
public static ConfigEntry<int> AutoConfigPLSChargePower; // 2~20, display as 3000000.0 * value public static ConfigEntry<int> AutoConfigPLSChargePower; // 2~20, display as 3000000.0 * value
public static ConfigEntry<int> AutoConfigPLSMaxTripDrone; // 1~180, by degress public static ConfigEntry<int> AutoConfigPLSMaxTripDrone; // 1~180, by degress
@@ -232,6 +234,11 @@ public static class LogisticsPatch
if (toFill > 0) dispenser.idleCourierCount += GameMain.data.mainPlayer.package.TakeItem((int)KnownItemId.Bot, toFill, out _); if (toFill > 0) dispenser.idleCourierCount += GameMain.data.mainPlayer.package.TakeItem((int)KnownItemId.Bot, toFill, out _);
} }
private static void DoConfigBattleBase(PlanetFactory factory, BattleBaseComponent battleBase)
{
factory.powerSystem.consumerPool[battleBase.pcId].workEnergyPerTick = (long)(5000.0 * (double)AutoConfigBattleBaseChargePower.Value + 0.5);
}
[HarmonyPostfix] [HarmonyPostfix]
[HarmonyPatch(typeof(PlanetTransport), nameof(PlanetTransport.NewStationComponent))] [HarmonyPatch(typeof(PlanetTransport), nameof(PlanetTransport.NewStationComponent))]
private static void PlanetTransport_NewStationComponent_Postfix(PlanetTransport __instance, StationComponent __result) private static void PlanetTransport_NewStationComponent_Postfix(PlanetTransport __instance, StationComponent __result)
@@ -239,6 +246,14 @@ public static class LogisticsPatch
DoConfigStation(__instance.factory, __result); DoConfigStation(__instance.factory, __result);
} }
[HarmonyPostfix]
[HarmonyPatch(typeof(DefenseSystem), nameof(DefenseSystem.NewBattleBaseComponent))]
private static void DefenseSystem_NewBattleBaseComponent_Postfix(DefenseSystem __instance, int __result)
{
if (__result <= 0) return;
DoConfigBattleBase(__instance.factory, __instance.battleBases[__result]);
}
[HarmonyPostfix] [HarmonyPostfix]
[HarmonyPatch(typeof(PlanetTransport), nameof(PlanetTransport.NewDispenserComponent))] [HarmonyPatch(typeof(PlanetTransport), nameof(PlanetTransport.NewDispenserComponent))]
private static void PlanetTransport_NewDispenserComponent_Postfix(PlanetTransport __instance, int __result) private static void PlanetTransport_NewDispenserComponent_Postfix(PlanetTransport __instance, int __result)
@@ -393,12 +408,14 @@ public static class LogisticsPatch
var maxCount = LDB.models.Select(modelIndex).prefabDesc.stationMaxItemCount; var maxCount = LDB.models.Select(modelIndex).prefabDesc.stationMaxItemCount;
var oldMaxCount = maxCount + history.localStationExtraStorage - _valuelf; var oldMaxCount = maxCount + history.localStationExtraStorage - _valuelf;
var intOldMaxCount = (int)Math.Round(oldMaxCount); var intOldMaxCount = (int)Math.Round(oldMaxCount);
var ratio = (maxCount + history.localStationExtraStorage) / oldMaxCount; var intNewMaxCount = (int)maxCount + history.localStationExtraStorage;
var ratio = intNewMaxCount / oldMaxCount;
var storage = stationPool[i].storage; var storage = stationPool[i].storage;
for (var j = storage.Length - 1; j >= 0; j--) for (var j = storage.Length - 1; j >= 0; j--)
{ {
if (storage[j].max + 10 < intOldMaxCount) continue; var max = storage[j].max;
storage[j].max = Mathf.RoundToInt((float)(storage[j].max * ratio / 50.0)) * 50; if (max + 10 < intOldMaxCount || max >= intNewMaxCount) continue;
storage[j].max = Mathf.RoundToInt((float)(max * ratio / 50.0)) * 50;
} }
} }
@@ -416,12 +433,14 @@ public static class LogisticsPatch
var maxCount = LDB.models.Select(modelIndex).prefabDesc.stationMaxItemCount; var maxCount = LDB.models.Select(modelIndex).prefabDesc.stationMaxItemCount;
var oldMaxCount = maxCount + history.remoteStationExtraStorage - _valuelf; var oldMaxCount = maxCount + history.remoteStationExtraStorage - _valuelf;
var intOldMaxCount = (int)Math.Round(oldMaxCount); var intOldMaxCount = (int)Math.Round(oldMaxCount);
var ratio = (maxCount + history.remoteStationExtraStorage) / oldMaxCount; var intNewMaxCount = (int)maxCount + history.remoteStationExtraStorage;
var ratio = intNewMaxCount / oldMaxCount;
var storage = stationPool[i].storage; var storage = stationPool[i].storage;
for (var j = storage.Length - 1; j >= 0; j--) for (var j = storage.Length - 1; j >= 0; j--)
{ {
if (storage[j].max + 10 < intOldMaxCount) continue; var max = storage[j].max;
storage[j].max = Mathf.RoundToInt((float)(storage[j].max * ratio / 100.0)) * 100; if (max + 10 < intOldMaxCount || max >= intNewMaxCount) continue;
storage[j].max = Mathf.RoundToInt((float)(max * ratio / 100.0)) * 100;
} }
} }

View File

@@ -92,16 +92,16 @@
- `Buffer count for researching in labs`: Range 2-20, default is 10 (same as game) - `Buffer count for researching in labs`: Range 2-20, default is 10 (same as game)
- `Ray Receiver Graviton Lens buffer count`: Range 1-20, default is 1 (game default is 20) - `Ray Receiver Graviton Lens buffer count`: Range 1-20, default is 1 (game default is 20)
+ Logistics + Logistics
- Enhanced control for logistic storage limits - Enhanced control for logistic storage capacities
- Logistic storage limits are not scaled on upgrading `Logistics Carrier Capacity`, if they are not set to maximum capacity. - Logistic storage capacities are not scaled on upgrading `Logistics Carrier Capacity`, if they are not set to maximum capacity or already greater than maximum capacity.
- You can use arrow keys to adjust logistic storage limits gracefully. - You can use arrow keys to adjust logistic storage capacities gracefully.
- Logistics Control Panel Improvement - Logistics Control Panel Improvement
- Auto apply filter with item under mouse cursor while opening the panel - Auto apply filter with item under mouse cursor while opening the panel
- Quick-set item filter while right-clicking item icons in storage list on the panel - Quick-set item filter while right-clicking item icons in storage list on the panel
- Allow overflow for Logistic Stations and Advanced Mining Machines - Allow overflow for Logistic Stations and Advanced Mining Machines
- Allow overflow when trying to insert in-hand items - Allow overflow when trying to insert in-hand items
- Allow `Enhanced control for logistic storage limits` to exceed tech capacity limits - Allow `Enhanced control for logistic storage capacities` to exceed tech capacity limits
- Remove logistic strorage limit check on loading game - Remove logistic strorage capacity limit check on loading game
- Real-time logistic stations info panel - Real-time logistic stations info panel
- Auto-config logistic stations - Auto-config logistic stations
- Auto-config buildings include: Logistics Distributor, PLS, ILS, Advanced Mining Machine - Auto-config buildings include: Logistics Distributor, PLS, ILS, Advanced Mining Machine
@@ -246,7 +246,7 @@
- `射线接收器透镜缓冲数量`范围1-20默认为1(游戏默认为20) - `射线接收器透镜缓冲数量`范围1-20默认为1(游戏默认为20)
+ 物流 + 物流
- 物流塔存储数量限制控制改进 - 物流塔存储数量限制控制改进
- 当升级`运输机舱扩容`时,不会对各种物流塔的存储限制按比例提升,除非设置为最大允许容量。 - 当升级`运输机舱扩容`时,不会对各种物流塔的存储限制按比例提升,除非设置为最大允许容量或者已经超过升级后的最大容量
- 你可以使用方向键微调物流塔存储限制 - 你可以使用方向键微调物流塔存储限制
- 物流控制面板改进 - 物流控制面板改进
- 打开面板时自动将鼠标指向物品设为筛选条件 - 打开面板时自动将鼠标指向物品设为筛选条件

View File

@@ -1,3 +1,2 @@
#### TODO #### TODO
* Set battlefield analysis base power charging
* Auto-navigation: avoid darkfogs * Auto-navigation: avoid darkfogs

View File

@@ -84,35 +84,31 @@ public static class UIConfigWindow
I18N.Add("Auto-config logistic stations", "Auto-config logistic stations", "自动配置物流设施"); I18N.Add("Auto-config logistic stations", "Auto-config logistic stations", "自动配置物流设施");
I18N.Add("Limit auto-replenish count to values below", "Limit auto-replenish count to values below", "限制自动补充数量为下面配置的值"); I18N.Add("Limit auto-replenish count to values below", "Limit auto-replenish count to values below", "限制自动补充数量为下面配置的值");
I18N.Add("Dispenser", "Logistics Distributor", "物流配送器"); I18N.Add("Dispenser", "Logistics Distributor", "物流配送器");
I18N.Add("Battlefield Analysis Base", "Battlefield Analysis Base", "战场分析基站");
I18N.Add("PLS", "PLS", "行星物流站"); I18N.Add("PLS", "PLS", "行星物流站");
I18N.Add("ILS", "ILS", "星际物流站"); I18N.Add("ILS", "ILS", "星际物流站");
I18N.Add("Advanced Mining Machine", "Advanced Mining Machine", "大型采矿机"); I18N.Add("Advanced Mining Machine", "Advanced Mining Machine", "大型采矿机");
I18N.Add("Max. Charging Power", "Max. Charging Power", "最大充能功率"); I18N.Add("Max. Charging Power", "Max. Charging Power", "最大充能功率");
I18N.Add("Count of Bots filled", "Count of Bots filled", "填充的配送机数量"); I18N.Add("Count of Bots filled", "Count of Bots filled", "填充的配送机数量");
I18N.Add("Max. Charging Power", "Max. Charging Power", "最大充能功率");
I18N.Add("Drone transport range", "Drone transport range", "运输机最远路程"); I18N.Add("Drone transport range", "Drone transport range", "运输机最远路程");
I18N.Add("Min. Load of Drones", "Min. Load of Drones", "运输机起送量"); I18N.Add("Min. Load of Drones", "Min. Load of Drones", "运输机起送量");
I18N.Add("Outgoing integration count", "Outgoing integration count", "输出货物集装数量"); I18N.Add("Outgoing integration count", "Outgoing integration count", "输出货物集装数量");
I18N.Add("Count of Drones filled", "Count of Drones filled", "填充的运输机数量"); I18N.Add("Count of Drones filled", "Count of Drones filled", "填充的运输机数量");
I18N.Add("Max. Charging Power", "Max. Charging Power", "最大充能功率");
I18N.Add("Drone transport range", "Drone transport range", "运输机最远路程");
I18N.Add("Vessel transport range", "Vessel transport range", "运输船最远路程"); I18N.Add("Vessel transport range", "Vessel transport range", "运输船最远路程");
I18N.Add("Warp distance", "Warp distance", "曲速启用路程"); I18N.Add("Warp distance", "Warp distance", "曲速启用路程");
I18N.Add("Min. Load of Drones", "Min. Load of Drones", "运输机起送量");
I18N.Add("Min. Load of Vessels", "Min. Load of Vessels", "运输船起送量"); I18N.Add("Min. Load of Vessels", "Min. Load of Vessels", "运输船起送量");
I18N.Add("Outgoing integration count", "Outgoing integration count", "输出货物集装数量"); I18N.Add("Outgoing integration count", "Outgoing integration count", "输出货物集装数量");
I18N.Add("Include Orbital Collector", "Include Orbital Collector", "包含轨道采集器"); I18N.Add("Include Orbital Collector", "Include Orbital Collector", "包含轨道采集器");
I18N.Add("Warpers required", "Warpers required", "翘曲器必备"); I18N.Add("Warpers required", "Warpers required", "翘曲器必备");
I18N.Add("Count of Drones filled", "Count of Drones filled", "填充的运输机数量");
I18N.Add("Count of Vessels filled", "Count of Vessels filled", "填充的运输船数量"); I18N.Add("Count of Vessels filled", "Count of Vessels filled", "填充的运输船数量");
I18N.Add("Collecting Speed", "Collecting Speed", "开采速度"); I18N.Add("Collecting Speed", "Collecting Speed", "开采速度");
I18N.Add("Min. Piler Value", "Outgoing integration count", "输出货物集装数量"); I18N.Add("Min. Piler Value", "Outgoing integration count", "输出货物集装数量");
I18N.Add("Allow overflow for Logistic Stations and Advanced Mining Machines", "Allow overflow for Logistic Stations and Advanced Mining Machines", "允许物流站和大型采矿机物品溢出"); I18N.Add("Allow overflow for Logistic Stations and Advanced Mining Machines", "Allow overflow for Logistic Stations and Advanced Mining Machines", "允许物流站和大型采矿机物品溢出");
I18N.Add("Enhance control for logistic storage limits", "Enhance control for logistic storage limits", "物流塔存储限制控制改进"); I18N.Add("Enhance control for logistic storage capacities", "Enhance control for logistic storage capacities", "物流塔存储容量控制改进");
I18N.Add("Enhance control for logistic storage limits tips", I18N.Add("Enhance control for logistic storage capacities tips",
"Logistic storage limits are not scaled on upgrading 'Logistics Carrier Capacity', if they are not set to maximum capacity.\nUse arrow keys to adjust logistic storage limits:\n \u2190/\u2192: -/+10 \u2193\u2191: -/+100", "Logistic storage capacity limits are not scaled on upgrading 'Logistics Carrier Capacity', if they are not set to maximum capacity or already greater than upgraded maximum capacity.\nUse arrow keys to adjust logistic storage capacities:\n \u2190/\u2192: -/+10 \u2193\u2191: -/+100",
"当升级'运输机舱扩容'时,不会对各种物流塔的存储限制按比例提升,除非设置为最大允许容量。\n你可以使用方向键微调物流塔存储限制\n \u2190\u2192: -/+10 \u2193\u2191: -/+100"); "当升级'运输机舱扩容'时,不会对各种物流塔的存储容量按比例提升,除非设置为最大允许容量或者已经超过升级后的最大容量。\n你可以使用方向键微调物流塔存储容量\n \u2190\u2192: -/+10 \u2193\u2191: -/+100");
I18N.Add("Logistics Control Panel Improvement", "Logistics Control Panel Improvement", "物流控制面板改进"); I18N.Add("Logistics Control Panel Improvement", "Logistics Control Panel Improvement", "物流控制面板改进");
I18N.Add("Logistics Control Panel Improvement tips", I18N.Add("Logistics Control Panel Improvement tips",
"Auto apply filter with item under mouse cursor while opening the panel\nQuick-set item filter while right-clicking item icons in storage list on the panel", "Auto apply filter with item under mouse cursor while opening the panel\nQuick-set item filter while right-clicking item icons in storage list on the panel",
@@ -199,7 +195,19 @@ public static class UIConfigWindow
public override string FormatValue(string format, int value) public override string FormatValue(string format, int value)
{ {
var sb = new StringBuilder(" "); var sb = new StringBuilder(" ");
StringBuilderUtility.WriteKMG(sb, 8, (long)value * 300000, false); StringBuilderUtility.WriteKMG(sb, 8, (long)value * 300000L, false);
sb.Append('W');
return sb.ToString().Trim();
}
}
private class AutoConfigBattleBaseChargePowerMapper() : MyWindow.RangeValueMapper<int>(4, 40)
{
public override string FormatValue(string format, int value)
{
var sb = new StringBuilder(" ");
StringBuilderUtility.WriteKMG(sb, 8, (long)value * 300000L, false);
sb.Append('W'); sb.Append('W');
return sb.ToString().Trim(); return sb.ToString().Trim();
} }
@@ -493,8 +501,8 @@ public static class UIConfigWindow
x = 0f; x = 0f;
y = 10f; y = 10f;
checkBoxForMeasureTextWidth = wnd.AddCheckBox(x, y, tab3, LogisticsPatch.LogisticsCapacityTweaksEnabled, "Enhance control for logistic storage limits"); checkBoxForMeasureTextWidth = wnd.AddCheckBox(x, y, tab3, LogisticsPatch.LogisticsCapacityTweaksEnabled, "Enhance control for logistic storage capacities");
wnd.AddTipsButton2(x + checkBoxForMeasureTextWidth.Width + 5f, y + 6f, tab3, "Enhance control for logistic storage limits", "Enhance control for logistic storage limits tips", "enhanced-logistic-limit-tips"); wnd.AddTipsButton2(x + checkBoxForMeasureTextWidth.Width + 5f, y + 6f, tab3, "Enhance control for logistic storage capacities", "Enhance control for logistic storage capacities tips", "enhanced-logistic-capacities-tips");
y += 36f; y += 36f;
wnd.AddCheckBox(x, y, tab3, LogisticsPatch.AllowOverflowInLogisticsEnabled, "Allow overflow for Logistic Stations and Advanced Mining Machines"); wnd.AddCheckBox(x, y, tab3, LogisticsPatch.AllowOverflowInLogisticsEnabled, "Allow overflow for Logistic Stations and Advanced Mining Machines");
y += 36f; y += 36f;
@@ -548,6 +556,11 @@ public static class UIConfigWindow
textForMeasureTextWidth = wnd.AddText2(x, y, tab3, "Count of Bots filled", 13, "text-dispenser-count-of-bots-filled"); textForMeasureTextWidth = wnd.AddText2(x, y, tab3, "Count of Bots filled", 13, "text-dispenser-count-of-bots-filled");
maxWidth = Mathf.Max(maxWidth, textForMeasureTextWidth.preferredWidth); maxWidth = Mathf.Max(maxWidth, textForMeasureTextWidth.preferredWidth);
y += 18f; y += 18f;
wnd.AddText2(10f, y, tab3, "Battlefield Analysis Base", 14, "text-battlefield-analysis-base");
y += 18f;
textForMeasureTextWidth = wnd.AddText2(x, y, tab3, "Max. Charging Power", 13, "text-battlefield-analysis-base-max-charging-power");
maxWidth = Mathf.Max(maxWidth, textForMeasureTextWidth.preferredWidth);
y += 18f;
wnd.AddText2(10f, y, tab3, "PLS", 14, "text-pls"); wnd.AddText2(10f, y, tab3, "PLS", 14, "text-pls");
y += 18f; y += 18f;
textForMeasureTextWidth = wnd.AddText2(x, y, tab3, "Max. Charging Power", 13, "text-pls-max-charging-power"); textForMeasureTextWidth = wnd.AddText2(x, y, tab3, "Max. Charging Power", 13, "text-pls-max-charging-power");
@@ -609,6 +622,8 @@ public static class UIConfigWindow
y += 18f; y += 18f;
wnd.AddSideSlider(nx, y, tab3, LogisticsPatch.AutoConfigDispenserCourierCount, new MyWindow.RangeValueMapper<int>(0, 10), "G", 150f, -100f).WithFontSize(13); wnd.AddSideSlider(nx, y, tab3, LogisticsPatch.AutoConfigDispenserCourierCount, new MyWindow.RangeValueMapper<int>(0, 10), "G", 150f, -100f).WithFontSize(13);
y += 36f; y += 36f;
wnd.AddSideSlider(nx, y, tab3, LogisticsPatch.AutoConfigBattleBaseChargePower, new AutoConfigBattleBaseChargePowerMapper(), "G", 150f, -100f).WithFontSize(13);
y += 36f;
wnd.AddSideSlider(nx, y, tab3, LogisticsPatch.AutoConfigPLSChargePower, new AutoConfigPLSChargePowerMapper(), "G", 150f, -100f).WithFontSize(13); wnd.AddSideSlider(nx, y, tab3, LogisticsPatch.AutoConfigPLSChargePower, new AutoConfigPLSChargePowerMapper(), "G", 150f, -100f).WithFontSize(13);
y += 18f; y += 18f;
wnd.AddSideSlider(nx, y, tab3, LogisticsPatch.AutoConfigPLSMaxTripDrone, new MyWindow.RangeValueMapper<int>(1, 180), "0°", 150f, -100f).WithFontSize(13); wnd.AddSideSlider(nx, y, tab3, LogisticsPatch.AutoConfigPLSMaxTripDrone, new MyWindow.RangeValueMapper<int>(1, 180), "0°", 150f, -100f).WithFontSize(13);

View File

@@ -142,6 +142,7 @@ public class UXAssist : BaseUnityPlugin, IModCanSave
"Limit auto-replenish count to config values"); "Limit auto-replenish count to config values");
LogisticsPatch.AutoConfigDispenserChargePower = Config.Bind("Factory", "AutoConfigDispenserChargePower", 30, new ConfigDescription("LD: Max. Charging Power", new AcceptableValueRange<int>(3, 30))); LogisticsPatch.AutoConfigDispenserChargePower = Config.Bind("Factory", "AutoConfigDispenserChargePower", 30, new ConfigDescription("LD: Max. Charging Power", new AcceptableValueRange<int>(3, 30)));
LogisticsPatch.AutoConfigDispenserCourierCount = Config.Bind("Factory", "AutoConfigDispenserCourierCount", 10, new ConfigDescription("LD: Count of Bots filled", new AcceptableValueRange<int>(0, 10))); LogisticsPatch.AutoConfigDispenserCourierCount = Config.Bind("Factory", "AutoConfigDispenserCourierCount", 10, new ConfigDescription("LD: Count of Bots filled", new AcceptableValueRange<int>(0, 10)));
LogisticsPatch.AutoConfigBattleBaseChargePower = Config.Bind("Factory", "AutoConfigBattleBaseChargePower", 8, new ConfigDescription("Battlefield Analysis Base: Max. Charging Power", new AcceptableValueRange<int>(4, 40)));
LogisticsPatch.AutoConfigPLSChargePower = Config.Bind("Factory", "AutoConfigPLSChargePower", 4, new ConfigDescription("PLS: Max. Charging Power", new AcceptableValueRange<int>(2, 20))); LogisticsPatch.AutoConfigPLSChargePower = Config.Bind("Factory", "AutoConfigPLSChargePower", 4, new ConfigDescription("PLS: Max. Charging Power", new AcceptableValueRange<int>(2, 20)));
LogisticsPatch.AutoConfigPLSMaxTripDrone = Config.Bind("Factory", "AutoConfigPLSMaxTripDrone", 180, new ConfigDescription("PLS: Drone transport range", new AcceptableValueRange<int>(1, 180))); LogisticsPatch.AutoConfigPLSMaxTripDrone = Config.Bind("Factory", "AutoConfigPLSMaxTripDrone", 180, new ConfigDescription("PLS: Drone transport range", new AcceptableValueRange<int>(1, 180)));
LogisticsPatch.AutoConfigPLSDroneMinDeliver = Config.Bind("Factory", "AutoConfigPLSDroneMinDeliver", 10, new ConfigDescription("PLS: Min. Load of Drones", new AcceptableValueRange<int>(0, 10))); LogisticsPatch.AutoConfigPLSDroneMinDeliver = Config.Bind("Factory", "AutoConfigPLSDroneMinDeliver", 10, new ConfigDescription("PLS: Min. Load of Drones", new AcceptableValueRange<int>(0, 10)));