[Release] Lemmings for 3DS

Discussion in '3DS - Homebrew Development and Emulators' started by bayleef, Sep 16, 2016.

  1. bayleef
    OP

    bayleef Advanced Member

    Newcomer
    2
    Sep 15, 2015
    Gambia, The
    @Quantumcat Thank you for your interest and your suggestions! :)

    When holding R, circle pad switches to this behavior. In the future, custom control settings will allow you assign this to circle pad directly.
    Okay. When I improve the top screen (this is really necessary), I will think about it.
    With custom control settings this will become possible. Internally, this feature is already implemented, but no key is assigned to it yet.
    The opposite is planned: Zoom into bottom screen while top screen shows the overview. Reason: Touch control on zoomed screen may be easier.
    I still think about what to display at the top screen. Maybe a normal-size level while bottom screen is zoomed in, and a full map while bottom screen is not zoomed in...

    Sure.

    Thank you. Indeed, I don't have access to the source. However, some people at Lemmings Forums, especcially a guy called ccexplore, had disassembled, reverse engineered, and documented many parts of DOS Lemmings about a decade ago. I collected these things and put the results here: https://github.com/esoteric-programmer/lemmings_3ds/tree/master/doc
    Is this sufficient, or do you want more details?:)

    It may be possible to disassemble and reverse engineer it on your own if no one has done this before. However, without getting the game to run somewhere, reverse engineering is much harder, because you cannot simply randomly modify something and look what happens. Just changing something and observing new behavior is very helpful when reverse engineering. But even if you get the game to work, reverse engineering costs a lot of time.
    Thus, theoretical it should be possible, but practical it requires much know how and a lot of effort. I guess it would be easier to modify the game to make it run in DOSBox (even this may not be easy and require a lot know how).
     
    Last edited by bayleef, Oct 14, 2016
  2. bayleef
    OP

    bayleef Advanced Member

    Newcomer
    2
    Sep 15, 2015
    Gambia, The
    In the next commit, I will introduce some internal changes (which should not be visible to the user).
    However, at the moment these changes still cause some problems. So, please, can anyone help me with the following problems?
    1. I start to use osGetTime() for timing. But I run into troubles when the game is suspended (HOME button or sleep mode). Is there a good way to detect suspension? Of course, I could define thresholds for elapsed time that should never occur during normal rendering. But maybe there is a method to ask ctrulib whether the application was suspending during the last aptMainLoop() (or whatever)...?
    2. Top screen does not appear any longer in home menu background while game is suspended (see here)
    Further, I have some problems playing sound from wave files without reading the entire file. I may describe this problem more detailed when the other problems from above are solved.
    edit: I've solved all the problems on my own.
     
    Last edited by bayleef, Oct 19, 2016
    0bvious likes this.
  3. bayleef
    OP

    bayleef Advanced Member

    Newcomer
    2
    Sep 15, 2015
    Gambia, The
    I've just released version 0.4. The main change is the support of custom sound files (only mono PCM wave files), besides bugfixes and some internal things.
    The /lemmings/audio folder and its subfolders come with readme files that explain which wave files should be placed in the corresponding folders. You could use arbitrary wave files of course. However, all sound effects are loaded on startup, so they should not be too big to fit into memory. The music is loaded just when played, so these files can be really large.

    Hopefully, the next big release introduces a settings menu (for custom controls and so on).

    @0bvious I've added a mapping to /lemmings/audio/README.txt that should help you to identify the correct sound effects.
     
    Last edited by bayleef, Oct 22, 2016
    Quantumcat, 0bvious and Cid2mizard like this.
  4. 0bvious

    0bvious GBAtemp Regular

    Member
    4
    Oct 1, 2007
    Amazing work! Thanks... looking forward to trying this out
     
  5. TarkinMX

    TarkinMX GBAtemp Regular

    Member
    3
    Nov 4, 2009
    United States
    Made a .bat file for renaming the windows sounds if anyone's interested, they were quite easy to find using a google search but I don't know if I can post that here. Anyway, cut and paste the stuff below to a .bat file and run it and you should get the result....

    Code:
    ren changeop.wav SFX01.WAV
    ren door.wav SFX02.WAV
    ren letsgo.wav SFX03.WAV
    ren mousepre.wav SFX04.WAV
    ren ohno.wav SFX05.WAV
    ren electric.wav SFX06.WAV
    ren thud.wav SFX07.WAV
    ren splat.wav SFX08.WAV
    ren chain.wav SFX09.WAV
    ren chink.wav SFX10.WAV
    ren explode.wav SFX12.WAV
    ren fire.wav SFX13.WAV
    ren tenton.wav SFX14.WAV
    ren thunk.wav SFX15.WAV
    ren yippee.wav SFX16.WAV
    ren glug.wav SFX17.WAV
    ren ting.wav SFX18.WAV
    There will be 7 additional files that aren't renamed afterward though so I'm guessing they're not needed or not used yet.
     
    Last edited by TarkinMX, Oct 25, 2016
    bayleef and Quantumcat like this.
  6. 0bvious

    0bvious GBAtemp Regular

    Member
    4
    Oct 1, 2007
    Related question about the sounds... I am assuming that there are some sounds missing from your mapping, since there are at least 7 remaining sounds. I noticed the sound missing when you increase/decrease entry speed, for instance. Any chance of including these remaining sounds?
     
  7. bayleef
    OP

    bayleef Advanced Member

    Newcomer
    2
    Sep 15, 2015
    Gambia, The
    All sounds used by the DOS version of Lemmings are included. The sounds mentioned above are not used by the DOS version. Thus, I don't know when they have to be played. If you report the triggers for the missing sounds, I will add them.

    I'd like to include the .bat file in the next release if that's okay for you.
     
    Last edited by bayleef, Oct 25, 2016
    TarkinMX likes this.
  8. TarkinMX

    TarkinMX GBAtemp Regular

    Member
    3
    Nov 4, 2009
    United States
    That's fine with me. I'm going to look for an easy way of getting the music files off YouTube as well, I just haven't had time to do it yet.
     
  9. bayleef
    OP

    bayleef Advanced Member

    Newcomer
    2
    Sep 15, 2015
    Gambia, The
    This would be great. I did it the hard way. I guess it is not allowed to share the ripped files. Thus, if you find an easy way to get these files and post the method here, it will help a lot of people.

    Btw., the files from youtube need about 640 MiB when saved as 16bit mono 44.1 kHz RIFF wave. In module format these files would need less than 3 MiB, so it's a giant waste of space. At the moment I have other priorities like custom control settings, so module support will not be implemented in the near future (maybe never). However, if anyone knows a library (or wants to implement it on herself or himself) to play module sound files on 3DS, just let me know.
     
    Last edited by bayleef, Oct 25, 2016
    TarkinMX likes this.
  10. TarkinMX

    TarkinMX GBAtemp Regular

    Member
    3
    Nov 4, 2009
    United States
    I noticed that with the lemmings DS project that the author had the files in an .xm format. I've already converted these to .wav but I'm not sure if all the music files you're using are the same or even if there's more or less because I haven't had a chance to look yet but when I do I was thinking of posting how to use either version.
     
  11. bayleef
    OP

    bayleef Advanced Member

    Newcomer
    2
    Sep 15, 2015
    Gambia, The
    If these files are different, google lemmix (not neolemmix!) and get the "Delphi Source Code of all Lemmix Clones". It contains a folder called Music with a subfolder called amiga. This folder contains all amiga music (except the three titles of Holiday Lemmings) in .mod format. The files that come with Lemmix Player should be the same as the files on youtube. Unfortunately, their names are different.
     
    Last edited by bayleef, Oct 25, 2016
    TarkinMX likes this.
  12. TarkinMX

    TarkinMX GBAtemp Regular

    Member
    3
    Nov 4, 2009
    United States
    Great idea, I totally forgot about lemmix.
     
  13. bayleef
    OP

    bayleef Advanced Member

    Newcomer
    2
    Sep 15, 2015
    Gambia, The
    If you can convert module files automatically to stereo wave files only, this MAY also work on 3DS. If it does not, let me know, then I'll try to fix it. I had some troubles in early tests, but I'm not sure if these problems still exist, because I just tried to get wave playback working anyway and haven't focused on playback of stereo files.

    If you get Lemmix Player V29 source, which may be found at the neolemmix page, Holiday Lemmings music is included as well. However, the files of this archive are in .it format. I guess, we have all common module formats now...
     
    Last edited by bayleef, Oct 25, 2016
  14. TarkinMX

    TarkinMX GBAtemp Regular

    Member
    3
    Nov 4, 2009
    United States
    I downloaded the source for lemmix and converted the .mod files to .wav. First thing I noticed is that they're shorter than the music on the youtube links, most are around 30 to 45 seconds long. It also seems like they're in a different order as well and since they're slightly different in tune I'm having trouble figuring out which one is which.

    I went to neolemmix.com looking for the Lemmix Player V29 source and was unable to find it, perhaps PM me a link?
     
  15. Quantumcat

    Quantumcat Dead and alive

    Moderator
    20
    GBAtemp Patron
    Quantumcat is a Patron of GBAtemp and is helping us stay independent!

    Our Patreon
    Nov 23, 2014
    Australia
    Canberra, Australia
    Has anyone gotten past Taxing Level 13 - Upsidedown World?

    I don't know if I'm just really bad or there's a bug. Whenever I try to mine through the last yellow arrow thing, the miner just takes one swing then turns around. I've tried all sorts of different starting places and he always does that. I even looked up guides, they suggest between the first little root and the yellow arrow thing, and only mention it because otherwise the other lemmings might have trouble getting up. No mention of what you need to do it to prevent the miner turning around.

    Also, in pictures of the level on the Web, the entire mound had yellow arrows but here only the bottom left chunk does? What's going on?
    image.
     
    Last edited by Quantumcat, Oct 28, 2016
  16. bayleef
    OP

    bayleef Advanced Member

    Newcomer
    2
    Sep 15, 2015
    Gambia, The
    This is an original glitch of the Lemmings DOS version which I have cloned. I tried to clone as much glitches as possible. See here:
    This glitch makes the DOS version of that level much harder than in other Lemmings versions. However, it is possible to solve the level, even with this glitch. At the moment, I have solved all levels up to (and including) Mayhem 5, so it is definitely possible with an other solution.
    For the SNES solution I have to put you off until a settings menu is implemented where you will be able to enable or disable some of the glitches.

    Missing arrows may be a bug, I'll check that later today.
     
    Last edited by bayleef, Oct 28, 2016
  17. Quantumcat

    Quantumcat Dead and alive

    Moderator
    20
    GBAtemp Patron
    Quantumcat is a Patron of GBAtemp and is helping us stay independent!

    Our Patreon
    Nov 23, 2014
    Australia
    Canberra, Australia
    Thanks for the response, now I know I'm not going crazy :-)
    Thanks again for making this, I have been really enjoying playing it.
     
  18. bayleef
    OP

    bayleef Advanced Member

    Newcomer
    2
    Sep 15, 2015
    Gambia, The
    You are welcome! It's nice to hear that other people like it, too. I also enjoy playing the game, which slows down development, because I interrupt coding to play the game over and over again.:blush::D
     
    Quantumcat likes this.
  19. hippy dave

    hippy dave BBMB

    Member
    15
    Apr 30, 2012
    United Kingdom
    Oh weird, I grew up playing the One True Version of Lemmings (i.e. the Amiga version), so that would be confusing. I'm happy to wait for the settings menu tho, keep up the great work :)
     
    TarkinMX and NuikopeaDemon like this.
  20. bayleef
    OP

    bayleef Advanced Member

    Newcomer
    2
    Sep 15, 2015
    Gambia, The
    If you build Lemmings for 3DS from source, you can enable or disable some glitches (including the mining glitch mentioned above) by editing include/settings.h file before building.

    Hopefully, settings menu will be implemented until November 7th.
     
    hippy dave and Quantumcat like this.
Quick Reply
Draft saved Draft deleted
Loading...