Answered Infinite Scroller Help Please

JayCoder

Veteran
Staff member
Messages
375
Reaction score
148
Points
903
you stated you made the menu base lol, you didnt say 'im using equalizer's menu base'
i did i can even give u a screenshot i said refrenced code, it doesn't matter anyways i understand my mistakes
 

JayCoder

Veteran
Staff member
Messages
375
Reaction score
148
Points
903
lol, Infinite scrolling is simple once you understand it.
yea true i got it down now that i was able to compair the orginal to the one u guys helped fix ty by the way.


PHP:
updateScrollbar()//infinite scrolling, 10 option's
{
    if(self.menu.curs[self.CurMenu]<0)
        self.menu.curs[self.CurMenu] = self.menu.menuopt[self.CurMenu].size-1;
      
    if(self.menu.curs[self.CurMenu]>self.menu.menuopt[self.CurMenu].size-1)
        self.menu.curs[self.CurMenu] = 0;
      
    if(!isDefined(self.menu.menuopt[self.CurMenu][self.menu.curs[self.CurMenu]-5])||self.menu.menuopt[self.CurMenu].size<=10)//adding
    {
        for(i = 0; i < 10; i++)//10
        {
            if(isDefined(self.menu.menuopt[self.CurMenu][i]))
                self.AIO["options"][i] setSafeText(self.menu.menuopt[self.CurMenu][i]);
            else
                self.AIO["options"][i] setSafeText("");
                  
            if(self.menu.curs[self.CurMenu] == i)
                 self.AIO["options"][i] affectElement("alpha", .2, 1);//current menu option alpha is 1
             else
                  self.AIO["options"][i] affectElement("alpha", .2, .3);//every other option besides the current option
        }
        self.AIO["scrollbar"].y = -50 + (25*self.menu.curs[self.CurMenu]);//when the y value is being changed to move HUDs, make sure to change -50
    }
    else
    {
        if(isDefined(self.menu.menuopt[self.CurMenu][self.menu.curs[self.CurMenu]+5]))//adding 5+5 = 10 derp
        {
            xePixTvx = 0;
            for(i=self.menu.curs[self.CurMenu]-5;i<self.menu.curs[self.CurMenu]+5;i++)//adding
            {
                if(isDefined(self.menu.menuopt[self.CurMenu][i]))
                    self.AIO["options"][xePixTvx] setSafeText(self.menu.menuopt[self.CurMenu][i]);
                else
                    self.AIO["options"][xePixTvx] setSafeText("");
                  
                if(self.menu.curs[self.CurMenu]==i)
                    self.AIO["options"][xePixTvx] affectElement("alpha", .2, 1);//current menu option alpha is 1
                 else
                      self.AIO["options"][xePixTvx] affectElement("alpha", .2, .3);//every other option besides the current option
                    
                xePixTvx ++;
            }         
            self.AIO["scrollbar"].y = -50 + (25*5);//25* number
        }
        else
        {
            for(i = 0; i < 10; i++)
            {
                self.AIO["options"][i] setSafeText(self.menu.menuopt[self.CurMenu][self.menu.menuopt[self.CurMenu].size+(i-10)]);
              
                if(self.menu.curs[self.CurMenu]==self.menu.menuopt[self.CurMenu].size+(i-10))
                     self.AIO["options"][i] affectElement("alpha", .2, 1);//current menu option alpha is 1
                 else
                      self.AIO["options"][i] affectElement("alpha", .2, .3);//every other option besides the current option
            }
            self.AIO["scrollbar"].y = -50 + (25*((self.menu.curs[self.CurMenu]-self.menu.menuopt[self.CurMenu].size)+10));//when the y value is being changed to move HUDs, make sure to change -50
        }
    }
}

Thank Yall BTW "the scrolling was the only problem, not entire base"
 
Last edited:

CabCon

Head Administrator
Staff member
Head Staff Team
Messages
5,093
Reaction score
2,881
Points
1,103
i fixed the whole base for him since he ****ed it good and proper.
That's nice!
Thank you, extinct!

Regards,
CabCon.

===

Question answered -> moved into answered question section!
 
Top