diff options
Diffstat (limited to 'src/simulation/elements/IGNT.cpp')
| -rw-r--r-- | src/simulation/elements/IGNT.cpp | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/src/simulation/elements/IGNT.cpp b/src/simulation/elements/IGNT.cpp index de26eb7..b1afe92 100644 --- a/src/simulation/elements/IGNT.cpp +++ b/src/simulation/elements/IGNT.cpp @@ -49,7 +49,7 @@ Element_IGNT::Element_IGNT() //#TPT-Directive ElementHeader Element_IGNT static int update(UPDATE_FUNC_ARGS) int Element_IGNT::update(UPDATE_FUNC_ARGS) { - int r, rx, ry; + int r, rx, ry, rt; if(parts[i].tmp==0) { for (rx=-1; rx<2; rx++) @@ -59,11 +59,8 @@ int Element_IGNT::update(UPDATE_FUNC_ARGS) r = pmap[y+ry][x+rx]; if (!r) continue; - if ((r&0xFF)==PT_FIRE || (r&0xFF)==PT_PLSM) - { - parts[i].tmp = 1; - } - else if ((r&0xFF)==PT_SPRK || (r&0xFF)==PT_LIGH || ((r&0xFF)==PT_IGNT && parts[r>>8].life==1)) + rt = r&0xFF; + if (rt==PT_FIRE || rt==PT_PLSM || rt==PT_SPRK || rt==PT_LIGH || (rt==PT_IGNT && parts[r>>8].life==1)) { parts[i].tmp = 1; } @@ -92,4 +89,4 @@ int Element_IGNT::update(UPDATE_FUNC_ARGS) } -Element_IGNT::~Element_IGNT() {}
\ No newline at end of file +Element_IGNT::~Element_IGNT() {} |
