Skip to content

Commit fb9cc96

Browse files
committed
Update 3.0.9
1 parent a01406c commit fb9cc96

17 files changed

+207
-43
lines changed

CHANGELOG.md

+27-3
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,30 @@
1+
- v3.0.9
2+
+ 调整开局赠送`无线输电塔`的科技为`高效电浆控制`
3+
+ 提高了两种研究站的制造速度和上传速度
4+
+ 提高了`批量建造`科技解锁的蓝图建筑数量
5+
+ 提高了快速开局模式的可使用物品数量
6+
+ 提高了`物质重组工厂`的制造成本和时间
7+
+ 添加了量化计算器游戏内提示
8+
+ 添加了`WeaponPlus`mod兼容补丁
9+
+ 修复了`湮灭弹箱`配方开局解锁的问题
10+
+ 量化计算器的默认建筑不再使用`物质重组工厂`
11+
12+
+ Adjusted the technology of the `Wireless Transmission Tower` given at the start to `Efficient Plasma Control`.
13+
+ Increased the manufacturing and uploading speeds of two types of research labs.
14+
+ Increased the number of blueprint buildings unlocked by the `Batch Build` technology.
15+
+ Increased the number of items that can be used in Quick Start mode.
16+
+ Increased the manufacturing cost and time of the Recombination Factory.
17+
+ Added in-game hints for Calculator
18+
+ Added `WeaponPlus` mod compatibility patch.
19+
+ Fixed an issue with the unlocking of the `Obliteration Crates` recipe at the beginning of the game.
20+
+ Fixed an issue with the unlocking of the recipe for the Annihilation Crates.
21+
+ The default building for the Calculator no longer uses the Recombination Factory.
22+
23+
24+
<details>
25+
<summary>点击展开日志 | Click to view all </summary>
26+
27+
128
- v3.0.8
229
+ 调整了部分科技的研究需求、前置科技
330
+ 复合矩阵不再可被增产
@@ -7,9 +34,6 @@
734
+ Composite Matrix production can no longer be increased by proliferator
835
+ Fixed misalignment of item pickup UI
936

10-
<details>
11-
<summary>点击展开日志 | Click to view all </summary>
12-
1337

1438
- v3.0.7
1539
+ 调整了制造复合矩阵时的工作颜色(感谢karki)

data/prefabDescs.json

