Project::OSiRiON - Git repositories
Project::OSiRiON
News . About . Screenshots . Downloads . Forum . Wiki . Tracker . Git
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStijn Buys <ingar@osirion.org>2007-10-21 23:02:47 +0000
committerStijn Buys <ingar@osirion.org>2007-10-21 23:02:47 +0000
commita237a2d7723b94df6cd3e91401ec28388de6f1a0 (patch)
tree7da376d276d03fced7b94a807c0952fd32bcde08 /src/client/shipdrawer.cc
parent084c6212afaa6f996091f36d0ff85ac845803a87 (diff)
namespace cleanup
Diffstat (limited to 'src/client/shipdrawer.cc')
-rw-r--r--src/client/shipdrawer.cc22
1 files changed, 12 insertions, 10 deletions
diff --git a/src/client/shipdrawer.cc b/src/client/shipdrawer.cc
index d889178..de8dee0 100644
--- a/src/client/shipdrawer.cc
+++ b/src/client/shipdrawer.cc
@@ -1,15 +1,18 @@
-/* shipdrawer.cc
+/*
+ shipdrawer.cc
This file is part of the Osirion project and is distributed under
the terms and conditions of the GNU General Public License version 2
*/
-#include <iostream>
-
-// project headers
+#include "shipdrawer.h"
#include "gl/osiriongl.h"
#include "gl/box.h"
-#include "shipdrawer.h"
+#include <iostream>
+
+namespace client {
+
+using namespace gl;
Vector3f v0(1.0f, -1.0f, -1.0f);
Vector3f v1(1.0f, 1.0f, -1.0f);
@@ -21,7 +24,7 @@ Vector3f v5(-1.0f, 1.0f, -1.0f);
Vector3f v6(-1.0f, 1.0f, 1.0f);
Vector3f v7(-1.0f, -1.0f, 1.0f);
-ShipDrawer::ShipDrawer(Ship *s)
+ShipDrawer::ShipDrawer(game::Ship *s)
{
angle = 0;
ship = s;
@@ -33,17 +36,14 @@ ShipDrawer::~ShipDrawer()
void ShipDrawer::draw(float elapsed)
{
- using namespace gl;
-
gl::push();
rotate(ship->yaw, 0.0f, 1.0f, 0.0f );
-
Vector3f tl(0.25, 0.125, 0.125);
Vector3f br(-0.25, -0.125, -0.125);
- Box box(tl, br);
+ gl::Box box(tl, br);
box.draw();
tl = Vector3f(0, 0.07, 0.25);
@@ -106,3 +106,5 @@ void ShipDrawer::draw(float elapsed)
gl::pop();
}
+
+} // namespace client