Todavía falla MUCHO con las rampas

This commit is contained in:
2022-09-06 21:25:41 +02:00
parent 9af135100c
commit 247e0060ee
5 changed files with 21 additions and 12 deletions

View File

@@ -31,11 +31,18 @@ void Debug::update()
void Debug::render()
{
int y = this->y;
int w = 0;
for (auto s : slot)
{
text->write(x, y, s);
w = (std::max(w, (int)s.length()));
y += text->getCharacterSize() + 1;
if (y > 192 - text->getCharacterSize())
{
y = this->y;
x += w*text->getCharacterSize() + 2;
}
}
}