+9
Original file line numberDiff line numberDiff line change
@@ -155,6 +155,10 @@
155155
"ModelID": 69,
156156
"assemblerSpeed": 40000
157157
},
158+
{
159+
"ModelID": 70,
160+
"labAssembleSpeed": 40000
161+
},
158162
{
159163
"ModelID": 71,
160164
"powerConnectDistance": 90.5,
@@ -233,6 +237,11 @@
233237
"ModelID": 434,
234238
"AmmoBlastRadius1": 15
235239
},
240+
{
241+
"ModelID": 455,
242+
"labAssembleSpeed": 120000,
243+
"labResearchSpeed": 3
244+
},
236245
{
237246
"ModelID": 456,
238247
"idleEnergyPerTick": 8000,

data/recipes.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -4146,7 +4146,7 @@
41464146
"IconPath": "",
41474147
"Type": 10,
41484148
"GridIndex": 2313,
4149-
"Time": 240,
4149+
"Time": 1800,
41504150
"Input": [
41514151
6503,
41524152
5202,
@@ -4176,7 +4176,7 @@
41764176
"IconPath": "",
41774177
"Type": 10,
41784178
"GridIndex": 2404,
4179-
"Time": 240,
4179+
"Time": 1800,
41804180
"Input": [
41814181
6503,
41824182
5203,
@@ -4185,9 +4185,9 @@
41854185
],
41864186
"InCounts": [
41874187
8,
4188-
10,
41894188
30,
4190-
2
4189+
30,
4190+
6
41914191
],
41924192
"Output": [
41934193
2318

data/strings.json

+11-1
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,17 @@
233233
"Name": "制造类型调整介绍前字",
234234
"ZHCN": "经过特化调整的制造台可以满足不同制造精度的需求,但除黑雾制造台外,不同制造台不能通用。",
235235
"ENUS": "After specialization, the assemblers can meet the needs of different precision, but except for the dark fog assembler, different assembler can not be used universally."
236-
},
236+
},
237+
{
238+
"Name": "量化计算器介绍标题",
239+
"ZHCN": "量化计算器",
240+
"ENUS": "Calculator"
241+
},
242+
{
243+
"Name": "量化计算器介绍前字",
244+
"ZHCN": "创世之书MOD自带量化计算器,默认为 <color=\"#FD965ECC\">~</color> 键,可在量化计算器的设置UI中修改。",
245+
"ENUS": "GenesisBook mod comes with a calculator, which defaults to the <color=\"#FD965ECC\">~</color> key, which can be changed in the settings in calculator ui."
246+
},
237247
{
238248
"Name": "钨矿脉",
239249
"ZHCN": "钨矿脉",

data/techs.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -71,11 +71,9 @@
7171
"PreTechsMax": false,
7272
"AddItems": [
7373
2201,
74-
2202,
7574
6508
7675
],
7776
"AddItemCounts": [
78-
3,
7977
3,
8078
1
8179
],
@@ -174,10 +172,12 @@
174172
"IsLabTech": false,
175173
"PreTechsMax": false,
176174
"AddItems": [
177-
1401
175+
1401,
176+
2202
178177
],
179178
"AddItemCounts": [
180-
10
179+
10,
180+
3
181181
],
182182
"PropertyOverrideItems": [],
183183
"PropertyItemCounts": []

data/tutorials.json

+9
Original file line numberDiff line numberDiff line change
@@ -48,5 +48,14 @@
4848
"DeterminatorParams": [
4949
2304
5050
]
51+
},
52+
{
53+
"ID": 36,
54+
"Name": "量化计算器介绍标题",
55+
"PreText": "量化计算器介绍前字",
56+
"DeterminatorName": "TOR_GameSecond",
57+
"DeterminatorParams": [
58+
5
59+
]
5160
}
5261
]

src/Compatibility/InstallationCheckPlugin.cs

+2
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ namespace ProjectGenesis.Compatibility
2727
[BepInDependency(FastTravelEnabler.GUID, BepInDependency.DependencyFlags.SoftDependency)]
2828
[BepInDependency(GigaStationsUpdated.GUID, BepInDependency.DependencyFlags.SoftDependency)]
2929
[BepInDependency(LazyOutposting.GUID, BepInDependency.DependencyFlags.SoftDependency)]
30+
[BepInDependency(WeaponPlus.GUID, BepInDependency.DependencyFlags.SoftDependency)]
3031
public class InstallationCheckPlugin : BaseUnityPlugin
3132
{
3233
public const string MODGUID = "org.LoShin.GenesisBook.InstallationCheck";
@@ -65,6 +66,7 @@ public static void AwakeCompatibilityPatchers()
6566
FastTravelEnabler.Awake();
6667
GigaStationsUpdated.Awake();
6768
LazyOutposting.Awake();
69+
WeaponPlus.Awake();
6870

6971
try { GalacticScale.Awake(); }
7072
catch (FileNotFoundException)

src/Compatibility/WeaponPlus.cs

+37
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
using System;
2+
using System.Reflection;
3+
using BepInEx;
4+
using BepInEx.Bootstrap;
5+
using HarmonyLib;
6+
using ProjectGenesis.Utils;
7+
8+
// ReSharper disable InconsistentNaming
9+
10+
namespace ProjectGenesis.Compatibility
11+
{
12+
internal static class WeaponPlus
13+
{
14+
internal const string GUID = "org.weaponplus.plugins.Xiaokls";
15+
16+
private static readonly Harmony HarmonyPatch = new Harmony("ProjectGenesis.Compatibility." + GUID);
17+
18+
internal static void Awake()
19+
{
20+
if (!Chainloader.PluginInfos.TryGetValue(GUID, out PluginInfo pluginInfo)) return;
21+
22+
Assembly assembly = pluginInfo.Instance.GetType().Assembly;
23+
24+
Type type = assembly.GetType("DSP_WeaponPlus.Utils.WPAddItem");
25+
26+
HarmonyPatch.Patch(AccessTools.Method(type, "AddDiyItem"), new HarmonyMethod(typeof(WeaponPlus), nameof(AddDiyItem_Prefix)));
27+
}
28+
29+
public static void AddDiyItem_Prefix(int[] inputIds)
30+
{
31+
for (var i = 0; i < inputIds.Length; i++)
32+
{
33+
if (inputIds[i] == 1201) inputIds[i] = ProtoID.I铝块;
34+
}
35+
}
36+
}
37+
}

src/Patches/Logic/FastStartOptionPatches.cs

+11-8
Original file line numberDiff line numberDiff line change
@@ -73,32 +73,35 @@ public static void SetForNewGame(GameData __instance)
7373
}
7474

