Fix CS
This commit is contained in:
parent
2484e4f1df
commit
d48d5b0285
5 changed files with 16 additions and 15 deletions
|
@ -18,7 +18,7 @@ export class ActionableItem {
|
|||
* OR null if we are out of range.
|
||||
*/
|
||||
public actionableDistance(x: number, y: number): number|null {
|
||||
let distanceSquared = (x - this.sprite.x)*(x - this.sprite.x) + (y - this.sprite.y)*(y - this.sprite.y);
|
||||
const distanceSquared = (x - this.sprite.x)*(x - this.sprite.x) + (y - this.sprite.y)*(y - this.sprite.y);
|
||||
if (distanceSquared < this.activationRadiusSquared) {
|
||||
return distanceSquared;
|
||||
} else {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue