Index: /code/branches/shipSelection/data/gui/layouts/ShipSelectionMenu.layout
===================================================================
--- /code/branches/shipSelection/data/gui/layouts/ShipSelectionMenu.layout	(revision 9200)
+++ /code/branches/shipSelection/data/gui/layouts/ShipSelectionMenu.layout	(revision 9201)
@@ -17,12 +17,15 @@
             <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" />
             <Property Name="VertFormatting" Value="TopAligned" />
-            <Property Name="UnifiedAreaRect" Value="{{0.2,0},{0.15,0},{0.8,0},{0.7,0}}" />
+            <Property Name="UnifiedAreaRect" Value="{{0.2,0},{0.15,0},{0.8,0},{0.7,0}}" /> 
             <Window Type="MenuWidgets/TabControl" Name="orxonox/ShipSelectionTabControl" >
                 <Property Name="TabHeight" Value="{0,26.4388}" />
                 <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" />
                 <Property Name="TabPanePosition" Value="Top" />
-                <Property Name="UnifiedAreaRect" Value="{{0.05,0},{0.1,0},{0.95,0},{0.925,0}}" />
+		<Property Name="UnifiedAreaRect" Value="{{0.05,0},{0.1,0},{0.95,0},{0.925,0}}" />
+		
             </Window>	
-            <Window Type="MenuWidgets/StaticImage" Name="orxonox/ShipSelectionLevelImage" >
+            
+	    <!-- TODO: Ship Description and Image
+	    <Window Type="MenuWidgets/StaticImage" Name="orxonox/ShipSelectionShipImage" >
                 <Property Name="AlwaysOnTop" Value="True" />
                 <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" />
@@ -35,5 +38,5 @@
                 <Property Name="HorzScrollbar" Value="True" />
                 <Property Name="UnifiedAreaRect" Value="{{0.1,0},{0.725,0},{0.9,0},{0.875,0}}" />
-            </Window>
+            </Window>--> 
 		 
         </Window>
@@ -44,5 +47,6 @@
             <Event Name="Clicked" Function="ShipSelectionMenu.ShipSelectionStartButton_clicked"/>
         </Window>
-        <Window Type="MenuWidgets/Button" Name="orxonox/ShipSelectionConfigButton" >
+        <!-- TODO: set ship properties
+	<Window Type="MenuWidgets/Button" Name="orxonox/ShipSelectionConfigButton" >
             <Property Name="Text" Value="Configure" />
             <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" />
@@ -50,5 +54,5 @@
             <Property Name="Disabled" Value="True" />
             <Event Name="Clicked" Function="ShipSelectionMenu.ShipSelectionConfigButton_clicked"/>
-        </Window>
+        </Window> --> 
         <Window Type="MenuWidgets/Button" Name="orxonox/ShipSelectionBackButton" >
             <Property Name="Text" Value="Back" />
Index: /code/branches/shipSelection/data/gui/scripts/ShipSelectionMenu.lua
===================================================================
--- /code/branches/shipSelection/data/gui/scripts/ShipSelectionMenu.lua	(revision 9200)
+++ /code/branches/shipSelection/data/gui/scripts/ShipSelectionMenu.lua	(revision 9201)
@@ -6,45 +6,30 @@
 P.shipList = {}
 function P.onLoad()
-   --orxonox.execute("orxout user_warning Ships= " .. selectedlevel:hasShip("abcdef"))
    local dircmd = "ls ../levels/templates/ -l | awk '{print $9}' | grep \"spaceship\" | sed -e 's/\\.[a-zA-Z]*$//'" -- go to spaceships folder and generate a list of installed shipmodels.
    os.execute(dircmd .. " > ../levels/templates/.shipmodels") --saves output in a textfile
