Index: code/trunk/bin/keybindings.ini
===================================================================
--- code/trunk/bin/keybindings.ini	(revision 1401)
+++ code/trunk/bin/keybindings.ini	(revision 1407)
@@ -1,5 +1,5 @@
 [KeyBinder]
-KeyUNASSIGNED=activateConsole
-KeyESCAPE=exit
+KeyUNASSIGNED=
+KeyESCAPE= exit
 Key1=
 Key2=
@@ -15,5 +15,5 @@
 KeyEQUALS=activateConsole
 KeyBACK=
-KeyTAB=cycleNavigationFocus
+KeyTAB=
 KeyQ=
 KeyW=
@@ -154,6 +154,6 @@
 MouseButton6=
 MouseButton7=
-MouseWheel1Up=
-MouseWheel1Down=
+MouseWheel1Up=AxisAmp 0.1 slomo
+MouseWheel1Down=AxisAmp 0.1 slomo
 MouseWheel2Up=
 MouseWheel2Down=
Index: code/trunk/bin/levels/sample.oxw
===================================================================
--- code/trunk/bin/levels/sample.oxw	(revision 1401)
+++ code/trunk/bin/levels/sample.oxw	(revision 1407)
@@ -10,9 +10,9 @@
 
 <!--Ambient colourvalue="1,1,1" /-->
-<Skybox src="Orxonox/Starbox" />
+<Skybox src="Orxonox/StarSkyBox" />
 <SpaceShip camera="true" position="0,0,0" scale="10" yawpitchroll="0,0,0" mesh="assff.mesh" maxSpeed="500" maxSideAndBackSpeed="50" maxRotation="1.0" transAcc="200" rotAcc="3.0" transDamp="75" rotDamp="1.0" />
-<Model position="2000,0,0" scale="10" mesh="tomato.mesh" yawpitchroll="-40,30,0" rotationAxis="1,0,0" rotationRate="-30"/>
-<Model position="0,2000,0" scale="10" mesh="tomato.mesh" yawpitchroll="-50,60,0" rotationAxis="1,0,0" rotationRate="-30"/>
-<Model position="0,0,2000" scale="10" mesh="tomato.mesh" yawpitchroll="-50,-30,0" rotationAxis="1,0,0" rotationRate="-30"/>
+<Model position="1500,0,100" scale="10" mesh="tomato.mesh" yawpitchroll="-40,30,0" rotationAxis="1,0,0" rotationRate="-30"/>
+<Model position="0,4200,0" scale="10" mesh="tomato.mesh" yawpitchroll="-50,60,0" rotationAxis="1,0,0" rotationRate="-30"/>
+<Model position="0,0,6800" scale="10" mesh="tomato.mesh" yawpitchroll="-50,-30,0" rotationAxis="1,0,0" rotationRate="-30"/>
 <NPC position="0,100,400" scale="1" mesh="razor.mesh"/>
 <NPC position="0,100,400" scale="1" mesh="razor.mesh"/>
Index: code/trunk/src/orxonox/CMakeLists.txt
===================================================================
--- code/trunk/src/orxonox/CMakeLists.txt	(revision 1401)
+++ code/trunk/src/orxonox/CMakeLists.txt	(revision 1407)
@@ -9,5 +9,4 @@
   hud/RadarOverlayElement.cc
   hud/RadarObject.cc
-  hud/Navigation.cc
   particle/ParticleInterface.cc
   tolua/tolua_bind.cc
