1 Commits

Author SHA1 Message Date
138b769f81 - add: script abilities 2025-07-13 10:08:07 +03:00
29 changed files with 371 additions and 349 deletions

View File

@@ -45,7 +45,6 @@
<entry key="Nebula.Launcher/Views/ServerListView.axaml" value="Nebula.Launcher/Nebula.Launcher.csproj" />
<entry key="Nebula.Launcher/Views/Tabs/AccountInfoTab.axaml" value="Nebula.Launcher/Nebula.Launcher.csproj" />
<entry key="Nebula.Launcher/Views/Tabs/ServerListTab.axaml" value="Nebula.Launcher/Nebula.Launcher.csproj" />
<entry key="Nebula.Launcher/Views/VisualErrorView.axaml" value="Nebula.Launcher/Nebula.Launcher.csproj" />
<entry key="Nebula.UpdateResolver/App.axaml" value="Nebula.UpdateResolver/Nebula.UpdateResolver.csproj" />
<entry key="Nebula.UpdateResolver/MainWindow.axaml" value="Nebula.UpdateResolver/Nebula.UpdateResolver.csproj" />
</map>

View File

@@ -28,16 +28,14 @@ public class App : Application
{
case IClassicDesktopStyleApplicationLifetime desktop:
DisableAvaloniaDataAnnotationValidation();
desktop.MainWindow = (Window)(provider = new MessageWindow());
desktop.MainWindow = new MessageWindow(out provider);
break;
case ISingleViewApplicationLifetime singleViewPlatform:
singleViewPlatform.MainView = (Control)(provider = new MessageView());
singleViewPlatform.MainView = new MessageView(out provider);
break;
}
provider?.ShowMessage(
"Error: An instance of the application is already running. Please close the existing instance before launching a new one.",
"Duplicate instance detected.");
provider?.ShowMessage("Launcher is already running.","hey shithead!");
return;
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 150 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 158 KiB

View File

@@ -24,9 +24,8 @@ account-auth-server = Authentication Server
account-auth-button = Authenticate
account-auth-save = Save Profile
account-auth-hello = Hello,
account-auth-current-server = Current server auth:
account-auth-logout = Log out
auth-current-login-name = Current login {$auth_server}: {$login}
auth-current-login-name = Current login: {$login}
auth-current-login-no-name = Profile not selected
auth-processing = Processing authentication request...
@@ -38,7 +37,6 @@ auth-name-resolution-error = Failed to resolve server address. Check your networ
auth-secure-error = Failed to cinnect to the server using SSL
auth-config-read = Reading authentication configuration...
auth-try-auth-config = Attempting to authenticate using saved configuration.
auth-try-auth-profile = Attempting to authenticate using profile
config-export-logs = Export logs
config-open-data = Open data path

View File

@@ -24,9 +24,8 @@ account-auth-server = Сервер аутентификации
account-auth-button = Аутентифицировать
account-auth-save = Сохранить профиль
account-auth-hello = Привет,
account-auth-current-server = Текущий сервер авторизации:
account-auth-logout = Выйти
auth-current-login-name = Текущий профиль {$auth_server}: {$login}
auth-current-login-name = Текущий профиль: {$login}
auth-current-login-no-name = Профиль не выбран
auth-processing = Обработка запроса аутентификации...
@@ -38,7 +37,6 @@ auth-name-resolution-error = Не удалось разрешить адрес
auth-secure-error = Не удалось подключиться к серверу по SSL. Проверьте сетевые настройки.
auth-config-read = Чтение конфигурации аутентификации...
auth-try-auth-config = Попытка аутентификации с использованием сохраненной конфигурации.
auth-try-auth-profile = Попытка аутентификации с использованием профиля
config-export-logs = Экспортировать логи
config-open-data = Открыть путь данных

View File

@@ -1,11 +1,11 @@
using System;
using Avalonia;
using Avalonia.Controls;
using Avalonia.Data.Converters;
using Avalonia.Media;
using Avalonia.Platform;
namespace Nebula.Launcher.Converters;
public static class TypeConverters
public class TypeConverters
{
public static FuncValueConverter<string, string?> IconConverter { get; } =
new(iconKey =>
@@ -13,11 +13,4 @@ public static class TypeConverters
if (iconKey == null) return null;
return $"/Assets/svg/{iconKey}.svg";
});
public static FuncValueConverter<string, IImage?> ImageConverter { get; } =
new(iconKey =>
{
if (iconKey == null) return null;
return new Avalonia.Media.Imaging.Bitmap(AssetLoader.Open(new Uri($"avares://Nebula.Launcher/Assets/error_presentation/{iconKey}.png")));
});
}

View File

@@ -34,13 +34,7 @@ public static class LauncherConVar
"WizDen",
[
"https://harpy.durenko.tatar/auth-api/",
"https://auth.spacestation14.com/",
"https://auth.fallback.spacestation14.com/",
]),
new AuthServerCredentials(
"SimpleStation",
[
"https://auth.simplestation.org/",
])
]);

View File

@@ -2,9 +2,16 @@
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:views="clr-namespace:Nebula.Launcher.Views"
mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
Width="600"
Height="400"
x:Class="Nebula.Launcher.MessageBox.MessageView">
<views:VisualErrorView x:Name="ErrorView"/>
<Grid RowDefinitions="50,*" ColumnDefinitions="*">
<Border Grid.Column="0" Background="#222222" Padding="10" BorderBrush="#444444" BorderThickness="0,0,0,3">
<Label VerticalAlignment="Center" x:Name="Title">Text</Label>
</Border>
<Panel Margin="5" Grid.Row="1">
<Label x:Name="Message">Message</Label>
</Panel>
</Grid>
</UserControl>

