Prevent segfault with high tmp values for pipe
This commit is contained in:
parent
f5a9f43b77
commit
203db57e57
@ -45,7 +45,7 @@ void pushParticle(int i, int count, int original)
|
|||||||
}
|
}
|
||||||
else //predefined 1 pixel thick pipe movement
|
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]];
|
r = pmap[y+ pos_1_ry[coords]][x+ pos_1_rx[coords]];
|
||||||
if (!r)
|
if (!r)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user