summaryrefslogtreecommitdiff
path: root/src/powder.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/powder.c')
-rw-r--r--src/powder.c21
1 files changed, 15 insertions, 6 deletions
diff --git a/src/powder.c b/src/powder.c
index ce3e4a9..71e8596 100644
--- a/src/powder.c
+++ b/src/powder.c
@@ -876,13 +876,14 @@ inline int create_part(int p, int x, int y, int tv)//the function for creating a
{
if (pmap[y][x])
{
+ int pmaptype = (pmap[y][x]&0xFF);
if ((
- ((pmap[y][x]&0xFF)==PT_STOR&&!(ptypes[t].properties&TYPE_SOLID))||
- (pmap[y][x]&0xFF)==PT_CLNE||
- (pmap[y][x]&0xFF)==PT_BCLN||
- (pmap[y][x]&0xFF)==PT_CONV||
- ((pmap[y][x]&0xFF)==PT_PCLN&&t!=PT_PSCN&&t!=PT_NSCN)||
- ((pmap[y][x]&0xFF)==PT_PBCN&&t!=PT_PSCN&&t!=PT_NSCN)
+ (pmaptype==PT_STOR&&!(ptypes[t].properties&TYPE_SOLID))||
+ pmaptype==PT_CLNE||
+ pmaptype==PT_BCLN||
+ pmaptype==PT_CONV||
+ (pmaptype==PT_PCLN&&t!=PT_PSCN&&t!=PT_NSCN)||
+ (pmaptype==PT_PBCN&&t!=PT_PSCN&&t!=PT_NSCN)
)&&(
t!=PT_CLNE&&t!=PT_PCLN&&
t!=PT_BCLN&&t!=PT_STKM&&
@@ -893,6 +894,11 @@ inline int create_part(int p, int x, int y, int tv)//the function for creating a
parts[pmap[y][x]>>8].ctype = t;
if (t==PT_LIFE && v<NGOLALT && (pmap[y][x]&0xFF)!=PT_STOR) parts[pmap[y][x]>>8].tmp = v;
}
+ else if (pmaptype == PT_DTEC && pmaptype != t)
+ {
+ parts[pmap[y][x]>>8].ctype = t;
+ if (t==PT_LIFE && v<NGOLALT) parts[pmap[y][x]>>8].tmp = v;
+ }
return -1;
}
if (photons[y][x] && (ptypes[t].properties & TYPE_ENERGY))
@@ -1114,6 +1120,9 @@ inline int create_part(int p, int x, int y, int tv)//the function for creating a
case PT_BIZR: case PT_BIZRG: case PT_BIZRS:
parts[i].ctype = 0x47FFFF;
break;
+ case PT_DTEC:
+ parts[i].tmp2 = 2;
+ break;
default:
if (t==PT_FIGH)
{