[Orxonox-commit 7801] r12393 - in code/branches/OrxoBlox_FS19: data/levels data/levels/templates data/overlays src/modules/OrxoBlox src/modules/weapons/projectiles

ahuwyler at orxonox.net ahuwyler at orxonox.net
Thu May 16 17:16:23 CEST 2019


Author: ahuwyler
Date: 2019-05-16 17:16:22 +0200 (Thu, 16 May 2019)
New Revision: 12393

Modified:
   code/branches/OrxoBlox_FS19/data/levels/orxoblox.oxw
   code/branches/OrxoBlox_FS19/data/levels/templates/spaceshipOrxoBlox.oxt
   code/branches/OrxoBlox_FS19/data/overlays/OrxoBloxHUD.oxo
   code/branches/OrxoBlox_FS19/src/modules/OrxoBlox/OrxoBloxStones.cc
   code/branches/OrxoBlox_FS19/src/modules/OrxoBlox/OrxoBloxStones.h
   code/branches/OrxoBlox_FS19/src/modules/OrxoBlox/OrxoBloxWall.cc
   code/branches/OrxoBlox_FS19/src/modules/weapons/projectiles/BallProjectile.cc
Log:
BOUNCE

Modified: code/branches/OrxoBlox_FS19/data/levels/orxoblox.oxw
===================================================================
--- code/branches/OrxoBlox_FS19/data/levels/orxoblox.oxw	2019-05-16 14:57:51 UTC (rev 12392)
+++ code/branches/OrxoBlox_FS19/data/levels/orxoblox.oxw	2019-05-16 15:16:22 UTC (rev 12393)
@@ -49,17 +49,20 @@
 
 
   
-  <Template name=OrxoBloxstone>
-    <OrxoBloxStones>
+  <!-- <Template name=OrxoBloxstone>
+    <OrxoBloxStones collisionType=static>
       <attached>
-        <Model position="0,0,0" mesh="CuboidBody.mesh" scale=4.5 />
+        <Model position="0,0,0" mesh="CuboidBody.mesh" scale3D="4.5,4.5,4.5" />
         <Model position="0,0,0" mesh="cube_orange.mesh" scale=4.3 />
       </attached>
-      <collisionShapes>
-                <BoxCollisionShape position="0,0,0" halfExtents="4.5, 4.5, 4.5" />
-      </collisionShapes>
+      <collisionShapes> 
+        <BoxCollisionShape position="0,0,0" halfExtents="2,2,2" /> 
+      </collisionShapes> 
     </OrxoBloxStones>
-  </Template>
+  </Template> -->
+
+  <!-- <StaticEntity position="0,-10000,0" direction="0,-1,0" collisionType=static mass=100000 friction=0.01 > -->
+   
   
   
   
@@ -68,7 +71,7 @@
     </OrxoBloxWall>
   </Template>
 
-
+    
 <Level
   plugins = "OrxoBlox"
  gametype = "OrxoBlox"
@@ -84,6 +87,7 @@
    ambientlight = "0.5, 0.5, 0.5"
    skybox       = "Orxonox/skyBoxBasic"
   >
+
     <!-- <Light type=directional position="0,0,0" direction="0.253, 0.593, -0.765" diffuse="1.0, 0.9, 0.9, 1.0" specular="1.0, 0.9, 0.9, 1.0"/> -->
     <Light type=directional position="-100, 10000, -700" direction="0.2, -1, 0" diffuse="1.0, 0.9, 0.9, 1.0" specular="1.0, 0.9, 0.9, 1.0" />
     <SpawnPoint team=0 position="0,-4.5,49" lookat="0,0,0" spawnclass= SpaceShip pawndesign=spaceshipOrxoBlox/>
@@ -103,6 +107,7 @@
       </attached>
     </OrxoBloxCenterpoint>
       
+  
 
   </Scene>
 </Level>

Modified: code/branches/OrxoBlox_FS19/data/levels/templates/spaceshipOrxoBlox.oxt
===================================================================
--- code/branches/OrxoBlox_FS19/data/levels/templates/spaceshipOrxoBlox.oxt	2019-05-16 14:57:51 UTC (rev 12392)
+++ code/branches/OrxoBlox_FS19/data/levels/templates/spaceshipOrxoBlox.oxt	2019-05-16 15:16:22 UTC (rev 12393)
@@ -92,4 +92,17 @@
 
 
   </MultiStateEngine>
+</Template>
+
+
+<Template name=OrxoBloxstone>
+  <OrxoBloxStones collisionType=dynamic>
+    <attached>
+      <Model position="0,0,0" mesh="CuboidBody.mesh" scale3D="4.5,4.5,4.5" />
+      <Model position="0,0,0" mesh="cube_orange.mesh" scale=4.3 />
+    </attached>
+    <collisionShapes> 
+          <BoxCollisionShape position="0,0,0" halfExtents="2,2,2" /> 
+    </collisionShapes> 
+  </OrxoBloxStones>
 </Template>
