/* 
 * Thomas Pantzer: t_path.h, v0.1b  23.9.97 22:29 
 * 
 * 
 * Copyright 1997 by Thomas Pantzer
 * 
 * Permission to use, copy, modify, and distribute this software for noncommercial 
 * use and without fee is hereby granted, provided that the above copyright notice 
 * appear in all copies and that both that copyright notice and this permission 
 * notice appear in supporting documentation, and that the name of the Author not be 
 * used in advertising or publicity pertaining to distribution of the software 
 * without specific, written prior permission. The Author makes no representations about
 * the suitability of this software for any purpose.  It is provided "as is" 
 * without expressed or implied warranty. 
 * 
 * 
 * pantec@aix520.informatik.uni-leipzig.de   (Thomas Pantzer) 
 * 
 */



#ifndef T_PATH_H
#define T_PATH_H

#include <stdio.h>
#include "world.h"


class t_PATH {
public:
	t_vector way;
	char border,end,adjusted;
	float block,info;
	t_PATH *next;


	void Init(t_vector *center);
	void Done(void);

	t_PATH *Add(t_vector *np);
	void Draw(t_world *W,int dc);

	t_vector *LastPos(void);
	t_PATH *LastPos(int pre);
	t_PATH *Last_not_Adjusted(void);  

	int Length(void);		// total length
	int Length(t_PATH *);        // length up to this point 
   
	void Save(char *fn);
	void Save(int);	
	t_PATH *NextPos(FILE *fs);


private:
	void Save(int fd, char *buf);
	char Load(FILE *fs);
	void Draw(t_world *W);
};



#endif








/**/
/**/
/**/
/**/
/**/
/**/
/**/
/**/
/*****  End Of File  ****************************/
