diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/powder.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/powder.c b/src/powder.c index df88f9d..3f68c18 100644 --- a/src/powder.c +++ b/src/powder.c @@ -1604,8 +1604,9 @@ void update_particles_i(pixel *vid, int start, int inc) pv[y/CELL+1][x/CELL] += ptypes[t].hotair*(3.5f-pv[y/CELL+1][x/CELL]); if (x+CELL<XRES) { - pv[y/CELL][x/CELL+1] += ptypes[t].hotair*(3.5f-pv[y/CELL][x/CELL+1]); - if (y+CELL<YRES) + if (pv[y/CELL][x/CELL+1]<3.5f) + pv[y/CELL][x/CELL+1] += ptypes[t].hotair*(3.5f-pv[y/CELL][x/CELL+1]); + if (y+CELL<YRES && pv[y/CELL+1][x/CELL+1]<3.5f) pv[y/CELL+1][x/CELL+1] += ptypes[t].hotair*(3.5f-pv[y/CELL+1][x/CELL+1]); } } |
