summaryrefslogtreecommitdiff
path: root/src/simulation/elements/DLAY.cpp
diff options
context:
space:
mode:
authorcracker64 <cracker642@gmail.com>2013-03-02 05:42:07 (GMT)
committer cracker64 <cracker642@gmail.com>2013-03-02 05:42:07 (GMT)
commitd58100dc070be97073d1f02cdbb7a382a67c376b (patch)
treecc0fc022e7f8524b7f9bcf5ed93eb83980596f91 /src/simulation/elements/DLAY.cpp
parenta9f4b5fe343fb0ada8934030abe6363695ea43dc (diff)
downloadpowder-d58100dc070be97073d1f02cdbb7a382a67c376b.zip
powder-d58100dc070be97073d1f02cdbb7a382a67c376b.tar.gz
More fixes, redid a bunch of SPRK, so far everything I've tested works fine.
Diffstat (limited to 'src/simulation/elements/DLAY.cpp')
-rw-r--r--src/simulation/elements/DLAY.cpp11
1 files changed, 4 insertions, 7 deletions
diff --git a/src/simulation/elements/DLAY.cpp b/src/simulation/elements/DLAY.cpp
index c0602db..d0dd4c1 100644
--- a/src/simulation/elements/DLAY.cpp
+++ b/src/simulation/elements/DLAY.cpp
@@ -77,14 +77,11 @@ int Element_DLAY::update(UPDATE_FUNC_ARGS)
parts[i].life--;
}
}
- else
+ else if (!parts[r>>8].life)
{
- if (!parts[r>>8].life)
- {
- parts[r>>8].life = parts[i].life;
- if((r>>8)>i) //If the other particle hasn't been life updated
- parts[r>>8].life++;
- }
+ parts[r>>8].life = parts[i].life;
+ if((r>>8)>i) //If the other particle hasn't been life updated
+ parts[r>>8].life++;
}
}
else if((r&0xFF)==PT_NSCN && oldl==1)