public ExecCommand[] PrepareText(String text)
    {       
        ArrayList<ExecCommand> currentCommands = new ArrayList<ExecCommand>();
        
        text = changePolishLetters(text);        
        String[] words = text.split(" ");
        
        int x = 0;
        int y = 0;
        Boolean isArgCus = false;
        
        for(int i = 0;i < words.length;i++)
        {
            if(!words[i].isEmpty())
            {
                for(int j = 0;j < commands.length;j++)
                {
                    String def = commands[j].text;
                    if(def.equals(words[i]))
                    {
                        ExecCommand ec = new ExecCommand(commands[j]);
                        if (commands[j].noArg > 0)
                        {
                            ec.SetArg();
                        }
                        currentCommands.add(ec);
                        break;
                    }
                }
                    
                    Pattern pattern = Pattern.compile("\\d{1,3}");
                    Matcher matcher = pattern.matcher(words[i]);
                    boolean isMatching = matcher.find();
        
                    if(isMatching)
                    {
                        String arg = matcher.group();
                        if(!isArgCus)
                        {
                            x = Integer.parseInt(arg);
                            isArgCus = true;
                        }
                        else
                        {
                            y = Integer.parseInt(arg);                        
                        }
                    }                      
            }           
        }
        
        if(isArgCus)
        {
            ExecCommand ec = new ExecCommand(null);
            ec.SetArgCus(x, y);
            currentCommands.add(ec);
        }
        
        return currentCommands.toArray(new ExecCommand[0]);
    }