aboutsummaryrefslogtreecommitdiff
path: root/src/particles.h
diff options
context:
space:
mode:
authorElias Fleckenstein <54945686+EliasFleckenstein03@users.noreply.github.com>2020-11-04 16:44:42 +0100
committerGitHub <noreply@github.com>2020-11-04 16:44:42 +0100
commit5d9ae5a91c544fc7fbd475decf47cef7e09ef8fc (patch)
treec980d614fec4a5495798be3e79e033229062c3cd /src/particles.h
parent28f6a79706b088c37268a59d90878220dc4ef9c7 (diff)
parent3af10766fd2b58b068e970266724d7eb10e9316b (diff)
downloaddragonfireclient-5d9ae5a91c544fc7fbd475decf47cef7e09ef8fc.tar.xz
Merge branch 'master' into master
Diffstat (limited to 'src/particles.h')
-rw-r--r--src/particles.h15
1 files changed, 10 insertions, 5 deletions
diff --git a/src/particles.h b/src/particles.h
index 6f518b771..aae460060 100644
--- a/src/particles.h
+++ b/src/particles.h
@@ -27,7 +27,8 @@ with this program; if not, write to the Free Software Foundation, Inc.,
// 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 {
+struct CommonParticleParams
+{
bool collisiondetection = false;
bool collision_removal = false;
bool object_collision = false;
@@ -38,14 +39,16 @@ struct CommonParticleParams {
MapNode node;
u8 node_tile = 0;
- CommonParticleParams() {
+ CommonParticleParams()
+ {
animation.type = TAT_NONE;
node.setContent(CONTENT_IGNORE);
}
/* This helper is useful for copying params from
* ParticleSpawnerParameters to ParticleParameters */
- inline void copyCommon(CommonParticleParams &to) const {
+ inline void copyCommon(CommonParticleParams &to) const
+ {
to.collisiondetection = collisiondetection;
to.collision_removal = collision_removal;
to.object_collision = object_collision;
@@ -58,7 +61,8 @@ struct CommonParticleParams {
}
};
-struct ParticleParameters : CommonParticleParams {
+struct ParticleParameters : CommonParticleParams
+{
v3f pos;
v3f vel;
v3f acc;
@@ -69,7 +73,8 @@ struct ParticleParameters : CommonParticleParams {
void deSerialize(std::istream &is, u16 protocol_ver);
};
-struct ParticleSpawnerParameters : CommonParticleParams {
+struct ParticleSpawnerParameters : CommonParticleParams
+{
u16 amount = 1;
v3f minpos, maxpos, minvel, maxvel, minacc, maxacc;
f32 time = 1;