From 769dbfeedddc774b177e2089eaa5abe870205e6b Mon Sep 17 00:00:00 2001 From: Felix Wallin Date: Sat, 2 Oct 2010 20:03:00 +0200 Subject: [PATCH] fixes to photons, thanks to skylark --- src/powder.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/powder.c b/src/powder.c index 79c1bd4ee..3ca1056f3 100644 --- a/src/powder.c +++ b/src/powder.c @@ -35,8 +35,11 @@ static int eval_move(int pt, int nx, int ny, unsigned *rr) r = (r&~0xFF) | parts[r>>8].type; if(rr) *rr = r; - - if(pt==PT_PHOT&&((r&0xFF)==PT_GLAS||(r&0xFF)==PT_PHOT||(r&0xFF)==PT_CLNE||((r&0xFF)==PT_LCRY||((r&0xFF)==PT_PCLN&&parts[r>>8].life > 5)))) + if(pt==PT_PHOT&&( + (r&0xFF)==PT_GLAS || (r&0xFF)==PT_PHOT || + (r&0xFF)==PT_CLNE || (r&0xFF)==PT_PCLN || + (r&0xFF)==PT_WATR || (r&0xFF)==PT_DSTW || (r&0xFF)==PT_SLTW || + ((r&0xFF)==PT_LCRY&&parts[r>>8].life > 5))) return 2; if(pt==PT_STKM) //Stick man's head shouldn't collide @@ -73,7 +76,7 @@ int try_move(int i, int x, int y, int nx, int ny) if(!e) { if(!legacy_enable) { if((r >> 8) < PT_NUM) - parts[i].temp = parts[r>>8].temp = restrict_flt(parts[r>>8].temp+parts[i].temp/2, MIN_TEMP, MAX_TEMP); + parts[i].temp = parts[r>>8].temp = restrict_flt(parts[r>>8].temp+parts[i].temp/2, MIN_TEMP, MAX_TEMP); } return 0; }