Code clearity improvements to Fonticons patch
This commit is contained in:
parent
a9fa476133
commit
de107be4e0
@ -169,9 +169,13 @@ namespace Components
|
||||
len += 1.0f;
|
||||
}
|
||||
}
|
||||
|
||||
*p = 0;
|
||||
|
||||
Game::cgsArray[0].teamChatMsgTimes[Game::cgsArray[0].teamChatPos % chatHeight] = Game::cgArray[0].time;
|
||||
if (Game::cgsArray[0].teamChatPos++ + 1 - Game::cgsArray[0].teamLastChatPos > chatHeight)
|
||||
|
||||
Game::cgsArray[0].teamChatPos++;
|
||||
if (Game::cgsArray[0].teamChatPos - Game::cgsArray[0].teamLastChatPos > chatHeight)
|
||||
Game::cgsArray[0].teamLastChatPos = Game::cgsArray[0].teamChatPos + 1 - chatHeight;
|
||||
}
|
||||
|
||||
|
@ -395,7 +395,7 @@ namespace Components
|
||||
UpdateAutocompleteContext(autocompleteContext, edit, font, ww);
|
||||
if (autocompleteContext.autocompleteActive)
|
||||
{
|
||||
DrawAutocomplete(autocompleteContext, std::floor(xx), /*std::floor(*/ yy/*)*/, font, ww, hh);
|
||||
DrawAutocomplete(autocompleteContext, std::floor(xx), std::floor(yy), font, ww, hh);
|
||||
}
|
||||
}
|
||||
|
||||
@ -1075,6 +1075,8 @@ namespace Components
|
||||
const auto width = text[1];
|
||||
const auto materialNameLength = text[3];
|
||||
|
||||
// This is how the game calculates width and height. Probably some 1 byte floating point number.
|
||||
// Details to be investigated if necessary.
|
||||
const auto v9 = font->pixelHeight * (width - 16) + 16;
|
||||
const auto w = ((((v9 >> 24) & 0x1F) + v9) >> 5);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user