xoreos  0.0.5
waypoint.h
Go to the documentation of this file.
1 /* xoreos - A reimplementation of BioWare's Aurora engine
2  *
3  * xoreos is the legal property of its developers, whose names
4  * can be found in the AUTHORS file distributed with this source
5  * distribution.
6  *
7  * xoreos is free software; you can redistribute it and/or
8  * modify it under the terms of the GNU General Public License
9  * as published by the Free Software Foundation; either version 3
10  * of the License, or (at your option) any later version.
11  *
12  * xoreos is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with xoreos. If not, see <http://www.gnu.org/licenses/>.
19  */
20 
25 #ifndef ENGINES_NWN2_WAYPOINT_H
26 #define ENGINES_NWN2_WAYPOINT_H
27 
28 #include "src/common/types.h"
29 #include "src/common/ustring.h"
30 
31 #include "src/aurora/types.h"
32 
33 #include "src/engines/nwn2/types.h"
35 
36 namespace Engines {
37 
38 namespace NWN2 {
39 
40 class Waypoint : public Object {
41 public:
43  Waypoint(const Aurora::GFF3Struct &waypoint);
44  ~Waypoint();
45 
46  // Basic properties
47 
49  bool hasMapNote() const;
51  bool enabledMapNote() const;
52 
54  void enableMapNote(bool enabled);
55 
58 
59 private:
60  bool _hasMapNote;
62 
65 
67  void load(const Aurora::GFF3Struct &waypoint);
69  void load(const Aurora::GFF3Struct &instance, const Aurora::GFF3Struct *blueprint);
70 
72  void loadProperties(const Aurora::GFF3Struct &gff);
73 };
74 
75 } // End of namespace NWN2
76 
77 } // End of namespace Engines
78 
79 #endif // ENGINES_NWN2_WAYPOINT_H
Common::UString getMapNote() const
Return the waypoint&#39;s map note text.
Definition: waypoint.cpp:71
bool hasMapNote() const
Does this waypoint have a map note?
Definition: waypoint.cpp:59
A class holding an UTF-8 string.
Definition: ustring.h:48
void load(const Aurora::GFF3Struct &waypoint)
Load from a waypoint instance.
Definition: waypoint.cpp:49
bool _hasMapNote
Does this waypoint have a map note?
Definition: waypoint.h:60
An object within a NWN2 area.
Definition: object.h:58
Basic Neverwinter Nights 2 type definitions.
Common::UString _mapNote
The waypoint&#39;s map note text.
Definition: waypoint.h:64
Low-level type definitions to handle fixed width types portably.
Waypoint(const Aurora::GFF3Struct &waypoint)
Load from a waypoint instance.
Definition: waypoint.cpp:39
void loadProperties(const Aurora::GFF3Struct &gff)
Load general waypoint properties.
Definition: waypoint.cpp:96
Unicode string handling.
Basic type definitions to handle files used in BioWare&#39;s Aurora engine.
void enableMapNote(bool enabled)
Enable/Disable the waypoint&#39;s map note.
Definition: waypoint.cpp:67
A struct within a GFF3.
Definition: gff3file.h:164
An object in a Neverwinter Nights 2 area.
bool enabledMapNote() const
Is this waypoint&#39;s map note currently enabled?
Definition: waypoint.cpp:63
bool _enabledMapNote
Is this waypoint&#39;s map note enabled?
Definition: waypoint.h:61