public Node getFrom(Status d){
			Node n;
			switch(d){
			case up:
				n=new Node(this.x-1,this.y);
				if(n.IsValid())
					return n;
				break;
			case down:
				n=new Node(this.x+1,this.y);
				if(n.IsValid())
					return n;
				break;
			case left:
				n=new Node(this.x,this.y-1);
				if(n.IsValid())
					return n;
				break;
			case right:
				n=new Node(this.x,this.y+1);
				if(n.IsValid())
					return n;
				break;
			default:
				return null;
			}
			return null;
		}