Index: orxonox/trunk/ToDo
===================================================================
--- orxonox/trunk/ToDo	(revision 1853)
+++ orxonox/trunk/ToDo	(revision 1853)
@@ -0,0 +1,7 @@
+
+
+./configure
+-----------
+- if dri is not supported glxinfo returns "Xlib:  extension "XFree86-DRI" missing on display ":0.0"." -> this message should not be shown on the console!
+
+
Index: orxonox/trunk/configure
===================================================================
--- orxonox/trunk/configure	(revision 1853)
+++ orxonox/trunk/configure	(revision 1853)
@@ -0,0 +1,133 @@
+## Conact Address
+###############################
+SUPPORT_ADDRESS="orxonox-dev@mail.datacore.ch"
+
+## Configure Version
+###############################
+CONFIG_VERS="0.1alpha - orxonox is still in development - please send bug-reports, requests, ideas to $SUPPORT_ADDRESS"
+
+## Defaults
+################################
+ENABLE_GLUT="yes"
+ENABLE_GTK="yes"
+VERBOSE="no"
+
+
+## Where to look for stuff
+################################
+std_bin_dirs="/usr/bin /usr/X11R6/bin /usr/local/bin $HOME/bin"
+std_include_dirs="/usr/include/GL"
+std_lib_dirs="/usr/lib /usr/X11R6/lib /usr/local/lib $HOME/lib"
+
+## The functions enter the room.
+## In order to understand this 
+## file you have to understand 
+## scripts/configure_functions
+################################
+source ./scripts/configure_functions
+
+## print instruction
+################################
+print_newline
+print_separator
+print_message "This scripts determines all options"
+print_message "needed to build Orxonox."
+print_message "This is no autoconf configure script"
+print_separator
+
+## Check command line for options
+#################################
+check_command_line_options $@
+
+## Check linux distribution
+#############################################################
+print_topic "Checking OS"
+OS=`uname -a | awk '{print $1}'`
+if [ $OS == "Linux" ]; then
+	print_ack
+	print_info "Running on a $OS system"
+else
+	print_nack
+	print_error "Running on a $OS system - probably not supported"
+	print_error "Orxonox is designed to run on Linux systems"
+	print_error "please do not stop here an try to port the game to"
+	print_error "your system. Send your patch to $SUPPORT_ADDRESS"
+	print_exit
+	exit 1
+fi
+
+## Check GLUT installation
+##############################################################
+if [ $ENABLE_GLUT = "yes" ]; then
+	print_topic "Verifing GLUT install"
+	if check_for_GLUT; then
+		print_ack
+		print_info "GLUT found at: $GLUT_DIR"
+	else
+		print_nack
+		print_error "GLUT not found!"
+		print_exit
+		exit 1
+	fi	
+fi
+
+
+## Check Direct Rendering Support
+##############################################################
+if [ $ENABLE_GLUT = "yes" ]; then
+	print_topic "Checking Direct Rendering Support (dri)"
+	if check_for_glxinfo; then
+		if check_for_dri; then
+			print_ack
+			print_info "DRI is working on your system"
+		else
+			print_nack
+			print_warning "DRI not supported, you probably want to configure it"
+			print_warning "or you try OpenGL emulation with Mesa"
+		fi
+	else
+		print_nack
+		print_error "no glxinfo detected - check your xfree install"
+	fi
+fi
+
+
+## Check GtK Installation
+##############################################################
+if [ $ENABLE_GTK == "yes" ]; then
+	print_topic "Checking for GtK Support"
+	if check_for_gtk_config; then
+		print_ack
+		print_info "gtk-config found: $GTK_CONFIG"
+	else
+		print_nack
+		print_warning "You won't be able to use our gtk config"
+		print_warning "menu. This ain't gonna hurt..."
+	fi
+fi
+
+## Write Makefile
+###############################################################
+print_topic "Writing out Makefile"
+if [ $ENABLE_GLUT == "yes" ]; then
+	if [ $ENABLE_GLUT == "yes" ]; then
+		cp scripts/Makefile.all Makefile > /dev/null
+	else
+		cp scripts/Makefile.GLUT Makefile > /dev/null
+	fi
+fi
+if [ -f Makefile ]; then
+	print_ack
+else
+	print_nack
+	print_error "This error should not occure, please send"
+	print_error "a full bug-report to $SUPPORT_ADDRESS"
+	exit 1
+fi
+print_separator
+print_message "Configure finished"
+print_newline
+print_message "Now, type 'make' to build Orxonox"
+print_newline
+
+### EOF
Index: orxonox/trunk/core/Makefile
===================================================================
--- orxonox/trunk/core/Makefile	(revision 1850)
+++ orxonox/trunk/core/Makefile	(revision 1853)
@@ -36,10 +36,13 @@
 OBJECTS = \
 	orxonox.o \
