Skip to content

Commit

Permalink
Merge pull request #68 from vasilisq/fix/freeze-superposition
Browse files Browse the repository at this point in the history
Fix/freeze superposition
  • Loading branch information
vasilisq authored Jun 5, 2017
2 parents e8907c9 + 659e235 commit 379f4fe
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions server/effects/freeze.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
let Effect = require('../core/effect');

const FREEZE_DURATION = 5;
const FREEZE_DURATION = 10;
const FREEZE_SLOW_FACTOR = 2;

/**
Expand All @@ -12,7 +12,6 @@ module.exports = class Freeze extends Effect {
constructor() {
super();
this.duration = FREEZE_DURATION;
this.__oldSpeed = null;
}

effect() {
Expand All @@ -24,6 +23,6 @@ module.exports = class Freeze extends Effect {

endEffect() {
// Возвращаем обратно
this.applicant.speed = this.__oldSpeed;
this.applicant.speed *= FREEZE_SLOW_FACTOR;
}
};
};

0 comments on commit 379f4fe

Please sign in to comment.