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

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

  public ASTTriangle(drawphase1 p, int id) {
    super(p, id);
  }


/****************************************************
 This generates 3 lines to create a square, based on 
 the input values. First line is first pair of values
 to the second pair. Second is second pair to third
 pair. And Third line is third pair to first pair, 
 therefore creating a triangle using 3 lines.
****************************************************/

  public void generate()
  {
    System.out.println
	  ("<line x1=\"" + ((ASTInt) jjtGetChild(0)).val +
        "\" y1=\"" + ((ASTInt) jjtGetChild(1)).val +
        "\" x2=\"" + ((ASTInt) jjtGetChild(2)).val +
        "\" y2=\"" + ((ASTInt) jjtGetChild(3)).val + 
        "\" fill=\"none\" stroke=\"black\" stroke-width=\"1\" />");

    System.out.println
	  ("<line x1=\"" + ((ASTInt) jjtGetChild(2)).val +
        "\" y1=\"" + ((ASTInt) jjtGetChild(3)).val +
        "\" x2=\"" + ((ASTInt) jjtGetChild(4)).val +
        "\" y2=\"" + ((ASTInt) jjtGetChild(5)).val + 
        "\" fill=\"none\" stroke=\"black\" stroke-width=\"1\" />");

    System.out.println
	  ("<line x1=\"" + ((ASTInt) jjtGetChild(4)).val +
        "\" y1=\"" + ((ASTInt) jjtGetChild(5)).val +
        "\" x2=\"" + ((ASTInt) jjtGetChild(0)).val +
        "\" y2=\"" + ((ASTInt) jjtGetChild(1)).val + 
        "\" fill=\"none\" stroke=\"black\" stroke-width=\"1\" />");
  }

}