-	data_tank.o
+	data_tank.o \
+	npc.o \
+	player.o \
+	world.o 
 
 TARGET = orxonox
 
 .SUFFIXES:
-.SUFFIXES: .cc
+.SUFFIXES: .cc .o
 
 #.cc: $(LIB_DEP)
@@ -47,5 +50,6 @@
 
 .cc.o:
-	$(CXX) -c $(CFLAGS) -I$(INCDIR) -o $@ $<
+	@ echo "$@ wird kompiliert..."
+	@ $(CXX) -c $(CFLAGS) -I$(INCDIR) -o $@ $<
 
 
@@ -54,6 +58,7 @@
 all: $(TARGET)
 
-$(TARGET): $(LIB_DEP) $(OBJECTS)
-	$(CXX) $(LIBS) -o $(TARGET) $(OBJECTS)
+$(TARGET): $(OBJECTS)
+	@ echo "orxonox wird gelinkt..."
+	@ $(CXX) $(LIBS) -o $(TARGET) $(OBJECTS)
 
 
@@ -68,14 +73,14 @@
 	
 clean:
-	rm -rf *.o *~ $(PROGS)
+	rm -rf *.o *~
 
 
 ####compile
 
-orxonox.o: orxonox.cc \
-		orxonox.h \
+#orxonox.o: orxonox.cc \
+#		orxonox.h
 
-data_tank.o: data_tank.cc \
-		data_tank.h	
+#data_tank.o: data_tank.cc \
+#		data_tank.h	
 	
 #EOF
