X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;f=src%2Finit.c;h=8d9571c9a88834006fc2934aac026245de8c6f97;hb=ff56a43aa3799aa3357f4deca4d6482fc25a6a41;hp=1c56fc0a3d9b7f6cfc782690452bc007333b5ae0;hpb=621b6a2c4781c9c3e2f5849f9c184a906e0ce5b6;p=rocksndiamonds.git diff --git a/src/init.c b/src/init.c index 1c56fc0a..8d9571c9 100644 --- a/src/init.c +++ b/src/init.c @@ -45,7 +45,7 @@ static void LoadGfx(int, struct PictureFileInfo *); static void InitGadgets(void); static void InitElementProperties(void); -void OpenAll(int argc, char *argv[]) +void OpenAll(void) { #if !defined(PLATFORM_UNIX) initErrorFile(); @@ -63,6 +63,11 @@ void OpenAll(int argc, char *argv[]) exit(0); } + InitProgramInfo(UNIX_USERDATA_DIRECTORY, + PROGRAM_TITLE_STRING, WINDOW_TITLE_STRING, + ICON_TITLE_STRING, X11_ICON_FILENAME, X11_ICONMASK_FILENAME, + MSDOS_POINTER_FILENAME); + InitPlayerInfo(); InitCounter(); @@ -143,14 +148,16 @@ void InitSound() OpenAudio(&audio); + AllocSoundArray(NUM_SOUNDS); + for(i=0; i=0; i++) { + int j; + for(j=0; jsurface = SDL_DisplayFormat(sdl_image_tmp)) == NULL) Error(ERR_EXIT, "SDL_DisplayFormat() failed: %s", SDL_GetError()); /* create native transparent surface for current image */ SDL_SetColorKey(sdl_image_tmp, SDL_SRCCOLORKEY, SDL_MapRGB(sdl_image_tmp->format, 0x00, 0x00, 0x00)); - if ((pix_masked[pos] = SDL_DisplayFormat(sdl_image_tmp)) == NULL) + if ((pix[pos]->surface_masked = SDL_DisplayFormat(sdl_image_tmp)) == NULL) Error(ERR_EXIT, "SDL_DisplayFormat() failed: %s", SDL_GetError()); /* free temporary surface */