gbadev.org forum archive

This is a read-only mirror of the content originally found on forum.gbadev.org (now offline), salvaged from Wayback machine copies. A new forum can be found here.

Coding > Before I convert my PC game to GBA ...

#1170 - TrisOver - Wed Jan 15, 2003 11:05 am

Hi,
I'm a french developper on PC.
I have coded a DOS game for PC, ( http://trisover.free.fr )

Since yesterday I'm interesting about GBA developpement.

My PC game is coded in C, with images and sprites based on 8x8 graphic blocks (screen resolution 240x240, 256 colors). I used "DOS style" development (Vertical blank, no double-buffering, C library to acces registers, animations with copy from video memory to video memory between 4 246x256 buffers).

GBA dev seems to be near from this style of dev (more near than Windows DirectX dev ...). Exact ?

Before I begin to work about this migration, can you give me some basic informations:
- The Mode 0-2 (tiles) seems to the best for my game ?

- Can I re-use exactly my 240x240 graphics ? Ideal would be the "resolution 256x256", but what does it exactly mean ?
We can effectively see 256x256 pixels on the GBA screen, or we see always 240x160 pixels (and so a 256x256 background can't be see integraly).

- when we use a mode 0-2, the background is composed with tiles which are identified with number (background=table of numbers); these numbers can be dynamicaly changed, or this table is constant ? If I change some tile numbers each VBL, the background will be refresh automaticaly, and quickly ?

- and finally, do you think this migration project is possible ?

thank you

Pascal

#1173 - Scritch - Wed Jan 15, 2003 12:14 pm

TrisOver wrote:
I have coded a DOS game for PC, ( http://trisover.free.fr )
Yeah, I played TrisFig a lot some years ago. I recently tried it on my PC, but it does not work with Win2k...
TrisOver wrote:
Since yesterday I'm interesting about GBA developpement.
Good thing :o)
TrisOver wrote:
My PC game is coded in C, with images and sprites based on 8x8 graphic blocks (screen resolution 240x240, 256 colors). I used "DOS style" development (Vertical blank, no double-buffering, C library to acces registers, animations with copy from video memory to video memory between 4 246x256 buffers).
GBA dev seems to be near from this style of dev (more near than Windows DirectX dev ...). Exact ?
Not really near... The GPU is a lot more powerfull and can handle sprite, tiles... And you should really use it, it's a lot faster than doing it yourself...
TrisOver wrote:
The Mode 0-2 (tiles) seems to the best for my game ?
I think so...
TrisOver wrote:
Can I re-use exactly my 240x240 graphics ? Ideal would be the "resolution 256x256", but what does it exactly mean ?
We can effectively see 256x256 pixels on the GBA screen, or we see always 240x160 pixels (and so a 256x256 background can't be see integraly).
We can only see 240x160 pixels on GBA screen (256x256 backgrounds are not seen integrally).
TrisOver wrote:
when we use a mode 0-2, the background is composed with tiles which are identified with number (background=table of numbers); these numbers can be dynamicaly changed, or this table is constant ?
They can be changed easilly...
TrisOver wrote:
If I change some tile numbers each VBL, the background will be refresh automaticaly, and quickly ?
You can do it each VBL without any problem. Many games work this way. You can even do some things during HBL.
TrisOver wrote:
and finally, do you think this migration project is possible ?
I think it's possible, the GBA has enough power for that. And I'd love having TrisFig/TrisOver on GBA :o)
But you should really use GBA sprites/tiles abilities so a part of your engine will have to be rewritten.

If you have not done anything on GBA or if you want to do it easily, you should really use a library like HAM or SGADE.

#1179 - TrisOver - Wed Jan 15, 2003 3:26 pm

Merci pour tes reponses, et vive la france :)

Marrant que tu connaisse Tris Fighter, c'est un signe !!!

Sur 2000, il doit y avoir effectivement des pbs avec Tris Fighters et Tris Over. Par contre, ca marche bien sous XP (pour les sons il faut un utilitaire gratuit, VMDSound). Si tu as aim? Tris Fighter, tu adorerais Tris Over, car c'est Tris Fighters puissance 10 (plein de modes de jeu avec des flammes, de la glace, etc ...). Maintenant, ce sont des freeware, comme tu as pu le constater si tu es all? voir le site.

Je vais sans doute commencer ? bidouiller sur la GBA, histoire de confirmer la faisabilit? du portage. 160 pixel en hauteur, ca m'arrange pas, car je vais devoir sucrer 5 lignes de jeu, et cela risque d'impacter la jouabilit?. A moins que les fonctions de zoom ne soient une solution (mais peut etre pas tres beau?
En tout cas, je ne me vois pas retravailler les graphiques, car toutes les images ont ?t? con?ues dans un esprit "Tile" de 8x8: ce serait dommage de ne pas en profiter ...

J'ai trouv? sur le web les library HAM, Sglade, et DirectGBA. Je n'ai pas vraiment besoin de fonctions graphiques tres evoluees, par contre j'aimerai avoir les sons (et je crois qu'? l'instant il n'y a que HAM payant mais c'est vrai pas extremement cher non plus) qui semble les gerer.
SGlade a l'air de bien "vivre", et j'ai vu que la gestion des sons etait prevu. Ca a de l'avenir selon toi ? Et si tu connais une bibliotheque (ou des sources free) gerant les sons, je suis preneur

Enfin, si tu as fait des demos ou des jeux GBA dispo sur le web, donne moi les adresses que j'y jette un oeil.

@+
Pascal

#1185 - Scritch - Wed Jan 15, 2003 4:45 pm

As you answered in French, I prefered to send you an e-mail (in French :o) to the address found on your Web Site.

#1296 - zeuhl - Thu Jan 16, 2003 2:47 pm

weird that French people keep supposing everybody in the world can speak French.

I speak French myself, but this is an accident ;-)

#1299 - Papa Smurf Advanced - Thu Jan 16, 2003 3:29 pm

here is a rough translation from http://babelfish.altavista.com/babelfish/tr:

"
Thank you for your reponses, and France lives:) Funny how you knows Tris Fighter, it is a sign!!! Over 2000, there must be indeed pbs with Tris Fighters and Tris Over. On the other hand, Ca goes well under XP (for the sounds one needs a free utility, VMDSound). If you liked Tris Fighter, you would adore Tris Over, because they is Tris Fighters power 10 (full with modes of play with flames, ice, etc...). Now, they are freeware, as you could note it if you went to see the site. I undoubtedly will start with bidouiller on the GBA, history to confirm the feasibility of the bearing. 160 pixel in height, Ca does not arrange me, because I will have to sweeten 5 lines of play, and that is likely to impact the jouability. With less than the functions of zoom are not a solution (but can be not very beautiful? In any case, I do not see myself working over again the graphs, because all the images were conceived in a spirit "Tile" of 8x8: it would be damage not to benefit from it... I found on the Web the library HAM, Sglade, and DirectGBA. I do not need really graphic functions very evoluees, on the other hand I will like to have the sounds (and I believe that at the moment there is only paying HAM but these is true step extremement expensive either) which seems the gerer. SGlade has the air of good "food", and I saw that the management of the sounds was prevu. Does Ca have future according to you? And if you know a library (or free sources) gerant the sounds, I am taking Lastly, if you made demos or plays GBA dispo on the Web, gives me the addresses that I throw an eye there. @ +

Pascal
"

-Papa Smurf Advanced-

#1307 - Ped - Thu Jan 16, 2003 5:27 pm

No the other hand you may do full 256x256 pixels visible with zoom feature, but than you could have only 256 different tiles (what doesn't look like problem with your game) and it looks ugly, because it's standart "skip pixel" zoom ... :) 8x8 tiles are ideal for GBA, so you should rather think about changing size of playing-field to 30x20 tiles, and refining gameplay for the new size. Or use some scrolling? (I didn't see the game, so I don't know, if it's appropriate).
Anyway, check Cowbite documents closer with Pern project tutorial, it'll take you few days, but you'll surely understand GBA's power lot more better. So if you can afford those few days, it'll save you many "newbie" questions...
_________________
-- Ped - ped at 7gods dot sk
there used to be times, when sex was safe and flying was dangerous...