View File

@@ -1,22 +1,21 @@
using Avalonia;
using Avalonia.Controls;
using Nebula.Launcher.ViewModels;
using Avalonia.Markup.Xaml;
namespace Nebula.Launcher.MessageBox;
public partial class MessageView : UserControl, IMessageContainerProvider
{
private readonly VisualErrorViewModel _context;
public MessageView()
public MessageView(out IMessageContainerProvider provider)
{
InitializeComponent();
_context = new VisualErrorViewModel();
ErrorView.Content = _context;
provider = this;
}
public void ShowMessage(string message, string title)
{
_context.Title = title;
_context.Description = message;
Title.Content = title;
Message.Content = message;
}
}

View File

@@ -3,52 +3,10 @@
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:messageBox="clr-namespace:Nebula.Launcher.MessageBox"
SystemDecorations="BorderOnly"
mc:Ignorable="d" d:DesignWidth="600" d:DesignHeight="260"
mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
Width="600"
Height="260"
CanResize="False"
Height="400"
x:Class="Nebula.Launcher.MessageBox.MessageWindow"
Title="MessageWindow">
<Grid ColumnDefinitions="*" RowDefinitions="30,*">
<messageBox:MessageView
Grid.Column="0"
Grid.Row="0"
Grid.RowSpan="2"
x:Name="MessageView" />
<Border
BorderThickness="0,0,0,2"
CornerRadius="0"
Grid.Column="0"
Grid.Row="0">
<Border.BorderBrush>
<LinearGradientBrush EndPoint="100%,50%" StartPoint="0%,50%">
<GradientStop Color="#222222" Offset="0.0" />
<GradientStop Color="#442222" Offset="1.0" />
</LinearGradientBrush>
</Border.BorderBrush>
<Panel
Height="30"
PointerPressed="InputElement_OnPointerPressed">
<TextBlock
FontSize="10"
Foreground="White"
IsVisible="False"
Margin="15,0"
Text="Nebula Launcher"
VerticalAlignment="Center" />
<StackPanel
HorizontalAlignment="Right"
Margin="5,0,5,0"
Orientation="Horizontal"
Spacing="8">
<Button
Click="Close_Click"
Content="🗙"
Foreground="Azure" />
</StackPanel>
</Panel>
</Border>
</Grid>
</Window>

View File

@@ -1,28 +1,12 @@
using Avalonia.Controls;
using Avalonia.Input;
using Avalonia.Interactivity;
namespace Nebula.Launcher.MessageBox;
public partial class MessageWindow : Window, IMessageContainerProvider
public partial class MessageWindow : Window
{
public MessageWindow()
public MessageWindow(out IMessageContainerProvider provider)
{
InitializeComponent();
}
public void ShowMessage(string message, string title)
{
MessageView.ShowMessage(message, title);
}
private void Close_Click(object? sender, RoutedEventArgs e)
{
Close();
}
private void InputElement_OnPointerPressed(object? sender, PointerPressedEventArgs e)
{
BeginMoveDrag(e);
Content = new MessageView(out provider);
}
}

View File

@@ -1,13 +1,10 @@
using System.Text.Json.Serialization;
using System.Windows.Input;
using Avalonia.Media;
using Nebula.Shared.Services;
namespace Nebula.Launcher.Models.Auth;
public sealed record ProfileAuthCredentials(
AuthTokenCredentials Credentials,
string AuthName,
Color Color,
AuthTokenCredentials Credentials,
[property: JsonIgnore] ICommand OnSelect = default!,
[property: JsonIgnore] ICommand OnDelete = default!);

View File

@@ -32,6 +32,7 @@
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="9.0.0"/>
<PackageReference Include="libsodium" Version="1.0.20"/>
<PackageReference Include="Robust.Natives" Version="0.1.1" />
<PackageReference Include="NLua" Version="1.7.5" />
</ItemGroup>
<ItemGroup>

View File

@@ -42,12 +42,12 @@ public partial class MainViewModel : ViewModelBase
[ObservableProperty] private ListItemTemplate? _selectedListItem;
public bool IsLoggedIn => AccountInfoViewModel.Credentials is not null;
public string LoginName => AccountInfoViewModel.Credentials?.Login ?? string.Empty;
public string LoginText => LocalisationService.GetString("auth-current-login-name",
new Dictionary<string, object>
{
{ "login", AccountInfoViewModel.Credentials?.Login ?? "" },
{ "auth_server", AccountInfoViewModel.CurrentAuthServerName}
{ "login", LoginName }
});
[GenerateProperty] private LocalisationService LocalisationService { get; } // Не убирать! Без этой хуйни вся локализация идет в пизду!

View File

