[gameprogrammer] Re: to roger d

  • From: "Charlie Lobo" <charlie.lobo@xxxxxxxxx>
  • To: gameprogrammer@xxxxxxxxxxxxx
  • Date: Tue, 27 Feb 2007 11:33:19 -0600

That's not so much a problem with the language as it is with the library.
You do all those pointers, subroutines and functions to load a window
because in those options you have a lot of power (plus in my opinion MS
Libraries, if we are talking about windows libraries, tend to have too much
useless trash).
There are other libaries that make the whole process much simpler, for
example using SDL I just need the next to have a window:

if ( SDL_Init(SDL_INIT_VIDEO) < 0 ) { //we make sure there isn't an
error loading SDL
       fprintf(stderr, "Unable to init SDL: %s\n", SDL_GetError());
       exit(1);
}
screen = SDL_SetVideoMode( SCREEN_WIDTH, SCREEN_HEIGHT, SCREEN_BPP,
SDL_SWSURFACE );
// we set the window's width, height, set it to windowed mode and save
it on software mem
SDL_WM_SetCaption( "Caption", NULL ); //We set the caption for the window
atexit(SDL_Quit);

This code also includes initializing SDL with safety and the cleaning of
memory of SDL at the end. Now of course with a grafic editor like Delphi you
don't see all the code that it actually creates, but with game programming
I'd reccomend you what a friend told me some time ago: run away from WYSIWYG
editors. It's not that they are wrong or anything, but the game will really
look so diferent from what you are shown, so you must get used to seeing a
bunch of lines of text and realizing they are actually a window, with the
animation of a certain dude running chased by maybe legless bunnies (I don't
know).
But if you hate the language, that is perfectly OK, there's a reason it's
not the only language.

On 2/27/07, Yasser Gonzalez <yassergs@xxxxxxxxxxxxxxx> wrote:

Not really I have a loud of time to learn C++. I have not project to do
anyway. The fact is I hate C++. Too many functions, pointers, and
subroutins to make a simple window. Delphi is not case sensitive. But I
going to think about learn a peace of C++

--
Using Opera's revolutionary e-mail client: http://www.opera.com/m2/


---------------------
To unsubscribe go to http://gameprogrammer.com/mailinglist.html



Other related posts: