/*===========================================
            Plant and fireworks
              Martin Robinson
                tree object
===========================================*/
#pragma once
#ifndef doddle_deja
#define doddle_deja

#include "turtle.hpp"

#include <math.h>
#include <string>
#include <stack>

using namespace std;

class doddle
{
    turtle _turtle,
           _start;
    stack <turtle> _stack;
    int _index;
    int _touch;
    string _path;
public:

    void init(int, int);
    int x();
    int y();
    //float rad();
    int len();
    char get();
    bool end();
    void reset();
    void next();
    void parse();
    int index();
    void insert(string);
    void pathTo(int, int);
    void touch();
    void unTouch();
    bool isTouch();
    bool atTouch();
};

#endif
