How do you literally OPEN .nds files?

Discussion in 'NDS - ROM Hacking and Translations' started by Etiennea, Jan 10, 2012.

Jan 10, 2012
  1. Etiennea
    OP

    Newcomer Etiennea Newbie

    Joined:
    Jan 10, 2012
    Messages:
    5
    Country:
    United States
    SORRY - I SHOULD'VE ASKED THIS IN "ASK!" (I created this account solely to ask this question - sorry!)

    I am pretty knew to this stuff, and I would like to know how I can actually mod games by viewing it's textures and scripts.

    I have some .nds files I would want to mod, but I have no idea how they can open, but I know how they can be played.

    I do have a flash card, btw.
     


  2. Rydian

    Member Rydian Resident Furvert™

    Joined:
    Feb 4, 2010
    Messages:
    27,883
    Location:
    Cave Entrance, Watching Cyan Write Letters
    Country:
    United States
    http://filetrip.net/f711-DSLazy-0-6.html
     
  3. Phoenix Goddess

    Member Phoenix Goddess The Ninja's Protégée

    Joined:
    Apr 25, 2009
    Messages:
    3,809
    Location:
    Away from civilization.
    Country:
    United States
    Knowing the game(s) would help because each game is different. One game could be harder than another and vice versa.

    You can unpack games with unpackers like DSLazy, DSBuff, ndstool, CrystalTile 2, etc. You can look at the files with hex editors(Like Crystal Tile 2) or you can use Tinke.


    Reading romhacking guides: Romhacking.net and The Romhacking Documentation

    And of course, practice :)
    I recommend practicing on games already localized first.
     
    3 people like this.
  4. rastsan

    Member rastsan 8 baller, Death Wizard

    Joined:
    May 28, 2008
    Messages:
    963
    Location:
    toronto
    Country:
    Canada
    read this thread first http://gbatemp.net/topic/73394-gbatemp-rom-hacking-documentation-project-wip/. Pretty much gets you a good start.

    try tinke first to open. as I don't know whether you are talking the text or the programming. If you are talking the programming crystaltile2 and IDAPro can help you with that. (idapro will need a plugin).

    though what are you planning on hacking?
     
  5. FAST6191

    Reporter FAST6191 Techromancer

    pip
    Joined:
    Nov 21, 2005
    Messages:
    21,705
    Country:
    United Kingdom
    DS roms (all the known ones at least) use a filesystem which is well known/catered for but it boils down to two main options-
    1) An all in one program. Crystaltile2 is probably the most well known http://filetrip.net/...2010-09-06.html but there are several others like tinke http://code.google.com/p/tinke/ and mkds course modifier http://gbatemp.net/t...ourse-modifier/ (despite the name it has some serious abilities in other areas these days) and the list goes on (there are a couple of nice tools coming out of Brazil,lowlines' the console tool and the likes of tahaxan). Compared to most crystaltile2 is a bit rough around the edges but is very powerful where the others are prettier and slightly more stable but might lack the ability to flick back and forth to get it all sorted (crystaltile2 is probably best described as a combined hex and tile editor with nice DS related features where the others are file explorers with the specs of a lot of DS formats inbuilt- a subtle difference but an important one).

    2) Something capable of parsing the DS filesystem. Several options with the base version (and one most will turn to so as to pull apart a rom) being ndstool which is command line but has frontends in DSlazy and DSbuff if you do not fancy making a batch file instead. After this you have the likes of ndsts http://www.no-intro.org/tools.htm (more of a file by file thing but worth having around) and nitroexplorer http://treeki.shacknet.nu/ (where ndstool methods can fail to rebuild a rom properly this will usually come through) and in addition to that most of the tools in 1 can spit out several files at once onto your hard drive. With plain files and a hex editor you can start to figure out how the files are put together and edit them from there.

    There are a handful of programs built for certain games although many of those are becoming more general programs and equally some programs to feed known file types or known files from games into to do stuff with. Although you can get quite far with these sorts of things you are going to want to get a tile editor (crystaltile2 or anything with 4bpp and 8bpp GBA), some knowledge of the general formats used ( http://www.romhackin...Go&title=&desc= and http://llref.emutalk.net/docs/ has several) and some knowledge of compression- http://code.google.com/p/dsdecmp/ and http://gbatemp.net/t...ba-compressors/ has a nice tools for it.

    Textures can be 2d paletted type, 2d bitmap, 3d material colours or 3d textured and 3d is reasonably well seen too these days as long as you do not stray far from the nitroSDK (the collection of software and formats Nintendo sends to licensed developers) stuff (I see tinke and MKDS modifier mentioned above getting pretty good at it).
    Scripts can be many things up to things that range from almost be able to be passed off as a programming language to actual text files but usually they are fairly simple once you understand pointers (you have a contents page for your book- so (probably) does your rom) and basic text encoding (ever made a code A=1, B=2, C=3.......- as your computer only understands binary and by extension hex it needs such a code and they can be well known ones, variations on the known theme or completely custom).

    I have however now seen the 3 new replies added thing come up and any more will start turning this into a rom hacking guide so I will point you at the one up the top of this section and http://gbatemp.net/t...-hacking-guide/ and leave it at that for now. If you wish to have something elaborated upon do speak up.
     
    filfat, jarejare3, Rydian and 2 others like this.
  6. StorMyu

    Member StorMyu "I'm too old for this"

    Joined:
    Jan 2, 2010
    Messages:
    892
    Country:
    France
    CT2 for programming ? Oo
    I don't know how you used that but I never will, the only thing related to programming (which by this I mean assembly programming) into a game, comes with a debugger AND IDA Pro, nothing else)
     
    1 person likes this.
  7. rastsan

    Member rastsan 8 baller, Death Wizard

    Joined:
    May 28, 2008
    Messages:
    963
    Location:
    toronto
    Country:
    Canada
    Ct2 needs a very specific syntax for the asm but yes you can. Depending on your point of view it can be much easier than writing it up than converting it than copying pasting it.
    ONLY if you have the right syntax. one wrong space, one wrong sign, then no insertion. try it - press f7 click the spot where you want to revise the asm (make sure you are in the right asm view) and type away. It will give give what is sees as the right syntax. It takes a bit to get used to the way it likes asm inserted. ( I swear I typed it right... really I did...)
     
  8. StorMyu

    Member StorMyu "I'm too old for this"

    Joined:
    Jan 2, 2010
    Messages:
    892
    Country:
    France
    All you said IDA can do it 50x better. There's no point in using a semi-coded ASM viewer just to see some Assembly function when you can the whole thing with IDA. You just need to locate the function you want to change => Debugger, Open the ARM9/Overlay in IDA Pro, then you just do your job. That's just optional, after that I'm not telling you what to do, I just find this way better.
    Btw, I'd like to see what you meant so if you could provide an example I'll be happy to look and maybe understand your point of view.
     
  9. Gericom

    Member Gericom GBAtemp Advanced Fan

    Joined:
    Jun 30, 2011
    Messages:
    585
    Country:
    Netherlands
    In my mkds course modifier you can also view 3d models, listen to sound, edit textures etc.

    >>FAST6191
    So it isn't only for mario kart!
     
  10. AngryEgg

    Newcomer AngryEgg Newbie

    Joined:
    Nov 13, 2013
    Messages:
    1
    Country:
    United States
    I am new to the mkds course modifier stuff. What Do I download it as so I can Create My own tracks?I wanna create my own tracks soooooooooooooooooooo badly!!!!!!:gba:
     
  11. FAST6191

    Reporter FAST6191 Techromancer

    pip
    Joined:
    Nov 21, 2005
    Messages:
    21,705
    Country:
    United Kingdom
    To the best of my knowledge MKDS course modifier (if that is the program you refer to) does not have the ability to edit the files that easily. If you are looking for a level creator of any form where you click a lot with a mouse like most other 3d editing these days you are going to be hard pressed as most of the hacking work involves manual editing.

    Generally though you are doing two things
    1) Making a model of the course. Mario kart DS uses a whole 3d model for the track (plus some extras if they have the space) and some textures. You will also have to make it so it works on the DS which has a somewhat more limited (turns are not on a track just because it is fun but because the draw distance is not enough to see you have massive straight sections)
    2) KCL and related files. The game does not "know" where to go on the 3d model so it has another file to describe the course layout. This is a reasonably common idea in level formats though.

    Some of the other Mario karts have more extensive hacks and hack tools (including ports of several of the DS tracks).

    I have probably paid less attention to Mario Kart DS hacking than I have pokemon hacking so I am afraid I am not going to be much help when it comes to specifics but if you want some general hacking pointers I or someone else should be around.
     
  12. user64

    Member user64 GBAtemp Fan

    Joined:
    Aug 14, 2013
    Messages:
    329
    Country:
    Canada
    The Unarchiver for OSX can open them.
     
    ipwndeveloper likes this.
  13. Xexyz

    Member Xexyz GBATemp's™ Official Xexyz

    Joined:
    Jul 29, 2013
    Messages:
    1,349
    Location:
    hippotomonstrosesquippedaliophobia
    Country:
    Japan
    This is how to literally open nds files.​
    [​IMG]
     
  14. JoostinOnline

    Member JoostinOnline Certified Crash Test Dummy

    Joined:
    Apr 2, 2011
    Messages:
    10,834
    Location:
    The Twilight Zone
    Country:
    United States
    For future reference, the term you were looking for is "unpack", not open.
     
    tbgtbg likes this.
  15. loco365

    Member loco365 GBAtemp Guru

    Joined:
    Sep 1, 2010
    Messages:
    5,459
    If you're wanting to look at individual files of DS games, or extract separate files, Tinke is a nice place to start, although it has a lot of bugs still (Like the notorious "File in use" error when saving a new rom). It does have support for some lesser-known formats though.
     
  16. ipwndeveloper

    Member ipwndeveloper GBAtemp Regular

    Joined:
    Jun 3, 2013
    Messages:
    276
    Location:
    San Fransisco, CA
    Country:
    United States
    You have a few options, all are fairly advanced:
    1)If you want to open NDS files you could brute force it with a hammer (sarcasm).
    2)Hex Editor or you could wire a microcontroller into the nds card reader (on the ds pcb) and record and edit the "files" on the fly as they enter the ds.
    3)Or perhaps you could make/find a C decompiler, that is compatible with the efs/nitro filesystem and devkitarm format
    4)You could use DSLazy(win/linux) or The Unarchiver (OSX) to unpack the .nds into arm7 and arm9 binaries, and access the textures icons, title information etc. (easiest method)

    Good Luck!
     
  17. GHANMI

    Member GHANMI GBAtemp Advanced Fan

    Joined:
    Jun 10, 2012
    Messages:
    918
    Country:
    Antarctica

    I don't know what's the "bug" you're referring to (aside from the buggy hex editor, but that one is an external tool).
    Tinke saves the ROM to a new file instead of overwriting the current one, which makes sense.
    If you "unpack" an archive and modify its innards, the changes won't be effective unless you "repack" it, otherwise it's as if you didn't touch it at all.
    These are the only things I think you would call "issues" imho.
     
  18. loco365

    Member loco365 GBAtemp Guru

    Joined:
    Sep 1, 2010
    Messages:
    5,459
    I kid you not. From time to time, when I click "Save Rom", I get an "Unhandled Exception". It says "The process cannot access the file "[location of DS rom]" because it is being used by another process." And nothing else is using the rom at all. I don't feel like decompiling it with .NET Reflector to debug it either.
     
  19. GHANMI

    Member GHANMI GBAtemp Advanced Fan

    Joined:
    Jun 10, 2012
    Messages:
    918
    Country:
    Antarctica
    Well, with the rev152 it never happened to me before, that's for sure :(
    If it's neither the emulator nor another instance of Tinke, I don't really know what might have caused your problem. I really hope this got fixed with the recent versions

    Most of what I got was errors due to unhandled exceptions with custom decompressions set to invalid parameters, invalid model data, invalid fonts (with width set to 0) ..
     
  20. loco365

    Member loco365 GBAtemp Guru

    Joined:
    Sep 1, 2010
    Messages:
    5,459
    Where can I find the latest build? I might try it and see if I have any luck.
     

Share This Page