summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--server/src/entity/environment_effect.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/server/src/entity/environment_effect.rs b/server/src/entity/environment_effect.rs
index b0e811c3..4976d9a3 100644
--- a/server/src/entity/environment_effect.rs
+++ b/server/src/entity/environment_effect.rs
@@ -15,7 +15,7 @@
along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
-use super::{EntityContext, Entity};
+use super::{Entity, EntityContext};
use hurrycurry_protocol::PacketC;
use rand::random;
use serde::{Deserialize, Serialize};
@@ -54,7 +54,7 @@ impl Entity for EnvironmentEffectController {
if self.next_transition < Instant::now() {
if self.active {
self.next_transition +=
- Duration::from_secs_f32(self.config.on + (0.5 + random::<f32>()));
+ Duration::from_secs_f32(self.config.on * (0.5 + random::<f32>()));
self.active = false;
c.game.environment_effects.remove(&self.config.name);
} else {