mirror of
https://github.com/The-Powder-Toy/The-Powder-Toy.git
synced 2025-09-02 12:32:40 +02:00
Update src/simulation/elements/VIBR.cpp
fix EXOT destroying exploding VIBR
This commit is contained in:
@@ -149,7 +149,7 @@ int Element_VIBR::update(UPDATE_FUNC_ARGS) {
|
|||||||
if (!r)
|
if (!r)
|
||||||
continue;
|
continue;
|
||||||
//Melts into EXOT
|
//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);
|
sim->create_part(i, x, y, PT_EXOT);
|
||||||
}
|
}
|
||||||
@@ -163,7 +163,7 @@ int Element_VIBR::update(UPDATE_FUNC_ARGS) {
|
|||||||
parts[r>>8].tmp += 10;
|
parts[r>>8].tmp += 10;
|
||||||
}
|
}
|
||||||
//Absorbs energy particles
|
//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;
|
parts[i].tmp += 20;
|
||||||
sim->kill_part(r>>8);
|
sim->kill_part(r>>8);
|
||||||
|
Reference in New Issue
Block a user