[Release] Meritous for 3ds (using lib SDL 1.2 )

Discussion in '3DS - Homebrew Development and Emulators' started by nop90, Feb 26, 2017.

Feb 26, 2017
  1. nop90
    OP

    Member nop90 GBAtemp Maniac

    Joined:
    Jan 11, 2014
    Messages:
    1,174
    Location:
    Rome
    Country:
    Italy
    Meritous.png

    Far below the surface of the planet is a secret. A place of limitless power. Those that seek to control such a utopia will soon bring an end to themselves.

    Seeking an end to the troubles that plague him, PSI user MERIT journeys into the hallowed Orcus Dome in search of answers.

    If the game is too difficult for you, you can play in 'Wuss mode' for a far more sombre gaming experience.

    Meritous
    is a cross between a top-view dungeon crawler and a bullet-hell shoot-em-up. In it, you control main character Merit, who travels through an enormous 3000-room labyrinth, the Orcus Dome, in order to find three artifacts called the PSI Keys, and restore them to their proper locations.

    Although enemies fire copious amounts of bullets at you, you don't shoot back- instead, you have an attack called a PSI Circuit, which you charge up to unleash a shockwave that hits enemies and nullifies their shots.

    As you charge up the PSI Circuit, target reticules appear on nearby enemies, the circle indicating they're in range, and the cross indicating you've charged up enough to damage or kill them.

    You can't just use the PSI Circuit as often as you want, though. After releasing it, there's a cooldown time before you can charge up again, and the longer you charge up, the longer you have to wait.

    Destroyed enemies leave behind PSI crystals you can use to upgrade three facets of your PSI Circuit- Circuit Charge (charge up faster), Circuit Refill (less cooldown time), and Reflect Shields.

    When you have at least one level in Shields, a barrier is projected around Merit, which will deflect one bullet per shield level, before having to regenerate. As you upgrade Shields, the barrier becomes bigger, then shows multiple layers as it gets stronger.

    --------​

    3DSX Users: Currently, the 3DSX build needs to utilize a large app installed on your 3ds. If you have used any of the similarly large RetroArch emulators or ScummVM 3ds, you have nothing to worry about. The easiest target to use is the Youtube app, so if you have that installed, you're ready to go.

    CIA Users: You will first need a DSP dump on your SD card.
    This is a one-time process and is needed for all homebrew CIAs that use DSP audio.
    The source code of my port is on my github (https://github.com/nop90/Meritous-3ds).
    The compiled game (3dsx and CIA format) is released on github (https://github.com/nop90/Meritous-3ds/releases).

    Credits:
    The original source is by Lancer-X/ASCEAI (http://www.asceai.net/meritous/)
    The 3ds port is based on the code of the dingoo port by 31, that has resized screen to 320x240
    This game uses the SDL 1.2 library for 3ds

    Changelog

    Ver. 1.2 (22 March 2017)
    - Released a new build using a fixed version of SDL lib that solves the screen flickering

    Ver. 1.1 (05 March 2017)
    - Using 400x240 resolution instead of 320x240 stretched (thanks to @asiekierka)
    - Fixed some bugs

    Ver. 1.0a (26 February 2017)
    - Added CIA format

    Ver. 1.0 (26 February 2017)
    - First reelase in 3dsx format

    Installation

    In the zip there is a folder with the 3dsx, smdh and the xml (for target title selection) files inside, to be used with a homebrew launcher, and a CIA file to be installed with FBI. All the resources are included in the executable using romfs.

    The game creates a Meritous subfolder inside the 3ds folder if doesn't exist. Here will be stored the gamesave.

    Commands

    - D-pad: Move
    - A: Select / use PSI
    - B: Activate tiles
    - X: Show artifacts
    - Y: Show shield meters
    - L: Open Help
    - R: Open map
    - Select: Exit
    - Start: Pause

    Known Bugs

    -

    To Do List

    -

    Screenshots

    Meritous1.png Meritous2.png Meritous3.png
     
    Last edited by nop90, Mar 22, 2017 at 10:35 PM


  2. nop90
    OP

    Member nop90 GBAtemp Maniac

    Joined:
    Jan 11, 2014
    Messages:
    1,174
    Location:
    Rome
    Country:
    Italy
    The game in cia format works fine, but theinteraction with the home menu (pressing start or closing the lid) dosn't work, and this is a problem of the SDL lib (related to threads I think).

    Hope to fix everything next week.
     
  3. orochi115

    Member orochi115 GBAtemp Regular

    Joined:
    Jun 8, 2013
    Messages:
    119
    Country:
    China
    Great job! It's a game I had fun time with, but forgot the name then.
    Thank you very much!
     
  4. Mystic Shadow

    Member Mystic Shadow GBAtemp Regular

    Joined:
    Mar 2, 2015
    Messages:
    116
    Country:
    United States
    yess loved this on my PSP good to see it coming to 3ds. Awesome work.
     
  5. nop90
    OP

    Member nop90 GBAtemp Maniac

    Joined:
    Jan 11, 2014
    Messages:
    1,174
    Location:
    Rome
    Country:
    Italy
    Added on github the CIA format of the game. Don't close the game from the 3dsx home menu or it will hung the 3ds (it's a problem of the SDL lib)
     
    Last edited by nop90, Mar 5, 2017
  6. nop90
    OP

    Member nop90 GBAtemp Maniac

    Joined:
    Jan 11, 2014
    Messages:
    1,174
    Location:
    Rome
    Country:
    Italy
    Released a new version that uses a resolution of 400x320 instead of 320x240 stretched (thanks to @asiekierka)

    Also fixed some bugs in the game.
     
    SLiV3R and thomasnet like this.
  7. Cid2mizard

    Member Cid2mizard GBAtemp Fan

    Joined:
    Aug 16, 2007
    Messages:
    347
    Location:
    Maubeuge
    Country:
    France
    Why all SDL port game (3dsx format) doesn't works for me ?
     
  8. nop90
    OP

    Member nop90 GBAtemp Maniac

    Joined:
    Jan 11, 2014
    Messages:
    1,174
    Location:
    Rome
    Country:
    Italy
    Probabily not enough permissions for something (Theads, dsp, who knows)

    I have several o3ds and one n3ds. All of them have a9lh + latest luma and are on 11.2.

    Meritous always works, Xrick srarts on the o3ds but not on the n3ds.

    Tyrian srarts only after starting and closing meritous.

    With this situation I'm not able to investigate the problem and I'm using the cia version
     
    SLiV3R and Cid2mizard like this.
  9. Cid2mizard

    Member Cid2mizard GBAtemp Fan

    Joined:
    Aug 16, 2007
    Messages:
    347
    Location:
    Maubeuge
    Country:
    France

    I have just last hbl (o3ds 9.2 with menuhax and soundhax), i can not install cia, FBI has encountered a fatal error (Kernel backdoor not installed).
     
  10. SLiV3R

    Member SLiV3R 3DS Friend Code: 0473-9069-2206

    Joined:
    Jan 9, 2006
    Messages:
    2,063
    Country:
    Sweden
    So many cool stuff from you!!!!!!
     
  11. nop90
    OP

    Member nop90 GBAtemp Maniac

    Joined:
    Jan 11, 2014
    Messages:
    1,174
    Location:
    Rome
    Country:
    Italy
    Added an xml file for target title selection that should make startd the 3dsx file if it wasn't starting without (for me the 3dsx file was working).

    Please let me know if the problem is solved now.
     
  12. Cid2mizard

    Member Cid2mizard GBAtemp Fan

    Joined:
    Aug 16, 2007
    Messages:
    347
    Location:
    Maubeuge
    Country:
    France
    I am in trouble,
    Usually I do not use the cia. I finally managed to start FBI thanks to fasthax but I can not install youtube. It's hard to find youtube in cia format, and when I find one, FBI refuses to install it.
     
  13. nop90
    OP

    Member nop90 GBAtemp Maniac

    Joined:
    Jan 11, 2014
    Messages:
    1,174
    Location:
    Rome
    Country:
    Italy
    If you have Freeshop you can download youtube with it.

    Other games that can be use to launch the 3dsx are:
    - Monster Hunter 4 Ultimate Special Demo (USA)
    - Monster Hunter 4 Ultimate Special Demo (Europe)
    - Monster Hunter 4 Ultimate (USA eShop)
    - Monster Hunter 4 Ultimate (Europe eShop)
    - Monster Hunter 4G (Japan eShop)-->
    - Monster Hunter 4 Ultimate (USA cartridge)
    - Monster Hunter 4 Ultimate (Europe cartridge)
    - Monster Hunter 4 Ultimate (Japan cartridge)
    - Super Smash Bros. for Nintendo 3DS Demo (USA)
    - Super Smash Bros. for Nintendo 3DS Demo (Europe)
    - Super Smash Bros. for Nintendo 3DS Special Demo (USA)
    - Super Smash Bros. for Nintendo 3DS Special Demo (Europe)
    - Super Smash Bros. for Nintendo 3DS (USA eShop)
    - Super Smash Bros. for Nintendo 3DS (Europe eShop)
    - Dairantou Smash Brothers for Nintendo 3DS (Japan eShop)
    - Super Smash Bros. for Nintendo 3DS (USA cartridge)
    - Super Smash Bros. for Nintendo 3DS (Europe cartridge)
    - Dairantou Smash Brothers for Nintendo 3DS (Japan cartridge)
     
  14. Cid2mizard

    Member Cid2mizard GBAtemp Fan

    Joined:
    Aug 16, 2007
    Messages:
    347
    Location:
    Maubeuge
    Country:
    France

    Freeshop is cia, and FBI will not install it. I install on Emunand Gateway with Devmenu and install is good. Now Freeshop need Decrypt9 but Decrypt9 doesn't works on my Emunand.
    This is a real journey of the fighter to operate cia without CFW. I'm giving up...
     
    Last edited by Cid2mizard, Mar 8, 2017
  15. Coolnez

    Newcomer Coolnez Advanced Member

    Joined:
    May 18, 2016
    Messages:
    80
    Location:
    Who are you? The Police?
    Country:
    Canada
    So I was playing this port and I was in one of the areas of the game, and then my System crashed. When I went back in to the game and pressed "continue", it kept kicking me back to the Home menu and sometimes crashing.

    Can you explain why this is happening?

    I'm also willing to provide the System Crash Dump if needed.
     
  16. nop90
    OP

    Member nop90 GBAtemp Maniac

    Joined:
    Jan 11, 2014
    Messages:
    1,174
    Location:
    Rome
    Country:
    Italy
    A crash happenend once to my son, but after restarting the game and continuing from the last save went fine.

    Probably some memory leak in the original source. I don't have time to debug it now, but if you want semd me the savefile and when I have time I'll try to see what I can do.

    Delering the savefile in the 3ds/Meritous folder should fix your problem, but you'll have to restart the game.
     
  17. Coolnez

    Newcomer Coolnez Advanced Member

    Joined:
    May 18, 2016
    Messages:
    80
    Location:
    Who are you? The Police?
    Country:
    Canada
    Alright, Sucks cause I upgraded the hell out of my Abilitys, but I can understand that things like this can happen, Especially for a Port.

    Oh, and here is the Save file that messed up.
     

    Attached Files:

  18. nop90
    OP

    Member nop90 GBAtemp Maniac

    Joined:
    Jan 11, 2014
    Messages:
    1,174
    Location:
    Rome
    Country:
    Italy
    It's easy to understand. Software has always bugs (often also hw has, look at the problems of the just launched Switch) and debugging is very time consuming. So homebrew are unlikely to be perfect.

    Porting a game to a console like 3ds with a limited amount of resources, small bugs In memory managing that on widows can be ignored, are a big problem.

    Another problem is the small stack size (on windows the default stack is 4MB :wacko:) so the use of large arrays as local variable in a function or an high use of recursion, don't give problems on compiling but will crash the game while running it on the 3ds.

    Using your savefile I'll try to trace the code execution to find the problem, but without a debugger I have to use the console output and hardcoded breakpoints. Really a dirty work.

    First I'll try with a quick fix. To solve the problem of local big arrays the easy solution is to declare them static, but this doesn't clear the memory on different calls of the function. Replacing this with malloc/free calls is a cleaner way and could solve a potential bug introduced by me. But if the bug is elsewhere, don't expect that fixing it will be fast.
     
  19. nop90
    OP

    Member nop90 GBAtemp Maniac

    Joined:
    Jan 11, 2014
    Messages:
    1,174
    Location:
    Rome
    Country:
    Italy
    @Coolnez your savefile has size 0.

    If it's the same on your SD you had a SD writing failure. In this case I don't know if it's a bug of the game or if your SD is damaged.
     
  20. Coolnez

    Newcomer Coolnez Advanced Member

    Joined:
    May 18, 2016
    Messages:
    80
    Location:
    Who are you? The Police?
    Country:
    Canada
    I'm leaning more to Bug of the game cause my SD Card never had a Writing error before, but okay.
     

Share This Page