summaryrefslogtreecommitdiff
path: root/src/elements
diff options
context:
space:
mode:
Diffstat (limited to 'src/elements')
-rw-r--r--src/elements/pbcn.c5
-rw-r--r--src/elements/pcln.c5
2 files changed, 10 insertions, 0 deletions
diff --git a/src/elements/pbcn.c b/src/elements/pbcn.c
index 5fb361c..f8424fe 100644
--- a/src/elements/pbcn.c
+++ b/src/elements/pbcn.c
@@ -69,6 +69,11 @@ int update_PBCN(UPDATE_FUNC_ARGS) {
{
parts[r].vx = rx*3;
parts[r].vy = ry*3;
+ if (r>i)
+ {
+ // Make sure movement doesn't happen until next frame, to avoid gaps in the beams of photons produced
+ parts[r].flags |= FLAG_SKIPMOVE;
+ }
}
}
}
diff --git a/src/elements/pcln.c b/src/elements/pcln.c
index 1972632..924ce7a 100644
--- a/src/elements/pcln.c
+++ b/src/elements/pcln.c
@@ -59,6 +59,11 @@ int update_PCLN(UPDATE_FUNC_ARGS) {
{
parts[r].vx = rx*3;
parts[r].vy = ry*3;
+ if (r>i)
+ {
+ // Make sure movement doesn't happen until next frame, to avoid gaps in the beams of photons produced
+ parts[r].flags |= FLAG_SKIPMOVE;
+ }
}
}
}