7575
AddItemToPackage(1131, 2000); // 地基
76-
AddItemToPackage(2003, 600); // 三级带
76+
AddItemToPackage(2003, 1200); // 三级带
7777
AddItemToPackage(2013, 200); // 三级爪
78-
AddItemToPackage(2103, 10); // 小塔
78+
AddItemToPackage(2103, 20); // 小塔
79+
AddItemToPackage(2104, 3); // 大塔
7980
AddItemToPackage(5001, 400); // 小船
81+
AddItemToPackage(5002, 8); // 大船
8082
AddItemToPackage(6267, 10); // 大气
81-
AddItemToPackage(2201, 98); // 电线杆
82-
AddItemToPackage(2202, 4); // 充电杆
83+
AddItemToPackage(2201, 97); // 电线杆
84+
AddItemToPackage(2202, 7); // 充电杆
8385
AddItemToPackage(2107, 20); // 配送器
8486
AddItemToPackage(5003, 100); // 配送小飞机
8587
AddItemToPackage(2203, 46); // 风电
8688
AddItemToPackage(2204, 19); // 火电
8789
AddItemToPackage(2205, 49); // 太阳能
8890
AddItemToPackage(2211, 10); // 裂变
89-
AddItemToPackage(2301, 46); // 矿机
90-
AddItemToPackage(2302, 16); // 熔炉
91-
AddItemToPackage(6230, 20); // 处理厂
91+
AddItemToPackage(2301, 45); // 矿机
92+
AddItemToPackage(2302, 36); // 熔炉
93+
AddItemToPackage(6230, 30); // 处理厂
9294
AddItemToPackage(2303, 16); // 制造台MK1
9395
AddItemToPackage(2304, 16); // 制造台MK2
96+
AddItemToPackage(2305, 16); // 制造台MK3
9497
AddItemToPackage(2306, 20); // 抽水站
9598
AddItemToPackage(2307, 10); // 抽油机
9699
AddItemToPackage(2308, 30); // 精炼厂
97100
AddItemToPackage(2309, 30); // 化工厂
98101
AddItemToPackage(2901, 49); // 研究站
99102
AddItemToPackage(6241, 60); // 燃料棒
100103
AddItemToPackage(3001, 10); // 机枪
101-
AddItemToPackage(3002, 10); // 激光
104+
AddItemToPackage(3002, 20); // 激光
102105
AddItemToPackage(3003, 10); // 加农炮
103106
AddItemToPackage(3005, 10); // 导弹
104107
AddItemToPackage(5102, 24); // 精准无人机

src/Patches/Logic/InitialTechPatches.cs

