Small question
#1

How could I like, know if the player clicked on the listitem 65 without having to do
if(listitem == 0)
{
}

if(listitem == 1)
{
}

Like for example a GetClickedListItem
Is it possible?
Reply
#2

Quote:

Like for example a GetClickedListItem
Is it possible?

Nope, but you can use switch, it's more better for 65 items than if-else construction
Example:
pawn Код:
switch(listitem)
{
    case 0:    //    first list item
    {
    }
    case 1:    //    second list item
    {
    }
    // ...
    case 64:   //    65th listitem
    {
    }
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)