Index: orxonox/trunk/core/Makefile.simple
===================================================================
--- orxonox/trunk/core/Makefile.simple	(revision 1850)
+++ 	(revision )
@@ -1,67 +1,0 @@
-
-CPLUSPLUS = g++
-APP_LIB_DEPS = -lglut -lGLU -lGL -lm -L/usr/X11R6/lib -lXt -lX11
-GL_LIB = libGL.so
-GLU_LIB = libGLU.so
-GLUT_LIB = libglut.so
-GLW_LIB = libGLw.so
-OSMESA_LIB = libOSMesa.so
-
-CFLAGS = -O3 -pedantic -fPIC -ffast-math -I/usr/X11R6/include
-CXXFLAGS = -fPIC -O3
-GLUT_CFLAGS = -fexceptions
-
-TOP = ../..
-INCDIR = /usr/Mesa-6.0.1/include
-LIBDIR = /usr/Mesa-6.0.1/lib
-
-LIBS = -L$(LIBDIR) $(APP_LIB_DEPS)
-
-OSMESA_LIBS = -L$(LIBDIR) -lglut -lOSMesa -lGLU -lGL $(APP_LIB_DEPS)
-
-LIB_DEP = $(LIBDIR)/$(GL_LIB) $(LIBDIR)/$(GLU_LIB) $(LIBDIR)/$(GLUT_LIB)
-
-PROGS = \
-	orxonox \
-
-HEADERS = \
-	orxonox.h \
-	data_core.h
-	
-SOURCES = \
-	orxonox.cc \
-	data_core.cc
-
-OBJECTS = \
-	orxonox.o \
-	data_core.o
-
-TARGET = orxonox
-
-.SUFFIXES:
-.SUFFIXES: .cc
-
-.cc: $(LIB_DEP)
-	$(CPLUSPLUS) -I$(INCDIR) $(CFLAGS) $< $(LIBS) -o $@
-
-default: $(PROGS)
-
-help:
-	@echo "Cleaning targets:"
-	@echo "  clean		- remove most generated files"
-	@echo ""
-	@echo "Generic targets:"
-	@echo "  all		- Build all targets"
-	@echo ""
-	@echo "For further info see the README file"
-	
-clean:
-	rm -rf *.o *~ $(PROGS)
-
-
-orxonox.o: orxonox.cc \
-		orxonox.h \
-		data_core.cc \
-		data_core.h
-	
-#EOF
Index: orxonox/trunk/core/npc.cc
===================================================================
--- orxonox/trunk/core/npc.cc	(revision 1853)
+++ orxonox/trunk/core/npc.cc	(revision 1853)
@@ -0,0 +1,25 @@
+
+
+/* 
+   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.
+*/
+
+
+#include "npc.h"
+
+
+
+NPC::NPC () {}
+
+
+
+NPC::~NPC () {}
+
+
Index: orxonox/trunk/core/npc.h
===================================================================
--- orxonox/trunk/core/npc.h	(revision 1853)
+++ orxonox/trunk/core/npc.h	(revision 1853)
@@ -0,0 +1,14 @@
+
+#ifndef NPC_H
+#define NPC_H
+
+
+class NPC {
+
+ public:
+  NPC ();
+  ~NPC ();
+
+};
+
+#endif
Index: orxonox/trunk/core/orxonox.cc
===================================================================
--- orxonox/trunk/core/orxonox.cc	(revision 1850)
+++ orxonox/trunk/core/orxonox.cc	(revision 1853)
@@ -27,4 +27,5 @@
 /* class definition header */
 #include "orxonox.h"
+#include "data_tank.h"
 
 /* standard headers */
