Repository navigation
BOTWRecompAndroid 0.2.2 (beta 15): modo nativo / native mode
Pre-releaseBeta 15. Chegou o modo nativo (experimental): o código do jogo roda direto na CPU do celular, sem compilar nada.
Novidades
Modo nativo (experimental)
Até agora, configurar o jogo significava compilar o código dele no próprio celular: uma espera longa, o aparelho quente, e em alguns celulares a compilação nem chegava ao fim. O Switch e os celulares Android usam processadores ARM64, então o código original do jogo pode rodar direto na CPU. O app só ajusta, ao carregar, as poucas instruções que dependem do Switch (chamadas ao sistema, registradores das threads, o relógio).
- Sem compilação: no modo nativo, a configuração só copia os arquivos do jogo. Para quem nunca conseguiu terminar a compilação, pode ser a saída.
- Como escolher: em Arquivos do jogo, a nova opção Código do jogo vem antes da pasta: Recompilado (como antes: o celular compila o código uma vez) ou Nativo (experimental).
- Dá para alternar: quem configurou como Recompilado pode ligar o nativo a qualquer momento em Vídeo > Código nativo do jogo (experimental). Quem configurou só como Nativo precisa compilar se depois quiser o Recompilado.
- Estado: joga-se do título ao mundo, com saves e reinício, na 1.9.0 e na 1.0.0. A 1.6.0 e a 1.8.2 ainda não foram testadas. O FPS fica parecido com o do Recompilado, mas oscila um pouco mais. O Link às vezes pisca num golpe, e as "cortinas" do terreno aparecem com mais frequência. Se algo der errado, conte numa issue com o log (Configurações > Arquivos > Salvar arquivo de log).
A ideia veio do MacNativeGames, do totk-mobile e do d2r-mobile, que rodam o código de BOTW e TOTK assim no Mac e no iPhone.
Cutscenes a 60 fps (experimental)
Em Vídeo > Cutscenes a 60 fps (experimental), as cenas e conversas feitas no próprio jogo rodam na taxa de quadros escolhida, em vez de ficarem presas em 30. Os vídeos pré-gravados continuam como são.
Correções
- Água branca e Link afundando (#43): desde a 0.2.1, algumas lagoas ficavam brancas, e as pernas do Link afundavam no chão quando ele ficava parado. Os resultados que a GPU devolve ao jogo (a cor da água, a altura do chão sob os pés) às vezes eram aplicados fora de ordem, e um valor antigo cobria o novo. Agora são aplicados na ordem certa. No teste, com o Sync lag ligado: água normal, Link no chão e 58-60 fps.
- A 1.6.0 não abria depois de compilar (#56, #60): o erro era
cannot locate symbol "__ubsan_handle_type_mismatch_v1". Uma compilação interrompida na 0.2.0 continuava na 0.2.1 com partes compiladas do jeito antigo. Agora ela recomeça do zero quando a forma de compilar muda. Se o seu código do jogo já ficou montado assim, o app percebe ao abrir: feche o aviso, abra o app de novo e compile outra vez em Arquivos do jogo.
Não precisa compilar o código do jogo de novo: é só instalar por cima da 0.2.x. Quem vem de uma versão anterior à 0.2.0 compila uma vez (o app avisa), ou escolhe o modo nativo.
Problemas conhecidos
- Num golpe, a névoa do horizonte e a nuvem da Montanha da Morte às vezes se esticam em pontas por um quadro. Acontece desde a 0.2.0 e está em investigação.
- A grama baixa perto do Link às vezes some; em investigação.
- Às vezes, logo depois da cena de ativação de uma torre, o terreno aparece esticado em "cortinas". Para resolver, carregue o save depois de a torre estar ativada.
- O reflexo na água acompanha a câmera quando o Link anda para os lados.
- No driver de fábrica da Qualcomm, o fundo do menu de pausa fica preto.
Nenhum arquivo do jogo vem incluído. Testada num celular só (POCO F7 Ultra, Adreno 830, Turnip). Novidades da 0.2: veja a 0.2.0-beta. Para instalar e configurar: 0.1.0-beta. Créditos no README.
Beta 15. Introducing native mode (experimental): the game's code runs directly on the phone's CPU, with nothing to build.
What's new
Native mode (experimental)
Until now, setting the game up meant building its code on the phone itself: a long wait, a hot phone, and on some phones the build never finished. The Switch and Android phones both use ARM64 processors, so the game's original code can run directly on the CPU. When it loads, the app adjusts only the few instructions that depend on the Switch (system calls, the thread registers, the clock).
- No build: in native mode, the setup only copies the game files. If you could never get the build to finish, this may be the way in.
- How to choose: on Game Files, the new Game code option comes before the folder: Recompiled (as before: the phone builds the code once) or Native (experimental).
- You can switch: set up as Recompiled, you can turn native on any time in Video > Native game code (experimental). Set up as Native only, you'll need to build if you later want Recompiled.
- Status: it plays from the title screen into the world, with saves and restarts, on 1.9.0 and 1.0.0. 1.6.0 and 1.8.2 haven't been tested yet. The frame rate is about the same as Recompiled's, but it wavers a little more. Link sometimes flickers on a hit, and the terrain's "curtains" show more often. If something goes wrong, open an issue with the log (Settings > Files > Save a log file).
The idea came from MacNativeGames, totk-mobile and d2r-mobile, which run BOTW's and TOTK's code this way on the Mac and iPhone.
Cutscenes at 60 fps (experimental)
In Video > Cutscenes at 60 fps (experimental), the game's own in-engine cutscenes and conversations run at the chosen frame rate instead of being held at 30. Pre-recorded movies stay as they are.
Fixes
- White water and Link sinking (#43): since 0.2.1, some ponds turned white, and Link's legs sank into the ground while he stood still. The results the GPU hands back to the game (the water's colour, the ground's height under his feet) were sometimes applied out of order, so an old value covered the new one. Now they're applied in order. In testing, with Sync lag on: normal water, Link on the ground, 58-60 fps.
- 1.6.0 wouldn't open after building (#56, #60): the error was
cannot locate symbol "__ubsan_handle_type_mismatch_v1". A build stopped on 0.2.0 went on in 0.2.1 with parts compiled the old way. Now the build starts over whenever the way it compiles changes. If your game code was already put together that way, the app notices when it opens: close the message, open the app again and build once more from Game Files.
No need to build the game code again: just install over 0.2.x. Coming from a version before 0.2.0, it's built once (the app says so), or choose native mode.
Known issues
- On a hit, the horizon's fog and Death Mountain's cloud sometimes stretch into spikes for one frame. This has happened since 0.2.0 and is under investigation.
- The short grass near Link sometimes disappears; under investigation.
- Sometimes, right after a tower's activation scene, the terrain shows stretched into "curtains". To fix it, load the save once the tower is active.
- The water's reflection follows the camera when Link walks sideways.
- On Qualcomm's stock driver, the pause menu's background is black.
No game files are included. Tested on one phone only (POCO F7 Ultra, Adreno 830, Turnip). What's new in 0.2: see 0.2.0-beta. To install and set up: 0.1.0-beta. Credits in the README.
