1
0
mirror of https://github.com/metrostroi-repo/MetrostroiAddon.git synced 2026-05-02 00:42:29 +00:00

Merge pull request #507 from metrostroi-repo/#10

#10 Distance -> DistToSqr
This commit is contained in:
CrIcKeT98
2022-07-12 02:19:19 +03:00
committed by GitHub
9 changed files with 10 additions and 10 deletions

View File

@@ -256,7 +256,7 @@ function ENT:Think()
local target = Vector(0,0,0)
for j=1,count do
local vec = self:GetNW2Vector("TrainDoor"..j,Vector(0,0,0))
local d = vec:Distance(self.ClientModels[i]:GetPos())
local d = vec:DistToSqr(self.ClientModels[i]:GetPos())
if d < distance then
target = vec
distance = d