Skip to main content
GameDev.net gamedev.net
🔒 Locked

Mutliplatform Programming

Started by TechnoGoth Apr 11, 2005 at 9:27 AM 6 replies 750+ views
Original Post
TechnoGoth
TechnoGoth
With the ever dwindling PC game market I'm beging to relize more and more the importance of the console market. While it may not be the most suitable place for my current game. I still want to leave the possiblity open for releasing the game on diffrent platforms. So, I am curious what links should I leave open/flexible when programming my game? For instance currently the render code is seperate from the game code so that I can change the graphics API if openGL is not supported on a given platform with vary little hassle. What about other things? Such floats, I use them frequently would it be better to create a macro or class called WFloat and use that when creating a float as opposed to float? The same applies to ints, and strings. Are there any good lists or online faq about making code easy to port to other platforms? So that I can ensure that if want to release my game on the XBOX or GBA it won't require extensive recoding.
werekarg
werekarg
no, there's no floating point on GBA and neither is on Gameboy DS.

make sure that your code compiles with as many compilers as possible. on some platforms you will need to compile with g++, on others maybe with codewarrior, so make sure your code is close to the standard and does not use compiler specifics.

also, work on your file I/O, because you will probablly run into byte-order problems (some machines are little endian, some others big endian). that's assuming your data files are produced on a little endian machine and you want to use them unchanged on big endian machines.
TechnoGoth
TechnoGoth
Perhaps I was thinking to low level and I forgort about those damn endians.
What aboutt third party libraries? Should I avoid using them? Currently I don't use any but I might want futher along in development.

Quote:
Original post by Anonymous Poster
Quote:
Original post by TechnoGoth
With the ever dwindling PC game market


Huh??? WTF are you on?


According the itfacts.biz
http://www.itfacts.biz/index.php?id=P2726
and
biz.gamedaily.com
http://biz.gamedaily.com/features.asp?article_id=8854#8854

The total PC game sales decreased by 2% in 2004 and now accounts for only 15% of total video games sales. So as you can see designing a game solely for the PC means cutting yourself off from most of the market.


werekarg
werekarg
yeah, ds sdk comes with a whole load of type/macros for fixed point stuff. their whole 3D sdk which resembles opengl takes fixed point types. anyway.

you will also bump into serious reconding due to screen size. i mean porting from pc where you can have 1600x1200 to gb ds 256x192 is going to require your gui to scale itself to any resolution (and paint into normalize coordinates). not to mention the fact that some devices may have specific features that will completely change the game design (eg. the touch screen of gb ds).

regarding the third party libs: use them if they are opensource and you can get your hands on the sources to compile them on other platforms (zlib, png/jpeg libs, ODE, freetype, mesa :o). otherwise, as AP said, it's going to cause troubles.

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.