Project

General

Profile

Revision 46587b36

ID46587b36263383b8009365ca3bf6dcfca7b32365

Added by Leon about 12 years ago

navigationMap prototype for Scout

View differences:

scout/libscout/src/behaviors/outboundVectTable.cpp
1
#include "navigationMap.h"
2

  
3
void navigationMap(std::string scoutname) : Behavior(scoutname)
4
{
5
    
6
}
scout/libscout/src/behaviors/outboundVectTable.h
1
#ifndef _NAVIGATION_MAP_
2
#define _NAVIGATION_MAP_
3

  
4
#include <cstdlib>
5

  
6
struct edge
7
{
8
    int direction; /// direction to turn
9
    int index;  /// map index
10
    int distance;   /// physical distance
11
};
12
typedef struct edge edge;
13

  
14
class navigationMap : Behavior
15
{
16
    public:
17
        navigationMap(std::string scoutname);
18
        
19
        void run();
20
        
21
        int get_state();
22
        int* shortest_path(int target_state);
23

  
24
        edge* get_outbound_edges();        
25

  
26
    private:
27
        edge** map; 
28
};
29
#endif

Also available in: Unified diff