From b55f685cbba8cf61f8be9bebcc87d33ad7bb1aa4 Mon Sep 17 00:00:00 2001 From: Evan Date: Tue, 29 Jul 2025 07:39:14 -0400 Subject: [PATCH 1/4] DRAFT: Update dev-client-winrt.rst Saving progress and still working through functionality. I'll need to have public testers of this tutorial to iron out kinks. --- source/pages/Tutorial/dev-client-winrt.rst | 241 +++++++++++---------- 1 file changed, 124 insertions(+), 117 deletions(-) diff --git a/source/pages/Tutorial/dev-client-winrt.rst b/source/pages/Tutorial/dev-client-winrt.rst index 1cb31c3..06783a9 100644 --- a/source/pages/Tutorial/dev-client-winrt.rst +++ b/source/pages/Tutorial/dev-client-winrt.rst @@ -1,193 +1,200 @@ -Setting Up a Development Game Client (Windows 8.1+) -======================================================= - -Requirements ------------- +.. _dev-client-winrt: -* Visual Studio or Visual Studio Build Tools installed on your system -* `Microsoft Visual C++ Runtime Package 12.0 for x86 `_ -* A copy of the Brave Frontier package (APPX) for Windows (`Share Drive link `_) -* Developer Mode enabled on your system -* Development game server setup and running (see `Setting Up a Development Game Server `_) +.. role:: raw-html(raw) + :format: html -.. warning:: - - If Developer Mode is not installed or enabled in Windows, the proxy will not function, and you will not see the command prompt. +Setting Up a Development Game Client (Windows 8.1+) +==================================================== -Cloning the Repository ----------------------- +.. contents:: + :local: -To clone the offline-proxy repository, run the following command: +Introduction +-------------- -:: +This tutorial guides you through setting up a development game client for Brave Frontier on Windows 8.1 and later, enabling offline play via a local proxy server. It assumes you have Visual Studio 2022 installed with the Desktop development with C++ workload and the Windows 10 SDK. The process involves cloning the repository, building the proxy, generating certificates, modifying the game client, and enabling loopback for local testing. - git clone --depth=1 https://github.com/decompfrontier/offline-proxy +.. note:: + If you are brand new to development, follow the exact folder structure shown in this tutorial (e.g., creating a folder on the root of your C: drive called BF). This will make storage and following along easier. You are free to use any folder structure you are comfortable with, but adjust paths in commands accordingly. -Building the Proxy ------------------- +Requirements +-------------- .. warning:: + If Developer Mode is not installed or enabled in Windows, the proxy will not function, and you will not see the command prompt. - The client *only* supports 32-bit platforms. Ensure you use the MINGW32 (i686-w64-mingw32) toolchain. - -Using CMake, configure the proxy with one of the following options: - -* For Visual Studio as your compiler: ``cmake --preset debug-vs`` -* For MSYS/MinGW as your compiler: ``cmake --preset debug-mingw`` - -After compilation, navigate to your CMake build directory. Inside the ``bin`` folder, you should find a ``libcurl.dll`` file. Keep track of this file, as it will be required later in the tutorial. - -Generating UWP Development Certificates ---------------------------------------- +- Windows 8.1 or later +- Visual Studio 2022 with Desktop development with C++ workload and Windows 10 SDK +- Microsoft Visual C++ Runtime Package 12.0 for x86 (from https://github.com/M1k3G0/Win10_LTSC_VP9_Installer/blob/master/Microsoft.VCLibs.120.00_12.0.21005.1_x86__8wekyb3d8bbwe.appx) +- Git for Windows +- Administrator privileges -.. warning:: +Cloning the Repository +------------------------ - It is recommended to remove these certificates when they are no longer needed to prevent them from compromising system trust. +To clone the offline-proxy repository, open PowerShell and run the following command: -.. important:: +.. code-block:: console - All commands in this section must be executed in PowerShell. Ensure you are using PowerShell, or the system will not recognize the required applications. + cd C:\BF + git clone --depth=1 https://github.com/decompfrontier/offline-proxy + cd C:\BF\offline-proxy .. note:: + Adjust the directory (e.g., ``C:\BF``) if you prefer a different location. - If you have previously generated a PFX certificate for deploying applications to the Windows Store or have already completed this section, skip ahead to the "Modifying Brave Frontier APPX" section. - -.. hint:: +Building the Proxy +-------------------- - This section provides a simplified process adapted from `this MSDN page `_. +.. warning:: + The client only supports 32-bit platforms. Ensure the build targets Win32. -To install custom Windows Store apps, you must first generate a development certificate. Run the following command in PowerShell to create a certificate: +Build the proxy using the following steps: -:: +.. code-block:: console - New-SelfSignedCertificate -Type Custom -Subject "CN=" -KeyUsage DigitalSignature -FriendlyName "Your friendly name goes here" -CertStoreLocation "Cert:\CurrentUser\My" -TextExtension @("2.5.29.37={text}1.3.6.1.5.5.7.3.3", "2.5.29.19={text}") + cmake --build . --config Debug -.. note:: +If the build fails, open ``offline-proxy.sln`` in Visual Studio 2022, set the solution platform to Win32 and configuration to Debug, then build (F7 or in some situations if you have an "Fn Lock" style keyboard ``Fn`` + ``F7``). After a successful build, locate ``libcurl.dll`` in ``C:\BF\offline-proxy\Debug\libcurl.dll`` (or search the Debug folder). - Replace ```` with a name of your choice (e.g., "My BraveFrontier"). Write down this name, as it will be needed later. +Generating UWP Development Certificates +----------------------------------------- -Take note of the certificate's **Thumbprint**, as it will be used to export the certificate. Then, run the following commands to export it: +Generate a development certificate to sign the modified client: -:: +.. code-block:: powershell - $password = ConvertTo-SecureString -String "" -Force -AsPlainText - Export-PfxCertificate -cert "Cert:\CurrentUser\My\" -FilePath MyKey.pfx -Password $password + $certName = "MyBraveFrontier" + $friendlyName = "Brave Frontier Dev Cert" + New-SelfSignedCertificate -Type Custom -Subject "CN=$certName" -KeyUsage DigitalSignature -FriendlyName "$friendlyName" -CertStoreLocation "Cert:\CurrentUser\My" -TextExtension @("2.5.29.37={text}1.3.6.1.5.5.7.3.3", "2.5.29.19={text}") .. note:: + The output will show a Thumbprint (e.g., ``ABC123...``). Highlight the first line of the output (starting with "Thumbprint") with your mouse, right-click to copy, then paste it into the next command using right-click paste. Use arrow keys (up/down/left/right) to navigate and edit the ``$thumbprint`` variable. This is a basic CLI skill: right-click pastes copied text, and arrow keys move the cursor without needing the mouse. - - Replace ```` with a strong password of your choosing. +``TODO: Add an gif here to show the process`` - - Replace ```` with the Thumbprint from the previous step. +Export the certificate: -You should now have a ``MyKey.pfx`` file. Keep this file safe, as it will be used to sign the modified Brave Frontier client. +.. code-block:: powershell -Installing the Certificate -~~~~~~~~~~~~~~~~~~~~~~~~~~ + $thumbprint = "ABC123..." # Paste and edit your Thumbprint here using right-click paste and arrow keys + $password = ConvertTo-SecureString -String "YourStrongPassword" -Force -AsPlainText # Change password + Export-PfxCertificate -cert "Cert:\CurrentUser\My\$thumbprint" -FilePath C:\BF\MyKey.pfx -Password $password -1. Open the ``MyKey.pfx`` file to launch the Certificate Import Wizard. -2. Select ``Local Machine`` and proceed. -3. When prompted for the certificate store, choose ``Place all certificates in the following store``. -4. Browse and select ``Trusted Root Certification Authorities``. -5. Click ``Finish``, then confirm with ``Yes`` when prompted. +Install the certificate: -.. image:: - ../../images/dev-client-winrt/certpath_win.png +#. Double-click ``C:\BF\MyKey.pfx`` to launch the Certificate Import Wizard. +#. Select ``Local Machine`` and proceed. +#. Choose ``Trusted Root Certification Authorities`` as the store. +#. Click ``Finish``, then confirm with ``Yes``. (``TODO: This step was a part of the legacy setup and needs a redone photo.``) -Modifying Brave Frontier APPX ------------------------------ +.. image:: ../../images/dev-client-winrt/certpath_win.png + :alt: Installing the Custom Certificate -.. important:: - - All commands in this section must be executed in a Developer Command Prompt for Visual Studio. Ensure you use this environment, or the required tools will not be recognized. +.. warning:: + Remove these certificates when you are done with Brave Frontier development to prevent compromising system trust. Removing the certificate after installing the patched BraveFrontier APPX is a safety step and will prevent launching the patched APPX if it relies on ongoing verification. -To unpack the game client, run the following command: +.. important:: + All commands must be executed in PowerShell with administrator privileges. -:: +Obtaining the APPX File +------------------------- - makeappx unpack /p gumi.BraveFrontier_2.19.6.0_x86__tdae4wqex79w6.appx /d BraveFrontierAppxClient +Download the unmodified Brave Frontier APPX file from the provided link: -A new folder named ``BraveFrontierAppxClient`` will be created, containing the extracted game client files for modification. +- URL: https://drive.google.com/file/d/1NB64gzQOe-QQx9fY0mkoZiCSfe3WlTYi/view?usp=sharing +- Save as: ``C:\BF\BraveFrontier_2.19.6.0_x86.appx`` (right-click link > Save As). -1. Copy the ``libcurl.dll`` file from the "`Building the Proxy `_" section and place it in the root of the ``BraveFrontierAppxClient`` directory. When prompted to replace the original file, select ``Yes``. -2. Delete the following files from the ``BraveFrontierAppxClient`` directory: +.. note:: + Verify the file size (~100MB) to ensure integrity. This file is not publicly hosted elsewhere; direct downloads are rare and often risky (e.g., APKs from APKPure/BlueStacks). If issues arise, extract from an installed app: ``Get-AppxPackage *BraveFrontier* | Export-AppxPackage -Path C:\BF\BraveFrontier.appx``. - - ``AppxMetadata`` +Modifying Brave Frontier APPX +------------------------------- - - ``AppxSignature.p7x`` +Unpack and modify the APPX file using Developer PowerShell for Visual Studio 2022: - - ``AppxBlockMap.xml`` +.. code-block:: console - - ``ApplicationInsights.config`` + makeappx unpack /p C:\BF\BraveFrontier_2.19.6.0_x86.appx /d C:\BF\BraveFrontierAppxClient -3. Open ``AppxManifest.xml`` in a text editor (e.g., Notepad++) and locate this line: +.. note:: + Launch "Developer PowerShell for Visual Studio 2022" from the Start menu to ensure SDK access. - :: +Copy the proxy library: - +.. code-block:: console - Replace ``CN=5AA816A3-ED94-4AA2-A2B4-3ADDA1FABFB6`` with ``CN=``, where ```` matches the name used during certificate generation (e.g., "My BraveFrontier"). This ensures the application installs correctly. + Copy-Item C:\BF\offline-proxy\Debug\libcurl.dll C:\BF\BraveFrontierAppxClient -Force -4. (Optional) Modify the ``Properties`` tag to customize the app’s display details, such as: +Delete unnecessary files: - :: +.. code-block:: console - - Brave Frontier - 株式会社gumi - Assets\StoreLogo.png - + Remove-Item C:\BF\BraveFrontierAppxClient\AppxMetadata -Recurse -Force + Remove-Item C:\BF\BraveFrontierAppxClient\AppxSignature.p7x, C:\BF\BraveFrontierAppxClient\AppxBlockMap.xml, C:\BF\BraveFrontierAppxClient\ApplicationInsights.config -Force -5. (Optional) To change the app’s name in the Windows Start menu, edit this tag: +Edit the manifest: - :: +#. Open ``C:\BF\BraveFrontierAppxClient\AppxManifest.xml`` in Notepad++. +#. Locate the line: ````. +#. Replace the Publisher CN with ``CN=MyBraveFrontier``. +#. (Optional) Update ``DisplayName`` to "Brave Frontier Offline" under ````. +#. Save and close. - " BraveFrontierPatched.appx + makeappx pack /d C:\BF\BraveFrontierAppxClient /p C:\BF\BraveFrontierPatched.appx + SignTool sign /a /v /fd SHA256 /f C:\BF\MyKey.pfx /p "YourStrongPassword" C:\BF\BraveFrontierPatched.appx .. note:: - - Replace ```` with the password used when exporting the certificate. + Ensure the password matches the one used during certificate export. Running the Game ----------------- +------------------ -Install the newly generated ``BraveFrontierPatched.appx`` file and launch the client. If all steps were followed correctly, a console window should appear alongside the game client, as shown below: +Install the patched client: -.. image:: - ../../images/dev-client-winrt/bf_appx_patched.png +.. code-block:: powershell -.. warning:: + Add-AppxPackage C:\BF\BraveFrontierPatched.appx - If no console appears, check the following: - - - Ensure the patched ``libcurl.dll`` was correctly installed. +Enable loopback for local server communication: - - Verify you did not use the ``deploy`` preset, as it is not supported in this build. +#. Download the Enable Loopback Utility: https://telerik-fiddler.s3.amazonaws.com/fiddler/addons/enableloopbackutility.exe +#. Run the utility and select "Brave Frontier". +#. Check "Enable loopback" and click "Save Changes". +#. If an error occurs, enable Device Portal in Settings > Update & Security > For developers and disable "Restrict to loopback connections only". - - Confirm Developer Mode is enabled on your Windows PC. +.. image:: ../../images/dev-client-winrt/loopback_win.png + :alt: Loopback Utility Configuration -Connecting to the Server -~~~~~~~~~~~~~~~~~~~~~~~~ +Launch the game by searching "Brave Frontier" in the Start menu. A console window should appear alongside the client. -Due to a default limitation in UWP apps, they cannot communicate with localhost, preventing the game from connecting to the server. To resolve this: +.. image:: ../../images/dev-client-winrt/bf_appx_patched.png + :alt: Running the Patched Game Client -1. Download the `Enable Loopback Utility `_. -2. Run the utility and select the Brave Frontier application. -3. Configure it as shown below, then click ``Save Changes`` and restart the game: +.. warning:: + If no console appears, verify the following: + - The patched ``libcurl.dll`` was correctly installed. + - Developer Mode is enabled on your Windows PC. -.. note:: +Connecting to the Server +-------------------------- - If Loopback Utility reports an error while saving changes, ensure Device Portal is enabled, and the ``Restrict to loopback connections only`` option is disabled under Developer settings. +Run the standalone server (e.g., ``standalone_frontend.exe`` from prior server automation) on ``127.0.0.1:9960``. With the loopback utility configured, the game should connect to the local server and display the login screen. -.. image:: - ../../images/dev-client-winrt/loopback_win.png +Troubleshooting +----------------- -If the game server is running, you should now see the Brave Frontier login screen upon launching the game. +- **Build Fails**: Ensure Visual Studio 2022 C++ workload is installed. Rebuild in VS if needed. +- **Unpack Error**: Verify the APPX path and Developer PowerShell for Visual Studio 2022 usage. +- **Signing Error**: Check certificate installation and password. +- **No Console**: Confirm DLL replacement and Developer Mode. From b95d9beaa48e2c6d34efc9be2eaffab325800b56 Mon Sep 17 00:00:00 2001 From: Evan Date: Tue, 12 Aug 2025 11:54:27 -0400 Subject: [PATCH 2/4] Update dev-client-winrt.rst --- source/pages/Tutorial/dev-client-winrt.rst | 73 +++++++++++----------- 1 file changed, 38 insertions(+), 35 deletions(-) diff --git a/source/pages/Tutorial/dev-client-winrt.rst b/source/pages/Tutorial/dev-client-winrt.rst index 06783a9..1bc8931 100644 --- a/source/pages/Tutorial/dev-client-winrt.rst +++ b/source/pages/Tutorial/dev-client-winrt.rst @@ -4,21 +4,21 @@ :format: html Setting Up a Development Game Client (Windows 8.1+) -==================================================== +================================================== .. contents:: :local: Introduction --------------- +------------ This tutorial guides you through setting up a development game client for Brave Frontier on Windows 8.1 and later, enabling offline play via a local proxy server. It assumes you have Visual Studio 2022 installed with the Desktop development with C++ workload and the Windows 10 SDK. The process involves cloning the repository, building the proxy, generating certificates, modifying the game client, and enabling loopback for local testing. .. note:: - If you are brand new to development, follow the exact folder structure shown in this tutorial (e.g., creating a folder on the root of your C: drive called BF). This will make storage and following along easier. You are free to use any folder structure you are comfortable with, but adjust paths in commands accordingly. + If you are brand new to development, follow the exact folder structure shown in this tutorial (e.g., creating a folder named BF under your user profile directory). This will make storage and following along easier. You are free to use any folder structure you are comfortable with, but adjust paths in commands accordingly. Requirements --------------- +------------ .. warning:: If Developer Mode is not installed or enabled in Windows, the proxy will not function, and you will not see the command prompt. @@ -30,35 +30,43 @@ Requirements - Administrator privileges Cloning the Repository ------------------------- +---------------------- To clone the offline-proxy repository, open PowerShell and run the following command: .. code-block:: console - cd C:\BF + cd $env:USERPROFILE\BF git clone --depth=1 https://github.com/decompfrontier/offline-proxy - cd C:\BF\offline-proxy + cd $env:USERPROFILE\BF\offline-proxy .. note:: - Adjust the directory (e.g., ``C:\BF``) if you prefer a different location. + The `$env:USERPROFILE` variable automatically points to your user directory (e.g., `C:\Users\YourUsername`). Adjust the path if you use a different structure. Building the Proxy --------------------- +------------------ .. warning:: The client only supports 32-bit platforms. Ensure the build targets Win32. +First, configure the project to generate the necessary solution file (`.sln`): + +.. code-block:: console + + cmake --preset debug-vs + +This command uses the Visual Studio preset to set up the project for a Debug build, creating the `.sln` file. If you encounter issues (e.g., "CMakePresets.json not found"), ensure your Visual Studio environment is correctly installed, or proceed manually with `cmake -G "Visual Studio 17 2022" -A Win32`. + Build the proxy using the following steps: .. code-block:: console cmake --build . --config Debug -If the build fails, open ``offline-proxy.sln`` in Visual Studio 2022, set the solution platform to Win32 and configuration to Debug, then build (F7 or in some situations if you have an "Fn Lock" style keyboard ``Fn`` + ``F7``). After a successful build, locate ``libcurl.dll`` in ``C:\BF\offline-proxy\Debug\libcurl.dll`` (or search the Debug folder). +If the build fails, open ``offline-proxy.sln`` in Visual Studio 2022, set the solution platform to Win32 and configuration to Debug, then build (F7 or, with an "Fn Lock" keyboard, ``Fn`` + ``F7``). After a successful build, locate ``libcurl.dll`` in ``$env:USERPROFILE\BF\offline-proxy\bin\libcurl.dll`` (or search the bin folder). Generating UWP Development Certificates ------------------------------------------ +--------------------------------------- Generate a development certificate to sign the modified client: @@ -71,25 +79,20 @@ Generate a development certificate to sign the modified client: .. note:: The output will show a Thumbprint (e.g., ``ABC123...``). Highlight the first line of the output (starting with "Thumbprint") with your mouse, right-click to copy, then paste it into the next command using right-click paste. Use arrow keys (up/down/left/right) to navigate and edit the ``$thumbprint`` variable. This is a basic CLI skill: right-click pastes copied text, and arrow keys move the cursor without needing the mouse. -``TODO: Add an gif here to show the process`` - Export the certificate: .. code-block:: powershell $thumbprint = "ABC123..." # Paste and edit your Thumbprint here using right-click paste and arrow keys $password = ConvertTo-SecureString -String "YourStrongPassword" -Force -AsPlainText # Change password - Export-PfxCertificate -cert "Cert:\CurrentUser\My\$thumbprint" -FilePath C:\BF\MyKey.pfx -Password $password + Export-PfxCertificate -cert "Cert:\CurrentUser\My\$thumbprint" -FilePath $env:USERPROFILE\BF\MyKey.pfx -Password $password Install the certificate: -#. Double-click ``C:\BF\MyKey.pfx`` to launch the Certificate Import Wizard. +#. Double-click ``$env:USERPROFILE\BF\MyKey.pfx`` to launch the Certificate Import Wizard. #. Select ``Local Machine`` and proceed. #. Choose ``Trusted Root Certification Authorities`` as the store. -#. Click ``Finish``, then confirm with ``Yes``. (``TODO: This step was a part of the legacy setup and needs a redone photo.``) - -.. image:: ../../images/dev-client-winrt/certpath_win.png - :alt: Installing the Custom Certificate +#. Click ``Finish``, then confirm with ``Yes``. .. warning:: Remove these certificates when you are done with Brave Frontier development to prevent compromising system trust. Removing the certificate after installing the patched BraveFrontier APPX is a safety step and will prevent launching the patched APPX if it relies on ongoing verification. @@ -98,24 +101,24 @@ Install the certificate: All commands must be executed in PowerShell with administrator privileges. Obtaining the APPX File -------------------------- +----------------------- Download the unmodified Brave Frontier APPX file from the provided link: - URL: https://drive.google.com/file/d/1NB64gzQOe-QQx9fY0mkoZiCSfe3WlTYi/view?usp=sharing -- Save as: ``C:\BF\BraveFrontier_2.19.6.0_x86.appx`` (right-click link > Save As). +- Save as: ``$env:USERPROFILE\BF\BraveFrontier_2.19.6.0_x86.appx`` (right-click link > Save As). .. note:: - Verify the file size (~100MB) to ensure integrity. This file is not publicly hosted elsewhere; direct downloads are rare and often risky (e.g., APKs from APKPure/BlueStacks). If issues arise, extract from an installed app: ``Get-AppxPackage *BraveFrontier* | Export-AppxPackage -Path C:\BF\BraveFrontier.appx``. + Verify the file size (~100MB) to ensure integrity. This file is not publicly hosted elsewhere; direct downloads are rare and often risky (e.g., APKs from APKPure/BlueStacks). If issues arise, extract from an installed app: ``Get-AppxPackage *BraveFrontier* | Export-AppxPackage -Path $env:USERPROFILE\BF\BraveFrontier.appx``. Modifying Brave Frontier APPX -------------------------------- +----------------------------- Unpack and modify the APPX file using Developer PowerShell for Visual Studio 2022: .. code-block:: console - makeappx unpack /p C:\BF\BraveFrontier_2.19.6.0_x86.appx /d C:\BF\BraveFrontierAppxClient + makeappx unpack /p $env:USERPROFILE\BF\BraveFrontier_2.19.6.0_x86.appx /d $env:USERPROFILE\BF\BraveFrontierAppxClient .. note:: Launch "Developer PowerShell for Visual Studio 2022" from the Start menu to ensure SDK access. @@ -124,18 +127,18 @@ Copy the proxy library: .. code-block:: console - Copy-Item C:\BF\offline-proxy\Debug\libcurl.dll C:\BF\BraveFrontierAppxClient -Force + Copy-Item $env:USERPROFILE\BF\offline-proxy\bin\libcurl.dll $env:USERPROFILE\BF\BraveFrontierAppxClient -Force Delete unnecessary files: .. code-block:: console - Remove-Item C:\BF\BraveFrontierAppxClient\AppxMetadata -Recurse -Force - Remove-Item C:\BF\BraveFrontierAppxClient\AppxSignature.p7x, C:\BF\BraveFrontierAppxClient\AppxBlockMap.xml, C:\BF\BraveFrontierAppxClient\ApplicationInsights.config -Force + Remove-Item $env:USERPROFILE\BF\BraveFrontierAppxClient\AppxMetadata -Recurse -Force + Remove-Item $env:USERPROFILE\BF\BraveFrontierAppxClient\AppxSignature.p7x, $env:USERPROFILE\BF\BraveFrontierAppxClient\AppxBlockMap.xml, $env:USERPROFILE\BF\BraveFrontierAppxClient\ApplicationInsights.config -Force Edit the manifest: -#. Open ``C:\BF\BraveFrontierAppxClient\AppxManifest.xml`` in Notepad++. +#. Open ``$env:USERPROFILE\BF\BraveFrontierAppxClient\AppxManifest.xml`` in Notepad++. #. Locate the line: ````. #. Replace the Publisher CN with ``CN=MyBraveFrontier``. #. (Optional) Update ``DisplayName`` to "Brave Frontier Offline" under ````. @@ -145,26 +148,26 @@ Edit the manifest: All commands must be executed in Developer PowerShell for Visual Studio 2022. Packing and Signing the Modified Client ------------------------------------------ +--------------------------------------- Pack and sign the modified APPX in Developer PowerShell for Visual Studio 2022: .. code-block:: console - makeappx pack /d C:\BF\BraveFrontierAppxClient /p C:\BF\BraveFrontierPatched.appx - SignTool sign /a /v /fd SHA256 /f C:\BF\MyKey.pfx /p "YourStrongPassword" C:\BF\BraveFrontierPatched.appx + makeappx pack /d $env:USERPROFILE\BF\BraveFrontierAppxClient /p $env:USERPROFILE\BF\BraveFrontierPatched.appx + SignTool sign /a /v /fd SHA256 /f $env:USERPROFILE\BF\MyKey.pfx /p "YourStrongPassword" $env:USERPROFILE\BF\BraveFrontierPatched.appx .. note:: Ensure the password matches the one used during certificate export. Running the Game ------------------- +---------------- Install the patched client: .. code-block:: powershell - Add-AppxPackage C:\BF\BraveFrontierPatched.appx + Add-AppxPackage $env:USERPROFILE\BF\BraveFrontierPatched.appx Enable loopback for local server communication: @@ -187,12 +190,12 @@ Launch the game by searching "Brave Frontier" in the Start menu. A console windo - Developer Mode is enabled on your Windows PC. Connecting to the Server --------------------------- +------------------------ Run the standalone server (e.g., ``standalone_frontend.exe`` from prior server automation) on ``127.0.0.1:9960``. With the loopback utility configured, the game should connect to the local server and display the login screen. Troubleshooting ------------------ +--------------- - **Build Fails**: Ensure Visual Studio 2022 C++ workload is installed. Rebuild in VS if needed. - **Unpack Error**: Verify the APPX path and Developer PowerShell for Visual Studio 2022 usage. From 74e52485b0ebf104f52a222d61c1a4392d7ff9e2 Mon Sep 17 00:00:00 2001 From: Evan Date: Tue, 12 Aug 2025 11:56:21 -0400 Subject: [PATCH 3/4] Update dev-client-winrt.rst --- source/pages/Tutorial/dev-client-winrt.rst | 24 +++++++++++----------- 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/source/pages/Tutorial/dev-client-winrt.rst b/source/pages/Tutorial/dev-client-winrt.rst index 1bc8931..91ed4a9 100644 --- a/source/pages/Tutorial/dev-client-winrt.rst +++ b/source/pages/Tutorial/dev-client-winrt.rst @@ -4,13 +4,13 @@ :format: html Setting Up a Development Game Client (Windows 8.1+) -================================================== +==================================================== .. contents:: :local: Introduction ------------- +------------- This tutorial guides you through setting up a development game client for Brave Frontier on Windows 8.1 and later, enabling offline play via a local proxy server. It assumes you have Visual Studio 2022 installed with the Desktop development with C++ workload and the Windows 10 SDK. The process involves cloning the repository, building the proxy, generating certificates, modifying the game client, and enabling loopback for local testing. @@ -18,7 +18,7 @@ This tutorial guides you through setting up a development game client for Brave If you are brand new to development, follow the exact folder structure shown in this tutorial (e.g., creating a folder named BF under your user profile directory). This will make storage and following along easier. You are free to use any folder structure you are comfortable with, but adjust paths in commands accordingly. Requirements ------------- +------------- .. warning:: If Developer Mode is not installed or enabled in Windows, the proxy will not function, and you will not see the command prompt. @@ -30,7 +30,7 @@ Requirements - Administrator privileges Cloning the Repository ----------------------- +----------------------- To clone the offline-proxy repository, open PowerShell and run the following command: @@ -44,7 +44,7 @@ To clone the offline-proxy repository, open PowerShell and run the following com The `$env:USERPROFILE` variable automatically points to your user directory (e.g., `C:\Users\YourUsername`). Adjust the path if you use a different structure. Building the Proxy ------------------- +------------------- .. warning:: The client only supports 32-bit platforms. Ensure the build targets Win32. @@ -66,7 +66,7 @@ Build the proxy using the following steps: If the build fails, open ``offline-proxy.sln`` in Visual Studio 2022, set the solution platform to Win32 and configuration to Debug, then build (F7 or, with an "Fn Lock" keyboard, ``Fn`` + ``F7``). After a successful build, locate ``libcurl.dll`` in ``$env:USERPROFILE\BF\offline-proxy\bin\libcurl.dll`` (or search the bin folder). Generating UWP Development Certificates ---------------------------------------- +---------------------------------------- Generate a development certificate to sign the modified client: @@ -101,7 +101,7 @@ Install the certificate: All commands must be executed in PowerShell with administrator privileges. Obtaining the APPX File ------------------------ +------------------------ Download the unmodified Brave Frontier APPX file from the provided link: @@ -112,7 +112,7 @@ Download the unmodified Brave Frontier APPX file from the provided link: Verify the file size (~100MB) to ensure integrity. This file is not publicly hosted elsewhere; direct downloads are rare and often risky (e.g., APKs from APKPure/BlueStacks). If issues arise, extract from an installed app: ``Get-AppxPackage *BraveFrontier* | Export-AppxPackage -Path $env:USERPROFILE\BF\BraveFrontier.appx``. Modifying Brave Frontier APPX ------------------------------ +------------------------------ Unpack and modify the APPX file using Developer PowerShell for Visual Studio 2022: @@ -148,7 +148,7 @@ Edit the manifest: All commands must be executed in Developer PowerShell for Visual Studio 2022. Packing and Signing the Modified Client ---------------------------------------- +----------------------------------------- Pack and sign the modified APPX in Developer PowerShell for Visual Studio 2022: @@ -161,7 +161,7 @@ Pack and sign the modified APPX in Developer PowerShell for Visual Studio 2022: Ensure the password matches the one used during certificate export. Running the Game ----------------- +----------------- Install the patched client: @@ -190,12 +190,12 @@ Launch the game by searching "Brave Frontier" in the Start menu. A console windo - Developer Mode is enabled on your Windows PC. Connecting to the Server ------------------------- +-------------------------- Run the standalone server (e.g., ``standalone_frontend.exe`` from prior server automation) on ``127.0.0.1:9960``. With the loopback utility configured, the game should connect to the local server and display the login screen. Troubleshooting ---------------- +---------------- - **Build Fails**: Ensure Visual Studio 2022 C++ workload is installed. Rebuild in VS if needed. - **Unpack Error**: Verify the APPX path and Developer PowerShell for Visual Studio 2022 usage. From 21a82227a078b19b1481d69a3a2d2e2bbac2ccf9 Mon Sep 17 00:00:00 2001 From: Evan Date: Tue, 26 Aug 2025 11:27:31 -0400 Subject: [PATCH 4/4] Update dev-client-winrt.rst Added a space to the warning --- source/pages/Tutorial/dev-client-winrt.rst | 1 + 1 file changed, 1 insertion(+) diff --git a/source/pages/Tutorial/dev-client-winrt.rst b/source/pages/Tutorial/dev-client-winrt.rst index 91ed4a9..5afc995 100644 --- a/source/pages/Tutorial/dev-client-winrt.rst +++ b/source/pages/Tutorial/dev-client-winrt.rst @@ -186,6 +186,7 @@ Launch the game by searching "Brave Frontier" in the Start menu. A console windo .. warning:: If no console appears, verify the following: + - The patched ``libcurl.dll`` was correctly installed. - Developer Mode is enabled on your Windows PC.