Index: branches/proxy/src/util/Makefile.am
===================================================================
--- branches/proxy/src/util/Makefile.am	(revision 9346)
+++ branches/proxy/src/util/Makefile.am	(revision 9347)
@@ -14,4 +14,6 @@
 			singleplayer_shootemup.cc \
 			\
+			\
+			\
 			mission_goal.cc\
 			kill_target.cc\
@@ -24,5 +26,7 @@
 			animation/animation_player.cc \
 			\
-			track/pilot_node.cc
+			track/pilot_node.cc \
+			\
+			network_stats_widget.cc
 
 #			track/track_manager.cc \
@@ -50,5 +54,8 @@
 			animation/t_animation.h \
 			\
-			track/pilot_node.h
+			track/pilot_node.h \
+			\
+			network_stats_widget.h
+
 
 #			track/track_manager.h \
Index: branches/proxy/src/util/game_rules.cc
===================================================================
--- branches/proxy/src/util/game_rules.cc	(revision 9346)
+++ branches/proxy/src/util/game_rules.cc	(revision 9347)
@@ -88,5 +88,5 @@
 void GameRules::registerKill(const Kill& kill)
 {
-  if ( !SharedNetworkData::getInstance()->isGameServer() )
+  if ( !SharedNetworkData::getInstance()->isMasterServer() )
     return;
 
Index: branches/proxy/src/util/multiplayer_team_deathmatch.cc
===================================================================
--- branches/proxy/src/util/multiplayer_team_deathmatch.cc	(revision 9346)
+++ branches/proxy/src/util/multiplayer_team_deathmatch.cc	(revision 9347)
@@ -204,5 +204,5 @@
   assignPlayable();
 
-  if ( !SharedNetworkData::getInstance()->isGameServer() )
+  if ( !SharedNetworkData::getInstance()->isMasterServer() )
     return;
 
@@ -214,5 +214,5 @@
     this->killList.erase( this->killList.begin() );
   }
-  
+
 
 
@@ -268,5 +268,5 @@
 void MultiplayerTeamDeathmatch::checkGameRules()
 {
-  if ( !SharedNetworkData::getInstance()->isGameServer() )
+  if ( !SharedNetworkData::getInstance()->isMasterServer() )
     return;
 
@@ -320,5 +320,5 @@
       return "maps/male_fiend.pcx";
   }
-  
+
   return "";
 }
@@ -330,5 +330,5 @@
     return 10.0f;
   }
-  
+
   return 1.0f;
 }
@@ -680,5 +680,5 @@
   char st[10];
   int i = 0;
-  
+
   i = 2;
   for ( TeamScoreList::const_iterator it = scoreList[0].begin(); it != scoreList[0].end(); it++ )
@@ -719,13 +719,13 @@
     return;
   }
-  
+
   int killerUserId = killer->getOwner();
   int victimUserId = victim->getOwner();
-  
+
   PRINTF(0)("%d %d %x %x %s %s\n", killerUserId, victimUserId, killer, victim, killer->getClassName(), victim->getClassName());
 
   PlayerStats & victimStats = *PlayerStats::getStats( victimUserId );
   PlayerStats & killerStats = *PlayerStats::getStats( killerUserId );
