So is coding homebrew for the DS hard?

Discussion in 'NDS - ROM Hacking and Translations' started by Harsky, May 23, 2007.

May 23, 2007
  1. Harsky
    OP

    Member Harsky Madmin

    Joined:
    Aug 2, 2004
    Messages:
    5,263
    Country:
    United Kingdom
    One day, I was bored and all of a sudden I just thought, "I know, I want to make a homebrew game for the DS". Don't ask me why but that's what happens when I'm bored. Sadly, I'm probably like the millions of gamers who lacks the coding skills to even begin but since summer is coming up, I'll take the time to learn a bit. Any starting points or is coding homebrew for the DS just diving into the deep end?
     
  2. lagman

    Former Staff lagman I wish I was green.

    Joined:
    Nov 5, 2003
    Messages:
    4,071
    Location:
    Me, To You
    Country:
    Mexico
    That's a interesting question.

    And this, this is a bump.
     
  3. nephdj

    Member nephdj GBAtemp Fan

    Joined:
    Apr 13, 2007
    Messages:
    442
    Country:
    Australia
    get a C+++ book from a local library, and download the free "MS visual studio 2005 Express edition"

    easy way to learn the code, I say express because its very helpful if u get stuck and got good debug
     
  4. mag2005

    Newcomer mag2005 Advanced Member

    Joined:
    May 2, 2007
    Messages:
    51
    Country:
    United States
    If you already know how to program in C++, it wont be hard to program a simple game.
    Here's a link for getting started.
     
  5. Kyuzumaki

    Member Kyuzumaki GBAtemp Regular

    Joined:
    Dec 24, 2006
    Messages:
    251
    Country:
    United Kingdom
    Personally i would advise you begin with a different language. The reason is because c++ will take alot of learning before getting any sort of result if your a beginner.

    Plus there are certian tricks to programming especially in games where speed is nessicary you will need to become framilliar with those as well as learn the language. A simpler language would probably be a good starting point then once you have the basic building blocks you can learn other languages and use the same tricks.

    I would advise using basic to begin with because it's very logical and you won't have to deal with classes which although invaluable can be a bit tough to get your head around.

    Here are a few reccomendations:

    1:
    QBasic is very good. It is not much use in modern day systems but it is still a good place to learn as it is simple and most basic languages are based on it. Thats where i started (lol about 9yrs old but it was still used commonl at that time). There is also tons of free code for Qbasic floating about so you'll be able to see how other people have done things.

    2:
    Visual Basic Express (microsoft give this away free as long as you have a genuine copy of winxp), this is a basic language but with alot more bells and whistles it's easy and lets you make windows applications. You can program games in it but it is best suited to simpiler utilites.

    3:
    A company called 'The Game Creators' make some nice tools:
    DarkBasic Pro
    DarkBasic

    These are basic compilers that give you easy access to 3d and 2d graphics ( via directx) I have made a few games in it because it's so easy.

    4:
    Visual c++ or c# express
    This is what i used to write RomeR it's very nice and i'm really getting into classes but I had alot of other experience before trying it.

    So basically you need to think up a simple project then make it in one of the given languages. Do a few projects and you'll get a feel for programming. If you need any help with darkBasic or any of the others feel free to PM me.


    EDIT:
    I didn't answer your question once you set it up it's pretty easy to program the DS, but you will need a decent understanding of c. Obvoiusly making a full game will take a very long time regardless of how good you are programming takes time....
     
  6. FAST6191

    Reporter FAST6191 Techromancer

    pip
    Joined:
    Nov 21, 2005
    Messages:
    21,743
    Country:
    United Kingdom
    Basic is OK for PC stuff although I would not suggest it if you plan on coding for the DS or want code to be able to run (either with a recompile or minor tweak) on another system, you also run the risk of learning some bad habits which can take a while to unlearn.

    Second what do you want to code?
    If it is an emulator or to a lesser extent port then ASM and c (c++ may not work too good for such things), I would not suggest such a project for anyone inexperienced with a system let along coding.

    If it is a nice app for the end user then palib may be of interest:
    http://www.palib.info/
    Also some find it nicer to start on the GBA, the DS hardware is not entirely dissimilar but current tools and libraries make short work of that.

    If you do want to jump of the deep end then devkitpro is the way to go:
    http://www.devkitpro.org/

    Way I see it is that there are three main languages for the DS

    ASM/assembler/assembly: this is the highest performance yet hardest to produce results with. It has the added bonus of making you able to hack commercial roms however. ASM on GBA, DS, Windows, linux is all different as well, ASM can even vary between assembler (the devkitpro assembler is different to the assembler used for stuff like pocketnes and nesDS).

    C: Efficient, nice enough to learn, can and is used on many systems.

    C++: As you might imagine it is a tweak on C (to the extent a coder that uses one can certainly read the other and with minimal delay pick up the other). Not quite as efficient (not that you will really notice) but has a bunch of nice features over C.


    *You can mix languages: ASM is often used for high performance parts of C? apps and is taught so people can be better C? programmers*


    C#: not for the DS, this is microsofts second take on C (they were instrumental in C++ uptake). It aims to reduce the so called DLL hell by providing some standard ones as well as a few choice classes (including some nice GUI stuff): this is why you need .net on your machine.

    Autoit: another windows only language. Used to make nice GUIs such as batchdpg and a few as yet unreleased projects of my own: I imagine the sort of app you will make will need it). Bonus of not needing a runtime on your machine.

    Kyuzumaki took basic already.
     
  7. Kyuzumaki

    Member Kyuzumaki GBAtemp Regular

    Joined:
    Dec 24, 2006
    Messages:
    251
    Country:
    United Kingdom
    yeah very true FAST! basic is no good for DS it really is dependant on your programming level i just thoght Harsky may struggle jumping into c++ with no previous exp
     
  8. Harsky
    OP

    Member Harsky Madmin

    Joined:
    Aug 2, 2004
    Messages:
    5,263
    Country:
    United Kingdom
    Actually, I really hope that in the future to code a nice rythmn type game not unlike Elite Beat Agents. Yes. I know. Games like those require a lot of team/effort and time to make but nonetheless, which is a good website to learn all the stuff from or is the one mag2005 posted okay?
     
  9. FAST6191

    Reporter FAST6191 Techromancer

    pip
    Joined:
    Nov 21, 2005
    Messages:
    21,743
    Country:
    United Kingdom
    @Kyuzumaki True, in that case as much as it pains me to say it Java: it will run on multiple systems and is able to do quite a bit. You will probably not write the next Azureus overnight but it is flexible enough.

    If and when it comes time to move to C? then chances are all you will really have to learn is some minor syntax stuff and some commands.

    @Harsky that is palib, without any experience I would say no. There are a few coding threads around as well but as it stands everyone I recall posting in them has several hundred posts at least, now I want to help you out but I do not feel like digging through all the posts to get it:
    http://gbatemp.net/index.php?showtopic=43944 is start though.
     
  10. Harsky
    OP

    Member Harsky Madmin

    Joined:
    Aug 2, 2004
    Messages:
    5,263
    Country:
    United Kingdom
    Thanks. I suppose it can't hurt to buy a C++ for dummies type book. Seems like you can do a LOT of stuff when you master it. Am I right?
     
  11. unr

    Member unr GBAtemp Regular

    Joined:
    Feb 20, 2007
    Messages:
    171
    Location:
    Lithuania
    Country:
    Lithuania
    For C++ I personally recommend SAM'S course:
    http://guides.oernii.sk/c++/index.htm

    It`s easy to understand, has some really good coding practices.

    However if you have zero programming knowledge, try basic or some pascal. Even C will do.
    Get a programming book for 11th-12th form, do a couple exercises from it.

    It will take time, don`t rush it.
    Be prepared to spend a year or two studying programming, but trust me, it`s worth it [​IMG]
     
  12. Xeijin

    Member Xeijin GBAtemp Fan

    Joined:
    Mar 25, 2007
    Messages:
    495
    Location:
    London, UK
    Country:
    United Kingdom
    I've heard that starting of with stuff like QBASIC is useful because you learn the logic needed to make programs, but the language isn't overwhelmingly confusing.

    Java seems like a good place to start, and its where I'm planning to once I get my hands on some free time [​IMG] Also, I've heard that when you learn something like Java (or it mighta been javascript not sure) you learn the basic syntax for alot of other languages, and most interestingly Macromedia Flash's 'ActionScript' which would mean you could make awesome flash stuff! (feel free anyone to correct me if I'm wrong).
     
  13. Xeijin

    Member Xeijin GBAtemp Fan

    Joined:
    Mar 25, 2007
    Messages:
    495
    Location:
    London, UK
    Country:
    United Kingdom
    Is that not a rip of the Sam's 'Teach yourself X in 21 Days' Books?
     
  14. unr

    Member unr GBAtemp Regular

    Joined:
    Feb 20, 2007
    Messages:
    171
    Location:
    Lithuania
    Country:
    Lithuania
    Most nowaday languages use C/Cpp-like syntax.
    JavaScript was the second programming (scripting) language I learned (HTML was first. Although technically it`s not a programming language, it was my very first experience of inputting something into text editor and getting visual result.), but it could`ve as well been PHP, Java, ActionScript, Pascal, C or something else.

    Pascal has a little different syntax, but it`s not difficult to convert to another language from it as keywords are almost the same.
    Also, it`s the programming experience that counts.
    Once you have mastered basic algorythming you can do all sorts of things in any language.
     
  15. iwakura

    Member iwakura HHNNNNNNGGGG

    Joined:
    Jul 20, 2006
    Messages:
    1,161
    Location:
    California
    Country:
    United States
  16. ggKfc

    Newcomer ggKfc Member

    Joined:
    May 22, 2007
    Messages:
    24
    Country:
    Australia
    i had a similar question. i have a bit of programming experience but onyl visual basic so im not sure that counts as only *c* is the *real* programming. i managed to make a mastermind game with an ownage ai that doesn't cheat and made a RPG system. Thats the limit to my c apabilities. im good @ designing stuff and lateral thinking so i was wondering if i would be able to make an ONLINE rpg-ish thing on ds? kinda like an rpg where you can train offline and then also come online to battle other pplz (turnbased) maybe be like FFTA except every character is one player so kinda like a team battle. im pretty sure i could make that kinda program on visual basic if i learn the web communications stuff but main;y wondering whether it would take me > 3months to learn c enuf to initiate progamming for my project on DS?
     
  17. FAST6191

    Reporter FAST6191 Techromancer

    pip
    Joined:
    Nov 21, 2005
    Messages:
    21,743
    Country:
    United Kingdom
    If going with online I highly suggest looking at the various libraries already made for the DS wifi communication as well as some of the apps already made (this will probably end up "gpl"ing any code you make though).

    As for the main question in my opinion learning to think like a programmer is the hardest step, if you have this down and understand C (as in you can decipher what is going on and understand how to write a program) then go for it, 3 months spending a hour or so a day should be more than enough if serious graphics are not your concern.
     

Share This Page