public void click(int iD, int mode)
    {
        if(cSelect != null)
        {
            if(mode == 0)
            {
                if(buttonMap.get(iD) == null)
                {
                    for(int i = 0; i < BCOUNT; i++)
                    {
                        if(buttonArray[i].getID() == iD)
                        {
                            System.out.println(buttonArray[i].getText());
                            buttonArray[i].click(cSelect);
                            break;
                        }
                    }
                }
                else
                {
                    System.out.println(buttonMap.get(iD).getText());
                    buttonMap.get(iD).click(cSelect);
                }
            }
            else if(mode == 1)
            {
                if(buttonArray[iD] != null)
                {
                    System.out.println(buttonArray[iD].getText());
                    buttonArray[iD].click(cSelect);
                }
            }
        }
    }