[Orxonox-commit 7140] r11757 - in code/branches/Presentation_HS17_merge: data/levels src/modules/flappyorx

landauf at orxonox.net landauf at orxonox.net
Sat Feb 17 23:06:08 CET 2018


Author: landauf
Date: 2018-02-17 23:06:06 +0100 (Sat, 17 Feb 2018)
New Revision: 11757

Removed:
   code/branches/Presentation_HS17_merge/src/modules/flappyorx/FlappyOrxCenterPoint.cc
   code/branches/Presentation_HS17_merge/src/modules/flappyorx/FlappyOrxCenterPoint.h
Modified:
   code/branches/Presentation_HS17_merge/data/levels/FlappyOrx.oxw
   code/branches/Presentation_HS17_merge/src/modules/flappyorx/CMakeLists.txt
   code/branches/Presentation_HS17_merge/src/modules/flappyorx/FlappyOrx.cc
   code/branches/Presentation_HS17_merge/src/modules/flappyorx/FlappyOrx.h
   code/branches/Presentation_HS17_merge/src/modules/flappyorx/FlappyOrxPrereqs.h
Log:
[FlappyOrx_HS17] removed FlappyOrxCenterPoint, it doesn't seem to be neede

Modified: code/branches/Presentation_HS17_merge/data/levels/FlappyOrx.oxw
===================================================================
--- code/branches/Presentation_HS17_merge/data/levels/FlappyOrx.oxw	2018-02-17 21:54:16 UTC (rev 11756)
+++ code/branches/Presentation_HS17_merge/data/levels/FlappyOrx.oxw	2018-02-17 22:06:06 UTC (rev 11757)
@@ -34,10 +34,6 @@
  <Light type=directional position="11000, 11000, -7000" lookat="0, 0, 0" diffuse="1, 1, 1, 1" specular="1.0, 0.9, 0.9, 1.0" />
     <SpawnPoint team=0 position="0,0,0" lookat="0,0,0" spawnclass=FlappyOrxShip pawndesign=spaceshipFlappyOrx />
   
-    <FlappyOrxCenterPoint name=flappyorxcenter />
-    
-    
-
     <?lua
       for i = 1, 5, 1 do
         for j = 3, 12,3 do

