1
Fork 0

Fix chart bg being shown one too many times in bany

This commit is contained in:
prescientmoon 2025-04-21 18:55:18 +02:00
parent 41d81e926f
commit fdc0f01847
Signed by: prescientmoon
SSH key fingerprint: SHA256:UUF9JT2s8Xfyv76b8ZuVL7XrmimH4o49p4b+iexbVH4

View file

@ -118,15 +118,15 @@ async fn best_plays<C: MessageContext>(
.layout
.edit_to_relative(item_with_margin, item_grid, origin.0, origin.1);
let top_bg = &*TOP_BACKGROUND;
drawer.blit_rbga(top_area, (0, 0), top_bg);
let (play, song, chart) = if let Some(item) = plays.get(i) {
item
} else {
break;
};
let top_bg = &*TOP_BACKGROUND;
drawer.blit_rbga(top_area, (0, 0), top_bg);
// {{{ Display index
let bg = &*COUNT_BACKGROUND;
let bg_center = Rect::from_image(bg).center();