MCSI-4 EULA Agreement #23

Merged
squid merged 2 commits from MCSI-4_eula_agreement into main 2025-07-11 00:09:56 +08:00
2 changed files with 5 additions and 0 deletions
Showing only changes of commit 5df2f06394 - Show all commits

View File

@ -39,6 +39,8 @@ class InstallationBloc extends Bloc<InstallationEvent, InstallationState> {
await writeFileUseCase(startScriptFilePath, startScriptContent); await writeFileUseCase(startScriptFilePath, startScriptContent);
await grantFilePermissionUseCase(startScriptFilePath); await grantFilePermissionUseCase(startScriptFilePath);
await writeFileUseCase(path.join(savePath, Constants.eulaFileName), Constants.eulaFileContent);
emit(state.copyWith(isLocked: false, downloadProgress: const ProgressViewModel.complete())); emit(state.copyWith(isLocked: false, downloadProgress: const ProgressViewModel.complete()));
}); });

View File

@ -3,6 +3,9 @@ import 'dart:io';
abstract class Constants { abstract class Constants {
static const gameVersionListUrl = 'https://www.dropbox.com/s/mtz3moc9dpjtz7s/GameVersions.txt?dl=1'; static const gameVersionListUrl = 'https://www.dropbox.com/s/mtz3moc9dpjtz7s/GameVersions.txt?dl=1';
static const serverFileName = 'server.jar'; static const serverFileName = 'server.jar';
static const eulaFileName = 'eula.txt';
static const eulaFileContent =
'#By changing the setting below to TRUE you are indicating your agreement to our EULA (https://account.mojang.com/documents/minecraft_eula).\neula=true';
static final startScriptFileName = Platform.isWindows ? 'start.bat' : 'start.sh'; static final startScriptFileName = Platform.isWindows ? 'start.bat' : 'start.sh';
} }