@@ -3,10 +3,7 @@ using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Net.Http;
using System.Security.Cryptography;
using System.Text;
using System.Threading.Tasks;
using Avalonia.Media;
using CommunityToolkit.Mvvm.ComponentModel;
using CommunityToolkit.Mvvm.Input;
using Nebula.Launcher.Models.Auth;
@@ -26,15 +23,20 @@ namespace Nebula.Launcher.ViewModels.Pages;
public partial class AccountInfoViewModel : ViewModelBase
{
[ObservableProperty] private bool _authMenuExpand;
[ObservableProperty] private bool _authUrlConfigExpand;
[ObservableProperty] private int _authViewSpan = 1;
[ObservableProperty] private string _currentAuthServer = string.Empty;
[ObservableProperty] private string _currentLogin = string.Empty;
[ObservableProperty] private string _currentPassword = string.Empty;
[ObservableProperty] private bool _isLogged;
[ObservableProperty] private bool _doRetryAuth;
[ObservableProperty] private AuthTokenCredentials? _credentials;
[ObservableProperty] private AuthServerCredentials _authItemSelect;
private bool _isProfilesEmpty;
[GenerateProperty] private PopupMessageService PopupMessageService { get; } = default!;
@@ -45,22 +47,18 @@ public partial class AccountInfoViewModel : ViewModelBase
public ObservableCollection<ProfileAuthCredentials> Accounts { get; } = new();
public ObservableCollection<AuthServerCredentials> AuthUrls { get; } = new();
public string CurrentAuthServerName => GetServerAuthName(Credentials);
[ObservableProperty] private AuthServerCredentials _authItemSelect;
private ILogger _logger;
partial void OnCredentialsChanged(AuthTokenCredentials? value)
{
OnPropertyChanged(nameof(CurrentAuthServerName));
}
//Design think
protected override void InitialiseInDesignMode()
{
AuthUrls.Add(new AuthServerCredentials("Test",["example.com"]));
AddAccount(new AuthTokenCredentials(Guid.Empty, LoginToken.Empty, "Binka", "example.com"));
AddAccount(new AuthTokenCredentials(Guid.Empty, LoginToken.Empty, "Binka", ""));
AddAccount(new AuthTokenCredentials(Guid.Empty, LoginToken.Empty, "Binka", ""));
AuthUrls.Add(new AuthServerCredentials("Test",["example.com"]));
}
//Real think
@@ -227,13 +225,6 @@ public partial class AccountInfoViewModel : ViewModelBase
{
IsLogged = false;
Credentials = null;
CurrentAuthServer = "";
}
public string GetServerAuthName(AuthTokenCredentials? credentials)
{
if (credentials is null) return "";
return AuthUrls.FirstOrDefault(p => p.Servers.Contains(credentials.AuthServer))?.Name ?? "CustomAuth";
}
private void UpdateAuthMenu()
@@ -248,13 +239,9 @@ public partial class AccountInfoViewModel : ViewModelBase
{
var onDelete = new DelegateCommand<ProfileAuthCredentials>(OnDeleteProfile);
var onSelect = new DelegateCommand<ProfileAuthCredentials>(AuthByProfile);
var serverName = GetServerAuthName(credentials);
var alpm = new ProfileAuthCredentials(
credentials,
serverName,
ColorUtils.GetColorFromString(credentials.AuthServer),
onSelect,
onDelete);
@@ -270,18 +257,16 @@ public partial class AccountInfoViewModel : ViewModelBase
message.InfoText = LocalisationService.GetString("auth-config-read");
message.IsInfoClosable = false;
PopupMessageService.Popup(message);
AuthUrls.Clear();
var authUrls = ConfigurationService.GetConfigValue(LauncherConVar.AuthServers)!;
foreach (var url in authUrls) AuthUrls.Add(url);
if(authUrls.Length > 0) AuthItemSelect = authUrls[0];
foreach (var profile in
ConfigurationService.GetConfigValue(LauncherConVar.AuthProfiles)!)
AddAccount(profile);
if (Accounts.Count == 0) UpdateAuthMenu();
AuthUrls.Clear();
var authUrls = ConfigurationService.GetConfigValue(LauncherConVar.AuthServers)!;
foreach (var url in authUrls) AuthUrls.Add(url);
if(authUrls.Length > 0) AuthItemSelect = authUrls[0];
message.Dispose();
DoCurrentAuth();
@@ -362,18 +347,4 @@ public partial class AccountInfoViewModel : ViewModelBase
ConfigurationService.SetConfigValue(LauncherConVar.AuthProfiles,
Accounts.Select(a => a.Credentials).ToArray());
}
}
public static class ColorUtils
{
public static Color GetColorFromString(string input)
{
var hash = MD5.HashData(Encoding.UTF8.GetBytes(input));
var r = byte.Clamp(hash[0], 10, 200);
var g = byte.Clamp(hash[1], 10, 100);
var b = byte.Clamp(hash[2], 10, 100);
return Color.FromArgb(Byte.MaxValue, r, g, b);
}
}

View File

@@ -1,22 +0,0 @@
using CommunityToolkit.Mvvm.ComponentModel;
using Nebula.Launcher.Views;
using Nebula.Shared.ViewHelper;
namespace Nebula.Launcher.ViewModels;
[ViewModelRegister(typeof(VisualErrorView))]
public partial class VisualErrorViewModel : ViewModelBase
{
[ObservableProperty] private string _imgPath = "cinka";
[ObservableProperty] private string _title = "Error";
[ObservableProperty] private string _description = "This is an error.";
protected override void InitialiseInDesignMode()
{
}
protected override void Initialise()
{
}
}

View File

