zc
This commit is contained in:
Binary file not shown.
Binary file not shown.
@@ -296,10 +296,14 @@ namespace ArachnaeSwarm
|
||||
ArachnaeLog.Debug($"Built {cachedConfigs.Count} equipment incubation configs for {parent.def.defName}");
|
||||
}
|
||||
|
||||
// 切换到特定索引
|
||||
// 切换到特定索引(-1 表示清除选择)
|
||||
public void SwitchToConfig(int index)
|
||||
{
|
||||
if (index >= 0 && index < IncubationConfigs.Count)
|
||||
if (index == -1)
|
||||
{
|
||||
selectedIndex = -1; // 清除选择
|
||||
}
|
||||
else if (index >= 0 && index < IncubationConfigs.Count)
|
||||
{
|
||||
selectedIndex = index;
|
||||
}
|
||||
|
||||
@@ -360,10 +360,14 @@ namespace ArachnaeSwarm
|
||||
// 获取当前选择的PawnKind
|
||||
public PawnKindDef SelectedPawnKind => SelectedConfig?.pawnKind;
|
||||
|
||||
// 切换到特定索引
|
||||
// 切换到特定索引(-1 表示清除选择)
|
||||
public void SwitchToConfig(int index)
|
||||
{
|
||||
if (index >= 0 && index < IncubationConfigs.Count)
|
||||
if (index == -1)
|
||||
{
|
||||
selectedIndex = -1; // 清除选择
|
||||
}
|
||||
else if (index >= 0 && index < IncubationConfigs.Count)
|
||||
{
|
||||
selectedIndex = index;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user