+2
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,8 @@ public static void SetForNewGame(GameData __instance)
3636
{
3737
if (DSPGame.IsMenuDemo) { return; }
3838

39+
__instance.history.recipeUnlocked.Remove(5);
40+
3941
foreach (int tech in InitialTechs.Concat(BonusTechs))
4042
{
4143
if (__instance.history.TechUnlocked(tech)) { continue; }

src/Patches/Logic/QTools/QTools.cs

+12-9
Original file line numberDiff line numberDiff line change
@@ -54,15 +54,7 @@ internal static class QTools
5454

5555
case Utils.ERecipeType.所有制造:
5656
{
57-
dict.TryAddOrInsert(Utils.ERecipeType.Chemical, proto);
58-
dict.TryAddOrInsert(Utils.ERecipeType.Refine, proto);
59-
dict.TryAddOrInsert(Utils.ERecipeType.Assemble, proto);
60-
dict.TryAddOrInsert(Utils.ERecipeType.Particle, proto);
61-
dict.TryAddOrInsert(Utils.ERecipeType.标准制造, proto);
62-
dict.TryAddOrInsert(Utils.ERecipeType.高精度加工, proto);
63-
dict.TryAddOrInsert(Utils.ERecipeType.Research, proto);
64-
dict.TryAddOrInsert(Utils.ERecipeType.高分子化工, proto);
65-
57+
// process later manually
6658
continue;
6759
}
6860

@@ -83,6 +75,17 @@ internal static class QTools
8375
}
8476
}
8577

78+
ItemProto itemProto = LDB.items.Select(ProtoID.I物质重组工厂);
79+
80+
dict.TryAddOrInsert(Utils.ERecipeType.Chemical, itemProto);
81+
dict.TryAddOrInsert(Utils.ERecipeType.Refine, itemProto);
82+
dict.TryAddOrInsert(Utils.ERecipeType.Assemble, itemProto);
83+
dict.TryAddOrInsert(Utils.ERecipeType.Particle, itemProto);
84+
dict.TryAddOrInsert(Utils.ERecipeType.标准制造, itemProto);
85+
dict.TryAddOrInsert(Utils.ERecipeType.高精度加工, itemProto);
86+
dict.TryAddOrInsert(Utils.ERecipeType.Research, itemProto);
87+
dict.TryAddOrInsert(Utils.ERecipeType.高分子化工, itemProto);
88+
8689
return dict;
8790
}
8891
}

src/Patches/UI/QTools/UIQToolsWindow.cs

+14-13
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
using System.Collections.Generic;
2+
using System.Linq;
23
using CommonAPI.Systems;
34
using NGPT;
45
using ProjectGenesis.Patches.Logic.QTools;
@@ -33,7 +34,7 @@ public class UIQToolsWindow : ManualBehaviour
3334
private Text _factoryLabelText;
3435
private ObjectPool<ItemNeedDetail> _itemCounterPool;
3536

36-
private GameObject _labelTextPrefeb;
37+
private GameObject _labelTextPrefab;
3738
private RectTransform _list;
3839
private RectTransform _listContent;
3940

@@ -93,30 +94,30 @@ private void CreateUI()
9394
_proliferatorComboBox = MyComboBox.MyComboBox.CreateComboBox<ProliferatorComboBox>(30, 380, _tabs[0], "默认增产策略");
9495

9596
_clearOptionsButton = Util.MakeHiliteTextButton("清空设置".TranslateFromJson(), 80, 24);
96-
Util.NormalizeRectWithTopLeft(_clearOptionsButton, 1635, 2, _labelTextPrefeb.transform);
97+
Util.NormalizeRectWithTopLeft(_clearOptionsButton, 1635, 2, _labelTextPrefab.transform);
9798

9899
CreateLabelText("工厂", 255, 0);
99100
CreateLabelText("配方选取", 415, 0);
100101
CreateLabelText("增产策略", 850, 0);
101102

