neo-engine / neo

A homebrew Pokémon nds game; written from scratch using libnds and devkitPro
GNU General Public License v3.0
110 stars 8 forks source link

Some bugs when trying to play through twilight 3DS menu #25

Closed Srchronotrigger closed 9 months ago

Srchronotrigger commented 1 year ago

I recently tried to play pokémon neo project on the Old 3DS via the Twilight menu, but unfortunately the game only loaded with some strings on the screen written "(uistring failed)" and no graphics were rendered, the tested version of the game was 1.0.1-alpha , and the version of Twilight until then was something released around 2020 which was probably the date I had initially installed it, so I updated that version to v25.7.0 (latest on the date I write this issue), and the error remains.

Screenshot ![img](https://user-images.githubusercontent.com/45925523/213716957-1c22acaf-b34b-49ac-a480-d9f5310de1f2.jpg)

So I downloaded some other previous versions to test, the v0.9.7 and v0.8, the 1.0-alpha I didn't find the compiled version on the github of the project, both versions 0.97 and 0.8 render normally, both does't have that bug from 1.0.1-alpha , but in all versions from what I've seen, the controls freeze after some time, in the first test on the 0.97 the game has freeze after i entered in the bedroom of the protagonist and went down the stairs, the game has stuck on dialog, but the Vigoroths animation it was normal, only the text or controls has stucked, theese bugs of freezing apparenly ocurrs on the three versions, even on the 1.0.1-alpha freezes if you remain waiting on menu.

the name of the game displayed on menu also has bug, it doesn't occurs on the v0.9.7 and v0.8.

Screenshot ![img](https://user-images.githubusercontent.com/45925523/213725410-a10eb2a1-1ab0-4b69-8d3f-c0e707085a7b.jpg)

Menu stucked, this picture is on v0.8 if I remember.

Screenshot ![img](https://user-images.githubusercontent.com/45925523/213726980-a63bfbbf-5a8a-4dbe-91ec-35c9078de926.jpg)

in one of the tests, if I'm not mistaken in version v0.9.7, my console crashed and I had to turn it off using the power button, I don't know if this is related to the game or if it was just a coincidence, I don't remember if this had already happened before with my 3ds.

Apparently change the execution mode between default, dsi and ds. It doesn't affect anything, I tested it only on 1.0.1-alpha.

well, from the tests I've done this is all I've noticed and I think it's relevant to help find the bugs, I'm sorry if anything got confusing, as you can see I'm not a native English speaker.

PH111P commented 1 year ago

Hi @Srchronotrigger,

Thanks for this report (and the already quite extensive tests)!

Could you perhaps test the "DESQUID"-version of v1.0.1-alpha (https://github.com/neo-engine/neo/releases/download/1.0.1-alpha/PNEO_DESQUID_1.0.1-alpha.nds)?

Ideally, you would be greeted by the following screen, but I would think that on a 3DS some of the "[ OK ]" will turn into a "[FAIL]" (the "(uistring failed)" makes me believe that at least the FSROOT should show up as FAIL).

Screenshot_2023-01-21_05-55-44

I will try to investigate as well once I get twilight running on my 3DS again (hopefully soon).

Srchronotrigger commented 1 year ago

promptly, I tested the version you asked for as you mentioned, the SFROOT item fails, on the top screen it just shows garbage, while I was taking the picture apparently the game also freezes, I forgot to mention earlier, but apparently when that happens the L + R + down + select from the Twilight menu to reset the game doesn't work, which forces you to close the twilight menu via the home button.

Screenshot ![img](https://user-images.githubusercontent.com/45925523/213819476-339f4707-c294-411a-9827-a8d4b4c495be.jpg)

the second time I opened it,when I pressed the button A, the text with errors on the top screen changed, but after a message related to the save file appeared, the game has frozen (this save message had not appeared in the previous attempt), maybe it can indicate that this freeze is related to the game trying to create/load a save, is just an assumption.

JonSTGaming commented 1 year ago

I have tried using Desquid on my DSi as well and it has produced the same errors, with the broken text up the top, and a failed fsroot boot.

antonialoytorrens commented 1 year ago

@Srchronotrigger @JonSTGaming

TL;DR: Do you have Twilight Menu++ and nds-bootstrap updated to the latest available version?

Typically, when you install Twilight Menu++, an additional utility called nds-bootstrap is installed, and it's used to patch ROMS. A major bug was introduced there, and it may be also present for versions installed before 2020.

If that's not the case, it's always recommended to have both utilities to the latest version available for testing (even in homebrew games), see FAQ.

Srchronotrigger commented 1 year ago

TL;DR: Do you have Twilight Menu++ and nds-bootstrap updated to the latest available version?

The Twilight Menu++ i had updated. the nds-bootstrap was outdated until now, but I just updated it and the bug still persists on PNEO_1.0.1-alpha.nds and PNEO_DESQUID_1.0.1-alpha.nds. (nds-bootstrap version: 0.69.0 [stable]).

EDIT: For the avoidance of doubt, I've updated the twilight menu again to the latest version (was on 25.7.0 and now it's 25.8.0), both twilight menu and nds-bootstrap are on the latest stable version now, and the issue persists, on the same versions PNEO_1.0.1-alpha.nds and PNEO_DESQUID_1.0.1-alpha.nds. (I tested again).

JonSTGaming commented 1 year ago

I also updated to the latest versions of nds-bootstrap and twilight and the issue persisted, the same ones shown earlier. If I change the clockspeed from 133mhz to 66mhz (or whatever the lower one is) it refuses to boot at all.

PH111P commented 1 year ago

I just confirmed this on my hardware and will start to investigate in detail. My hinch is that the version of nitrofs.c ndstool used does something weird; again, I will investigate.

PH111P commented 1 year ago

~~I switched to vanilla ndstool and created a test build that I just added to the latest release (as it is too large to be uploaded here). The build runs on my hardware (currently with sound disabled as that seems to cause some more problems); feel free to test if it works for you as well. https://github.com/neo-engine/neo/releases/download/1.0.1-alpha/TESTBUILD_PNEO_FLASH_NOSOUND.nds~~

I just added a new release with a new set of builds that should work. There is also a NOSOUND build (with sound disabled), as currently, the game seems to hang when loading a map with sound enabled.

Srchronotrigger commented 1 year ago

I switched to vanilla ndstool and created a test build that I just added to the latest release (as it is too large to be uploaded here). The build runs on my hardware (currently with sound disabled as that seems to cause some more problems); feel free to test if it works for you as well.

it worked for me, i played all the way to rustboro city with no crashes, just a few slowdowns.

PH111P commented 1 year ago

Quick update on the sound issue: it seems that the fade in/out does something weird atm. I will investigate further.

BluRosie commented 9 months ago

decided to take a look at this today, compiling it myself gave an error without the Names capitalized as it appears here https://github.com/neo-engine/neo/blob/main/PNEO/arm9/source/mysteryGift.cpp#L39 on hardware through twlmenu, i get the (uistring failed) message still and an R4 flash card does not load the game at all melonDS appears to work fine though! compiled both with and without FLASHCARD=1 and NOSOUNDFADE=1

PH111P commented 9 months ago

Hi @BluRosie,

Thanks for spotting that typo! For some reason, my compiler happily compiled the files anyway (even on a clean build.)

For a flashcard, did you compile the with FLASHCARD=1? You can also try the pre-compiled builds from the releases page.

BluRosie commented 9 months ago

nice! for some reason i thought i had tried FLASHCARD=1 on the R4, but after making sure that it was built as such it boots now. still getting the (uistring failed) screen after booting up

i'll take a look at the precompiled build

edit: getting the same thing with the precompiled on the R4 and twlmenu, downloaded from https://github.com/neo-engine/neo/releases/tag/1.0

is there a good way to contribute to this as well?

PH111P commented 9 months ago

The message (uistring failed) implies that something is wrong with the filesystem in the ROM.

It sounds like that there might be an issue with the DLDI. Are you sure that you are using an original R4 (and not a clone)? Are you using WoodR4 or some other firmware on your R4?

BluRosie commented 9 months ago

looks like there is a massive can of worms surrounding R4 cards, haha. not sure if it's a clone or what the deal there is, but it's running RGF's YSMenu 7.06

is there a dldi patch that i need? i've played through other games, it seems like dldi patches are needed when no games are loading...?

that all being said, twilightmenu with nds-bootstrap also doesn't work though

PH111P commented 9 months ago

Indeed, "R4" cards come in many varieties, all of them have their different quirks. Some of them have more quirks, some of them have less. There might be some specific instructions for the specific model that you are using.

I will investigate the twilightmenu issue. In the meantime, you can check if you have the most recent version installed (if I recall correctly, there is also a version called twilight++, but perhaps that is what you are using).

Quick update: I tried on my own hardware and indeed, with the current TM++, there seems to an issue with the ROM file system. I am investigating.

BluRosie commented 9 months ago

tysm for looking into it!!

PH111P commented 9 months ago

So, it was a problem with the custom ndstool, again.

I added a flashcard-vanilla build to the latest release that should work with TM++ (when running the ROM in DSi mode). I also added a "VANILLA" flag to the makefile to allow for using the vanilla ndstool instead of the custom ndstool.

Background: typically, ndstool creates dsi enhanced images; with neo this resulted in some emulators not being able to save/load games, so the customized ndstool creates standard ds images. Twilight menu doesn't seem to like such non-dsi enhanced images, though.