#include "irrlichttypes_extrabloated.h"
#include "client/tile.h"
#include "localplayer.h"
-#include "environment.h"
#include "tileanimation.h"
struct ClientEvent;
u8 glow,
video::SColor color = video::SColor(0xFFFFFFFF)
);
- ~Particle();
+ ~Particle() = default;
virtual const aabb3f &getBoundingBox() const
{
class ParticleSpawner
{
- public:
+public:
ParticleSpawner(IGameDef* gamedef,
LocalPlayer *player,
u16 amount,
const struct TileAnimationParams &anim, u8 glow,
ParticleManager* p_manager);
- ~ParticleSpawner();
+ ~ParticleSpawner() = default;
void step(float dtime, ClientEnvironment *env);
bool get_expired ()
{ return (m_amount <= 0) && m_spawntime != 0; }
- private:
- ParticleManager* m_particlemanager;
+private:
+ void spawnParticle(ClientEnvironment *env, float radius,
+ bool is_attached, const v3f &attached_pos,
+ float attached_yaw);
+
+ ParticleManager *m_particlemanager;
float m_time;
IGameDef *m_gamedef;
LocalPlayer *m_player;
void addDiggingParticles(IGameDef *gamedef, LocalPlayer *player, v3s16 pos,
const MapNode &n, const ContentFeatures &f);
- void addPunchingParticles(IGameDef *gamedef, LocalPlayer *player, v3s16 pos,
- const MapNode &n, const ContentFeatures &f);
-
void addNodeParticle(IGameDef *gamedef, LocalPlayer *player, v3s16 pos,
const MapNode &n, const ContentFeatures &f);