1
0
Fork 0
mirror of https://github.com/AquariaOSE/Aquaria.git synced 2024-11-29 12:03:51 +00:00

fix tex repeat in mod selector left+right bars

This commit is contained in:
fgenesis 2023-10-20 02:43:20 +02:00
parent 4c941419b4
commit 0391052e51

View file

@ -178,12 +178,12 @@ static void _MenuIconClickCallback(int id, void *user)
// can be called multiple times without causing trouble
void ModSelectorScreen::init()
{
leftbar.setBarWidth(100);
leftbar.height = height;
leftbar.alpha = 0;
leftbar.alpha.interpolateTo(1, 0.2f);
leftbar.position = Vector((leftbar.width - width) / 2, 0);
leftbar.followCamera = 1;
leftbar.setBarWidth(100);
if(!leftbar.getParent())
{
leftbar.init();
@ -193,12 +193,12 @@ void ModSelectorScreen::init()
std::fill(panels.begin(), panels.end(), (IconGridPanel*)NULL);
}
rightbar.setBarWidth(100);
rightbar.height = height;
rightbar.alpha = 0;
rightbar.alpha.interpolateTo(1, 0.2f);
rightbar.position = Vector(((width - rightbar.width) / 2), 0);
rightbar.followCamera = 1;
rightbar.setBarWidth(100);
if(!rightbar.getParent())
{
rightbar.init();
@ -839,6 +839,8 @@ void MenuBasicBar::setBarWidth(float w)
{
width = w;
repeatToFillScale.x = texture->width / w;
repeatToFillScale.y = repeatToFillScale.x;
updateTexCoords();
}
void MenuBasicBar::init()