GroundParticle Class Reference

#include <ground_particles.h>

Inheritance diagram for GroundParticle:

Inheritance graph
[legend]
Collaboration diagram for GroundParticle:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 GroundParticle (const Point2i &size, const Point2i &position)
void Refresh ()

Detailed Description

Definition at line 26 of file ground_particles.h.


Constructor & Destructor Documentation

GroundParticle::GroundParticle ( const Point2i size,
const Point2i position 
)

Definition at line 27 of file ground_particles.cpp.

00027                                                                            :
00028   Particle("ground_particle")
00029 {
00030   m_left_time_to_live = 1;
00031   image = NULL;
00032 
00033   Rectanglei rec;
00034   rec.SetPosition( position - size / 2);
00035   rec.SetSize( size );
00036   image = new Sprite(world.ground.GetPart(rec));
00037 }

Here is the call graph for this function:


Member Function Documentation

void GroundParticle::Refresh (  )  [virtual]

Reimplemented from Particle.

Definition at line 39 of file ground_particles.cpp.

00040 {
00041   UpdatePosition();
00042   image->SetRotation_rad((Time::GetInstance()->Read()/2) % 360/* /180*/ * M_PI);
00043   image->Update();
00044   if(IsOutsideWorld(GetPosition()))
00045     m_left_time_to_live = 0;
00046 }

Here is the call graph for this function:


The documentation for this class was generated from the following files:
Generated on Mon Jan 1 13:51:22 2007 for Wormux by  doxygen 1.4.7