pingus-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Pingus-CVS] CVS: Games/Pingus/src/particles explosive_particle.hxx, 1.


From: Ingo Ruhnke
Subject: [Pingus-CVS] CVS: Games/Pingus/src/particles explosive_particle.hxx, 1.6, 1.7 pingu_particle_holder.cxx, 1.9, 1.10 rain_particle_holder.cxx, 1.6, 1.7 rain_particle_holder.hxx, 1.6, 1.7 smoke_particle_holder.cxx, 1.5, 1.6 smoke_particle_holder.hxx, 1.4, 1.5 snow_particle_holder.cxx, 1.7, 1.8
Date: Sun, 19 Oct 2003 14:25:50 +0200

Update of /var/lib/cvs/Games/Pingus/src/particles
In directory dark:/tmp/cvs-serv19578/particles

Modified Files:
        explosive_particle.hxx pingu_particle_holder.cxx 
        rain_particle_holder.cxx rain_particle_holder.hxx 
        smoke_particle_holder.cxx smoke_particle_holder.hxx 
        snow_particle_holder.cxx 
Log Message:
- some more stuff, still not much useable

Index: explosive_particle.hxx
===================================================================
RCS file: /var/lib/cvs/Games/Pingus/src/particles/explosive_particle.hxx,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- explosive_particle.hxx      19 Apr 2003 10:23:19 -0000      1.6
+++ explosive_particle.hxx      19 Oct 2003 12:25:47 -0000      1.7
@@ -23,6 +23,8 @@
 #include "../sprite.hxx"
 #include "particle.hxx"
 
+namespace Pingus {
+
 class ExplosiveParticle
   : public Particle
 {

Index: pingu_particle_holder.cxx
===================================================================
RCS file: /var/lib/cvs/Games/Pingus/src/particles/pingu_particle_holder.cxx,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -d -r1.9 -r1.10
--- pingu_particle_holder.cxx   19 Apr 2003 10:23:19 -0000      1.9
+++ pingu_particle_holder.cxx   19 Oct 2003 12:25:47 -0000      1.10
@@ -24,12 +24,11 @@
 #include "../world.hxx"
 #include "pingu_particle_holder.hxx"
 
+namespace Pingus {
 namespace Particles {
 
-namespace {
-  const float x_collision_decrease = 0.3f;
-  const float y_collision_decrease = 0.6f;
-}
+const float x_collision_decrease = 0.3f;
+const float y_collision_decrease = 0.6f;
 
 PinguParticleHolder::PinguParticle::PinguParticle (int x, int y)
   : livetime(50 + (rand() % 75)),
@@ -167,5 +166,6 @@
 }
 
 } // namespace Particles
+} // namespace Pingus
 
 /* EOF */

Index: rain_particle_holder.cxx
===================================================================
RCS file: /var/lib/cvs/Games/Pingus/src/particles/rain_particle_holder.cxx,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- rain_particle_holder.cxx    19 Apr 2003 10:23:19 -0000      1.6
+++ rain_particle_holder.cxx    19 Oct 2003 12:25:47 -0000      1.7
@@ -25,6 +25,7 @@
 #include "../world.hxx"
 #include "rain_particle_holder.hxx"
 
+namespace Pingus {
 namespace Particles {
 
 RainParticleHolder::RainParticle::RainParticle(int x, int y)
@@ -36,9 +37,9 @@
 
 
 RainParticleHolder::RainParticleHolder ()
-  : rain1_surf (PingusResource::load_surface("Particles/rain1", "pingus")),
-    rain2_surf (PingusResource::load_surface("Particles/rain2", "pingus")),
-    rain_splash(PingusResource::load_surface("Particles/rain_splash", 
"pingus"))
+  : rain1_surf (PingusResource::load_sprite("Particles/rain1", "pingus")),
+    rain2_surf (PingusResource::load_sprite("Particles/rain2", "pingus")),
+    rain_splash(PingusResource::load_sprite("Particles/rain_splash", "pingus"))
 {
 }
 
@@ -70,7 +71,7 @@
 
       if (it->splash)
        {
-         if (it->splash_frame >= rain_splash.get_num_frames())
+         if (it->splash_frame >= rain_splash.get_frame_count())
            {
              it->alive = false;
              continue;
@@ -107,6 +108,7 @@
 void
 RainParticleHolder::draw (GraphicContext& gc)
 {
+#ifdef CLANLIB_0_6
   for (std::vector<RainParticle>::iterator it=particles.begin(); it != 
particles.end(); ++it)
     {
       // skip dead/invisible particles
@@ -121,8 +123,10 @@
         else
           gc.draw(rain1_surf, static_cast<int>(it->pos.x), 
static_cast<int>(it->pos.y - rain1_surf.get_height()));
     }
+#endif
 }
 
 } // namespace Particles
+} // namespace Pingus
 
 /* EOF */

Index: rain_particle_holder.hxx
===================================================================
RCS file: /var/lib/cvs/Games/Pingus/src/particles/rain_particle_holder.hxx,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- rain_particle_holder.hxx    18 Oct 2003 23:17:28 -0000      1.6
+++ rain_particle_holder.hxx    19 Oct 2003 12:25:47 -0000      1.7
@@ -21,10 +21,12 @@
 #define HEADER_PINGUS_PARTICLES_RAIN_PARTICLE_HOLDER_HXX
 
 #include <vector>
-#include <ClanLib/Display/surface.h>
+#include <ClanLib/Display/sprite.h>
 #include "../vector.hxx"
 #include "../worldobj.hxx"
 
+namespace Pingus {
+
 class GraphicContext;
 
 namespace Particles {
@@ -45,9 +47,9 @@
   };
 
 private:
-  CL_Surface rain1_surf;
-  CL_Surface rain2_surf;
-  CL_Surface rain_splash;
+  CL_Sprite rain1_surf;
+  CL_Sprite rain2_surf;
+  CL_Sprite rain_splash;
 
   std::vector<RainParticle> particles;
 
@@ -70,6 +72,7 @@
 };
 
 } // namespace Particles
+} // namespace Pingus
 
 #endif
 

Index: smoke_particle_holder.cxx
===================================================================
RCS file: /var/lib/cvs/Games/Pingus/src/particles/smoke_particle_holder.cxx,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- smoke_particle_holder.cxx   19 Apr 2003 10:23:19 -0000      1.5
+++ smoke_particle_holder.cxx   19 Oct 2003 12:25:47 -0000      1.6
@@ -22,7 +22,7 @@
 #include "../pingus_resource.hxx"
 #include "smoke_particle_holder.hxx"
 
-
+namespace Pingus {
 namespace Particles {
 
 SmokeParticleHolder::SmokeParticle::SmokeParticle (int x, int y, float vel_x, 
float vel_y)
@@ -89,5 +89,6 @@
 }
 
 } // namespace Particles
+} // namespace Pingus
 
 /* EOF */

