summaryrefslogtreecommitdiff
path: root/src/simulation
diff options
context:
space:
mode:
authorjacob1 <jfu614@gmail.com>2012-11-24 02:28:10 (GMT)
committer jacob1 <jfu614@gmail.com>2012-11-24 02:28:10 (GMT)
commit6a4040f2b7aa86992a340f8bf5afb95011a1e989 (patch)
tree5beb2ed4515c7eb5063db29dfdbf8ad9896b9536 /src/simulation
parentda554cfef24b6a207db50507e7dae3513b36e59b (diff)
downloadpowder-6a4040f2b7aa86992a340f8bf5afb95011a1e989.zip
powder-6a4040f2b7aa86992a340f8bf5afb95011a1e989.tar.gz
Update src/simulation/elements/VIBR.cpp
fix EXOT destroying exploding VIBR
Diffstat (limited to 'src/simulation')
-rw-r--r--src/simulation/elements/VIBR.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/simulation/elements/VIBR.cpp b/src/simulation/elements/VIBR.cpp
index 68119f7..7a8c30c 100644
--- a/src/simulation/elements/VIBR.cpp
+++ b/src/simulation/elements/VIBR.cpp
@@ -149,7 +149,7 @@ int Element_VIBR::update(UPDATE_FUNC_ARGS) {
if (!r)
continue;
//Melts into EXOT
- if ((r&0xFF) == PT_EXOT && !(rand()%250))
+ if ((r&0xFF) == PT_EXOT && !(rand()%250) && !parts[i].life)
{
sim->create_part(i, x, y, PT_EXOT);
}
@@ -163,7 +163,7 @@ int Element_VIBR::update(UPDATE_FUNC_ARGS) {
parts[r>>8].tmp += 10;
}
//Absorbs energy particles
- if ((sim->elements[r&0xFF].Properties & TYPE_ENERGY))
+ if ((sim->elements[r&0xFF].Properties & TYPE_ENERGY) && !parts[i].life)
{
parts[i].tmp += 20;
sim->kill_part(r>>8);