summaryrefslogtreecommitdiff
path: root/src/simulation/elements/FILT.cpp
diff options
context:
space:
mode:
authorSimon Robertshaw <simon@hardwired.org.uk>2013-10-29 19:39:52 (GMT)
committer Simon Robertshaw <simon@hardwired.org.uk>2013-10-29 19:39:52 (GMT)
commite78dcae8517e3cc9efc4883935655d7098ab54b1 (patch)
tree138fac654d0322644353bed17a94dd3e72722f08 /src/simulation/elements/FILT.cpp
parenta4da2566ecf3802f0dfdf7fc2ddba58ede246025 (diff)
parent79a2ac3103815d10e83619fd36615f0c0909cf7a (diff)
downloadpowder-e78dcae8517e3cc9efc4883935655d7098ab54b1.zip
powder-e78dcae8517e3cc9efc4883935655d7098ab54b1.tar.gz
Merge branch 'master' into develop
Diffstat (limited to 'src/simulation/elements/FILT.cpp')
-rw-r--r--src/simulation/elements/FILT.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/simulation/elements/FILT.cpp b/src/simulation/elements/FILT.cpp
index 8ece142..36ea414 100644
--- a/src/simulation/elements/FILT.cpp
+++ b/src/simulation/elements/FILT.cpp
@@ -106,10 +106,9 @@ int Element_FILT::interactWavelengths(Particle* cpart, int origWl)
return (~origWl) & mask; // Invert colours
case 9:
{
- int t1, t2, t3, r;
- t1 = (origWl & 0x0000FF)+(rand()%5)-2;
- t1 = ((origWl & 0x00FF00)>>8)+(rand()%5)-2;
- t3 = ((origWl & 0xFF0000)>>16)+(rand()%5)-2;
+ int t1 = (origWl & 0x0000FF)+(rand()%5)-2;
+ int t2 = ((origWl & 0x00FF00)>>8)+(rand()%5)-2;
+ int t3 = ((origWl & 0xFF0000)>>16)+(rand()%5)-2;
return (origWl & 0xFF000000) | (t3<<16) | (t2<<8) | t1;
}
default: