Jun 012011
 

Version:

3.10

Date:

22/05/2011

Log:

  • Adding support textures up to 4096 pixels (Requirement by Jamie Woodhouse);
  • Fixing the build to encode iso8859;
May 292011
 
void write(const char * WORDS, int X, int Y)
{
   int i,t=strlen(WORDS);
   unsigned char l;
   position.x=X; //screen x
   position.y=Y; //screen y

   for (i=0; i<t; i++){
     l=WORDS[i];
     width.x=(l%16)*sizeChar.w; width.w=width[l];
     width.y=(l/16)*sizeChar.h; width.h=sizeChar.h;
     gsScreen->blitSurface(image,&width,&position);
     position.y=Y;
     position.x=position.x+width[l];
   }
}
May 292011
 
//Global our member of class
char width[256];

void load(std::string fileimage)
{
   FILE *file;
   std::string txt="";
   image = IMG_Load(fileimage.c_str());

   if (image!=NULL){
       txt=fileimage.substr(0,fileimage.length()-4);
       txt+=".dat";
       file = fopen(txt.c_str(),"rb");
       fread(&width, 256, 1, file);
       fclose(file);
   }
}