mirror of
https://github.com/RoyalnetworkTR/simple-launcher.git
synced 2026-09-25 00:19:50 +03:00
Backend (PHP+SQLite): Discord OAuth2 + JWT, coklu hesap (1 Discord = 3-5), tek-kullanimlik join token (/api/join/prepare+verify), custom skin yukleme/sunma, hesap/Discord/HWID ban, admin paneli kartlari; deterministik offline UUID (PHP<->C# paritesi dogrulandi). 25 entegrasyon testi gecti. AthenaCore (Forge 1.12.2): tek client+server mod — join token dogrulama + kick, grace-gate, custom skin uygulama. Sunucu offline-mode kalir (UUID/dunya verisi korunur). Masaustu: WPF -> Avalonia (Windows+Linux), Discord giris/hesap/skin/oyna; WMI/DPAPI yerine cross-platform (machine-id HWID, AES-GCM secret store). Derlenir + calisir. CI: athenacore-mod.yml (JDK8), desktop-release.yml (Win+Linux self-contained). Deploy: deploy.sh (.env uretimi, php-gd, nginx Authorization gecisi) + HANDOFF.md. Android: backend hazir; entegrasyon spec'i ANDROID_INTEGRATION.md.
43 lines
1.4 KiB
C#
43 lines
1.4 KiB
C#
using System;
|
||
using System.IO;
|
||
using System.Windows;
|
||
using System.Windows.Threading;
|
||
|
||
namespace OfflineMinecraftLauncher;
|
||
|
||
public partial class App : Application
|
||
{
|
||
protected override void OnStartup(StartupEventArgs e)
|
||
{
|
||
// Global hata yakalama — çökmeleri günlüğe yaz, kullanıcıya nazikçe bildir.
|
||
DispatcherUnhandledException += OnDispatcherUnhandledException;
|
||
AppDomain.CurrentDomain.UnhandledException += (s, args) =>
|
||
{
|
||
if (args.ExceptionObject is Exception ex) LogCrash(ex);
|
||
};
|
||
base.OnStartup(e);
|
||
}
|
||
|
||
private void OnDispatcherUnhandledException(object sender, DispatcherUnhandledExceptionEventArgs e)
|
||
{
|
||
LogCrash(e.Exception);
|
||
MessageBox.Show("Beklenmeyen bir hata oluştu:\n\n" + e.Exception.Message,
|
||
"Athena Studios Launcher", MessageBoxButton.OK, MessageBoxImage.Error);
|
||
e.Handled = true;
|
||
}
|
||
|
||
internal static void LogCrash(Exception ex)
|
||
{
|
||
try
|
||
{
|
||
var dir = Path.Combine(
|
||
Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData),
|
||
AppConfig.AppDataFolder, "logs");
|
||
Directory.CreateDirectory(dir);
|
||
var file = Path.Combine(dir, "launcher-errors.log");
|
||
File.AppendAllText(file, $"[{DateTime.Now:u}] {ex}\n\n");
|
||
}
|
||
catch { }
|
||
}
|
||
}
|