/* Generated By:JJTree: Do not edit this line. ASTTriangle.java */

public class ASTTriangle extends SimpleNode {
  public ASTTriangle(int id) {
    super(id);
  }

  public ASTTriangle(drawsimple p, int id) {
    super(p, id);
  }
  
  public generate()
  {
     // get the six children that define the points
     // for the triangle
     int c1 = ((ASTInt) jjtGetChild(0)).val;
     int c2 = ((ASTInt) jjtGetChild(1)).val;
     int c3 = ((ASTInt) jjtGetChild(2)).val;
     int c4 = ((ASTInt) jjtGetChild(3)).val;
     int c5 = ((ASTInt) jjtGetChild(4)).val;
     int c6 = ((ASTInt) jjtGetChild(5)).val;
     
     // output the SVG for the three lines
     System.out.println("<line x1=\"" + c1 +
        "\" y1=\"" + c2 +
        "\" x2=\"" + c3 +
        "\" y2=\"" + c4 +
        "\" stroke=\"black\" stroke-width=\"1\"/>");
     System.out.println("<line x1=\"" + c3 +
        "\" y1=\"" + c4 +
        "\" x2=\"" + c5 +
        "\" y2=\"" + c6 +
        "\" stroke=\"black\" stroke-width=\"1\"/>");
     System.out.println("<line x1=\"" + c5 +
        "\" y1=\"" + c6 +
        "\" x2=\"" + c1 +
        "\" y2=\"" + c2 +
        "\" stroke=\"black\" stroke-width=\"1\"/>");
  }

}
