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

/**************************************************************

File				: ASTOffset.java
Auther				: M. Spiller
Registration #		: Y0259667
Date				: Thursday 13th november 2003
Unit				: CMP-2A25 Programming - Software Development Techniques
Description			: offset class containing offset method

**************************************************************/

import java.io.*;

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

	public ASTOffset(DrawPhase3 p, int id) 
	{
		super(p, id);
	}

    public void generate(FileWriter SVGFile, int Xsc, int Ysc, int X, 
						int Y, String colour, int brush)
    {
		//obtains offset values
		int Xnew = X + ((ASTInt)jjtGetChild(0)).val;
		int Ynew = Y + ((ASTInt)jjtGetChild(1)).val;
		//adds new vallues to generate method
        jjtGetChild(2).generate(SVGFile, Xsc, Ysc, Xnew, Ynew, colour, brush);
    }
}
