TETRIS: use new TextRenderer interface
This commit is contained in:
+3
-4
@@ -18,9 +18,8 @@
|
||||
|
||||
std::vector< std::shared_ptr< SDLPP::RenderObject > > line_coliders{};
|
||||
|
||||
void updateScore( std::shared_ptr< SDLPP::Font > font ) {
|
||||
g_score_texture->setText( *font, std::to_string( g_score ), colors["text"],
|
||||
colors["text_out"], 0.1 );
|
||||
void updateScore() {
|
||||
g_score_texture->changeText( std::to_string( g_score ) );
|
||||
}
|
||||
|
||||
void doInput() {
|
||||
@@ -131,7 +130,7 @@ int main() {
|
||||
g_checked_line = false;
|
||||
}
|
||||
if ( g_update_score ) {
|
||||
updateScore( g_font );
|
||||
updateScore();
|
||||
g_update_score = false;
|
||||
}
|
||||
if ( g_update_colors ) {
|
||||
|
||||
Reference in New Issue
Block a user