Index: orxonox/trunk/core/player.cc
===================================================================
--- orxonox/trunk/core/player.cc	(revision 1853)
+++ orxonox/trunk/core/player.cc	(revision 1853)
@@ -0,0 +1,25 @@
+
+
+/* 
+   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.
+*/
+
+
+#include "player.h"
+
+
+
+Player::Player () {}
+
+
+
+Player::~Player () {}
+
+
Index: orxonox/trunk/core/player.h
===================================================================
--- orxonox/trunk/core/player.h	(revision 1853)
+++ orxonox/trunk/core/player.h	(revision 1853)
@@ -0,0 +1,14 @@
+
+#ifndef PLAYER_H
+#define PLAYER_H
+
+
+class Player {
+
+ public:
+  Player ();
+  ~Player ();
+
+};
+
+#endif
Index: orxonox/trunk/core/proto_class.cc
===================================================================
--- orxonox/trunk/core/proto_class.cc	(revision 1853)
+++ orxonox/trunk/core/proto_class.cc	(revision 1853)
@@ -0,0 +1,25 @@
+
+
+/* 
+   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.
+*/
+
+
+#include "proto_class.h"
+
+
+
+ProtoClass::ProtoClass () {}
+
+
+
+ProtoClass::~ProtoClass () {}
+
+
Index: orxonox/trunk/core/proto_class.h
===================================================================
--- orxonox/trunk/core/proto_class.h	(revision 1853)
+++ orxonox/trunk/core/proto_class.h	(revision 1853)
@@ -0,0 +1,14 @@
+
+#ifndef PROTO_CLASS_H
+#define PROTO_CLASS_H
+
+
+class ProtoClass {
+
+ private:
+  ProtoClass ();
+  ~ProtoClass ();
+
+};
+
+#endif
Index: orxonox/trunk/core/world.cc
===================================================================
--- orxonox/trunk/core/world.cc	(revision 1853)
+++ orxonox/trunk/core/world.cc	(revision 1853)
@@ -0,0 +1,28 @@
+
+
+/* 
+   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.
+*/
+
+
+#include "world.h"
+
+
+
+
+World::World () {
+  
+}
+
+
+
+World::~World () {}
+
+
Index: orxonox/trunk/core/world.h
===================================================================
--- orxonox/trunk/core/world.h	(revision 1853)
+++ orxonox/trunk/core/world.h	(revision 1853)
@@ -0,0 +1,29 @@
+
+#include "npc.h"
+#include "player.h"
+
+#ifndef WORLD_H
+#define WORLD_H
+
+
+class World {
+
+ public:
+  World ();
+  ~World ();
+
+  Player *player1;
+
+  struct player_list {
+    player_list* next_player;
+    Player* player;
+  };
+
+  struct npc_list {
+    npc_list* next_npc;
+    NPC* npc;
+  };
+
+};
+
+#endif
Index: orxonox/trunk/doc/CODING-STANDARDS
===================================================================
--- orxonox/trunk/doc/CODING-STANDARDS	(revision 1853)
+++ orxonox/trunk/doc/CODING-STANDARDS	(revision 1853)
@@ -0,0 +1,25 @@
+We use the GNU conding convention (which is also used in xemacs etc.):
+
+-- Put a space after every comma.
+-- Put a space before the parenthesis that begins a function call,
+   macro call, function declaration or definition, or control
+   statement (if, while, switch, for). (DO NOT do this for macro
+   definitions; this is invalid preprocessor syntax.)
+-- The brace that begins a control statement (if, while, for, switch,
+   do) or a function definition should go on a line by itself.
+-- In function definitions, put the return type and all other
+   qualifiers on a line before the function name.  Thus, the function
+   name is always at the beginning of a line.
+-- Indentation level is two spaces.  (However, the first and following
+   statements of a while/for/if/etc. block are indented four spaces
+   from the while/for/if keyword.  The opening and closing braces are
+   indented two spaces.)
+-- Variable and function names should be all lowercase, with underscores
+   separating words, except for a prefixing tag, which may be in
+   uppercase.  Do not use the mixed-case convention (e.g.
+   SetVariableToValue ()) and *especially* do not use Microsoft
+   Hungarian notation (char **rgszRedundantTag).
+-- preprocessor and enum constants should be all uppercase, and should
+   be prefixed with a tag that groups related constants together.
+
+
Index: orxonox/trunk/doc/CREDITS
===================================================================
--- orxonox/trunk/doc/CREDITS	(revision 1850)
+++ orxonox/trunk/doc/CREDITS	(revision 1853)
@@ -1,9 +1,9 @@
 
 
-This is the thanks to File:
+The Orxonox Team Thanks To 
+--------------------------
 
-The Orxonox team thanks to 
-amir@datacore.ch  for giving us access to subversion and mailling lists
+amir@datacore.ch	for giving us access to subversion and mailing lists
+Luke Grey		for making the orxonox sound
 
-bensch's brother for making the orxonox sound!
 
