⚔️ Como Hospedar um Servidor de Ocarina of Time/Ship of Harkinian no Android
Quer jogar o lendário The Legend of Zelda - Ocarina of Time com seus amigos? Tudo o que precisa é de um celular Android, a configuração de um servidor leve de Linux e poucos minutos de seu tempo.
Etapa 1 — Repita o Mesmo Procedimento do Servidor Anterior
-
Baixe Termux e AnLinux no seu Android na Google Play Store.
-
Selecione Ubuntu no AnLinux e copie o código.
-
Execute o comando no Termux.
-
Para iniciar o servidor, execute:
./start-ubuntu.sh-
Você pode renomear para
s, executando:mv start-ubuntu.sh sIsso permite entrar no Ubuntu escrevendo apenas
./s.
-
IMPORTANTE: Arraste para baixo na barra de notificações — deve haver uma opção de Wakelock para o Termux. Isso impede que o serviço seja encerrado e permite que continue funcionando em segundo plano.
Etapa 2 — Instalação dos Componentes Necessários
Antes de instalar os componentes necessários, execute:
apt-get update && apt-get upgrade
apt install nano # Programa de edição e adição de arquivos
apt install curl # Usado para instalação do Ngrok, serve para obter URLs
Instale também o Git e o Deno:
apt install git # Utilizado para clonar o repositório contendo o projeto do servidor
curl -fsSL https://deno.land/install.sh | sh -s v1.46.3 # Aplicação responsável pela execução do servidor e das sessões
Instalação: Você pode selecionar uma outra versão do Deno, contanto que seja anterior a 2.0.0.
Certifique-se da instalação com:
deno -version
Etapa 3 — Configurando o Servidor Anchor
-
Clone (transfira) o repositório do GitHub e acesse a nova pasta criada:
git clone https://github.com/garrettjoecox/anchor.git && cd anchor -
Inicialize o servidor sem alterações, utilizando a porta padrão
43385:deno run --allow-all mod.ts -
Para executar em uma porta específica (caso queira usar a mesma do Minecraft, por exemplo):
PORT={Nº da porta} deno run --allow-all mod.ts -
Você pode realizar alterações no código editando o arquivo
mod.tsna pastaanchor. Porém, o servidor já está funcional sem modificações. -
O servidor estará ativo quando a seguinte mensagem for exibida:
[Server]: Server Started on port {Nº da porta ativa} -
Para encerrar o servidor:
Ctrl+C
Etapa 4 — Configurando o Ngrok (Repita o Procedimento do Servidor Anterior)
-
Acesse ngrok.com.
-
Crie uma conta e faça login.
-
Na página Dashboard, selecione Linux em Agents.
-
Copie e cole o comando
curlfornecido pelo site para instalar. Caso não funcione, use:apt install ngrok -
Após instalar o programa, copie e cole o comando contendo o Token de Autenticação fornecido pelo site (algo parecido com isto):
ngrok config add-authtoken [...] -
Gere um link de acesso ao servidor:
ngrok tcp 25565Cada vez que é inicializado, o link gerado é diferente. O site requer o cadastro de um cartão de crédito, mas este serviço não é cobrado — serve apenas para verificar a identidade do usuário como pessoa física (assim como a Oracle faz).IMPORTANTE: Caso queira utilizar a porta25565para abrir a conexão ao servidor, não execute simultaneamente com o servidor Minecraft ou qualquer outro serviço que esteja utilizando esta porta. Caso queira registrar em outra porta, altere25565para outra. O padrão utilizado pelo Anchor é43385. -
Se aparecer "Status da sessão online" em verde, a autenticação foi bem-sucedida. O link de acesso está na linha Forwarding. Copie a parte no formato:
0.tcp.ngrok.io:12345
Etapa 5 — Automatizando a Inicialização
-
Se os dois serviços estiverem funcionando corretamente, é necessário mantê-los ativos simultaneamente. Abra uma nova sessão apertando
Ctrl+Alt+C. -
Alterne entre as sessões com
Ctrl+Alt+↑/↓ouCtrl+Alt+P/N. Você também pode fazer isso pela aba do Termux. -
Para simplificar, crie arquivos sem extensão para iniciar o servidor Anchor e o serviço do Ngrok:
Script do Anchor:
nano zConteúdo:
#!/bin/bash cd ./anchor PORT={Nº da porta} deno run --allow-all mod.tsSalve (
Ctrl+S), saia (Ctrl+X) e dê permissão:chmod +x zScript do Ngrok:
nano nConteúdo:
#!/bin/bash ngrok tcp 25565Salve (
Ctrl+S), saia (Ctrl+X) e dê permissão:chmod +x n -
Execute cada script em uma sessão separada:
./z./n -
Para encerrar os dois serviços, use
Ctrl+Cnas duas sessões ativas.
Etapa 6 — Instalação do Ship of Harkinian
O acesso ao servidor é realizado por meio de um build personalizado do programa, feito pelo próprio usuário garrettjoecox. Pule para a próxima etapa caso já tenha instalado.
- Acesse github.com/garrettjoecox/OOT/pull/64 e baixe o
.zipda aplicação no item Build Artifacts, de acordo com o sistema operacional do seu PC. - Descompacte o
.zipe realize o processo de instalação do jogo. Você precisa obter o arquivo ROM do jogo — deve ser a versão europeia para funcionar corretamente. - Ao iniciar
soh.exepela primeira vez, ele solicitará a criação dos arquivos OTR e a localização da ROM. Aceite a criação, localize seu arquivo ROM e deixe o programa descompactar os assets do jogo. - Terminado o processo, execute
soh.exenovamente e o jogo iniciará com as configurações padrão.
Etapa 6.1 [OPCIONAL] — Configurações Adicionais
-
Configurações: Pressionando
F1é exibido um menu com opções como Enhancements (melhorias) e Settings (configurações gerais, incluindo controle). Por exemplo, é possível jogar sem limitação de FPS e com suporte a teclado e mouse. -
Mods: Você pode personalizar a aparência do jogo instalando modificações na pasta
mods. Acesse gamebanana.com/mods/games/16121 para ver diferentes opções feitas pela comunidade. Para alternar o uso dos mods durante o jogo, pressioneTABou ative a opção Enable Alternate Assets no menu Enhancements.Os mods são aplicados localmente, na instalação do seu jogo — portanto, não afetam os outros jogadores.
Etapa 7 — Conectando ao Servidor
- Pressione
F1para exibir o menu de configurações e abra a aba Network. - Insira as seguintes configurações:
- Remote Interaction Scheme: selecione
Anchor. - Remote IP & Port: escreva o endereço
0.tcp.ngrok.iono primeiro campo e a porta no segundo. - Outras configurações: você pode alternar a cor do seu personagem para diferenciar de outros jogadores ativos, definir seu nome e o ID da sala. Também é possível ativar/desativar janelas de localização dos jogadores (Player Location Window) e de ações realizadas no servidor (Incoming Item Window).
- Remote Interaction Scheme: selecione
- Realizadas as configurações, selecione Enable para conectar-se ao servidor. Caso não funcione, verifique as configurações e se o servidor está rodando normalmente.
Se tudo der certo, jogue e seja feliz!
Fontes
- GitHub — garrettjoecox/OOT Pull Request_#64
- GitHub — garrettjoecox/anchor — contém mais informações, como alterar configurações de conexão, usar Docker, etc.
- Deno — Guia de Instalação
- GameBanana — Ocarina of Time Mods
- YouTube — Ocarina of Time Multiplayer Setup — pelo canal A Couple of Average Gamers
⚔️ How to Host an Ocarina of Time/Ship of Harkinian Server on Android
Want to play the legendary The Legend of Zelda - Ocarina of Time with your friends? All that is necessary is an Android phone, a lightweight Linux server configuration and a few minutes of your time.
Step 1 — Repeat the Same Procedure as the Previous Server
-
Download Termux and AnLinux on your Android from the Google Play Store.
-
Select Ubuntu in AnLinux and copy the code.
-
Run the command in Termux.
-
To start the server, run:
./start-ubuntu.sh-
You can rename it to
sby running:mv start-ubuntu.sh sThis lets you enter Ubuntu just by typing
./s.
-
IMPORTANT: Pull down the notification bar — there should be a Wakelock option for Termux. This prevents the service from being killed and lets it keep running in the background.
Step 2 — Installing the Required Components
Before installing the required components, run:
apt-get update && apt-get upgrade
apt install nano # Editing/file-adding program
apt install curl # Used for installing Ngrok, used to get URLs
Also install Git and Deno:
apt install git # Used to clone the repository containing the server project
curl -fsSL https://deno.land/install.sh | sh -s v1.46.3 # Application responsible for running the server and sessions
Installation: You can select a different Deno version, as long as it's earlier than 2.0.0.
Confirm the installation with:
deno -version
Step 3 — Setting Up the Anchor Server
-
Clone (transfer) the GitHub repository and go into the newly created folder:
git clone https://github.com/garrettjoecox/anchor.git && cd anchor -
Start the server with no changes, using the default port
43385:deno run --allow-all mod.ts -
To run on a specific port (in case you want to use the same one as Minecraft, for example):
PORT={port number} deno run --allow-all mod.ts -
You can make changes to the code by editing the
mod.tsfile in theanchorfolder. However, the server already works fine without modifications. -
The server will be active once the following message appears:
[Server]: Server Started on port {active port number} -
To stop the server:
Ctrl+C
Step 4 — Setting Up Ngrok (Repeat the Procedure from the Previous Server)
-
Go to ngrok.com.
-
Create an account and log in.
-
On the Dashboard page, select Linux under Agents.
-
Copy and paste the
curlinstall command provided by the site. If it doesn't work, use:apt install ngrok -
After installing the program, copy and paste the command containing the Auth Token provided by the site (something like this):
ngrok config add-authtoken [...] -
Generate an access link to the server:
ngrok tcp 25565Each time it's started, the generated link is different. The site requires registering a credit card, but this service is not charged — it's only used to verify the user's identity as a real person (the same way Oracle does).IMPORTANT: If you want to use port25565to open the connection to the server, do not run it at the same time as the Minecraft server or any other service using this port. If you want to register on another port, change25565to a different one. The default used by Anchor is43385. -
If "Session Status: online" appears in green, authentication was successful. The access link is on the Forwarding line. Copy the part in the format:
0.tcp.ngrok.io:12345
Step 5 — Automating Startup
-
If both services are working correctly, you need to keep them running simultaneously. Open a new session by pressing
Ctrl+Alt+C. -
Switch between sessions with
Ctrl+Alt+↑/↓orCtrl+Alt+P/N. You can also do this from the Termux tab. -
To simplify things, create extensionless files to start the Anchor server and the Ngrok service:
Anchor script:
nano zContent:
#!/bin/bash cd ./anchor PORT={port number} deno run --allow-all mod.tsSave (
Ctrl+S), exit (Ctrl+X), and grant permission:chmod +x zNgrok script:
nano nContent:
#!/bin/bash ngrok tcp 25565Save (
Ctrl+S), exit (Ctrl+X), and grant permission:chmod +x n -
Run each script in a separate session:
./z./n -
To stop both services, use
Ctrl+Cin both active sessions.
Step 6 — Installing Ship of Harkinian
Access to the server is done through a custom build of the program made by the user garrettjoecox themselves. Skip to the next step if you've already installed it.
- Go to github.com/garrettjoecox/OOT/pull/64 and download the app's
.zipfrom the Build Artifacts item, matching your PC's operating system. - Unzip the
.zipfile and go through the game's install process. You'll need to obtain the game's ROM file — it must be the European version to work correctly. - The first time you launch
soh.exe, it will ask you to create the OTR files and locate the ROM. Accept the creation, locate your ROM file, and let the program unpack the game's assets. - Once finished, run
soh.exeagain and the game will start with the default settings.
Step 6.1 [OPTIONAL] — Additional Settings
-
Settings: Pressing
F1shows a menu with options like Enhancements and Settings (general settings, including controls). For example, you can play with no FPS cap and with keyboard/mouse support. -
Mods: You can customize the game's appearance by installing modifications in the
modsfolder. Go to gamebanana.com/mods/games/16121 to see different options made by the community. To toggle mod usage during gameplay, pressTABor enable the Enable Alternate Assets option in the Enhancements menu.Mods are applied locally, on your own game install — so they don't affect other players.
Step 7 — Connecting to the Server
- Press
F1to bring up the settings menu and open the Network tab. - Enter the following settings:
- Remote Interaction Scheme: select
Anchor. - Remote IP & Port: enter
0.tcp.ngrok.ioin the first field and the port in the second. - Other settings: you can change your character's color to set yourself apart from other active players, set your name and the room ID. You can also enable/disable the Player Location Window and the Incoming Item Window.
- Remote Interaction Scheme: select
- Once configured, select Enable to connect to the server. If it doesn't work, check your settings and whether the server is running properly.
If everything works, play and have fun!
Sources
- GitHub — garrettjoecox/OOT Pull Request_#64
- GitHub — garrettjoecox/anchor — contains more information, such as changing connection settings, using Docker, etc.
- Deno — Installation Guide
- GameBanana — Ocarina of Time Mods
- YouTube — Ocarina of Time Multiplayer Setup — by the channel A Couple of Average Gamers
Comments