relocation
This commit is contained in:
parent
b1501d7251
commit
539f227dba
1 changed files with 4 additions and 0 deletions
|
@ -1,3 +1,7 @@
|
||||||
|
if (!crypto) {
|
||||||
|
crypto = import('node:crypto');
|
||||||
|
}
|
||||||
|
|
||||||
function distF(ent, target) {
|
function distF(ent, target) {
|
||||||
return ((ent.pos.x - target.pos.x) ** 2) + ((ent.pos.y - target.pos.y) ** 2)
|
return ((ent.pos.x - target.pos.x) ** 2) + ((ent.pos.y - target.pos.y) ** 2)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue