/** * Prepares the canvas and renders the supplied text at {@code x, y} using the given config. */ public void renderText (Graphics gfx, StyledText.Plain text, int x, int y) { prepare(gfx, text.width(), text.height()); Canvas canvas = begin(); text.render(canvas, x, y); end(); _layer.setTranslation(text.style.effect.offsetX(), text.style.effect.offsetY()); }
logger.layer.setTranslation(x, y); game.rootLayer.add(logger.layer); y += logger.layer.height() + 5; motionLabel.layer.setTranslation(x, y); game.rootLayer.add(motionLabel.layer);