• Welcome to SCdev.org. Please log in.

Welcome to the new SCdev forums!

Taking this class at school next year and....

Started by WegeHop, January 11, 2008, 07:20:06 PM

Previous topic - Next topic

WegeHop

well its gong to teach me the computer language of C++. So i was wondering if after i take this class, will i be able to make homebrew games for the DS or even the PSP?
Sports + Video Games = My Life

mudlouse1

i'd say it'll help.

i did computing at university but the stuff they taught only covered the concepts. if i needed to write a program that was actually useful, i'd have to venture off into something more specific.

so the bottom line is, (if your course was anything like mine) the class alone probably wouldn't turn you into a games developer but it will get you started.

Devil_Spawn

from my understanding, you can develop for the ds in 2 main languages, C, and C++, however C being majorly preferred, mostly because of performance. knowing alot of the theory behind it helps alot too, as developing for the ds is similar logically, but not so much directly

dantheman

I think that's more true on the GBA, where you really have to make everything count on its 16 MHz processor and 256 KB of RAM.  Many DS coders use C++, believing the benefits outweigh the additional RAM and CPU power requirements.  http://forum.gbadev.org/viewtopic.php?t=14783 has two pages of insightful discussion about choosing between the two when coding for the DS.  In essence, for the GBA you'd want to use C, while for the DS either one can be used.

Granted, I don't know either of the two languages myself.  The only thing I can do is crank out some simple GBA demos using the high-level DragonBASIC compiler for the GBA.  Much less skill required, but much more limited as a result.  I've made a multiboot-capable image viewer in DragonBASIC(so it can be run on the GBAMP for instance) but that's about the limit of my skill in coding for the GBA/DS.  Oh, and I've run a few simple Java programs that output to the console on the DS port of the Java runtime environment.

joewandy

Quote from: WegeHop on January 11, 2008, 07:20:06 PM
well its gong to teach me the computer language of C++. So i was wondering if after i take this class, will i be able to make homebrew games for the DS or even the PSP?

if you don't know how to program in any language (yet), learning a programming language will definitely get you started :)

socket

Quote from: joewandy on January 13, 2008, 09:23:35 PM
if you don't know how to program in any language (yet), learning a programming language will definitely get you started :)

I agree.  You may not be able to dive right in, but sure, it's great to get your feet wet with C or C++.

bitblt

Quote from: WegeHop on January 11, 2008, 07:20:06 PM
well its gong to teach me the computer language of C++. So i was wondering if after i take this class, will i be able to make homebrew games for the DS or even the PSP?

Yes, learning the C++ programming language will enable you to experiment making games for DS and PSP. I would say 99% of all professional game software developed on ANY platform in the last 17 years was written in C/C++. The other 1% of professional game software is written in Java for cell phones. So learning C/C++ will help you develop game software for virtually any platform.

However learning C++ alone will not make you a game programmer. Schools don't teach people how to write great games. Learning to program games requires lots of patience, practice and experimentation. Programming games is almost like an art. Start with simple game ideas and build your skills up to develop more sophisticated games. Understand a full blown game is merely an organized collection of simple game objects.

If you want to make 3D games you will also need some math skills and an understanding of computer graphics concepts like ray casting, dot product, 4x4 matrix, 3D transformations, z-buffer, backface/frustum culling, texture and lighting, etc.  Developing fast 3D games also requires an understanding optimization techniques like using look-up tables, integer math, LOD (level of detail), as well as hidden surface removal techniques such as using BSPs (binary space partitions), octrees, and portals.

If you just want to get started programming 2D mini games for DS, and you already have some previous programming skills, then you can probably learn C/C++ and DS game programming at the same time. I suggest as a prerequisite to learn how to program the GBA first. The way GBA and DS are programmed are similar in many respects. To learn GBA programming I recommend downloading the HAM toolchain for GBA and reading this excellent book "Programming The Nintendo Game Boy Advance by Jonathan S. Harbour". This should help programmers get up to speed with console programming.

http://www.jharbour.com/gameboy/default.aspx
http://www.ngine.de/index.jsp?pageid=3510

When you are familiar with ins and outs of programming GBA you can move on to the more advanced challenge of programming DS.  Start by downloading devkitPro and hacking some of the included DS examples. Also have a look at PALIB and the many examples that use that library.  Read as much information as you can find about programming DS. Sometimes source code example will be good documentation.  I recommend developing with WiFiMe/WMB so you can compile and test the latest build on your DS by sending it wirelessly using download play. I also highly recommend using a DS emulator like no$gba to help speed up testing and development turnaround.

http://www.devkitpro.org/
http://www.palib.info/forum/

Also check this nifty little tool called XtenDS
http://www.scdev.org/forum/index.php?topic=12260.0

Quote from: Devil_Spawn on January 12, 2008, 04:53:11 PM
from my understanding, you can develop for the ds in 2 main languages, C, and C++, however C being majorly preferred, mostly because of performance. knowing alot of the theory behind it helps alot too, as developing for the ds is similar logically, but not so much directly

The C programming language does not provide any significant advantages as far as performance over C++. The so-called overhead introduced by certain C++ specific features (such as virtual function calls), is comparable to the overhead programmers would introduce themselves when implementing well structured C code. Also, both languages allow the programmer to get down to assembly language level and bit bang the hardware when needed. Basically C++ is a "better C".

VoX

I'd recommend (While learning C++) to read some tut's on DS Programming and C++ tut's to get ahead so that you can learn more