diff options
| author | jacob1 <jfu614@gmail.com> | 2013-05-08 14:29:10 (GMT) |
|---|---|---|
| committer | jacob1 <jfu614@gmail.com> | 2013-05-08 14:29:10 (GMT) |
| commit | c0b45928392efdffbde819842387a041e2d1936a (patch) | |
| tree | e315dc38d198a8ed05aafa1788293339b271951d /src/simulation/elements/ARAY.cpp | |
| parent | 77102f4bbaff9d15617b83e674939b108442ae21 (diff) | |
| download | powder-c0b45928392efdffbde819842387a041e2d1936a.zip powder-c0b45928392efdffbde819842387a041e2d1936a.tar.gz | |
fix PSCN BRAY (tmp = 2) not stopping normal BRAY from going through
also some other random things
Diffstat (limited to 'src/simulation/elements/ARAY.cpp')
| -rw-r--r-- | src/simulation/elements/ARAY.cpp | 23 |
1 files changed, 10 insertions, 13 deletions
diff --git a/src/simulation/elements/ARAY.cpp b/src/simulation/elements/ARAY.cpp index f7d3194..b1c2b84 100644 --- a/src/simulation/elements/ARAY.cpp +++ b/src/simulation/elements/ARAY.cpp @@ -78,20 +78,17 @@ int Element_ARAY::update(UPDATE_FUNC_ARGS) parts[nr].temp = parts[i].temp; } } else if (!destroy) { - if ((r&0xFF)==PT_BRAY) { - if (parts[r>>8].tmp==0){//if it hits another BRAY that isn't red - if (nyy!=0 || nxx!=0) { - parts[r>>8].life = 1020;//makes it last a while - parts[r>>8].tmp = 1; - if (!parts[r>>8].ctype)//and colors it if it isn't already - parts[r>>8].ctype = colored; - } - docontinue = 0;//then stop it - } - else if (parts[r>>8].tmp==1) {//if it hits one that already was a long life, reset it - parts[r>>8].life = 1020; - //docontinue = 1; + if ((r&0xFF)==PT_BRAY&&parts[r>>8].tmp==0) {//if it hits another BRAY that isn't red + if (nyy!=0 || nxx!=0) { + parts[r>>8].life = 1020;//makes it last a while + parts[r>>8].tmp = 1; + if (!parts[r>>8].ctype)//and colors it if it isn't already + parts[r>>8].ctype = colored; } + docontinue = 0;//then stop it + } else if ((r&0xFF)==PT_BRAY&&parts[r>>8].tmp==1) {//if it hits one that already was a long life, reset it + parts[r>>8].life = 1020; + //docontinue = 1; } else if ((r&0xFF)==PT_FILT) {//get color if passed through FILT colored = parts[r>>8].ctype; //this if prevents BRAY from stopping on certain materials |
