diff options
author | Paweł Kołodziejski | 2003-04-20 16:22:34 +0000 |
---|---|---|
committer | Paweł Kołodziejski | 2003-04-20 16:22:34 +0000 |
commit | ce6859d6c6d0baa6d663fe0d36f10db3eb558531 (patch) | |
tree | 5b64f8244bd30922736faaee766eb9567630b4a7 /sky/text.cpp | |
parent | 3b32494755b8e7b2162201645af2503565ceece5 (diff) | |
download | scummvm-rg350-ce6859d6c6d0baa6d663fe0d36f10db3eb558531.tar.gz scummvm-rg350-ce6859d6c6d0baa6d663fe0d36f10db3eb558531.tar.bz2 scummvm-rg350-ce6859d6c6d0baa6d663fe0d36f10db3eb558531.zip |
fixed warnings under VC6
svn-id: r7032
Diffstat (limited to 'sky/text.cpp')
-rw-r--r-- | sky/text.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/sky/text.cpp b/sky/text.cpp index 3c0a368165..8b1e24cac2 100644 --- a/sky/text.cpp +++ b/sky/text.cpp @@ -77,7 +77,7 @@ void SkyText::fnSetFont(uint32 fontNr) { _curCharSet = fontNr; _characterSet = newCharSet->addr; - _charHeight = newCharSet->charHeight; + _charHeight = (byte)newCharSet->charHeight; _dtCharSpacing = newCharSet->charSpacing; } @@ -198,7 +198,7 @@ void SkyText::displayText(char *textPtr, uint8 *dest, bool centre, uint16 pixelW } lineWidth += *(_characterSet+textChar); //add character width - lineWidth += _dtCharSpacing; //include character spacing + lineWidth += (int)_dtCharSpacing; //include character spacing if (pixelWidth <= lineWidth) { @@ -238,8 +238,8 @@ void SkyText::displayText(char *textPtr, uint8 *dest, bool centre, uint16 pixelW //make the header ((struct dataFileHeader *)curDest)->s_width = TO_LE_16(_dtLineWidth); - ((struct dataFileHeader *)curDest)->s_height = TO_LE_16(_charHeight * _dtLines); - ((struct dataFileHeader *)curDest)->s_sp_size = TO_LE_16(_dtLineWidth * _charHeight * _dtLines); + ((struct dataFileHeader *)curDest)->s_height = TO_LE_16((int)(_charHeight * _dtLines)); + ((struct dataFileHeader *)curDest)->s_sp_size = TO_LE_16((int)(_dtLineWidth * _charHeight * _dtLines)); ((struct dataFileHeader *)curDest)->s_offset_x = TO_LE_16(0); ((struct dataFileHeader *)curDest)->s_offset_y = TO_LE_16(0); @@ -278,7 +278,7 @@ void SkyText::displayText(char *textPtr, uint8 *dest, bool centre, uint16 pixelW void SkyText::makeGameCharacter(char textChar, uint8 *charSet, uint8 *&dest, uint8 color) { bool maskBit, dataBit; - uint8 charWidth = (*(charSet + textChar)) + 1 - _dtCharSpacing; + uint8 charWidth = (int)((*(charSet + textChar)) + 1 - _dtCharSpacing); uint16 data, mask; byte *charSpritePtr = (charSet + CHAR_SET_HEADER + ((_charHeight << 2) * textChar)); byte *startPos = dest; @@ -294,9 +294,9 @@ void SkyText::makeGameCharacter(char textChar, uint8 *charSet, uint8 *&dest, uin for (int j = 0; j < charWidth; j++) { - maskBit = (bool)(mask & 0x8000); //check mask + maskBit = (mask & 0x8000) != 0; //check mask mask <<= 1; - dataBit = (bool)(data & 0x8000); //check data + dataBit = (data & 0x8000) != 0; //check data data <<= 1; if (maskBit) |