#pragma once

namespace arounders
{
    namespace accions
    {
        const int caminar       = 0;
        const int parar		    = 1;
        const int cavar		    = 2;
        const int escalar		= 3;
        const int perforar	    = 4;
        const int escalera	    = 5;
        const int pasarela	    = 6;
        const int corda		    = 7;
        const int suicidi		= 8;
        const int fastforward	= 9;
        const int caure         = 10;
        const int pujarcorda    = 11;
        const int baixarcorda   = 12;
        const int mort	        = 13;
    }

    namespace orientacions
    {
        const int dreta         = 0;
        const int esquerra      = 8;
    }

    struct arounder
    {
        int x, y, orientacio;
        int accio, prevista;
        int frame, frameX, frameY, altura;

        arounder *anterior;
        arounder *siguiente;
    };

    extern arounder *first;
    extern arounder *seleccionat;

    void init();

    void afegir();
    void pintar();

    const bool seleccionar();
    void abortarAccio();

    void procesar();

}