\ No newline at end of file

Modified: code/branches/OrxoBlox_FS19/data/overlays/OrxoBloxHUD.oxo
===================================================================
--- code/branches/OrxoBlox_FS19/data/overlays/OrxoBloxHUD.oxo	2019-05-16 14:57:51 UTC (rev 12392)
+++ code/branches/OrxoBlox_FS19/data/overlays/OrxoBloxHUD.oxo	2019-05-16 15:16:22 UTC (rev 12393)
@@ -27,28 +27,16 @@
      textsize  = 0.05
      colour    = "1.0, 1.0, 1.0, 1.0"
      align     = "left"
-     
+
+     showhealth  = true
     />
 
 
   </OverlayGroup>
 </Template>
-<Template name="spaceshiphud">
-  <OverlayGroup name = "spaceshiphud" scale = "1, 1">
-    <HUDNavigation
-     name          = "Navigation"
-     correctaspect = true
-     font          = "Monofur"
-     textsize      = 0
-     navMarkerSize = 0.06
-     aimMarkerSize = 0
-     healthMarkerSize = 0
-     healthLevelMarkerSize = 0
-    />
-  </OverlayGroup>
-</Template>
 
 
+
 <Template name="spectatorhud">
   <OverlayGroup name = "spectatorhud" scale = "1, 1">
   </OverlayGroup>

Modified: code/branches/OrxoBlox_FS19/src/modules/OrxoBlox/OrxoBloxStones.cc
===================================================================
--- code/branches/OrxoBlox_FS19/src/modules/OrxoBlox/OrxoBloxStones.cc	2019-05-16 14:57:51 UTC (rev 12392)
+++ code/branches/OrxoBlox_FS19/src/modules/OrxoBlox/OrxoBloxStones.cc	2019-05-16 15:16:22 UTC (rev 12393)
@@ -12,7 +12,7 @@
     @brief
         Constructor. Registers and initializes the object.
     */
-    OrxoBloxStones::OrxoBloxStones(Context* context) : StaticEntity(context)
+    OrxoBloxStones::OrxoBloxStones(Context* context) : Pawn(context)
     {
         RegisterObject(OrxoBloxStones);
 

Modified: code/branches/OrxoBlox_FS19/src/modules/OrxoBlox/OrxoBloxStones.h
===================================================================
--- code/branches/OrxoBlox_FS19/src/modules/OrxoBlox/OrxoBloxStones.h	2019-05-16 14:57:51 UTC (rev 12392)
+++ code/branches/OrxoBlox_FS19/src/modules/OrxoBlox/OrxoBloxStones.h	2019-05-16 15:16:22 UTC (rev 12393)
@@ -6,6 +6,7 @@
 
 
 #include "worldentities/StaticEntity.h"
+#include "worldentities/pawns/Pawn.h"
 #include "tools/Timer.h"
 
 namespace orxonox
@@ -18,7 +19,7 @@
 
     @ingroup OrxoBlox
     */
-    class _OrxoBloxExport OrxoBloxStones : public StaticEntity
+    class _OrxoBloxExport OrxoBloxStones : public Pawn
     {
         public:
             OrxoBloxStones(Context* context); //!< Constructor. Registers and initializes the object.

Modified: code/branches/OrxoBlox_FS19/src/modules/OrxoBlox/OrxoBloxWall.cc
===================================================================
--- code/branches/OrxoBlox_FS19/src/modules/OrxoBlox/OrxoBloxWall.cc	2019-05-16 14:57:51 UTC (rev 12392)
+++ code/branches/OrxoBlox_FS19/src/modules/OrxoBlox/OrxoBloxWall.cc	2019-05-16 15:16:22 UTC (rev 12393)
@@ -34,6 +34,7 @@
             if(j<2){
                 this->size_ = 9.0f;
                 OrxoBloxStones* stone = new OrxoBloxStones(this->center_->getContext());
+                stone->addTemplate(this->orxoblox_->getCenterpoint()->getStoneTemplate());
                 if (stone == nullptr) {
                     std::abort();
                 }

Modified: code/branches/OrxoBlox_FS19/src/modules/weapons/projectiles/BallProjectile.cc
===================================================================
--- code/branches/OrxoBlox_FS19/src/modules/weapons/projectiles/BallProjectile.cc	2019-05-16 14:57:51 UTC (rev 12392)
+++ code/branches/OrxoBlox_FS19/src/modules/weapons/projectiles/BallProjectile.cc	2019-05-16 15:16:22 UTC (rev 12393)
@@ -141,6 +141,7 @@
             if (otherObject->isA(Class(OrxoBloxStones))) {
                 Bounce(otherObject, contactPoint, cs);
                 orxout() << "BOUNCED!" << endl;
+                
             }
         }
         return result;



More information about the Orxonox-commit mailing list