Index: orxonox/trunk/doc/program_examples/openGL/Makefile
===================================================================
--- orxonox/trunk/doc/program_examples/openGL/Makefile	(revision 1853)
+++ orxonox/trunk/doc/program_examples/openGL/Makefile	(revision 1853)
@@ -0,0 +1,48 @@
+
+CPLUSPLUS = g++
+APP_LIB_DEPS = -lglut -lGLU -lGL -lm -L/usr/X11R6/lib -lXt -lX11
+GL_LIB = libGL.so
+GLU_LIB = libGLU.so
+GLUT_LIB = libglut.so
+GLW_LIB = libGLw.so
+OSMESA_LIB = libOSMesa.so
+
+CFLAGS = -O3 -ansi -pedantic -fPIC -ffast-math -I/usr/X11R6/include
+CXXFLAGS = -fPIC -O3
+GLUT_CFLAGS = -fexceptions
+
+TOP = ../..
+INCDIR = /usr/Mesa-6.0.1/include
+LIBDIR = /usr/Mesa-6.0.1/lib
+
+LIBS = -L$(LIBDIR) $(APP_LIB_DEPS)
+
+OSMESA_LIBS = -L$(LIBDIR) -lglut -lOSMesa -lGLU -lGL $(APP_LIB_DEPS)
+
+LIB_DEP = $(LIBDIR)/$(GL_LIB) $(LIBDIR)/$(GLU_LIB) $(LIBDIR)/$(GLUT_LIB)
+
+PROGS = \
+	cube \
+	gl_test \
+	double
+
+.SUFFIXES:
+.SUFFIXES: .c
+
+.c: $(LIB_DEP)
+	$(CPLUSPLUS) -I$(INCDIR) $(CFLAGS) $< $(LIBS) -o $@
+
+default: $(PROGS)
+
+help:
+	@echo "Cleaning targets:"
+	@echo "  clean		- remove most generated files"
+	@echo ""
+	@echo "Generic targets:"
+	@echo "  all		- Build all targets"
+	@echo ""
+	@echo "For further info see the README file"
+	
+clean:
+	rm -rf *.o *~ $(PROGS)
+
Index: orxonox/trunk/doc/program_examples/openGL/cube.c
===================================================================
--- orxonox/trunk/doc/program_examples/openGL/cube.c	(revision 1850)
+++ orxonox/trunk/doc/program_examples/openGL/cube.c	(revision 1853)
@@ -5,5 +5,5 @@
 #include <stdio.h>
 #include <stdlib.h>
-
+#include <math.h>
 
 static float alpha = 0;
