#ifndef _DIRTY_H_
#define _DIRTY_H_

#include "rect.h"

class dirty : public m_rect
{
public:
    dirty();
    dirty(int, int, int, int, dirty *next = 0);
    void clear();
    
    dirty *next;
};

dirty *new_dirty(int top = 0, int bot = 0, int left = 0, int right = 0);
dirty *new_dirty(m_rect const &);
dirty *pop(dirty **list);
dirty *pop_list(dirty **list);
void push(dirty **list, dirty *elem);
void push_list(dirty **list, dirty *elem_list);

void clear_scratch();
void clear_screen();

void dirty_border_scratch();
void dirty_bonusses_scratch();
void dirty_screen(int x, int y);

void draw_tick_marks(BITMAP *b);
void draw_map();

void init_dirty();

extern int tick_spacing;

extern dirty *recycled;
extern dirty *scratch_dirty;
extern dirty *screen_dirty;

#endif
