Jump to content

[General] - Component playerprox not properly detecting player leave


Ryuushu

Recommended Posts

Bug Submission:

Category: General
Issue Title: Component playerprox not properly detecting player leave
Issue Description: As the title says, the component playerprox isn't detecting players leaving the area (TargetMode = AnyPlayer) due to a comparison error on line 19:

elseif not IsAnyPlayerInRange(x, y, z, self.far) == nil then

This line will always return true since IsAnyPlayerInRange returns either true or false. This was probably changed in one of the recent updates because playerprox used to use FindAnyTargetablePlayerInRange, which returns the first player found in the desired range.

The Solution:
Remove the == nil comparison in line 19, in playerprox:

elseif not IsAnyPlayerInRange(x, y, z, self.far) then

That'll work just as expected.

Steps to Reproduce:
1. Start/join a server
2. Find a wormhole
3. Get close enough so it opens.
4. Run away from it.
5. Keep running.
6. Notice how it never closes.

Archived

This topic is now archived and is closed to further replies.

Please be aware that the content of this thread may be outdated and no longer applicable.

×
  • Create New...