Page 98 - MDP2022-3
P. 98

}
                                for  (int  y  =  3;  y  >  -1;  y--)  {
                                    for  (int  x  =  0;  x  <  4;  x++)  drawLine(color,x,0,0,x,y,3);
                                    flushBuffer();
                                    clearBuffer();
                                    delay(animationSpeed);
                                }
                                side  =  3;  break;
                            case  28:
                                for  (int  y  =  0;  y  <  4;  y++)  {
                                    for  (int  z  =  0;  z  <  4;  z++)  drawLine(color,3,z,0,0,z,y);
                                    flushBuffer();
                                    clearBuffer();
                                    delay(animationSpeed);
                                }
                                for  (int  y  =  0;  y  <  4;  y++)  {
                                    for  (int  x  =  0;  x  <  4;  x++)  drawLine(color,3,x,0,y,x,3);
                                    flushBuffer();
                                    clearBuffer();
                                    delay(animationSpeed);
                                }
                                side  =  4;  break;
                            }
                        }
                    color  =  nextColor(color);
                }
            }
   93   94   95   96   97   98   99   100   101   102   103