@@ -1,6 +1,6 @@
<UserControl
d:DesignHeight="450"
d:DesignWidth="1000"
d:DesignWidth="800"
mc:Ignorable="d"
x:Class="Nebula.Launcher.Views.Pages.AccountInfoView"
x:DataType="pages:AccountInfoViewModel"
@@ -39,56 +39,39 @@
Padding="0">
<ItemsControl.ItemTemplate>
<DataTemplate DataType="{x:Type auth:ProfileAuthCredentials}">
<Grid ColumnDefinitions="4*,*">
<Border
BoxShadow="0 1 15 -2 #121212"
CornerRadius="0,10,0,10"
Margin="5,5,5,0">
<Border.Background>
<LinearGradientBrush EndPoint="100%,50%" StartPoint="20%,50%">
<GradientStop Color="{Binding Color}" Offset="0.0" />
<GradientStop Color="#222222" Offset="1.0" />
</LinearGradientBrush>
</Border.Background>
<Label>
<TextBlock Text="{Binding AuthName}" Margin="5"/>
</Label>
</Border>
<Border Grid.Column="0"
CornerRadius="0,10,0,10"
Margin="5,5,5,0">
<Border.Background>
<LinearGradientBrush EndPoint="100%,50%" StartPoint="20%,50%">
<GradientStop Color="#aa222222" Offset="0.0" />
<GradientStop Color="#222222" Offset="0.4" />
</LinearGradientBrush>
</Border.Background>
<Button
HorizontalAlignment="Stretch"
Command="{Binding OnSelect}">
<Border
BoxShadow="0 1 15 -2 #121212"
CornerRadius="0,10,0,10"
Margin="5,5,5,0"
VerticalAlignment="Center">
<Border.Background>
<LinearGradientBrush EndPoint="50%,100%" StartPoint="50%,0%">
<GradientStop Color="#292222" Offset="0.0" />
<GradientStop Color="#222222" Offset="1.0" />
</LinearGradientBrush>
</Border.Background>
<Panel>
<StackPanel Margin="10,5,5,5" Orientation="Horizontal">
<Label>
<TextBlock Text="{Binding Credentials.Login}" HorizontalAlignment="Right" VerticalAlignment="Center" Margin="0,0,5,0"/>
<TextBlock Text="{Binding Credentials.Login}" />
</Label>
</Button>
</Border>
<Border
BoxShadow="0 1 15 -2 #121212"
CornerRadius="0,10,0,10"
Margin="0,5,5,0" Grid.Column="1" Padding="0">
<Border.Background>
<LinearGradientBrush EndPoint="100%,50%" StartPoint="20%,50%">
<GradientStop Color="#292222" Offset="1.0" />
<GradientStop Color="#222222" Offset="1.0" />
</LinearGradientBrush>
</Border.Background>
<Button Command="{Binding OnDelete}" CornerRadius="0,10,0,10" HorizontalAlignment="Stretch">
<Svg
Height="15"
Path="/Assets/svg/delete.svg"
Width="15" />
</Button>
</Border>
</Grid>
</StackPanel>
<StackPanel HorizontalAlignment="Right" Orientation="Horizontal">
<Button
Command="{Binding OnSelect}"
CornerRadius="0,0,0,10"
Padding="5">
<customControls:LocalizedLabel LocalId="account-profile-select"/>
</Button>
<Button
Command="{Binding OnDelete}"
CornerRadius="0,10,0,0"
Padding="5">
<customControls:LocalizedLabel LocalId="account-profile-delete"/>
</Button>
</StackPanel>
</Panel>
</Border>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
@@ -186,15 +169,9 @@
Margin="0,0,0,20"
Path="/Assets/svg/user.svg" />
<Label>
<StackPanel>
<StackPanel HorizontalAlignment="Center" Orientation="Horizontal" Spacing="5">
<customControls:LocalizedLabel LocalId="account-auth-hello"/>
<TextBlock Text="{Binding CurrentLogin}" />
</StackPanel>
<StackPanel HorizontalAlignment="Center" Orientation="Horizontal" Spacing="5">
<customControls:LocalizedLabel LocalId="account-auth-current-server"/>
<TextBlock Text="{Binding CurrentAuthServerName}" />
</StackPanel>
<StackPanel HorizontalAlignment="Center" Orientation="Horizontal">
<customControls:LocalizedLabel LocalId="account-auth-hello"/>
<TextBlock Text="{Binding CurrentLogin}" />
</StackPanel>
</Label>
<StackPanel

View File

@@ -1,39 +0,0 @@
<UserControl xmlns="https://github.com/avaloniaui"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:viewModels="clr-namespace:Nebula.Launcher.ViewModels"
xmlns:converters="clr-namespace:Nebula.Launcher.Converters"
mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
x:DataType="viewModels:VisualErrorViewModel"
x:Class="Nebula.Launcher.Views.VisualErrorView">
<Design.DataContext>
<viewModels:VisualErrorViewModel />
</Design.DataContext>
<Grid RowDefinitions="30,*" ColumnDefinitions="200,*">
<Border Grid.Row="1" Grid.Column="0"
CornerRadius="10,0,0,10"
BorderThickness="0,0,2,0"
BorderBrush="{StaticResource DefaultForeground}">
<Image Source="{Binding ImgPath, Converter={x:Static converters:TypeConverters.ImageConverter}}" Width="200" Height="200"/>
</Border>
<Border Grid.Row="0" Grid.Column="0" Grid.ColumnSpan="2" CornerRadius="10,10,0,0">
<Border.Background>
<LinearGradientBrush EndPoint="100%,50%" StartPoint="10%,20%">
<GradientStop Color="#FF6B6B" Offset="0.0" />
<GradientStop Color="#FF8E53" Offset="0.3" />
<GradientStop Color="#FF5E3A" Offset="0.6" />
<GradientStop Color="#FF5e5e" Offset="1.0" />
</LinearGradientBrush>
</Border.Background>
<Label HorizontalAlignment="Center"><TextBlock Text="{Binding Title}"/></Label>
</Border>
<TextBlock
Grid.Row="1"
Grid.Column="1"
Margin="15"
HorizontalAlignment="Center"
TextWrapping="Wrap"
Text="{Binding Description}"/>
</Grid>
</UserControl>

View File

