Improved Setup
Update Dependency
This commit is contained in:
parent
6778375f43
commit
92cc79f707
@ -11,7 +11,7 @@
|
|||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<PackageReference Include="CS2GSI" Version="1.0.7" />
|
<PackageReference Include="CS2GSI" Version="1.0.7" />
|
||||||
<PackageReference Include="CShocker" Version="1.2.3" />
|
<PackageReference Include="CShocker" Version="1.2.5" />
|
||||||
<PackageReference Include="Newtonsoft.Json" Version="13.0.3" />
|
<PackageReference Include="Newtonsoft.Json" Version="13.0.3" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
|
@ -218,23 +218,26 @@ public static class Setup
|
|||||||
|
|
||||||
private static List<string> GetShockerIds(List<Shocker> shockers)
|
private static List<string> GetShockerIds(List<Shocker> shockers)
|
||||||
{
|
{
|
||||||
List<string> allShockerIds = new();
|
|
||||||
foreach(Shocker shocker in shockers)
|
|
||||||
allShockerIds.AddRange(shocker.ShockerIds);
|
|
||||||
|
|
||||||
List<string> ids = new();
|
List<string> ids = new();
|
||||||
bool addAnother = true;
|
bool addAnother = true;
|
||||||
while (ids.Count < 1 || addAnother)
|
while (ids.Count < 1 || addAnother)
|
||||||
{
|
{
|
||||||
|
Console.WriteLine("Select Shocker API:");
|
||||||
|
for(int i = 0; i < shockers.Count; i++)
|
||||||
|
Console.WriteLine($"{i}) {shockers[i]}");
|
||||||
|
|
||||||
for (int i = 0; i < allShockerIds.Count; i++)
|
int selectedShocker;
|
||||||
Console.WriteLine($"{i}) {allShockerIds[i]}");
|
while (!int.TryParse(Console.ReadLine(), out selectedShocker) || selectedShocker < 0 || selectedShocker >= shockers.Count)
|
||||||
|
Console.WriteLine("Select Shocker API:");
|
||||||
|
|
||||||
|
for (int i = 0; i < shockers[selectedShocker].ShockerIds.Count; i++)
|
||||||
|
Console.WriteLine($"{i}) {shockers[selectedShocker].ShockerIds[i]}");
|
||||||
|
|
||||||
int selectedIndex;
|
int selectedIndex;
|
||||||
while (!int.TryParse(Console.ReadLine(), out selectedIndex) || selectedIndex < 0 || selectedIndex >= allShockerIds.Count)
|
while (!int.TryParse(Console.ReadLine(), out selectedIndex) || selectedIndex < 0 || selectedIndex >= shockers[selectedShocker].ShockerIds.Count)
|
||||||
Console.WriteLine("Select ID:");
|
Console.WriteLine("Select ID:");
|
||||||
|
|
||||||
ids.Add(allShockerIds[selectedIndex]);
|
ids.Add(shockers[selectedShocker].ShockerIds[selectedIndex]);
|
||||||
|
|
||||||
Console.WriteLine("Add another ID? (Y/N):");
|
Console.WriteLine("Add another ID? (Y/N):");
|
||||||
addAnother = Console.ReadKey().Key == ConsoleKey.Y;
|
addAnother = Console.ReadKey().Key == ConsoleKey.Y;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user