~mudlet-makers/mudlet/gmcp

« back to all changes in this revision

Viewing changes to src/TMap.h

  • Committer: Vadim Peretokin
  • Date: 2010-08-28 18:10:10 UTC
  • Revision ID: vadi@vadi-laptop-20100828181010-bew8lo0qqqdxajmu
Added missing files.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/***************************************************************************
 
2
 *   Copyright (C) 2008 by Heiko Koehn (KoehnHeiko@googlemail.com)         *
 
3
 *                                                                         *
 
4
 *                                                                         *
 
5
 *   This program is free software; you can redistribute it and/or modify  *
 
6
 *   it under the terms of the GNU General Public License as published by  *
 
7
 *   the Free Software Foundation; either version 2 of the License, or     *
 
8
 *   (at your option) any later version.                                   *
 
9
 *                                                                         *
 
10
 *   This program is distributed in the hope that it will be useful,       *
 
11
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of        *
 
12
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         *
 
13
 *   GNU General Public License for more details.                          *
 
14
 *                                                                         *
 
15
 *   You should have received a copy of the GNU General Public License     *
 
16
 *   along with this program; if not, write to the                         *
 
17
 *   Free Software Foundation, Inc.,                                       *
 
18
 *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.             *
 
19
 ***************************************************************************/
 
20
 
 
21
 
 
22
 
 
23
#ifndef TMAP_H
 
24
#define TMAP_H
 
25
 
 
26
class TRoom;
 
27
class TArea;
 
28
class Host;
 
29
class GLWidget;
 
30
 
 
31
#include <QMap>
 
32
#include "TRoom.h"
 
33
#include "TArea.h"
 
34
#include "glwidget.h"
 
35
#include <stdlib.h>
 
36
#include "TAstar.h"
 
37
//#include "dlgMapper.h"
 
38
 
 
39
class dlgMapper;
 
40
 
 
41
class TMap
 
42
{
 
43
public:
 
44
    TMap( Host *);
 
45
    void init(Host*);
 
46
    void buildAreas();
 
47
    void setRoom( int );
 
48
    bool findPath( int from, int to );
 
49
    bool gotoRoom( int );
 
50
    bool gotoRoom( int, int );
 
51
    void setView( float, float, float, float );
 
52
    bool serialize( QDataStream & );
 
53
    bool restore();
 
54
    QMap<int, TRoom *> rooms;
 
55
    QMap<int, TArea *> areas;
 
56
    QMap<int, QString> areaNamesMap;
 
57
    QMap<int, int> envColors;
 
58
    QVector3D span;
 
59
    Host * mpHost;
 
60
    int mRoomId;
 
61
    int mTargetID;
 
62
    QList<int> mPathList;
 
63
    QList<QString> mDirList;
 
64
    GLWidget * mpM;
 
65
    dlgMapper * mpMapper;
 
66
 
 
67
};
 
68
 
 
69
 
 
70
 
 
71
 
 
72
#endif // TMAP_H
 
73
 
 
74