Index: orxonox/trunk/scripts/Makefile.GLUT
===================================================================
--- orxonox/trunk/scripts/Makefile.GLUT	(revision 1853)
+++ orxonox/trunk/scripts/Makefile.GLUT	(revision 1853)
@@ -0,0 +1,23 @@
+
+ORXONOX_DIRS = ./core
+
+all: orxonox
+
+orxonox: $(ORXONOX_DIRS) finish
+
+$(ORXONOX_DIRS): FORCE
+	cd $@; $(MAKE)
+	
+finish:
+	@echo ""
+	@mv -vf ./core/orxonox ./bin
+	@echo ""
+	@echo "now cd to ./bin and run orxonox"
+	@echo ""
+
+clean:
+	for i in $(ORXONOX_DIRS); do ( cd $$i ; $(MAKE) clean ) ; done
+	-rm -f ./bin/*
+	-rm -f *~
+	
+FORCE:
Index: orxonox/trunk/scripts/Makefile.all
===================================================================
--- orxonox/trunk/scripts/Makefile.all	(revision 1853)
+++ orxonox/trunk/scripts/Makefile.all	(revision 1853)
@@ -0,0 +1,23 @@
+
+ORXONOX_DIRS = ./core
+
+all: orxonox
+
+orxonox: $(ORXONOX_DIRS) finish
+
+$(ORXONOX_DIRS): FORCE
+	cd $@; $(MAKE)
+	
+finish:
+	@echo ""
+	@mv -vf ./core/orxonox ./bin
+	@echo ""
+	@echo "now cd to ./bin and run orxonox"
+	@echo ""
+
+clean:
+	for i in $(ORXONOX_DIRS); do ( cd $$i ; $(MAKE) clean ) ; done
+	-rm -f ./bin/*
+	-rm -f *~
+	
+FORCE:
Index: orxonox/trunk/scripts/configure_functions
===================================================================
--- orxonox/trunk/scripts/configure_functions	(revision 1853)
+++ orxonox/trunk/scripts/configure_functions	(revision 1853)
@@ -0,0 +1,173 @@
+
+function print_message
+{
+	echo "   " $@
+}
+
+function print_topic
+{
+	echo -n "(II) " $@
+}
+
+function print_ack
+{
+	echo "...ok"
+}
+
+function print_nack
+{
+	echo "...failed"
+}
+
+function print_error
+{
+	echo "(EE) " $@
+}
+
+function print_warning
+{
+	echo "(WW) " $@
+}
+
+function print_info
+{
+	if [ $VERBOSE == "yes" ]; then
+		echo "         " $@
+	fi
+}
+
+function print_exit
+{
+	echo " => fatal error occured - see (WW) and (EE) tags for more info"
+	echo " => for support send a bugreport with this output to"
+	echo "            $SUPPORT_ADDRESS"
+	echo " => exiting gracefuly..."
+}
+
+function print_separator
+{
+	echo "--------------------------------------------------------------"
+}
+
+function print_small_separator
+{
+	echo "      ---"
+}
+
+function print_newline
+{
+	echo ""
+}
+
+
+#### Command Line Options
+
+function check_command_line_options
+{
+	local arg
+	for arg in $@; do
+		case $arg in
+			--enable-glut )
+				ENABLE_GLUT="yes"
+				;;
+			--disable-glut )
+				ENABLE_GLUT="no"
+				;;
+			--enable-gtk )
+				ENABLE_GTK="yes"
+				;;
+			--disable-gtk )
+				ENABLE_GTL="no"
+				;;
+			-v )
+				VERBOSE="yes"
+				;;
+			--verbose )
+				VERBOSE="yes"
+				;;
+			*)
+				print_command_line_options
+				exit 1
+				;;
+		esac
+	done
+}
+
+function print_command_line_options
+{
+	echo ""
+	echo "USAGE:"
+	echo "--enable-<option>     enable option"
+	echo "--disable-<option>    disable option"
+	echo "-v  --verbose         verbose output"
+	echo ""
+	echo "OPTIONS:"
+	echo "glut                  enable use of glut library (default: $ENABLE_GLUT)"
+	echo "gtk                   enable use of gtl libraty (default: $ENABLE_GTK)"
+	echo ""
+	echo "EXAMPLE:"
+	echo "./configure --enable-gtk"
+	echo ""
+}
+
+
+#### Check OS
+function get_OS
+{
+	#if [ uname -a | awk '{print $1}' ==  "Linux" ]; then
+	#	return 0
+	#fi
+	#return 1
+	#name -a | awk '{if( $1 == "Linux" ) print "1"; else print "0"}'
+	echo "not supported function"
+}
+
+
+#### Check GLUT 
+function check_for_GLUT
+{
+	local directory
+	for directory in $std_include_dirs; do
+		if [ -f $directory/glut.h ]; then
+			GLUT_DIR=$directory/glut.h
+			return 0
+		fi
+	done
+	return 1
+}
+
+
+### Check for Direct Rendering Support
+function check_for_glxinfo
+{
+	local directory
+	for directory in $std_bin_dirs; do
+		if [ -f $directory/glxinfo ]; then
+			return 0
+		fi
+	done
+	return 1
+}
+
+function check_for_dri
+{
+	DRI_SUPPORT=`glxinfo | grep "direct rendering:" | awk '{print $3}'`
+	if [ $DRI_SUPPORT == "No" ]; then
+		return 1
+	fi
+	return 0
+}
+
+### GtK Check
+function check_for_gtk_config
+{
+	local directory
+	for directory in $std_bin_dirs; do
+		if [ -f $directory/gtk-config ]; then
+			GTK_CONFIG=$directory/gtk-config
+			return 0
+		fi
+	done
+	return 1
+}
+
