Save images of owned bots

This commit is contained in:
Norbi Peti 2024-05-14 19:40:48 +02:00
parent 2a5d73608d
commit 89908b95e7
2 changed files with 3 additions and 7 deletions

View file

@ -7,7 +7,7 @@ public static class DownloadImages
{
public static async Task DoIt(HttpClient client)
{
foreach (var dir in Directory.EnumerateDirectories("robots"))
foreach (var dir in Directory.EnumerateDirectories("my_robots"))
{
var json = await File.ReadAllTextAsync(Path.Combine(dir, "metadata.json"));
var doc = JsonDocument.Parse(json);

View file

@ -12,9 +12,6 @@ Console.WriteLine("Hello, World!");
var client = new HttpClient();
await DownloadImages.DoIt(client);
/*
async Task<JsonElement?> GetResponse(HttpResponseMessage result, string url)
{
if (result.StatusCode == HttpStatusCode.OK)
@ -91,7 +88,6 @@ foreach (var result in results.EnumerateArray())
Thread.Sleep(100);
}
// TODO: Get local saves
// TODO: Save robot images
await DownloadImages.DoIt(client);
// TODO: Chart of amount of bots on CRF by date & amount of starter bots
*/