102-
_labelTextPrefeb.GetComponent<Text>().text = "物品".TranslateFromJson();
103-
Util.NormalizeRectWithTopLeft(_labelTextPrefeb.transform, -5, 0);
103+
_labelTextPrefab.GetComponent<Text>().text = "物品".TranslateFromJson();
104+
Util.NormalizeRectWithTopLeft(_labelTextPrefab.transform, -5, 0);
104105

105-
Util.NormalizeRectWithTopLeft(Util.CreateLabelText(_labelTextPrefeb, "添加需求:".TranslateFromJson()), 20, 19, _rightContent);
106+
Util.NormalizeRectWithTopLeft(Util.CreateLabelText(_labelTextPrefab, "添加需求:".TranslateFromJson()), 20, 19, _rightContent);
106107

107-
_needLabelText = Util.CreateLabelText(_labelTextPrefeb, "需求:".TranslateFromJson());
108+
_needLabelText = Util.CreateLabelText(_labelTextPrefab, "需求:".TranslateFromJson());
108109
Util.NormalizeRectWithTopLeft(_needLabelText, 20, 60, _rightContent);
109110

110-
_asRawsLabelText = Util.CreateLabelText(_labelTextPrefeb, "额外输入:".TranslateFromJson());
111+
_asRawsLabelText = Util.CreateLabelText(_labelTextPrefab, "额外输入:".TranslateFromJson());
111112
Util.NormalizeRectWithTopLeft(_asRawsLabelText, 20, 160, _rightContent);
112113

113-
_rawsLabelText = Util.CreateLabelText(_labelTextPrefeb, "原料需求:".TranslateFromJson());
114+
_rawsLabelText = Util.CreateLabelText(_labelTextPrefab, "原料需求:".TranslateFromJson());
114115
Util.NormalizeRectWithTopLeft(_rawsLabelText, 20, 260, _rightContent);
115116

116-
_byproductsLabelText = Util.CreateLabelText(_labelTextPrefeb, "副产物:".TranslateFromJson());
117+
_byproductsLabelText = Util.CreateLabelText(_labelTextPrefab, "副产物:".TranslateFromJson());
117118
Util.NormalizeRectWithTopLeft(_byproductsLabelText, 20, 360, _rightContent);
118119

119-
_factoryLabelText = Util.CreateLabelText(_labelTextPrefeb, "工厂:".TranslateFromJson());
120+
_factoryLabelText = Util.CreateLabelText(_labelTextPrefab, "工厂:".TranslateFromJson());
120121
Util.NormalizeRectWithTopLeft(_factoryLabelText, 20, 460, _rightContent);
121122

122123
var inputObj = GameObject.Find("UI Root/Overlay Canvas/In Game/Planet & Star Details/planet-detail-ui/name-input");
@@ -370,7 +371,7 @@ public void SetTabIndex(int index, bool immediate)
370371
}
371372

372373
private void CreateLabelText(string s, float left, float top) =>
373-
Util.NormalizeRectWithTopLeft(Util.CreateLabelText(_labelTextPrefeb, s.TranslateFromJson()), left, top);
374+
Util.NormalizeRectWithTopLeft(Util.CreateLabelText(_labelTextPrefab, s.TranslateFromJson()), left, top);
374375

375376
public override void _OnUpdate()
376377
{
@@ -500,8 +501,8 @@ internal static UIQToolsWindow CreateWindow()
500501

501502
if (t.name == "title")
502503
{
503-
win._labelTextPrefeb = t.GetChild(0).gameObject;
504-
Destroy(win._labelTextPrefeb.GetComponent<Localizer>());
504+
win._labelTextPrefab = t.GetChild(0).gameObject;
505+
Destroy(win._labelTextPrefab.GetComponent<Localizer>());
505506

506507
for (var j = 1; j < t.childCount; j++) Destroy(t.GetChild(j).gameObject);
507508
}

0 commit comments

Comments
 (0)