//Template made by Lester Matthew Sollano

#define tempo 500 //this will be the delay per frame multiplied by yung last part ng frames[][] variable sa line 78
char lenChecker[] = "00000000"; //this is used to measure ilan yung frames like in this example 8 frames kase 8 yung mga "0", if you want more frames dagdagan mo lang yung 0, also dapat same sila lahat ng length ah
const int NUM_FRAMES = sizeof(lenChecker) / sizeof(lenChecker[0]); //dont mind this line
const char frames[][NUM_FRAMES-1] =
{ //     v--- isang vertical line meaning 1 frame, try mo palitan yung ibang 0 gawin mong 1, yung last line sa baba is timings dapat 1-9 value don, mumultiply sa tempo yon, bali it determines gano katagal yung frame
/*0*/   "00000000",
/*1*/   "00000000",
/*2*/   "00000000",
/*3*/   "00000000",
/*4*/   "00000000",
/*5*/   "00000000",
/*6*/   "00000000",
/*7*/   "00000000",
/*8*/   "00000000",
/*9*/   "00000000",
/*10*/  "00000000",
/*11*/  "00000000",
/*12*/  "00000000",
/*13*/  "00000000",
/*14*/  "00000000",
/*15*/  "00000000",
/*16*/  "00000000",
/*17*/  "00000000",
/*18*/  "00000000",
/*19*/  "00000000",
/*20*/  "00000000",
/*21*/  "00000000",
/*22*/  "00000000",
/*23*/  "00000000",
/*24*/  "00000000",
/*25*/  "00000000",
/*26*/  "00000000",
/*27*/  "00000000",
/*28*/  "00000000",
/*29*/  "00000000",
/*30*/  "00000000",
/*31*/  "00000000",
/*32*/  "00000000",
/*33*/  "00000000",
/*34*/  "00000000",
/*35*/  "00000000",
/*36*/  "00000000",
/*37*/  "00000000",
/*38*/  "00000000",
/*39*/  "00000000",
/*40*/  "00000000",
/*41*/  "00000000",
/*42*/  "00000000",
/*43*/  "00000000",
/*44*/  "00000000",
/*45*/  "00000000",
/*46*/  "00000000",
/*47*/  "00000000",
/*48*/  "00000000",
/*49*/  "00000000",
/*50*/  "00000000",
/*51*/  "00000000",
/*52*/  "00000000",
/*53*/  "00000000",
/*A0*/  "00000000",
/*A1*/  "00000000",
/*A2*/  "00000000",
/*A3*/  "00000000",
/*A4*/  "00000000",
/*A5*/  "00000000",
/*A6*/  "00000000",
/*A7*/  "00000000",
/*A8*/  "00000000",
/*A9*/  "00000000",
/*A10*/ "00000000",
/*A11*/ "00000000",
/*A12*/ "00000000",
/*A13*/ "00000000",
/*A14*/ "00000000",
/*A15*/ "00000000",
/*time*/"11111111", // This will be multiplied to tempo in line 3 and will be used as delay per frame
};

// feel free na dagdagan yung frames, pero in case you do that dapat update mo yung line 4, yon kc magsasabi sa program kung gaano kadame frames yeah, ih mahirap explain mahirap din intindihin pero kaya nyo na yan :)
// itong mga nasa baba bahala ka kung babasahin mo basta wala kang babaguhin

void setup()
{
  for (int i = 0; i <= 69; i++)
  {
    pinMode(i, OUTPUT);
  }
}

void loop()
{
  for (int i = 0; i <= NUM_FRAMES-2; i++)
  {
    for(int j = 0; j <= 69; j++)
    {
      if (frames[j][i] == '1')
      {
        digitalWrite(j, HIGH);
      } else if(frames[j][i] == '0')
      {
        digitalWrite(j, LOW);
      }
    }
    int timer = frames[70][i]-'0';
    delay(timer*tempo);
  }
}