@@ -1,11 +0,0 @@
using Avalonia.Controls;
namespace Nebula.Launcher.Views;
public partial class VisualErrorView : UserControl
{
public VisualErrorView()
{
InitializeComponent();
}
}

View File

@@ -14,6 +14,7 @@
<ItemGroup>
<PackageReference Include="Lib.Harmony" Version="2.3.6" />
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="9.0.0"/>
<PackageReference Include="NLua" Version="1.7.5" />
<PackageReference Include="SharpZstd.Interop" Version="1.5.6"/>
</ItemGroup>
</Project>

View File

@@ -1,11 +1,10 @@
using System.Data;
using HarmonyLib;
using Nebula.Shared;
namespace Nebula.Runner.Services;
[ServiceRegister]
public class HarmonyService(ReflectionService reflectionService)
public class HarmonyService
{
private HarmonyInstance? _instance;
@@ -25,21 +24,6 @@ public class HarmonyService(ReflectionService reflectionService)
throw new Exception();
_instance = new HarmonyInstance();
UnShittyWizard();
}
/// <summary>
/// Я помню пенис большой,Я помню пенис большой, Я помню пенис большой, я помню....
/// </summary>
private void UnShittyWizard()
{
var method = reflectionService.GetType("Robust.Client.GameController").TypeInitializer;
_instance!.Harmony.Patch(method, new HarmonyMethod(Prefix));
}
static bool Prefix()
{
return false;
}
}

View File

