diff options
-rw-r--r-- | ClientHamr/extantz/crappisspuke.cpp | 25 | ||||
-rw-r--r-- | ClientHamr/extantz/extantz.h | 23 |
2 files changed, 23 insertions, 25 deletions
diff --git a/ClientHamr/extantz/crappisspuke.cpp b/ClientHamr/extantz/crappisspuke.cpp index 51fb274..b853d96 100644 --- a/ClientHamr/extantz/crappisspuke.cpp +++ b/ClientHamr/extantz/crappisspuke.cpp | |||
@@ -1,30 +1,5 @@ | |||
1 | 1 | ||
2 | #include <irrlicht.h> | 2 | #include <irrlicht.h> |
3 | |||
4 | /* | ||
5 | In the Irrlicht Engine, everything can be found in the namespace 'irr'. So if | ||
6 | you want to use a class of the engine, you have to write irr:: before the name | ||
7 | of the class. For example to use the IrrlichtDevice write: irr::IrrlichtDevice. | ||
8 | To get rid of the irr:: in front of the name of every class, we tell the | ||
9 | compiler that we use that namespace from now on, and we will not have to write | ||
10 | irr:: anymore. | ||
11 | */ | ||
12 | using namespace irr; | ||
13 | |||
14 | /* | ||
15 | There are 5 sub namespaces in the Irrlicht Engine. Take a look at them, you can | ||
16 | read a detailed description of them in the documentation by clicking on the top | ||
17 | menu item 'Namespace List' or by using this link: | ||
18 | http://irrlicht.sourceforge.net/docu/namespaces.html | ||
19 | Like the irr namespace, we do not want these 5 sub namespaces now, to keep this | ||
20 | example simple. Hence, we tell the compiler again that we do not want always to | ||
21 | write their names. | ||
22 | */ | ||
23 | using namespace core; | ||
24 | using namespace scene; | ||
25 | using namespace video; | ||
26 | |||
27 | // This is here so that we can use the name spacing above, and not have to #ifdef lots of shit. | ||
28 | #include "extantz.h" | 3 | #include "extantz.h" |
29 | 4 | ||
30 | 5 | ||
diff --git a/ClientHamr/extantz/extantz.h b/ClientHamr/extantz/extantz.h index c234e81..a3c46e5 100644 --- a/ClientHamr/extantz/extantz.h +++ b/ClientHamr/extantz/extantz.h | |||
@@ -14,6 +14,29 @@ | |||
14 | 14 | ||
15 | 15 | ||
16 | #ifdef __cplusplus | 16 | #ifdef __cplusplus |
17 | /* | ||
18 | In the Irrlicht Engine, everything can be found in the namespace 'irr'. So if | ||
19 | you want to use a class of the engine, you have to write irr:: before the name | ||
20 | of the class. For example to use the IrrlichtDevice write: irr::IrrlichtDevice. | ||
21 | To get rid of the irr:: in front of the name of every class, we tell the | ||
22 | compiler that we use that namespace from now on, and we will not have to write | ||
23 | irr:: anymore. | ||
24 | */ | ||
25 | using namespace irr; | ||
26 | |||
27 | /* | ||
28 | There are 5 sub namespaces in the Irrlicht Engine. Take a look at them, you can | ||
29 | read a detailed description of them in the documentation by clicking on the top | ||
30 | menu item 'Namespace List' or by using this link: | ||
31 | http://irrlicht.sourceforge.net/docu/namespaces.html | ||
32 | Like the irr namespace, we do not want these 5 sub namespaces now, to keep this | ||
33 | example simple. Hence, we tell the compiler again that we do not want always to | ||
34 | write their names. | ||
35 | */ | ||
36 | using namespace core; | ||
37 | using namespace scene; | ||
38 | using namespace video; | ||
39 | |||
17 | extern "C"{ | 40 | extern "C"{ |
18 | #else | 41 | #else |
19 | 42 | ||