Prevent segfault with high tmp values for pipe

This commit is contained in:
jacksonmj 2011-09-28 23:44:10 +01:00 committed by Simon Robertshaw
parent f5a9f43b77
commit 203db57e57

View File

@ -45,7 +45,7 @@ void pushParticle(int i, int count, int original)
}
else //predefined 1 pixel thick pipe movement
{
int coords = 7 - (parts[i].tmp>>10);
int coords = 7 - ((parts[i].tmp>>10)&7);
r = pmap[y+ pos_1_ry[coords]][x+ pos_1_rx[coords]];
if (!r)
{