diff options
| author | cracker64 <cracker642@gmail.com> | 2013-02-27 05:11:23 (GMT) |
|---|---|---|
| committer | cracker64 <cracker642@gmail.com> | 2013-02-27 05:11:23 (GMT) |
| commit | 27e3e1251837f5d64e835068d5f5bd5b67b95921 (patch) | |
| tree | af6383f7df96485633c91ebcfbe6318ee927403f /src/simulation/elements/FWRK.cpp | |
| parent | a62467c74e9391dd2a9173cfa167d32eceed506b (diff) | |
| download | powder-27e3e1251837f5d64e835068d5f5bd5b67b95921.zip powder-27e3e1251837f5d64e835068d5f5bd5b67b95921.tar.gz | |
Small optimizations number 2.
Diffstat (limited to 'src/simulation/elements/FWRK.cpp')
| -rw-r--r-- | src/simulation/elements/FWRK.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/simulation/elements/FWRK.cpp b/src/simulation/elements/FWRK.cpp index f05db69..a16fbc6 100644 --- a/src/simulation/elements/FWRK.cpp +++ b/src/simulation/elements/FWRK.cpp @@ -83,8 +83,6 @@ int Element_FWRK::update(UPDATE_FUNC_ARGS) return 0; } } - if (parts[i].life>=45) - parts[i].life=0; if (parts[i].life<3&&parts[i].life>0) { int r = (rand()%245+11); @@ -113,8 +111,10 @@ int Element_FWRK::update(UPDATE_FUNC_ARGS) sim->kill_part(i); return 1; } + if (parts[i].life>=45) + parts[i].life=0; return 0; } -Element_FWRK::~Element_FWRK() {}
\ No newline at end of file +Element_FWRK::~Element_FWRK() {} |
