-#ifndef PARTICLES_HEADER
-#define PARTICLES_HEADER
-
-#define DIGGING_PARTICLES_AMOUNT 10
-
-#include <iostream>
-#include "irrlichttypes_extrabloated.h"
-#include "tile.h"
-#include "localplayer.h"
-#include "environment.h"
-
-class Particle : public scene::ISceneNode
-{
- public:
- Particle(
- IGameDef* gamedef,
- scene::ISceneManager* mgr,
- LocalPlayer *player,
- s32 id,
- v3f pos,
- v3f velocity,
- v3f acceleration,
- float expirationtime,
- float size,
- AtlasPointer texture
- );
- ~Particle();
-
- virtual const core::aabbox3d<f32>& getBoundingBox() const
- {
- return m_box;
- }
-
- virtual u32 getMaterialCount() const
- {
- return 1;
+#pragma once
+
+#include <string>
+#include "irrlichttypes_bloated.h"
+#include "tileanimation.h"
+#include "mapnode.h"
+
+// This file defines the particle-related structures that both the server and
+// client need. The ParticleManager and rendering is in client/particles.h
+
+struct CommonParticleParams {
+ bool collisiondetection = false;
+ bool collision_removal = false;
+ bool object_collision = false;
+ bool vertical = false;
+ std::string texture;
+ struct TileAnimationParams animation;
+ u8 glow = 0;
+ MapNode node;
+ u8 node_tile = 0;
+
+ CommonParticleParams() {
+ animation.type = TAT_NONE;
+ node.setContent(CONTENT_IGNORE);