@@ -1,33 +1,29 @@
using System.Reflection;
using Nebula.Shared;
using Nebula.Shared.FileApis;
using Nebula.Shared.Services;
namespace Nebula.Runner.Services;
[ServiceRegister]
public class ReflectionService(AssemblyService assemblyService)
public class ReflectionService
{
private Dictionary<string, Assembly> _typeCache = new();
private readonly Dictionary<string, Assembly> _typeCache = new();
public ReflectionService(AssemblyService assemblyService)
{
assemblyService.OnAssemblyLoaded += OnAssemblyLoaded;
}
private void OnAssemblyLoaded(Assembly obj)
{
RegisterAssembly(obj);
}
public void RegisterAssembly(Assembly robustAssembly)
{
_typeCache.Add(robustAssembly.GetName().Name!, robustAssembly);
}
public void RegisterRobustAssemblies(AssemblyApi engine)
{
RegisterAssembly(GetRobustAssembly("Robust.Shared", engine));
RegisterAssembly(GetRobustAssembly("Robust.Client", engine));
}
private Assembly GetRobustAssembly(string assemblyName, AssemblyApi engine)
{
if(!assemblyService.TryOpenAssembly(assemblyName, engine, out var assembly))
throw new Exception($"Unable to locate {assemblyName}.dll in engine build!");
return assembly;
}
public Type? GetTypeImp(string name)
{
foreach (var (prefix,assembly) in _typeCache)
@@ -51,7 +47,7 @@ public class ReflectionService(AssemblyService assemblyService)
: assembly.GetType(name)!;
}
private string ExtrackPrefix(string path)
public string ExtrackPrefix(string path)
{
var sp = path.Split(".");
return sp[0] + "." + sp[1];

View File

@@ -1,6 +1,5 @@
using System.Globalization;
using System.Reflection;
using System.Reflection.Emit;
using HarmonyLib;
using Nebula.Shared;
using Nebula.Shared.Models;
@@ -18,9 +17,10 @@ public sealed class RunnerService(
EngineService engineService,
AssemblyService assemblyService,
ReflectionService reflectionService,
HarmonyService harmonyService)
HarmonyService harmonyService,
ScriptService scriptService)
{
private ILogger _logger = debugService.GetLogger("RunnerService");
private readonly ILogger _logger = debugService.GetLogger("RunnerService");
private bool MetricEnabled = false; //TODO: ADD METRIC THINKS LATER
public async Task Run(string[] runArgs, RobustBuildInfo buildInfo, IRedialApi redialApi,
@@ -58,6 +58,24 @@ public sealed class RunnerService(
var args = new MainArgs(runArgs, engine, redialApi, extraMounts);
var assemblyManifest = hashApi.Manifest.Where(p =>
p.Key.StartsWith("Assemblies/"))
.Select(p =>
{
return p.Value with { Path = Path.GetFileNameWithoutExtension(p.Key) };
}).ToList();
var assembliesHash = contentService.CreateHashApi(assemblyManifest);
var contentAssemblyApi = assemblyService.Mount(assembliesHash);
foreach (var file in contentAssemblyApi.AllFiles.Where(p => Path.GetExtension(p) == ".dll"))
{
var newExt = Path.GetFileNameWithoutExtension(file);
if(!assemblyService.TryOpenAssembly(newExt, contentAssemblyApi, out _)) throw new Exception("Assembly not found: " + newExt);
}
if (!assemblyService.TryOpenAssembly(varService.GetConfigValue(CurrentConVar.RobustAssemblyName)!, engine,
out var clientAssembly))
throw new Exception("Unable to locate Robust.Client.dll in engine build!");
@@ -68,7 +86,6 @@ public sealed class RunnerService(
if(!assemblyService.TryOpenAssembly("Prometheus.NetStandard", engine, out var prometheusAssembly))
return;
reflectionService.RegisterRobustAssemblies(engine);
harmonyService.CreateInstance();
IDisposable? metricServer = null;
@@ -78,12 +95,18 @@ public sealed class RunnerService(
MetricsEnabledPatcher.ApplyPatch(reflectionService, harmonyService);
metricServer = RunHelper.RunMetric(prometheusAssembly);
}
scriptService.LoadScripts();
await Task.Run(() => loader.Main(args), cancellationToken);
metricServer?.Dispose();
}
private void CacheAssembly()
{
}
}
public static class MetricsEnabledPatcher

View File

@@ -0,0 +1,181 @@
using System.Reflection;
using System.Text.Json;
using System.Text.Json.Serialization;
using HarmonyLib;
using Nebula.Shared;
using Nebula.Shared.FileApis;
using Nebula.Shared.Services;
using NLua;
namespace Nebula.Runner.Services;
[ServiceRegister]
public class ScriptService
{
private readonly HarmonyService _harmonyService;
private readonly ReflectionService _reflectionService;
private readonly AssemblyService _assemblyService;
private readonly FileApi _scriptFileApi;
private static Dictionary<MethodBase, ScriptManifestDict> _scriptCache = [];
private static Dictionary<string, Action> _assemblyLoadingQuery = [];
public ScriptService(HarmonyService harmonyService, ReflectionService reflectionService, FileService fileService, AssemblyService assemblyService)
{
_harmonyService = harmonyService;
_reflectionService = reflectionService;
_assemblyService = assemblyService;
_scriptFileApi = fileService.CreateFileApi("scripts");
_assemblyService.OnAssemblyLoaded += OnAssemblyLoaded;
}
private void OnAssemblyLoaded(Assembly obj)
{
var objName = obj.GetName().Name ?? string.Empty;
if (!_assemblyLoadingQuery.TryGetValue(objName, out var a)) return;
Console.WriteLine("Inject assembly: " + objName);
a();
_assemblyLoadingQuery.Remove(objName);
}
public void LoadScripts()
{
Console.WriteLine("Loading scripts... " + _scriptFileApi.EnumerateDirectories("").Count());
foreach (var dir in _scriptFileApi.EnumerateDirectories(""))
{
LoadScript(dir);
}
}
public void LoadScript(string name)
{
Console.WriteLine($"Reading script {name}");
var manifests = ReadManifest(name);
foreach (var entry in manifests)
{
if (entry.TypeInitializer.HasValue) LoadTypeInitializer(entry.TypeInitializer.Value, name);
if (entry.Method.HasValue) LoadMethod(entry.Method.Value, name);
}
}
private void LoadTypeInitializer(ScriptMethodInjectItem item, string name)
{
Console.WriteLine($"Loading Initializer injection {name}...");
var assemblyName = _reflectionService.ExtrackPrefix(item.Method.Class);
if (!_assemblyService.Assemblies.Select(a => a.GetName().Name).Contains(assemblyName))
{
_assemblyLoadingQuery.Add(assemblyName, () => LoadTypeInitializer(item, name));
return;
}
var targetType = _reflectionService.GetType(item.Method.Class);
var method = targetType.TypeInitializer;
InitialiseShared(method!, name, item);
}
private void LoadMethod(ScriptMethodInjectItem item, string name)
{
Console.WriteLine($"Loading method injection {name}...");
var assemblyName = _reflectionService.ExtrackPrefix(item.Method.Class);
if (!_assemblyService.Assemblies.Select(a => a.GetName().Name).Contains(assemblyName))
{
_assemblyLoadingQuery.Add(assemblyName, () => LoadMethod(item, name));
return;
}
var targetType = _reflectionService.GetType(item.Method.Class);
var method = targetType.GetMethod(item.Method.Method, BindingFlags.Public | BindingFlags.NonPublic | BindingFlags.Instance | BindingFlags.Static);
InitialiseShared(method!, name, item);
}
private void InitialiseShared(MethodBase method, string scriptName, ScriptMethodInjectItem item)
{
var scriptCode = File.ReadAllText(Path.Combine(_scriptFileApi.RootPath, scriptName, item.Script.LuaFile));
var methodInfo = method as MethodInfo;
HarmonyMethod dynamicPatch;
if (methodInfo == null || methodInfo.ReturnType == typeof(void))
dynamicPatch = new HarmonyMethod(typeof(ScriptService).GetMethod(nameof(LuaPrefix), BindingFlags.Static | BindingFlags.NonPublic));
else
dynamicPatch = new HarmonyMethod(typeof(ScriptService).GetMethod(nameof(LuaPrefixResult), BindingFlags.Static | BindingFlags.NonPublic));
_scriptCache[method] = new ScriptManifestDict(scriptCode, item);
_harmonyService.Instance.Harmony.Patch(method, prefix: dynamicPatch);
Console.WriteLine($"Injected {scriptName}");
}
private ScriptEntry[] ReadManifest(string scriptName)
{
if(!_scriptFileApi.TryOpen(Path.Join(scriptName, "MANIFEST.json"), out var stream))
throw new FileNotFoundException(Path.Join(scriptName, "MANIFEST.json") + " not found manifest!");
return JsonSerializer.Deserialize<ScriptEntry[]>(stream) ?? [];
}
private static bool LuaPrefix(MethodBase __originalMethod, object __instance)
{
if (!_scriptCache.TryGetValue(__originalMethod, out var luaCode))
return true;
using var lua = new Lua();
lua["this"] = __instance;
var results = lua.DoString(luaCode.Code);
if (results is { Length: > 0 } && results[0] is bool b)
return b;
return luaCode.ScriptMethodInjectItem.ContinueAfterInject;
}
private static bool LuaPrefixResult(MethodBase __originalMethod, object __instance, ref object __result)
{
if (!_scriptCache.TryGetValue(__originalMethod, out var luaCode))
return true;
using var lua = new Lua();
lua["this"] = __instance;
lua["result"] = __result;
var results = lua.DoString(luaCode.Code);
if (lua["result"] != null)
__result = lua["result"];
if (results is { Length: > 0 } && results[0] is bool b)
return b;
return luaCode.ScriptMethodInjectItem.ContinueAfterInject;
}
}
public record struct ScriptManifestDict(string Code, ScriptMethodInjectItem ScriptMethodInjectItem);
public record struct ScriptEntry(
[property: JsonPropertyName("method")] ScriptMethodInjectItem? Method,
[property: JsonPropertyName("type_initializer")] ScriptMethodInjectItem? TypeInitializer
);
public record struct ScriptMethodInjectItem(
[property: JsonPropertyName("method")] ScriptMethodInfo Method,
[property: JsonPropertyName("continue")] bool ContinueAfterInject,
[property: JsonPropertyName("script")] LuaMethodEntry Script
);
public record struct ScriptMethodInfo(
[property: JsonPropertyName("class")] string Class,
[property: JsonPropertyName("method")] string Method
);
public record struct LuaMethodEntry(
[property: JsonPropertyName("lua_file")] string LuaFile
);

View File

@@ -75,6 +75,11 @@ public sealed class FileApi : IReadWriteFileApi
return File.Exists(fullPath);
}
public IEnumerable<string> EnumerateDirectories(string path)
{
return Directory.GetDirectories(Path.Join(RootPath, path)).Select(p=>p.Replace(RootPath,"").Substring(1));
}
private IEnumerable<string> GetAllFiles(){
if(!Directory.Exists(RootPath)) return [];

View File

@@ -12,15 +12,23 @@ namespace Nebula.Shared.Services;
[ServiceRegister]
public class AssemblyService
{
private readonly List<Assembly> _assemblies = new();
private readonly Dictionary<string, Assembly> _assemblyCache = new();
private readonly ILogger _logger;
private readonly HashSet<string> _resolvingAssemblies = new();
private List<AssemblyApi> _mountedApis = [];
public Action<Assembly>? OnAssemblyLoaded;
public IReadOnlyList<Assembly> Assemblies => _assemblyCache.Values.ToList().AsReadOnly();
public AssemblyService(DebugService debugService)
{
_logger = debugService.GetLogger(this);
AssemblyLoadContext.Default.ResolvingUnmanagedDll += LoadContextOnResolvingUnmanaged;
AssemblyLoadContext.Default.Resolving += (context, name) => OnAssemblyResolving(context, name);
ZstdImportResolver.ResolveLibrary += (name, assembly1, path) =>
{
if (name.Equals("SharpZstd.Native"))
@@ -36,21 +44,41 @@ public class AssemblyService
};
}
public IReadOnlyList<Assembly> Assemblies => _assemblies;
private Assembly? OnAssemblyResolving(AssemblyLoadContext context, AssemblyName name)
{
if (_resolvingAssemblies.Contains(name.FullName))
{
_logger.Debug($"Already resolving {name.Name}, skipping.");
return null; // Prevent recursive resolution
}
Assembly? assembly;
if (_assemblyCache.TryGetValue(name.Name ?? "", out assembly))
{
return assembly;
}
foreach (var api in _mountedApis)
{
if((assembly = OnAssemblyResolving(context, name, api)) != null)
return assembly;
}
return null;
}
public AssemblyApi Mount(IFileApi fileApi)
{
var asmApi = new AssemblyApi(fileApi);
AssemblyLoadContext.Default.Resolving += (context, name) => OnAssemblyResolving(context, name, asmApi);
AssemblyLoadContext.Default.ResolvingUnmanagedDll += LoadContextOnResolvingUnmanaged;
_mountedApis.Add(asmApi);
return asmApi;
}
public bool TryGetLoader(Assembly clientAssembly, [NotNullWhen(true)] out ILoaderEntryPoint? loader)
{
loader = null;
// Find ILoaderEntryPoint with the LoaderEntryPointAttribute
var attrib = clientAssembly.GetCustomAttribute<LoaderEntryPointAttribute>();
if (attrib == null)
{
@@ -79,9 +107,11 @@ public class AssemblyService
assembly = AssemblyLoadContext.Default.LoadFromStream(asm, pdb);
_logger.Log("LOADED ASSEMBLY " + name);
if (!_assemblies.Contains(assembly)) _assemblies.Add(assembly);
if (_assemblyCache.TryAdd(name, assembly))
{
OnAssemblyLoaded?.Invoke(assembly);
}
asm.Dispose();
pdb?.Dispose();
@@ -103,21 +133,18 @@ public class AssemblyService
private Assembly? OnAssemblyResolving(AssemblyLoadContext context, AssemblyName name, AssemblyApi assemblyApi)
{
if (_resolvingAssemblies.Contains(name.FullName))
lock (_resolvingAssemblies)
{
_logger.Debug($"Already resolving {name.Name}, skipping.");
return null; // Prevent recursive resolution
}
try
{
_resolvingAssemblies.Add(name.FullName);
_logger.Debug($"Resolving assembly from FileAPI: {name.Name}");
return TryOpenAssembly(name.Name!, assemblyApi, out var assembly) ? assembly : null;
}
finally
{
_resolvingAssemblies.Remove(name.FullName);
try
{
_resolvingAssemblies.Add(name.FullName);
_logger.Debug($"Resolving assembly from FileAPI: {name.Name}");
return TryOpenAssembly(name.Name!, assemblyApi, out var assembly) ? assembly : null;
}
finally
{
_resolvingAssemblies.Remove(name.FullName);
}
}
}

View File

@@ -23,7 +23,7 @@ public class FileService
Directory.CreateDirectory(RootPath);
}
public IReadWriteFileApi CreateFileApi(string path)
public FileApi CreateFileApi(string path)
{
_logger.Debug($"Creating file api for {path}");
return new FileApi(Path.Join(RootPath, path));

View File

@@ -1,5 +1,9 @@
<wpf:ResourceDictionary xml:space="preserve" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:s="clr-namespace:System;assembly=mscorlib" xmlns:ss="urn:shemas-jetbrains-com:settings-storage-xaml" xmlns:wpf="http://schemas.microsoft.com/winfx/2006/xaml/presentation">
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AArchiving_002EUtils_002EWindows_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003F27e9f12ad1e4318b9b02849ec3e6a502fa3ee761c4f0522ba756ab30cde1c_003FArchiving_002EUtils_002EWindows_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AAssemblyLoadContext_002ECoreCLR_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003F99b58e5049c4c1b08628baf3843f62e765df3a131566566b5bcf4a2c47fb4bd_003FAssemblyLoadContext_002ECoreCLR_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AAssemblyLoadContext_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003Fa6b7f037ba7b44df80b8d3aa7e58eeb2e8e938_003F9f_003F247e98fb_003FAssemblyLoadContext_002Ecs_002Fz_003A2_002D1/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AAssemblyLoadContext_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003F47e646b7b981834f2b1298e9ba8543fc4994cc50e15f81d515ec883b6e3797b_003FAssemblyLoadContext_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AAssemblyName_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003Fe151f62e5a2bc2dcf247d43eb37d7ba6ae4177aabc3e46e7aa6563b35a374536_003FAssemblyName_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AAssembly_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003F501151723a8d43558c75acbd334f26322066fa4b1c82b1297291314bf92ff_003FAssembly_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AAuthenticationHeaderValue_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003F88b338246f59cffdb6f3dc3d8dbcfc169599dc71d6f44a8f2732983db7f73a_003FAuthenticationHeaderValue_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AAvaloniaXamlLoader_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003F80462644bd1cc7e0b229dc4f5752b48c01cb67b46ae563b1b5078cc2556b98_003FAvaloniaXamlLoader_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
@@ -20,7 +24,6 @@
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AFileShare_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003Fa6b7f037ba7b44df80b8d3aa7e58eeb2e8e938_003F54_003Fc3f4f140_003FFileShare_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AFile_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003F3f31e7e8aa33de883c2ccfa62a9c81bfc246c36e825b489476f9472032e512_003FFile_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AFrozenDictionary_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003F89dff9063ddb01ff8125b579122b88bf4de94526490d77bcbbef7d0ee662a_003FFrozenDictionary_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AFuncValueConverter_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003Fe91c13e7e24d7ba324e0e6eb12a24ea8c7761299d3c4703e55c86dd120835e61_003FFuncValueConverter_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AFuture_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003Fb3575a2f41d7c2dbfaa36e866b8a361e11dd7223ff82bc574c1d5d4b7522f735_003FFuture_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AHttpClient_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003Fc439425da351c75ac7d966a1cc8324b51a9c471865af79d2f2f3fcb65e392_003FHttpClient_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AHttpContent_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003F9657cc383c70851dc2bdcf91eff27f21196844abfe552fc9c3243ff36974cd_003FHttpContent_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
@@ -33,13 +36,13 @@
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AHttpResponseMessage_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003F4cfeb8b377bc81e1fbb5f7d7a02492cb6ac23e88c8c9d7155944f0716f3d4b_003FHttpResponseMessage_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AIDispatcherImpl_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003F22d92db124764b1ab49745245c66f01b1e1a00_003F0f_003F01061787_003FIDispatcherImpl_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AIDisposable_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003Fa6b7f037ba7b44df80b8d3aa7e58eeb2e8e938_003F98_003Fd1b23281_003FIDisposable_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AImage_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003F2b95745d8f2ddf7b8ad6130e01c5b2782e253ff11247a9aeefcef47277b1ab_003FImage_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AIndex_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003F2a1a813823579c69832f1304f97761e7be433bd6aa928f351d138050b56a38_003FIndex_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AInt32_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003Fa882d183338544fdbcbdfc7b6d3dcb78916630765551644a221b5be9c45a121b_003FInt32_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AInterop_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003Fc4d71b51722245ae8cde97bfd996e68386928_003F3a_003F004a1338_003FInterop_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AJsonSerializer_002ERead_002EString_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003F27c4858128168eda568c1334d70d5241efb9461e2a3209258a04deee5d9c367_003FJsonSerializer_002ERead_002EString_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AKnownHeader_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003F1079f3c57a31ec97cba3b6ebb3d45c5a4afcdf6fa483a4db57c3d58ea59d7a9_003FKnownHeader_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AListBox_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003F3a6cdc26ff4d30986a9a16b6bbc9bb6a7f2657431c82cde5c66dd377cf51e2b_003FListBox_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AMethodInfo_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003F6bd3b909e3250b8181899b1a1238cd417918c6c816fbeba173df45af2ec41e_003FMethodInfo_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AMetricServer_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003Fb07ddb833489431aae882d295a4e94797e00_003Fcf_003F23af7cad_003FMetricServer_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AMetricServer_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003F66d3496ea2e7f3cbfb5f2ba1362869af0588ac72e87912659693443b5b7c3a_003FMetricServer_002Ecs_002Fz_003A2_002D1/@EntryIndexedValue">ForceIncluded</s:String>
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AMetrics_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003FUsers_003FCinka_003FAppData_003FRoaming_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003Fb07ddb833489431aae882d295a4e94797e00_003F0f_003Fc9e3d448_003FMetrics_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>