you can now charge WIRE with pscn and it'll create only one

electron.
This commit is contained in:
lieuwe 2011-07-29 22:52:05 +08:00 committed by Simon Robertshaw
parent b1b3fbbc20
commit dd2d06425e
2 changed files with 1 additions and 6 deletions

View File

@ -42,10 +42,6 @@ int update_DLAY(UPDATE_FUNC_ARGS) {
{
create_part(-1, x+rx, y+ry, PT_SPRK);
}
else if((r&0xFF)==PT_WIRE && oldl==1)
{
parts[r>>8].ctype=1;
}
}
//}
return 0;

View File

@ -22,8 +22,7 @@ int update_WIRE(UPDATE_FUNC_ARGS) {
if(x+rx>=0 && y+ry>0 && x+rx<XRES && y+ry<YRES && pmap[y+ry][x+rx] && (rx!=0 || ry!=0) && (pmap[y+ry][x+rx]&0xFF)!=0xFF)
{
r = pmap[y+ry][x+rx];
if((r&0xFF)==PT_NSCN && parts[s>>8].tmp==1){create_part(-1, x+rx, y+ry, PT_SPRK);}
if((r&0xFF)==PT_SPRK && parts[r>>8].ctype==PT_PSCN){parts[s>>8].ctype=1; return 0;}
if((r&0xFF)==PT_SPRK && parts[r>>8].ctype==PT_PSCN){parts[s>>8].ctype=1; parts[r>>8].life=0; return 0;}
if((r&0xFF)==PT_WIRE && parts[r>>8].tmp==1){count++;}
}
}