diff options
| author | cracker64 <cracker642@gmail.com> | 2013-03-01 05:41:53 (GMT) |
|---|---|---|
| committer | cracker64 <cracker642@gmail.com> | 2013-03-01 05:41:53 (GMT) |
| commit | 0d70547cf059b5bd0a7a4a0acd9251fb94c6115e (patch) | |
| tree | 99a0b212eeecee83662d963da052b439375acbf3 /src/simulation/elements/CO2.cpp | |
| parent | 5873d6958641af21b92fcb039d26c336331f19e7 (diff) | |
| download | powder-0d70547cf059b5bd0a7a4a0acd9251fb94c6115e.zip powder-0d70547cf059b5bd0a7a4a0acd9251fb94c6115e.tar.gz | |
More fixes to fix fixes and new fixes to fix stuff.
Diffstat (limited to 'src/simulation/elements/CO2.cpp')
| -rw-r--r-- | src/simulation/elements/CO2.cpp | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/src/simulation/elements/CO2.cpp b/src/simulation/elements/CO2.cpp index 09dbe8c..9eade3d 100644 --- a/src/simulation/elements/CO2.cpp +++ b/src/simulation/elements/CO2.cpp @@ -56,7 +56,14 @@ int Element_CO2::update(UPDATE_FUNC_ARGS) { r = pmap[y+ry][x+rx]; if (!r) + { + if (parts[i].ctype==5 && !(rand()%83)) + { + if (sim->create_part(-1, x+rx, y+ry, PT_WATR)>=0) + parts[i].ctype = 0; + } continue; + } if ((r&0xFF)==PT_FIRE){ sim->kill_part(r>>8); if(!(rand()%150)){ @@ -79,11 +86,6 @@ int Element_CO2::update(UPDATE_FUNC_ARGS) } } } - if (parts[i].ctype==5 && !(rand()%83)) - { - if (sim->create_part(-1, x+rx, y+ry, PT_WATR)>=0) - parts[i].ctype = 0; - } if (parts[i].temp > 9773.15 && sim->pv[y/CELL][x/CELL] > 200.0f) { if (!(rand()%5)) |