-  
+
   if ( killerStats.getPlayable() != killer || victimStats.getPlayable() != victim )
   {
Index: branches/proxy/src/util/network_stats_widget.cc
===================================================================
--- branches/proxy/src/util/network_stats_widget.cc	(revision 9347)
+++ branches/proxy/src/util/network_stats_widget.cc	(revision 9347)
@@ -0,0 +1,90 @@
+/*
+   orxonox - the future of 3D-vertical-scrollers
+
+   Copyright (C) 2004 orx
+
+   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, or (at your option)
+   any later version.
+
+   ### File Specific:
+   main-programmer: Benjamin Grauer
+   co-programmer: ...
+*/
+
+//#define DEBUG_SPECIAL_MODULE DEBUG_MODULE_
+
+#include "network_stats_widget.h"
+
+namespace OrxGui
+{
+  /**
+   * @brief standard constructor
+   */
+  NetworkStatsWidget::NetworkStatsWidget ()
+  {
+    //   this->setClassID(CL_PROTO_ID, "NetworkStatsWidget");
+
+    this->_bar.setSize2D(100, 30);
+    this->pack(&this->_valueText);
+    this->_bar.setParent2D(&this->_valueText);
+
+    this->_valueText.setChangedTextColor(Color::white);
+
+    //this->setBackgroundTexture("maps/gui_element_background_2.png");
+    this->setBackgroundColor(Color(.5,.5,.5,1));
+
+    //this->_name.setBackgroundTexture(Texture());
+    //this->_valueText.setBackgroundTexture("maps/gui_element_background_2.png");
+    this->_bar.setBackgroundTexture(Texture());
+    this->_bar.setBackgroundColor(Color(0,0,0,0));
+    this->_bar.setForegroundTexture("maps/gui_element_background_faded.png");
+    this->_bar.setForegroundColor(Color(.5, .5, .5, 1));
+    this->_bar.setChangedValueColor(Color::black);
+  }
+
+
+  /**
+   * @brief standard deconstructor
+   */
+  NetworkStatsWidget::~NetworkStatsWidget ()
+  {
+  }
+
+
+  void NetworkStatsWidget::setMaximum(float max)
+  {
+    this->_bar.setMaximum(max);
+  }
+
+  void NetworkStatsWidget::setValue(float value)
+  {
+    MultiType val(value);
+    val.setType(MT_INT);
+
+
+    this->_bar.setValue(value);
+    this->_bar.setForegroundColor(Color::slerpHSVColor(Color::red, Color::green, value/this->_bar.maximum()));
+    this->_bar.setFrontColor(Color(1,1,1,1), true);
+    this->_valueText.setText(val.getString());
+  }
+
+  void NetworkStatsWidget::resize()
+  {
+    GLGuiBox::resize();
+  }
+
+
+  void NetworkStatsWidget::showing()
+  {
+    this->_valueText.show();
+    this->_bar.show();
+  }
+
+  void NetworkStatsWidget::hiding()
+  {
+    this->_valueText.hide();
+    this->_bar.hide();
+  }
+}
Index: branches/proxy/src/util/network_stats_widget.h
===================================================================
--- branches/proxy/src/util/network_stats_widget.h	(revision 9347)
+++ branches/proxy/src/util/network_stats_widget.h	(revision 9347)
@@ -0,0 +1,59 @@
+/*!
+ * @file network_stats_widget.h
+ * @brief Definition of an EnergyWidget, that displays a bar and a Text
+*/
+
+#ifndef _NETWORK_STATS_WIDGET_H
+#define _NETWORK_STATS_WIDGET_H
+
+#include "glgui_box.h"
+#include "glgui_bar.h"
+#include "glgui_text.h"
+
+#include "network/ip.h"
+
+
+namespace OrxGui
+{
+
+  //! A class to display network Statistics.
+  class NetworkStatsWidget : public GLGuiBox
+  {
+
+  public:
+    NetworkStatsWidget();
+    virtual ~NetworkStatsWidget();
+
+    void setUpstream(unsigned int upstream);
+    void setDownstream(unsigned int upstream);
+    void setIP(const IP& ip);
+
+
+
+    //void rebuildConnectedHosts(std::vector<hosts> hosts);
+
+    void setMaximum(float max);
+    void setValue(float value);
+
+  protected:
+    virtual void resize();
+    virtual void showing();
+    virtual void hiding();
+
+  private:
+    IP                     _ip;
+    GLGuiText              _ipText;
+
+    GLGuiText              _upstreamText;
+    GLGuiText              _downstreamText;
+
+    std::vector<GLGuiText> _connectedHosts;
+
+    GLGuiText              _serverIP;
+
+
+    GLGuiText              _valueText;
+    GLGuiBar               _bar;
+  };
+}
+#endif /* _NETWORK_STATS_WIDGET_H */
Index: branches/proxy/src/util/signal_handler.cc
===================================================================
--- branches/proxy/src/util/signal_handler.cc	(revision 9346)
+++ branches/proxy/src/util/signal_handler.cc	(revision 9347)
@@ -27,7 +27,16 @@
 }
 