Index: code/trunk/src/orxonox/Orxonox.cc
===================================================================
--- code/trunk/src/orxonox/Orxonox.cc	(revision 1401)
+++ code/trunk/src/orxonox/Orxonox.cc	(revision 1407)
@@ -180,6 +180,6 @@
   {
     // keep in mind: the order of deletion is very important!
-//    if (this->orxonoxHUD_)
-//      delete this->orxonoxHUD_;
+    if (this->orxonoxHUD_)
+      delete this->orxonoxHUD_;
     Loader::close();
     InputManager::destroy();
@@ -348,5 +348,5 @@
     // Load the HUD
     COUT(3) << "Orxonox: Loading HUD..." << std::endl;
-    orxonoxHUD_ = &HUD::getSingleton();
+    orxonoxHUD_ = new HUD(1);
 
     COUT(3) << "Orxonox: Loading Console..." << std::endl;
@@ -487,5 +487,5 @@
 //      orxonoxHUD_->setRocket2(ogreRoot.getCurrentFrameNumber());
       if (eventTimes[3].back() - eventTimes[3].front() != 0)
-        HUD::setFPS(50000.0f/(eventTimes[3].back() - eventTimes[3].front()));
+//        orxonoxHUD_->setRocket1((int)(50000.0f/(eventTimes[3].back() - eventTimes[3].front())));
 
       // Iterate through all Tickables and call their tick(dt) function
Index: code/trunk/src/orxonox/hud/BarOverlayElement.cc
===================================================================
--- code/trunk/src/orxonox/hud/BarOverlayElement.cc	(revision 1401)
+++ code/trunk/src/orxonox/hud/BarOverlayElement.cc	(revision 1407)
@@ -27,4 +27,6 @@
 
 #include <OgreOverlayManager.h>
+#include <OgreOverlayElement.h>
+#include <OgrePanelOverlayElement.h>
 #include "GraphicsEngine.h"
 #include "BarOverlayElement.h"
@@ -34,5 +36,5 @@
   using namespace Ogre;
 
-    BarOverlayElement::BarOverlayElement(const String& name):PanelOverlayElement(name){
+    BarOverlayElement::BarOverlayElement(const String& name):Ogre::PanelOverlayElement(name){
         name_ = name;
     }
@@ -40,8 +42,8 @@
     BarOverlayElement::~BarOverlayElement(){}
 
-    void BarOverlayElement::init(Real leftRel, Real topRel, Real dimRel, OverlayContainer* container){
+    void BarOverlayElement::init(Real leftRel, Real topRel, Real dimRel, Ogre::OverlayContainer* container){
         // init some values...
         container_ = container;
-        om = &OverlayManager::getSingleton();
+        om = &Ogre::OverlayManager::getSingleton();
         value_ = 0;
         color_ = 2;
@@ -51,10 +53,10 @@
         topRel_ = topRel;
         dimRel_ = dimRel;
-
+        
         // create background...
         background_ = static_cast<OverlayContainer*>(om->createOverlayElement("Panel", name_+"container"));
         background_->show();
         container_->addChild(background_);
-        background_->setMetricsMode(GMM_PIXELS);
+        background_->setMetricsMode(Ogre::GMM_PIXELS);
         background_->setMaterialName("Orxonox/BarBackground");
 
@@ -63,5 +65,5 @@
 
         show();
-        setMetricsMode(GMM_PIXELS);
+        setMetricsMode(Ogre::GMM_PIXELS);
         setMaterialName("Orxonox/Green");
         background_->addChild(this);
Index: code/trunk/src/orxonox/hud/BarOverlayElement.h
===================================================================
--- code/trunk/src/orxonox/hud/BarOverlayElement.h	(revision 1401)
+++ code/trunk/src/orxonox/hud/BarOverlayElement.h	(revision 1407)
@@ -30,8 +30,12 @@
 #define _BAR_H__
 
+#include <OgreOverlayManager.h>
+#include <OgreOverlayElement.h>
+#include <OgrePanelOverlayElement.h>
 
-#include <OgrePanelOverlayElement.h>
 #include <OgrePrerequisites.h>
 #include "../OrxonoxPrereqs.h"
+
+
 
 namespace orxonox
Index: code/trunk/src/orxonox/hud/HUD.cc
===================================================================
--- code/trunk/src/orxonox/hud/HUD.cc	(revision 1401)
+++ code/trunk/src/orxonox/hud/HUD.cc	(revision 1407)
@@ -26,29 +26,25 @@
 */
 
-#include <string.h>
+
 #include "OrxonoxStableHeaders.h"
 #include <OgreOverlay.h>
 #include <OgreOverlayContainer.h>
 #include <OgreOverlayManager.h>
+#include <OgreSceneNode.h>
+#include <OgreEntity.h>
 #include <OgreStringConverter.h>
-
 #include "core/Debug.h"
-#include "core/ConsoleCommand.h"
 #include "objects/SpaceShip.h"
+#include "HUD.h"
 #include "BarOverlayElement.h"
 #include "RadarOverlayElement.h"
 #include "OverlayElementFactories.h"
-#include "HUD.h"
 
 namespace orxonox
 {
-    ConsoleCommandShortcut(HUD, cycleNavigationFocus, AccessLevel::User);
-
     using namespace Ogre;
 
-    HUD::HUD(){
+    HUD::HUD(int zoom){
         om = &Ogre::OverlayManager::getSingleton();
-        firstRadarObject = NULL;
-        lastRadarObject = NULL;
 
 		// create Factories
@@ -60,14 +56,12 @@
         orxonoxHUD = om->create("Orxonox/HUD");
         container = static_cast<Ogre::OverlayContainer*>(om->createOverlayElement("Panel", "Orxonox/HUD/container"));
-
-        // creating text to display fps
-        fpsText = static_cast<TextAreaOverlayElement*>(om->createOverlayElement("TextArea", "fpsText"));
-        fpsText->show();
-        fpsText->setMetricsMode(Ogre::GMM_PIXELS);
-        fpsText->setDimensions(0.001, 0.001);
-        fpsText->setPosition(10, 10);
-        fpsText->setFontName("Console");
-        fpsText->setCharHeight(20);
-        fpsText->setCaption("init");
+        // test
+        test = static_cast<TextAreaOverlayElement*>(om->createOverlayElement("TextArea", "test123"));
+        test->show();
+        test->setMetricsMode(Ogre::GMM_RELATIVE);
+        test->setDimensions(0.8, 0.8);
+        test->setPosition(0.02, 0.02);
+        test->setFontName("Console");
+        test->setCaption("init");
 
         // create energy bar
@@ -81,7 +75,4 @@
         radar->show();
 
-        // create Navigation
-        nav = new Navigation(container);
-
 		// set up screen-wide container
         container->show();
@@ -94,23 +85,21 @@
         container->setHeight(1.0);
         container->setMetricsMode(Ogre::GMM_RELATIVE);
-        container->addChild(fpsText);
-
+        container->addChild(test);
         energyBar->init(0.01, 0.94, 0.4, container);
         energyBar->setValue(1);
-
         speedoBar->init(0.01, 0.90, 0.4, container);
-
         radar->init(0.5, 0.9, 0.2, container);
-        addRadarObject(Vector3(2000.0, 0.0, 0.0));
-        addRadarObject(Vector3(0.0, 2000.0, 0.0));
-        addRadarObject(Vector3(0.0, 0.0, 2000.0));
-    }
-
-    HUD::~HUD(){
-        //todo: clean up objects
+        radar->addObject(Vector3(1500.0, 0.0, 100.0));
+        radar->addObject(Vector3(0.0, 4000.0, 0.0));
+        radar->addObject(Vector3(0.0, 0.0, 6800.0));
+        RadarOverlayElement::cycleFocus();
     }
 
     void HUD::tick(float dt)
     {
+        int d = radar->getDist2Focus()/10;
+        if(d) test->setCaption("Distance: " + Ogre::StringConverter::toString(d));
+        else test->setCaption("");
+
         energyBar->resize();
 
@@ -122,39 +111,7 @@
         radar->resize();
         radar->update();
-
-        nav->update();
     }
 
-    void HUD::addRadarObject(Vector3 pos){
-        // check if this is the first RadarObject to create
-        if(firstRadarObject == NULL){
-            firstRadarObject = new RadarObject(container, pos);
-            lastRadarObject = firstRadarObject;
-        }
-        else{ // if not, append to list
-            lastRadarObject->next = new RadarObject(container, pos);
-            lastRadarObject = lastRadarObject->next;
-        }
-    }
-
-    RadarObject* HUD::getFirstRadarObject(){
-        return firstRadarObject;
-    }
-
-    /*static*/HUD& HUD::getSingleton(){
-        static HUD theInstance;
-        return theInstance;
-    }
-
-    /*static*/void HUD::setFPS(float fps){
-        HUD::getSingleton().fpsText->setCaption("FPS: " + Ogre::StringConverter::toString(fps));
-    }
-
-    /*static*/void HUD::setEnergy(float value){
-        HUD::getSingleton().energyBar->setValue(value);
-    }
-
-    /*static*/void HUD::cycleNavigationFocus(){
-        HUD::getSingleton().nav->cycleFocus();
+    HUD::~HUD(void){
     }
 }
Index: code/trunk/src/orxonox/hud/HUD.h
===================================================================
--- code/trunk/src/orxonox/hud/HUD.h	(revision 1401)
+++ code/trunk/src/orxonox/hud/HUD.h	(revision 1407)
@@ -30,12 +30,13 @@
 #define _HUD_H__
 
+#include <string.h>
+#include <OgreOverlayElement.h>
+#include <OgreTextAreaOverlayElement.h>
 #include <OgrePrerequisites.h>
-#include <OgreTextAreaOverlayElement.h>
+
 #include "OrxonoxPrereqs.h"
 #include "core/Tickable.h"
 #include "BarOverlayElement.h"
 #include "RadarOverlayElement.h"
-#include "Navigation.h"
-#include "RadarObject.h"
 
 
@@ -45,28 +46,17 @@
     {
         private:
-            HUD();
-            HUD(HUD& instance);
-            ~HUD();
             Ogre::OverlayManager* om;
             Ogre::Overlay* orxonoxHUD;
             Ogre::OverlayContainer* container;
-            Ogre::TextAreaOverlayElement* fpsText;
+            Ogre::TextAreaOverlayElement* test;
             BarOverlayElement* energyBar;
             BarOverlayElement* speedoBar;
             RadarOverlayElement* radar;
-            RadarObject* firstRadarObject;
-            RadarObject* lastRadarObject;
-            Navigation* nav;
 
         public:
+            HUD(int zoom);
+            ~HUD();
             virtual void tick(float);
-            void addRadarObject(Vector3 pos);
-            RadarObject* getFirstRadarObject();
 
-            static HUD* instance_s;
-            static HUD& getSingleton();
-            static void setFPS(float fps);
-            static void setEnergy(float value);
-            static void cycleNavigationFocus();
     };
 }
Index: code/trunk/src/orxonox/hud/Navigation.cc
===================================================================
--- code/trunk/src/orxonox/hud/Navigation.cc	(revision 1401)
+++ 	(revision )
@@ -1,196 +1,0 @@
-/*
-*   ORXONOX - the hotnavText_ 3D action shooter ever to exist
-*
-*
-*   License notice:
-*
-*   This program is free software; you can redistribute it and/or
-*   modify it under the terms of the GNU General Public License
-*   as published by the Free Software Foundation; either version 2
-*   of the License, or (at your option) any later version.
-*
-*   This program is distributed in the hope that it will be useful,
-*   but WITHOUT ANY WARRANTY; without even the implied warranty of
-*   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-*   GNU General Public License for more details.
-*
-*   You should have received a copy of the GNU General Public License
-*   along with this program; if not, write to the Free Software
-*   Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
-*
-*   Author:
-*      Felix Schulthess
-*   Co-authors:
-*      ...
-*
-*/
-
-#include <OgreOverlayManager.h>
-#include <OgrePanelOverlayElement.h>
-#include <OgreTextAreaOverlayElement.h>
-#include <OgreStringConverter.h>
-#include <GraphicsEngine.h>
-#include "objects/SpaceShip.h"
-#include "objects/CameraHandler.h"
-#include "HUD.h"
-#include "Navigation.h"
-
-namespace orxonox
-{
-    using namespace Ogre;
-
-    Navigation::Navigation(OverlayContainer* container){
-        container_ = container;
-        focus_ = NULL;
-        init();
-    }
-
-    Navigation::Navigation(OverlayContainer* container, RadarObject* focus){
-        container_ = container;
-        focus_ = focus;
-        init();
-    }
-
-    void Navigation::init(){
-		om = &OverlayManager::getSingleton();
-		navCam_ = NULL;
-        // create nav text
-        navText_ = static_cast<TextAreaOverlayElement*>(om->createOverlayElement("TextArea", "navText"));
-        navText_->show();
-        navText_->setMetricsMode(Ogre::GMM_PIXELS);
-        navText_->setDimensions(0.001, 0.001);
-        navText_->setPosition(0.02, 0.02);
-        navText_->setFontName("Console");
-        navText_->setCharHeight(20);
-        navText_->setCaption("");
-        container_->addChild(navText_);
-
-
-        // create nav marker ...
-        navMarker_ = static_cast<PanelOverlayElement*>(om->createOverlayElement("Panel", "NavMarker"));
-        navMarker_->setMetricsMode(GMM_PIXELS);
-        navMarker_->hide();
-        navText_->hide();
-        container_->addChild(navMarker_);
-	}
-
-	void Navigation::update(){
-        if(focus_ == NULL) return;
-        navCamPos_ = SpaceShip::getLocalShip()->getPosition();
-        currentDir_ = SpaceShip::getLocalShip()->getDir();
-		currentOrth_ = SpaceShip::getLocalShip()->getOrth();
-
-        windowW_ = GraphicsEngine::getSingleton().getWindowWidth();
-        windowH_ = GraphicsEngine::getSingleton().getWindowHeight();
-        updateMarker();
-    }
-
-    void Navigation::updateMarker(){
-        // set text
-        int dist = (float)(getDist2Focus()/100);
-        navText_->setCaption(Ogre::StringConverter::toString(dist));
-
-        if(navCam_ == NULL) navCam_ = SpaceShip::getLocalShip()->getCamera()->cam_;
-        Vector3 pos = focus_->pos_;
-        // transform to screen coordinates
-        pos = navCam_->getProjectionMatrix()*navCam_->getViewMatrix()*pos;
-        float xPosRel = 0.5*pos.x+0.5;
-        float yPosRel = 1-(0.5*pos.y+0.5);
-        int xPos = xPosRel*windowW_;
-        int yPos = yPosRel*windowH_;
-        // is object in view?
-        bool outOfView = (xPosRel<0 || xPosRel>1 || yPosRel<0 || yPosRel>1);
-        // if object is behind us, it is out of view anyway:
-        if(!outOfView && RadarOverlayElement::calcRadius(navCamPos_, currentDir_, currentOrth_, focus_)>3.14/2) outOfView = true;
-
-        if(outOfView){
-            // NO!
-            navMarker_->setMaterialName("Orxonox/NavArrows");
-            navMarker_->setDimensions(16,16);
-            float phiUpRight = atan((float)(windowW_)/(float)(windowH_));
-            // from the angle we find out where to draw the marker
-            // and which of the four arrows to take
-            float phiNav = RadarOverlayElement::calcPhi(navCamPos_, currentDir_, currentOrth_, focus_);
-            bool right = RadarOverlayElement::calcRight(navCamPos_, currentDir_, currentOrth_, focus_);
-            if(right){
-                if(phiNav<phiUpRight){
-                    // arrow up
-                    navMarker_->setPosition(tan(phiNav)*windowH_/2+windowW_/2, 0);
-                    navMarker_->setUV(0.5, 0.0, 1.0, 0.5);
-                    navText_->setLeft(navMarker_->getLeft()+navMarker_->getWidth());
-                    navText_->setTop(navMarker_->getHeight());
-                }
-                else if(phiNav>3.14-phiUpRight){
-                    // arrow down
-                    navMarker_->setPosition(-tan(phiNav)*windowH_/2+windowW_/2, windowH_-16);
-                    navMarker_->setUV(0.0, 0.5, 0.5, 1.0);
-                    navText_->setLeft(navMarker_->getLeft()+navMarker_->getWidth());
-                    navText_->setTop(navMarker_->getTop()-navMarker_->getHeight());
-                }
-                else {
-                    // arrow right
-                    navMarker_->setPosition(windowW_-16, -tan((3.14-2*phiNav)/2)*windowW_/2+windowH_/2);
-                    navMarker_->setUV(0.5, 0.5, 1.0, 1.0);
-                    navText_->setLeft(navMarker_->getLeft()-navMarker_->getWidth());
-                    navText_->setTop(navMarker_->getTop()+navMarker_->getHeight());
-                }
-            }
-            else{
-                if(phiNav<phiUpRight) {
-                    // arrow up
-                    navMarker_->setPosition(-tan(phiNav)*windowH_/2+windowW_/2, 0);
-                    navMarker_->setUV(0.5, 0.0, 1.0, 0.5);
-                    navText_->setLeft(navMarker_->getLeft()+navMarker_->getWidth());
-                    navText_->setTop(navMarker_->getHeight());
-                }
-                else if(phiNav>3.14-phiUpRight) {
-                    // arrow down
-                    navMarker_->setPosition(tan(phiNav)*windowH_/2+windowW_/2, windowH_-16);
-                    navMarker_->setUV(0.0, 0.5, 0.5, 1.0);
-                    navText_->setLeft(navMarker_->getLeft()+navMarker_->getWidth());
-                    navText_->setTop(navMarker_->getTop()-navMarker_->getHeight());
-                }
-                else {
-                    // arrow left
-                    navMarker_->setPosition(0, -tan((3.14-2*phiNav)/2)*windowW_/2+windowH_/2);
-                    navMarker_->setUV(0.0, 0.0, 0.5, 0.5);
-                    navText_->setLeft(navMarker_->getWidth());
-                    navText_->setTop(navMarker_->getTop()+navMarker_->getHeight());
-                }
-            }
-        }
-        else{
-            // YES!
-            navMarker_->setMaterialName("Orxonox/NavTDC");
-            navMarker_->setDimensions(24,24);
-            navMarker_->setUV(0.0,0.0,1.0,1.0);
-            navMarker_->setPosition(xPos-navMarker_->getWidth()/2, yPos-navMarker_->getHeight()/2);
-            navText_->setPosition(xPos+navMarker_->getWidth()/2, yPos+navMarker_->getHeight()/2);
-        }
-	}
-
-    void Navigation::cycleFocus(){
-	    if(focus_ == NULL){
-            focus_ = HUD::getSingleton().getFirstRadarObject();
-	    }
-        else{
-            focus_->panel_->setMaterialName("Orxonox/RedDot");
-            if(focus_ != NULL) focus_ = focus_->next;
-        }
-
-        if(focus_ == NULL){
-            navMarker_->hide();
-            navText_->hide();
-        }
-        else{
-            navMarker_->show();
-            navText_->show();
-            focus_->panel_->setMaterialName("Orxonox/WhiteDot");
-        }
-	}
-
-	float Navigation::getDist2Focus(){
-	    if(focus_ == NULL) return(0.0);
-	    return((focus_->pos_-SpaceShip::getLocalShip()->getPosition()).length());
-	}
-}
Index: code/trunk/src/orxonox/hud/Navigation.h
===================================================================
--- code/trunk/src/orxonox/hud/Navigation.h	(revision 1401)
+++ 	(revision )
@@ -1,66 +1,0 @@
-/*
-*   ORXONOX - the hottest 3D action shooter ever to exist
-*
-*
-*   License notice:
-*
-*   This program is free software; you can redistribute it and/or
-*   modify it under the terms of the GNU General Public License
-*   as published by the Free Software Foundation; either version 2
-*   of the License, or (at your option) any later version.
-*
-*   This program is distributed in the hope that it will be useful,
-*   but WITHOUT ANY WARRANTY; without even the implied warranty of
-*   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-*   GNU General Public License for more details.
-*
-*   You should have received a copy of the GNU General Public License
-*   along with this program; if not, write to the Free Software
-*   Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
-*
-*   Author:
-*      Felix Schulthess
-*   Co-authors:
-*      ...
-*
-*/
-
-#ifndef _NAVIGATION_H__
-#define _NAVIGATION_H__
-
-#include <OgrePrerequisites.h>
-#include "../OrxonoxPrereqs.h"
-#include <OgrePlane.h>
-#include "util/Math.h"
-#include "RadarObject.h"
-
-namespace orxonox
-{
-    class _OrxonoxExport Navigation
-    {
-    	private:
-    		Ogre::OverlayManager* om;				    // our one and only overlay manager
-            Ogre::OverlayContainer* container_;
-            Ogre::PanelOverlayElement* navMarker_;      // the panel used to show the arrow
-            Ogre::TextAreaOverlayElement* navText_;     // displaying distance
-            Ogre::Camera* navCam_;
-    		Vector3 navCamPos_;                            // position of ship
-    		Vector3 currentDir_;
-            Vector3 currentOrth_;
-    		int windowW_, windowH_;
-    		void init();
-    		void updateMarker();
-
-    	public:
-    		Navigation(Ogre::OverlayContainer* container);
-    		Navigation(Ogre::OverlayContainer* container, RadarObject* focus);
-    		~Navigation();
-			RadarObject* focus_;                        // next pointer of linked list
-
-    		void update();
-    		void cycleFocus();
-    		float getDist2Focus();
-	};
-}
-
-#endif
Index: code/trunk/src/orxonox/hud/RadarObject.cc
===================================================================
--- code/trunk/src/orxonox/hud/RadarObject.cc	(revision 1401)
+++ code/trunk/src/orxonox/hud/RadarObject.cc	(revision 1407)
@@ -26,9 +26,4 @@
 */
 
-#include <string.h>
-#include <OgreOverlayManager.h>
-#include <OgrePanelOverlayElement.h>
-#include <OgreStringConverter.h>
-#include <util/Math.h>
 #include "RadarObject.h"
 
@@ -39,5 +34,5 @@
 	int RadarObject::count = 0;		// initialize static variable
 
-	RadarObject::RadarObject(OverlayContainer* container){
+	RadarObject::RadarObject(Ogre::OverlayContainer* container){
 		container_ = container;
 		pos_ = Vector3(0.0, 0.0, 0.0);
@@ -45,5 +40,5 @@
 	}
 
-	RadarObject::RadarObject(OverlayContainer* container, Vector3 pos){
+	RadarObject::RadarObject(Ogre::OverlayContainer* container, Vector3 pos){
 		container_ = container;
 		pos_ = pos;
@@ -55,7 +50,7 @@
 	void RadarObject::init(){
 	    next = NULL;
-		om = &OverlayManager::getSingleton();
+		om = &Ogre::OverlayManager::getSingleton();
 		panel_ = static_cast<PanelOverlayElement*>(om->createOverlayElement("Panel",
-			"Object"+StringConverter::toString(count)));
+			"Object"+Ogre::StringConverter::toString(count)));
 		panel_->setMaterialName("Orxonox/RedDot");
 		panel_->setDimensions(3,3);
@@ -67,2 +62,8 @@
 	}
 }
+
+/* my local clipboard...
+COUT(3) << "WWWWWWWWWWWWWWWWWWWWWWWWWWWW\n";
+COUT(3) << firstRadarObject_->radius_ << "  " << firstRadarObject_->phi_ << std::endl;
+COUT(3) << "WWWWWWWWWWWWWWWWWWWWWWWWWWWW\n";
+*/
Index: code/trunk/src/orxonox/hud/RadarObject.h
===================================================================
--- code/trunk/src/orxonox/hud/RadarObject.h	(revision 1401)
+++ code/trunk/src/orxonox/hud/RadarObject.h	(revision 1407)
@@ -28,5 +28,13 @@
 #ifndef _RADAR2_H__
 #define _RADAR2_H__
+
+#include <string.h>
 #include <OgrePrerequisites.h>
+#include <OgreOverlayManager.h>
+#include <OgreOverlayElement.h>
+#include <OgrePanelOverlayElement.h>
+#include <OgreStringConverter.h>
+
+#include <util/Math.h>
 #include "../OrxonoxPrereqs.h"
 
@@ -47,4 +55,5 @@
             int index_;                             // index number of object
     		Vector3 pos_;							// position in space
+			Ogre::Real radius_, phi_;				// position on radar
 			Ogre::OverlayContainer* container_;
 			Ogre::PanelOverlayElement* panel_;		// the panel used to show the dot
Index: code/trunk/src/orxonox/hud/RadarOverlayElement.cc
===================================================================
--- code/trunk/src/orxonox/hud/RadarOverlayElement.cc	(revision 1401)
+++ code/trunk/src/orxonox/hud/RadarOverlayElement.cc	(revision 1407)
@@ -22,28 +22,20 @@
 *      Yuning Chai
 *   Co-authors:
-*      Felix Schulthess
+*      ...
 *
 */
-#include <string.h>
-
-
-#include <string.h>
-#include <OgreOverlayManager.h>
-#include <OgreStringConverter.h>
-#include <OgrePanelOverlayElement.h>
-
-#include "GraphicsEngine.h"
-#include "core/Tickable.h"
-#include "core/ConsoleCommand.h"
-#include "objects/SpaceShip.h"
-#include "HUD.h"
+
 #include "RadarOverlayElement.h"
 
 namespace orxonox
 {
+    ConsoleCommandShortcut(RadarOverlayElement, cycleFocus, AccessLevel::User);
 
     using namespace Ogre;
 
-    RadarOverlayElement::RadarOverlayElement(const String& name):PanelOverlayElement(name){
+    RadarOverlayElement* RadarOverlayElement::instance_s = NULL;
+
+    RadarOverlayElement::RadarOverlayElement(const String& name):Ogre::PanelOverlayElement(name){
+        RadarOverlayElement::instance_s = this;
     }
 
@@ -51,13 +43,33 @@
     }
 
-    void RadarOverlayElement::init(Real leftRel, Real topRel, Real dimRel, OverlayContainer* container){
+    void RadarOverlayElement::init(Real leftRel, Real topRel, Real dimRel, Ogre::OverlayContainer* container){
         // some initial data
-		om = &OverlayManager::getSingleton();
+		om = &Ogre::OverlayManager::getSingleton();
         dimRel_ = dimRel;
         leftRel_ = leftRel;
         topRel_ = topRel;
         container_ = container;
-
-        setMetricsMode(GMM_PIXELS);
+        firstRadarObject_ = NULL;
+        lastRadarObject_ = NULL;
+        focus_ = NULL;
+
+        // create nav marker ...
+        navMarker_ = static_cast<PanelOverlayElement*>(om->createOverlayElement("Panel", "NavMarker"));
+        navMarker_->setMetricsMode(Ogre::GMM_PIXELS);
+        navMarker_->setMaterialName("Orxonox/NavMarker");
+        navMarker_->setDimensions(16,16);
+        navMarker_->setPosition(0,386);
+        navMarker_->hide();
+        container_->addChild(navMarker_);
+
+        // these have to fit the data in the level
+        shipPos_ = Vector3(0.0, 0.0, 0.0);
+        initialDir_ = Vector3(1.0, 0.0, 0.0);
+        currentDir_ = initialDir_;
+        initialOrth_ = Vector3(0.0, 0.0, 1.0);
+        currentOrth_ = initialOrth_;
+        plane = Plane(currentDir_, shipPos_);
+
+        setMetricsMode(Ogre::GMM_PIXELS);
         setMaterialName("Orxonox/Radar");
         resize();
@@ -78,14 +90,16 @@
 
     void RadarOverlayElement::update() {
-        shipPos_ = SpaceShip::getLocalShip()->getPosition();
-        currentDir_ = SpaceShip::getLocalShip()->getDir();
-		currentOrth_ = SpaceShip::getLocalShip()->getOrth();
-        RadarObject* ro = HUD::getSingleton().getFirstRadarObject();
+        shipPos_ = SpaceShip::instance_s->getPosition();
+        currentDir_ = SpaceShip::instance_s->getOrientation()*initialDir_; 		// according to beni....
+		currentOrth_ = SpaceShip::instance_s->getOrientation()*initialOrth_;
+        plane = Plane(currentDir_, shipPos_);
+
+        RadarObject* ro = firstRadarObject_;
         // iterate through all RadarObjects
 		while(ro != NULL){
 		    // calc position on radar...
-            float radius = calcRadius(shipPos_, currentDir_, currentOrth_, ro);
-            float phi = calcPhi(shipPos_, currentDir_, currentOrth_, ro);
-            bool right = calcRight(shipPos_, currentDir_, currentOrth_, ro);
+            ro->radius_ = calcRadius(ro);
+            ro->phi_ = calcPhi(ro);
+            ro->right_ = calcRight(ro);
 
             // set size to fit distance...
@@ -96,19 +110,67 @@
             else ro->panel_->setDimensions(1,1);
 
-            if (right){
-                ro->panel_->setPosition(sin(phi)*radius/
-                    3.5*dim_/2+dim_/2+left_-2,-cos(phi)*radius/3.5*dim_/2+dim_/2+top_-2);
+            if (ro->right_){
+                ro->panel_->setPosition(sin(ro->phi_)*ro->radius_/
+                    3.5*dim_/2+dim_/2+left_-2,-cos(ro->phi_)*ro->radius_/3.5*dim_/2+dim_/2+top_-2);
             }
             else {
-                ro->panel_->setPosition(-sin(phi)*radius/
-                    3.5*dim_/2+dim_/2+left_-2,-cos(phi)*radius/3.5*dim_/2+dim_/2+top_-2);
+                ro->panel_->setPosition(-sin(ro->phi_)*ro->radius_/
+                    3.5*dim_/2+dim_/2+left_-2,-cos(ro->phi_)*ro->radius_/3.5*dim_/2+dim_/2+top_-2);
             }
             ro = ro->next;
 		}
-    }
+		updateNavMarker();
+    }
+
+    void RadarOverlayElement::updateNavMarker(){
+        if(focus_ == NULL) return;
+        // from the angle we find out where to draw the marker
+        // and which of the four arrows to take
+        float r1 = atan((float)(windowW_)/(float)(windowH_));
+        float phi = focus_->phi_;
+        if(focus_->right_){
+            if(phi<r1){
+                navMarker_->setPosition(tan(phi)*windowH_/2+windowW_/2, 0);
+                navMarker_->setUV(0.5, 0.0, 1.0, 0.5);
+            }
+            else if(phi>3.14-r1){
+                navMarker_->setPosition(-tan(phi)*windowH_/2+windowW_/2, windowH_-16);
+                navMarker_->setUV(0.0, 0.5, 0.5, 1.0);
+            }
+            else {
+                navMarker_->setPosition(windowW_-16, -tan((3.14-2*phi)/2)*windowW_/2+windowH_/2);
+                navMarker_->setUV(0.5, 0.5, 1.0, 1.0);
+            }
+        }
+        else{
+            if(phi<r1) {
+                navMarker_->setPosition(-tan(phi)*windowH_/2+windowW_/2, 0);
+                navMarker_->setUV(0.5, 0.0, 1.0, 0.5);
+            }
+            else if(phi>3.14-r1) {
+                navMarker_->setPosition(tan(phi)*windowH_/2+windowW_/2, windowH_-16);
+                navMarker_->setUV(0.0, 0.5, 0.5, 1.0);
+            }
+            else {
+                navMarker_->setPosition(0, -tan((3.14-2*phi)/2)*windowW_/2+windowH_/2);
+                navMarker_->setUV(0.0, 0.0, 0.5, 0.5);
+            }
+        }
+    }
+
+    void RadarOverlayElement::addObject(Vector3 pos){
+        if(firstRadarObject_ == NULL){
+            firstRadarObject_ = new RadarObject(container_, pos);
+            lastRadarObject_ = firstRadarObject_;
+        }
+        else{
+            lastRadarObject_->next = new RadarObject(container_, pos);
+            lastRadarObject_ = lastRadarObject_->next;
+        }
+	}
 
 	void RadarOverlayElement::listObjects(){
 	    int i = 0;
-	    RadarObject* ro = HUD::getSingleton().getFirstRadarObject();
+	    RadarObject* ro = firstRadarObject_;
 	    COUT(3) << "List of RadarObjects:\n";
 	    // iterate through all Radar Objects
@@ -119,21 +181,52 @@
 	}
 
-	float RadarOverlayElement::calcRadius(Vector3 pos, Vector3 dir, Vector3 orth, RadarObject* obj){
-	    return(acos((dir.dotProduct(obj->pos_ - pos))/
-			((obj->pos_ - pos).length()*dir.length())));
-	}
-
-	float RadarOverlayElement::calcPhi(Vector3 pos, Vector3 dir, Vector3 orth, RadarObject* obj){
+	float RadarOverlayElement::getDist2Focus(){
+	    if(focus_ == NULL) return(0.0);
+	    return((focus_->pos_-shipPos_).length());
+	}
+
+	float RadarOverlayElement::calcRadius(RadarObject* obj){
+	    return(acos((currentDir_.dotProduct(obj->pos_ - shipPos_))/
+			((obj->pos_ - shipPos_).length()*currentDir_.length())));
+	}
+
+	float RadarOverlayElement::calcPhi(RadarObject* obj){
 	    // project difference vector on our plane...
-	    Vector3 proj = Plane(dir, pos).projectVector(obj->pos_ - pos);
+	    Ogre::Vector3 proj = plane.projectVector(obj->pos_ - shipPos_);
 	    // ...and find out the angle
-	    return(acos((orth.dotProduct(proj))/
-            (orth.length()*proj.length())));
-	}
-
-	bool RadarOverlayElement::calcRight(Vector3 pos, Vector3 dir, Vector3 orth, RadarObject* obj){
-	    if((dir.crossProduct(orth)).dotProduct(obj->pos_ - pos) > 0)
+	    return(acos((currentOrth_.dotProduct(proj))/
+            (currentOrth_.length()*proj.length())));
+	}
+
+	bool RadarOverlayElement::calcRight(RadarObject* obj){
+	    if((currentDir_.crossProduct(currentOrth_)).dotProduct(obj->pos_ - shipPos_) > 0)
         	return true;
         else return false;
 	}
+
+	/*static*/void RadarOverlayElement::cycleFocus(){
+	    if(RadarOverlayElement::instance_s == NULL) return;
+
+	    if(RadarOverlayElement::instance_s->focus_ == NULL){
+            RadarOverlayElement::instance_s->focus_ = RadarOverlayElement::instance_s->firstRadarObject_;
+	    }
+        else{
+            RadarOverlayElement::instance_s->focus_->panel_->setMaterialName("Orxonox/RedDot");
+            RadarOverlayElement::instance_s->focus_ = RadarOverlayElement::instance_s->focus_->next;
+        }
+
+        if(RadarOverlayElement::instance_s->focus_ == NULL){
+            RadarOverlayElement::instance_s->navMarker_->hide();
+        }
+        else{
+            RadarOverlayElement::instance_s->navMarker_->show();
+            RadarOverlayElement::instance_s->focus_->panel_->setMaterialName("Orxonox/WhiteDot");
+        }
+	}
 }
+
+/* my local clipboard...
+COUT(3) << "WWWWWWWWWWWWWWWWWWWWWWWWWWWW\n";
+COUT(3) << firstRadarObject_->radius_ << "  " << firstRadarObject_->phi_ << std::endl;
+COUT(3) << "WWWWWWWWWWWWWWWWWWWWWWWWWWWW\n";
+*/
Index: code/trunk/src/orxonox/hud/RadarOverlayElement.h
===================================================================
--- code/trunk/src/orxonox/hud/RadarOverlayElement.h	(revision 1401)
+++ code/trunk/src/orxonox/hud/RadarOverlayElement.h	(revision 1407)
@@ -29,8 +29,19 @@
 #define _RADAR_H__
 
+#include <string.h>
+#include <OgreOverlayManager.h>
+#include <OgreStringConverter.h>
+#include <OgreOverlayElement.h>
+#include <OgrePanelOverlayElement.h>
+#include <OgrePrerequisites.h>
+
 #include <util/Math.h>
-#include <OgrePrerequisites.h>
+#include <string.h>
+#include "core/Tickable.h"
+#include "core/ConsoleCommand.h"
+#include "objects/SpaceShip.h"
 #include "../OrxonoxPrereqs.h"
 #include "RadarObject.h"
+#include "GraphicsEngine.h"
 
 namespace orxonox
@@ -41,7 +52,10 @@
             Ogre::OverlayManager* om;               // our one and only overlay manager
             Ogre::OverlayContainer* container_;     // pointer to the container we're in
+            Vector3 initialDir_;	                // direction of nose
             Vector3 currentDir_;
+            Vector3 initialOrth_;                   // direction of normal
             Vector3 currentOrth_;
             Vector3 shipPos_;                       // position of ship
+            Ogre::Plane plane;                      // plane perpendicular to dir
 
             Ogre::Real leftRel_, topRel_, dimRel_;  // relative position/dimension
@@ -55,9 +69,19 @@
 			void resize();
             void update();
+            void updateNavMarker();
+            void addObject(Vector3 pos);
             void listObjects();
+            float getDist2Focus();
+            float calcRadius(RadarObject* obj);
+            float calcPhi(RadarObject* obj);
+            bool calcRight(RadarObject* obj);
 
-            static float calcRadius(Vector3 pos, Vector3 dir, Vector3 orth, RadarObject* obj);
-            static float calcPhi(Vector3 pos, Vector3 dir, Vector3 orth, RadarObject* obj);
-            static bool calcRight(Vector3 pos, Vector3 dir, Vector3 orth, RadarObject* obj);
+            Ogre::PanelOverlayElement* navMarker_;  // marker to help navigating
+			RadarObject* firstRadarObject_;         // start of linked list
+			RadarObject* lastRadarObject_;          // end of linked list
+			RadarObject* focus_;                    // object that is focussed
+
+            static RadarOverlayElement* instance_s;
+            static void cycleFocus();
 	};
 }
Index: code/trunk/src/orxonox/objects/Camera.h
===================================================================
--- code/trunk/src/orxonox/objects/Camera.h	(revision 1401)
+++ code/trunk/src/orxonox/objects/Camera.h	(revision 1407)
@@ -50,6 +50,4 @@
         void setTargetNode(Ogre::SceneNode* obj);
 
-        Ogre::Camera* cam_;
-
         void tick(float dt);
         void update();
@@ -65,4 +63,5 @@
         Ogre::SceneNode* cameraNode_;
         Ogre::Vector3 oldPos;
+        Ogre::Camera* cam_;
         bool bHasFocus_;
     };
Index: code/trunk/src/orxonox/objects/SpaceShip.cc
===================================================================
--- code/trunk/src/orxonox/objects/SpaceShip.cc	(revision 1401)
+++ code/trunk/src/orxonox/objects/SpaceShip.cc	(revision 1407)
@@ -69,5 +69,5 @@
       return NULL;
     }
-
+    
     SpaceShip::SpaceShip() :
       //testvector_(0,0,0),
@@ -112,8 +112,4 @@
         this->setConfigValues();
 
-        initialDir_ = Vector3(1.0, 0.0, 0.0);
-        currentDir_ = initialDir_;
-        initialOrth_ = Vector3(0.0, 0.0, 1.0);
-        currentOrth_ = initialOrth_;
 
         this->setRotationAxis(1, 0, 0);
@@ -241,8 +237,4 @@
         CameraHandler::getInstance()->requestFocus(cam_);
 
-    }
-
-    Camera* SpaceShip::getCamera(){
-        return cam_;
     }
 
@@ -399,10 +391,10 @@
     }
 
-    Vector3 SpaceShip::getDir() {
-        return currentDir_;
-    }
-
-    Vector3 SpaceShip::getOrth(){
-        return currentOrth_;
+    Vector3 SpaceShip::getSPosition() {
+	return SpaceShip::getLocalShip()->getPosition();
+    }
+
+    Quaternion SpaceShip::getSOrientation() {
+	return SpaceShip::getLocalShip()->getOrientation();
     }
 
@@ -411,7 +403,4 @@
     void SpaceShip::tick(float dt)
     {
-        currentDir_ = getOrientation()*initialDir_;
-		currentOrth_ = getOrientation()*initialOrth_;
-
         if (this->cam_)
             this->cam_->tick(dt);
@@ -433,7 +422,7 @@
         if (this->bLMousePressed_ && this->timeToReload_ <= 0)
         {
-
+          
             Projectile *p = new Projectile(this);
-
+            
             p->setBacksync(true);
             this->timeToReload_ = this->reloadTime_;
Index: code/trunk/src/orxonox/objects/SpaceShip.h
===================================================================
--- code/trunk/src/orxonox/objects/SpaceShip.h	(revision 1401)
+++ code/trunk/src/orxonox/objects/SpaceShip.h	(revision 1407)
@@ -44,7 +44,7 @@
     {
         public:
-
+          
             static SpaceShip *getLocalShip();
-
+            
             SpaceShip();
             ~SpaceShip();
@@ -64,7 +64,9 @@
             void setTransDamp(float value);
             void setRotDamp(float value);
+
             void getFocus();
-
             static SpaceShip* instance_s;
+            static Vector3 getSPosition();
+            static Quaternion getSOrientation();
             static std::string whereAmI();
             static void setMaxSpeedTest(float value)
@@ -78,7 +80,4 @@
 
             float getMaxSpeed();
-            Vector3 getDir();
-            Vector3 getOrth();
-            Camera* getCamera();
 
         private:
@@ -86,8 +85,4 @@
 
             Vector3 testvector_;
-            Vector3 initialDir_;
-            Vector3 currentDir_;
-            Vector3 initialOrth_;
-            Vector3 currentOrth_;
             bool bInvertYAxis_;
             bool setMouseEventCallback_;