-   --[[ Program a Windows Version here:
+   --[[TODO: program a Windows Version / platform independent version here:
    if string.sub(package.config,1,1) == '\\' then
            -- Windows
            dircmd = "dir /b/s"
    end]]	
+   P.createFilterTab("All Ships")   
+end
 
+function P.createShipList() --generates list with tagged shipmodels
    P.shipList = {}
-   for line in io.lines("../levels/templates/.shipmodels") do  
+   for line in io.lines("../levels/templates/.shipmodels") do  --checks if shipmodel is included in level file
 	if selectedlevel:hasShip(string.lower(line)) then
 		P.shipList[#P.shipList+1] = string.lower(line)
 	end
-   end 
-   P.createFilterTab("Show All")
-
+   end  
 end
 
-function P.createShipList()
-       
-
-end
-
-
-
-function P.createFilterTab(name)
-
-    local tabName = "orxonox/ShipSelectionLevelTab"
-    -- create new tab window with desired name
-    local listbox = CEGUI.toListbox(winMgr:createWindow("MenuWidgets/Listbox", tabName))
-    listbox:setText(name)
-    listbox:setProperty("UnifiedMaxSize", "{{1,0},{1,0}}")
-    listbox:setProperty("UnifiedAreaRect", "{{0.05,0},{0.1,0},{0.5,0},{0.675,0}}")
-    -- fill listbox with items
+function P.update() --updates listbox with found models
+    P.createShipList()
     listbox:resetList()
-    orxonox.GUIManager:setItemTooltipsEnabledHelper(listbox, true)
-    local preselect = orxonox.LevelManager:getInstance():getDefaultLevel()
+    --orxonox.GUIManager:setItemTooltipsEnabledHelper(listbox, true)
     local tabIndexes = {}
     for k,v in pairs(P.shipList) do
-        -- only add level if it has desired tag
+        --TODO: only add ship if is in the right filter tab
         --if tag == nil or v:hasShip(tag) then
             local item = CEGUI.createListboxTextItem(v)
@@ -52,11 +37,21 @@
             listbox:addItem(item)
             table.insert(tabIndexes, k)
-            --[[if v:getXMLFilename() == preselect then
-                listbox:setItemSelectState(item, true)
-            end--]]
             --orxonox.GUIManager:setTooltipTextHelper(item, v:getDescription())
         --end
     end
     table.insert(P.activeTabIndexes, tabIndexes)
+end
+
+function P.createFilterTab(name) -- generates filter tab and list box, sets handler for selection changes
+    tabName = "orxonox/ShipSelectionLevelTab"
+    -- create new tab window with desired name
+    listbox = CEGUI.toListbox(winMgr:createWindow("MenuWidgets/Listbox", tabName)) 
+    listbox:setText(name)
+    listbox:setProperty("UnifiedMaxSize", "{{1,0},{1,0}}")
+    --[[TODO: smaller list if image and description is implemented. 
+	listbox:setProperty("UnifiedAreaRect", "{{0.05,0},{0.1,0},{0.5,0},{0.675,0}}") --]]	 
+    listbox:setProperty("UnifiedAreaRect", "{{0,0},{0,0},{1,0},{1,0}}")
+    -- fill listbox with items
+    P.update()
     -- listen to selection changes
     orxonox.GUIManager:subscribeEventHelper(listbox, "ItemSelectionChanged", P.name..".ShipSelectionSelectionChanged")
@@ -68,5 +63,5 @@
 end
 
-function P.ShipSelectionGetSelectedModel()
+function P.ShipSelectionGetSelectedModel() --returns selected model, if available.
     -- choose the active listbox
     local tabControl = CEGUI.toTabControl(winMgr:getWindow("orxonox/ShipSelectionTabControl"))
@@ -84,4 +79,5 @@
 
 function P.ShipSelectionSelectionChanged(e)
+    --[[ TODO: Get image and description from template file
     local levelImage = winMgr:getWindow("orxonox/ShipSelectionLevelImage")
     local levelDescription = winMgr:getWindow("orxonox/ShipSelectionLevelDescription")
@@ -104,21 +100,21 @@
         levelImage:setProperty("Image", nil)
         levelDescription:setText("")
-        configButton:setProperty("Disabled", "True")
     end
+   --]]
 end
 
 function P.ShipSelectionStartButton_clicked(e)
 
-    if selectedlevel ~= nil then
+    if (selectedlevel ~= nil and P.ShipSelectionGetSelectedModel() ~= nil)  then
 	selectedlevel:selectShip(P.ShipSelectionGetSelectedModel())
         orxonox.execute("startGame " .. "_temp.oxw")
         hideAllMenuSheets()
     else
-        orxonox.execute("keyESC")
+	orxonox.execute("orxout user_warning no ship model selected or no tagged shipmodel installed")
     end
 end
 
-function P.ShipSelectionConfigButton_clicked(e)
---[[
+--[[ TODO: function P.ShipSelectionConfigButton_clicked(e)
+
     local level = P.ShipSelectionGetSelectedModel()
     if level ~= nil then
@@ -126,9 +122,9 @@
         configMenu:loadConfig(level)
     end
+end
 --]]
-end
+
 
 function P.ShipSelectionBackButton_clicked(e)
-    --hideAllMenuSheets()
     orxonox.execute("keyESC")
 end 
Index: /code/branches/shipSelection/data/gui/scripts/SingleplayerMenu.lua
===================================================================
--- /code/branches/shipSelection/data/gui/scripts/SingleplayerMenu.lua	(revision 9200)
+++ /code/branches/shipSelection/data/gui/scripts/SingleplayerMenu.lua	(revision 9201)
@@ -147,5 +147,5 @@
         if selectedlevel:hasTag("shipselection") then
             local shipSelectionMenu = showMenuSheet("ShipSelectionMenu", true)
-            shipSelectionMenu:createShipList()
+            shipSelectionMenu:update()
         else
             orxonox.execute("startGame " .. selectedlevel:getXMLFilename())
Index: /code/branches/shipSelection/data/levels/tutorial.oxw
===================================================================
--- /code/branches/shipSelection/data/levels/tutorial.oxw	(revision 9200)
+++ /code/branches/shipSelection/data/levels/tutorial.oxw	(revision 9201)
@@ -4,5 +4,5 @@
  tags = "tutorial, shipselection"
  screenshot = "codingtutorial.png"
- startingships = "spaceshipassff, spaceshipghost, spaceshipspacecruiser,spaceshippirate"
+ startingships = "spaceshipassff, spaceshipghost, spaceshipspacecruiser"
 />
 
@@ -14,5 +14,4 @@
   include("templates/spaceshipSpacecruiser.oxt")
   include("templates/lodInformation.oxt")
-  include("templates/spaceshipPirate.oxt")
 ?>
 
@@ -27,8 +26,4 @@
    skybox       = "Orxonox/skypanoramagen1"
   >
-
-
-
-
 <Drone name="meineDrohne" primarythrust="80" auxilarythrust="10" rotationthrust="10" mass= "50" linearDamping = "0.9" angularDamping = "0.7">
   <attached>
Index: /code/branches/shipSelection/src/orxonox/ShipManager.cc
===================================================================
--- /code/branches/shipSelection/src/orxonox/ShipManager.cc	(revision 9200)
+++ /code/branches/shipSelection/src/orxonox/ShipManager.cc	(revision 9201)
@@ -21,13 +21,12 @@
  *
  *   Author:
- *      Fabian 'x3n' Landau
- *   Co-authors:
- *      Damian 'Mozork' Frick
- *
+ *      Matthias Hutter
+ *   
  */
 
 /**
-    @file LevelManager.cc
-    @brief Implementation of the LevelManager singleton.
+    @file ShipManager.cc
+    @brief Work-in Progress: Implementation of the ShipManager singleton.
+    	   Should make SpaceShip info available to lua handlers.
 */
 