-void SignalHandler::doCatch( std::string appName )
+/**
+ * register signal handlers for SIGSEGV and SIGABRT
+ * @param appName path to executable eg argv[0]
+ * @param fileName filename to append backtrace to
+ */
+void SignalHandler::doCatch( const std::string & appName, const std::string & fileName )
 {
   this->appName = appName;
+  this->fileName = fileName;
+  
+  // make sure doCatch is only called once without calling dontCatch
+  assert( sigRecList.size() == 0 );
 
   catchSignal( SIGSEGV );
@@ -35,4 +44,7 @@
 }
 
+/**
+ * restore previous signal handlers
+ */
 void SignalHandler::dontCatch()
 {
@@ -45,4 +57,8 @@
 }
 
+/**
+ * catch signal sig
+ * @param sig signal to catch
+ */
 void SignalHandler::catchSignal( int sig )
 {
@@ -58,4 +74,8 @@
 }
 
+/**
+ * sigHandler is called when receiving signals
+ * @param sig 
+ */
 void SignalHandler::sigHandler( int sig )
 {
@@ -167,4 +187,6 @@
         )
           charsFound++;
+    else
+      charsFound = 0;
 
     if ( charsFound == 6 )
@@ -183,5 +205,5 @@
   write( sigPipe[1], &someData, sizeof(someData) );
 
-  write( gdbIn[1], "bt\nq\n", 5 );
+  write( gdbIn[1], "bt\nk\nq\n", 7 );
 
   
@@ -202,4 +224,6 @@
         )
           charsFound++;
+    else
+      charsFound = 0;
 
     if ( charsFound == 6 )
@@ -210,5 +234,5 @@
     }
 
-    if ( promptFound == 2 )
+    if ( promptFound == 3 )
     {
       break;
@@ -240,9 +264,9 @@
   bt.insert(0, timeString);
   
-  FILE * f = fopen( GDB_BT_FILE, "a" );
+  FILE * f = fopen( getInstance()->fileName.c_str(), "a" );
 
   if ( !f )
   {
-    perror("could not append to " GDB_BT_FILE);
+    perror( ( std::string( "could not append to " ) + getInstance()->fileName ).c_str() );
     exit(EXIT_FAILURE);
   }
@@ -250,5 +274,5 @@
   if ( fwrite( bt.c_str(), 1, bt.length(), f ) != bt.length() )
   {
-    printf("could not write %d byte to " GDB_BT_FILE, bt.length());
+    printf( ( std::string("could not write %d byte to ") + getInstance()->fileName ).c_str(), bt.length());
     exit(EXIT_FAILURE);
   }
Index: branches/proxy/src/util/signal_handler.h
===================================================================
--- branches/proxy/src/util/signal_handler.h	(revision 9346)
+++ branches/proxy/src/util/signal_handler.h	(revision 9347)
@@ -9,7 +9,4 @@
 #include <list>
 #include <string>
-
-
-#define GDB_BT_FILE "orxonox.backtrace"
 
 typedef int (*SignalCallback)( void * someData );
@@ -44,5 +41,5 @@
     void registerCallback( SignalCallback cb, void * someData );
 
-    void doCatch( std::string appName );
+    void doCatch( const std::string & appName, const std::string & fileName );
     void dontCatch();
 
@@ -58,4 +55,5 @@
 
     std::string appName;
+    std::string fileName;
 };
 
