summaryrefslogtreecommitdiff
path: root/src/elements/O2.c
diff options
context:
space:
mode:
authorjacksonmj <mj-pt@jacksonmj.co.uk>2011-04-05 23:22:29 (GMT)
committer Simon <simon@hardwired.org.uk>2011-04-08 10:10:01 (GMT)
commit30f2b3217c527c3ca04b81fe0b18d20d1a6cfc20 (patch)
tree9e3d30502e2a5532517c7af8fbf8d98226fda379 /src/elements/O2.c
parent767d73c5fc51647dcb5da4ed8349da2186c5060c (diff)
downloadpowder-30f2b3217c527c3ca04b81fe0b18d20d1a6cfc20.zip
powder-30f2b3217c527c3ca04b81fe0b18d20d1a6cfc20.tar.gz
More accurate H2O ratio when forming water
Diffstat (limited to 'src/elements/O2.c')
-rw-r--r--src/elements/O2.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/elements/O2.c b/src/elements/O2.c
index a8be78b..2d7aff0 100644
--- a/src/elements/O2.c
+++ b/src/elements/O2.c
@@ -30,10 +30,13 @@ int update_O2(UPDATE_FUNC_ARGS)
if ((r>>8)>=NPART || !r)
continue;
if ((r&0xFF)==PT_H2)
+ {
+ part_change_type(r>>8,x+rx,y+ry,PT_WATR);
if (50<(rand()/(RAND_MAX/100))) {
part_change_type(i,x,y,PT_WATR);
- part_change_type(r>>8,x+rx,y+ry,PT_WATR);
+ rx = ry = 3;
}
+ }
}
}