source/src/printfuncs.c
//print a number on levelselect or game screen (used to display levelnr & moves)
//again based on asci codes and adjust to tiles in the tileset
print a number on levelselect or game screen (used to display levelnr & moves)
again based on asci codes and adjust to tiles in the tileset
print a number on levelselect or game screen ( used to display levelnr & moves ) again based on asci codes and adjust to tiles in the tileset
void printNumber(uint8_t ax, uint8_t ay, uint16_t aNumber, uint8_t maxDigits, uint8_t emptyBlock)
{
    uitoa(aNumber, number, 10);
    for (c=0; c < maxDigits; c++)
    {
        if (number[c] == 0)
        {
            break;
        }
        set_bkg_tile_xy(ax + c, ay, number[c] + 32);
    }
    for( ; c < maxDigits; c++)
    {
         set_bkg_tile_xy(ax + c, ay, emptyBlock);
    }
}
void printNumber ( uint8_t ax , uint8_t ay , uint16_t aNumber , uint8_t maxDigits , uint8_t emptyBlock ) { uitoa ( aNumber , number , 10 ) ; for ( c = 0 ; c < maxDigits ; c ++ ) { if ( number [ c ] == 0 ) { break ; } set_bkg_tile_xy ( ax + c , ay , number [ c ] + 32 ) ; } for ( ; c < maxDigits ; c ++ ) { set_bkg_tile_xy ( ax + c , ay , emptyBlock ) ; } }
print a number on levelselect or game screen (used to display levelnr & moves)
again based on asci codes and adjust to tiles in the tileset
print a number on levelselect or game screen ( used to display levelnr & moves ) again based on asci codes and adjust to tiles in the tileset
//sprintf(number,"%u",aNumber);