Exemplo n.º 1
0
 public void updateBrick(String uData)
 {
     int bx, by, bd;
     String[] bricks = uData.Split(';');
     for (int i = 0; i < bricks.Length; i++)
     {
         String[] bData = bricks[i].Split(',');
         bx = int.Parse(bData[0]);
         by = int.Parse(bData[1]);
         bd = int.Parse(bData[2]);
         Brick brick = new Brick(300, bx, by, bd);
         Battle.addObjects(brick, bx, by);
     }
 }
Exemplo n.º 2
0
 public void setBricks(String bData)
 {
     int bx, by;
     String[] bricks = bData.Split(';');
     for (int i = 0; i < bricks.Length; i++)
     {
         String[] data = bricks[i].Split(',');
         bx = int.Parse(data[0]);
         by = int.Parse(data[1]);
         Brick brick = new Brick(300, bx, by, 0);
         Battle.addObjects(brick, bx, by);
     }
 }