Index: smoke_particle_holder.hxx
===================================================================
RCS file: /var/lib/cvs/Games/Pingus/src/particles/smoke_particle_holder.hxx,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- smoke_particle_holder.hxx   18 Oct 2003 23:17:28 -0000      1.4
+++ smoke_particle_holder.hxx   19 Oct 2003 12:25:47 -0000      1.5
@@ -25,6 +25,8 @@
 #include "../vector.hxx"
 #include "../worldobj.hxx"
 
+namespace Pingus {
+
 class GraphicContext;
 
 namespace Particles {
@@ -66,6 +68,7 @@
 };
 
 } // namespace Particles
+} // namespace Pingus
 
 #endif
 

Index: snow_particle_holder.cxx
===================================================================
RCS file: /var/lib/cvs/Games/Pingus/src/particles/snow_particle_holder.cxx,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -d -r1.7 -r1.8
--- snow_particle_holder.cxx    19 Apr 2003 10:23:19 -0000      1.7
+++ snow_particle_holder.cxx    19 Oct 2003 12:25:47 -0000      1.8
@@ -26,6 +26,7 @@
 #include "../world.hxx"
 #include "snow_particle_holder.hxx"
 
+namespace Pingus {
 namespace Particles {
 
 SnowParticleHolder::SnowParticle::SnowParticle (int x, int y, bool colliding_)
@@ -149,6 +150,7 @@
     }
 }
 
-} //namespace Particles
+} // namespace Particles
+} // namespace Pingus
 
 /* EOF */





reply via email to

[Prev in Thread] Current Thread [Next in Thread]