Esempio n. 1
0
    public void Count_NemoNemo()
    {
        Vector2 pos;

        bool check        = true;
        int  row_count    = nemoData.GetRow(list_index);
        int  column_count = nemoData.GetColumn(list_index);
        bool condition    = true;
        int  line_count   = 0;
        int  count        = 0;


        for (int i = 0; i < column_count; ++i)
        {
            pos.y = (column_count * 10) - (20 * i);

            check      = true;
            line_count = 0;
            for (int j = 0; j < row_count; ++j)
            {
                condition = nemoData.GetNemos(list_index, i * row_count + j);
                if (check == false)
                {
                    if (condition == false)
                    {
                        count += 1;
                        if (j == row_count - 1)
                        {
                            Create_CountText(count.ToString(), pos.y, row_count, line_count);
                            line_count += 1;
                        }
                    }
                    else
                    {
                        Create_CountText(count.ToString(), pos.y, row_count, line_count);
                        line_count += 1;
                    }
                }
                else
                {
                    if (condition == false)
                    {
                        count = 1;
                        if (j == row_count - 1)
                        {
                            Create_CountText(count.ToString(), pos.y, row_count, line_count);
                            line_count += 1;
                        }
                    }
                }

                if (condition == false)
                {
                    check = false;
                }
                else
                {
                    check = true;
                }
            }
        }
    }