mirror of
https://github.com/The-Powder-Toy/The-Powder-Toy.git
synced 2025-08-29 02:40:47 +02:00
fix bug where when sparks were reset, ctype wasn't
This commit is contained in:
@@ -1100,7 +1100,7 @@ int luatpt_reset_spark(lua_State* l)
|
||||
if (luacon_sim->parts[i].ctype >= 0 && luacon_sim->parts[i].ctype < PT_NUM)
|
||||
{
|
||||
luacon_sim->parts[i].type = luacon_sim->parts[i].ctype;
|
||||
luacon_sim->parts[i].life = 0;
|
||||
luacon_sim->parts[i].life = luacon_sim->parts[i].ctype = 0;
|
||||
}
|
||||
else
|
||||
luacon_sim->kill_part(i);
|
||||
|
@@ -749,7 +749,7 @@ void GameController::ResetSpark()
|
||||
if (sim->parts[i].ctype >= 0 && sim->parts[i].ctype < PT_NUM && sim->elements[sim->parts[i].ctype].Enabled)
|
||||
{
|
||||
sim->parts[i].type = sim->parts[i].ctype;
|
||||
sim->parts[i].life = 0;
|
||||
sim->parts[i].ctype = sim->parts[i].life = 0;
|
||||
}
|
||||
else
|
||||
sim->kill_part(i);
|
||||
|
Reference in New Issue
Block a user