Modified: code/branches/Presentation_HS17_merge/src/modules/flappyorx/CMakeLists.txt
===================================================================
--- code/branches/Presentation_HS17_merge/src/modules/flappyorx/CMakeLists.txt	2018-02-17 21:54:16 UTC (rev 11756)
+++ code/branches/Presentation_HS17_merge/src/modules/flappyorx/CMakeLists.txt	2018-02-17 22:06:06 UTC (rev 11757)
@@ -1,7 +1,6 @@
 SET_SOURCE_FILES(FlappyOrx_SRC_FILES
 BUILD_UNIT FlappyOrxBuildUnit.cc
   FlappyOrx.cc
-  FlappyOrxCenterPoint.cc
   FlappyOrxShip.cc
   FlappyOrxHUDinfo.cc
 END_BUILD_UNIT

Modified: code/branches/Presentation_HS17_merge/src/modules/flappyorx/FlappyOrx.cc
===================================================================
--- code/branches/Presentation_HS17_merge/src/modules/flappyorx/FlappyOrx.cc	2018-02-17 21:54:16 UTC (rev 11756)
+++ code/branches/Presentation_HS17_merge/src/modules/flappyorx/FlappyOrx.cc	2018-02-17 22:06:06 UTC (rev 11757)
@@ -47,7 +47,6 @@
 // ! HACK
 #include "infos/PlayerInfo.h"
 
-#include "FlappyOrxCenterPoint.h"
 #include "FlappyOrxShip.h"
 
 #include "core/command/ConsoleCommand.h"
@@ -61,7 +60,7 @@
     FlappyOrx::FlappyOrx(Context* context) : Deathmatch(context)
     {
         RegisterObject(FlappyOrx);
-        this->center_ = nullptr;
+
         point = 0;                          //number of cleared tubes
         bIsDead = true;
         firstGame = true;                   //needed for the HUD
@@ -157,7 +156,7 @@
 
     //Create a new Asteroid
     void FlappyOrx::createAsteroid(Circle &c){
-        MovableEntity* newAsteroid = new MovableEntity(this->center_->getContext());
+        MovableEntity* newAsteroid = new MovableEntity(player->getContext());
 
         //Add Model fitting the Size of the Asteroid
         if(c.r<=5)
@@ -218,10 +217,6 @@
         return 1;
     }
 
-    void FlappyOrx::setCenterpoint(FlappyOrxCenterPoint* center){
-        this->center_ = center;
-    }
-
     bool FlappyOrx::isDead(){
         return bIsDead;
     }
@@ -239,12 +234,6 @@
         // Set variable to temporarily force the player to spawn.
         this->bForceSpawn_ = true;
 
-        if (this->center_ == nullptr)  // abandon mission!
-        {
-            orxout(internal_error) << "FlappyOrx: No Centerpoint specified." << endl;
-            GSLevel::startMainMenu();
-            return;
-        }
         // Call start for the parent class.
         Deathmatch::start();
     }

Modified: code/branches/Presentation_HS17_merge/src/modules/flappyorx/FlappyOrx.h
===================================================================
--- code/branches/Presentation_HS17_merge/src/modules/flappyorx/FlappyOrx.h	2018-02-17 21:54:16 UTC (rev 11756)
+++ code/branches/Presentation_HS17_merge/src/modules/flappyorx/FlappyOrx.h	2018-02-17 22:06:06 UTC (rev 11757)
@@ -73,8 +73,6 @@
             void createAsteroid(Circle &c);
             void asteroidField(float x, float y, float slope);
             void spawnTube();
-            
-            void setCenterpoint(FlappyOrxCenterPoint* center);
            
             int getPoints(){return this->point;}
             
@@ -125,7 +123,6 @@
             bool circleCollision(Circle &c1, Circle &c2);
             int addIfPossible(Circle c);
 
-            WeakPtr<FlappyOrxCenterPoint> center_;
             WeakPtr<FlappyOrxShip> player;
 
             int level;

Deleted: code/branches/Presentation_HS17_merge/src/modules/flappyorx/FlappyOrxCenterPoint.cc
===================================================================
--- code/branches/Presentation_HS17_merge/src/modules/flappyorx/FlappyOrxCenterPoint.cc	2018-02-17 21:54:16 UTC (rev 11756)
+++ code/branches/Presentation_HS17_merge/src/modules/flappyorx/FlappyOrxCenterPoint.cc	2018-02-17 22:06:06 UTC (rev 11757)
@@ -1,60 +0,0 @@
-/*
- *   ORXONOX - the hottest 3D action shooter ever to exist
- *                    > www.orxonox.net <
- *
- *
- *   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:
- *      Leo Merholz
- *      Pascal Schärli
- *   Co-authors:
- *      ...
- *
- */
-
-/**
-    @file FlappyOrxCenterPoint.cc
-    @brief Implementation of the FlappyOrxCenterPoint class.
-*/
-
-#include "FlappyOrxCenterPoint.h"
-
-#include "core/CoreIncludes.h"
-
-#include "FlappyOrx.h"
-
-namespace orxonox
-{
-    RegisterClass(FlappyOrxCenterPoint);
-
-    FlappyOrxCenterPoint::FlappyOrxCenterPoint(Context* context) : StaticEntity(context)
-    {
-        RegisterObject(FlappyOrxCenterPoint);
-
-        this->checkGametype();
-    }
-
-    void FlappyOrxCenterPoint::checkGametype()
-    {
-        if (this->getGametype() != nullptr && this->getGametype()->isA(Class(FlappyOrx)))
-        {
-            FlappyOrx* FlappyOrxGametype = orxonox_cast<FlappyOrx*>(this->getGametype());
-            FlappyOrxGametype->setCenterpoint(this);
-        }
-    }
-}

Deleted: code/branches/Presentation_HS17_merge/src/modules/flappyorx/FlappyOrxCenterPoint.h
===================================================================
--- code/branches/Presentation_HS17_merge/src/modules/flappyorx/FlappyOrxCenterPoint.h	2018-02-17 21:54:16 UTC (rev 11756)
+++ code/branches/Presentation_HS17_merge/src/modules/flappyorx/FlappyOrxCenterPoint.h	2018-02-17 22:06:06 UTC (rev 11757)
@@ -1,56 +0,0 @@
-/*
- *   ORXONOX - the hottest 3D action shooter ever to exist
- *                    > www.orxonox.net <
- *
- *
- *   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:
- *      Leo Merholz
- *      Pascal Schärli
- *   Co-authors:
- *      ...
- *
- */
-
-/**
-    @file FlappyOrxCenterPoint.h
-    @brief Declaration of the FlappyOrxCenterPoint class.
-    @ingroup FlappyOrx
-*/
-
-#ifndef _FlappyOrxCenterPoint_H__
-#define _FlappyOrxCenterPoint_H__
-
-#include "flappyorx/FlappyOrxPrereqs.h"
-
-#include "worldentities/StaticEntity.h"
-
-namespace orxonox
-{
-    class _FlappyOrxExport FlappyOrxCenterPoint : public StaticEntity
-    {
-        public:
-            FlappyOrxCenterPoint(Context* context); //checks whether the gametype is actually FlappyOrx.
-
-        private:
-            void checkGametype();
-
-    };
-}
-
-#endif /* _FlappyOrxCenterPoint_H__ */

Modified: code/branches/Presentation_HS17_merge/src/modules/flappyorx/FlappyOrxPrereqs.h
===================================================================
--- code/branches/Presentation_HS17_merge/src/modules/flappyorx/FlappyOrxPrereqs.h	2018-02-17 21:54:16 UTC (rev 11756)
+++ code/branches/Presentation_HS17_merge/src/modules/flappyorx/FlappyOrxPrereqs.h	2018-02-17 22:06:06 UTC (rev 11757)
@@ -69,7 +69,6 @@
 namespace orxonox
 {
     class FlappyOrx;
-    class FlappyOrxCenterPoint;
     class FlappyOrxShip;
     class FlappyOrxHUDinfo;
 }



More information about the Orxonox-commit mailing list