FAT PLAYER MOD

Discussion in 'NDS - ROM Hacking and Translations' started by Cid2mizard, Oct 25, 2007.

  1. Cid2mizard
    OP

    Cid2mizard GBAtemp Fan

    Member
    4
    Aug 16, 2007
    France
    Maubeuge
    I have a problem for create a FAT Player .mod, when i opened my first .mod it's good but with the 2nd i have no sound and a bug.

    When you touch the name of .mod, it's played... enjoy

    CODE#include
    #include
    #include
    #include

    #define MAX_FILENAME_LEN 256;
    void ManipFichier(int number);

    char * buffer;
    char * debut;
    char * fin;

    typedef struct{
    Â char filename[100];
    Â char name[100];
    Â char ext[10];
    Â u32 size;
    } ÂPAfiletype;
    PAfiletype files[50];

    extern inline char PA_GetSmall(char letter){
    Â if((letter >= 'A')&&(letter = FileNumber-1) nfile = FileNumber-1;
    Â Â Â Â Â Â Â Â Â
    Â Â Â Â ManipFichier(nfile);
    Â Â Â Â PA_OutputSimpleText(1, 1, 14, "Lecture du .mod");
    Â Â Â Â PA_PlayMod(buffer); LectureEnCours = 1; Â Â Â Â
    Â Â Â}
    Â Â Â
    Â Â ÂPA_WaitForVBL();
    Â }
    Â Â Â
    Â return 0;
    }

    Where is my problème ? [​IMG]
     
  2. chuckstudios

    chuckstudios Putting the pro in procrastination

    Member
    2
    Jul 19, 2006
    United States
    North Carolina, USA
    I don't know if it will solve your problem, but you shouldn't be doing a free() on filename. free() is only supposed to be used on malloc()'d pointers, not char arrays.
     
Loading...
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice