mirror of
https://github.com/renorris/openfsd
synced 2026-05-02 06:35:38 +08:00
only do velocity distance calculation for relevant clients
This commit is contained in:
@@ -98,7 +98,7 @@ func (p *postOffice) search(client *Client, callback func(recipient *Client) boo
|
||||
return true // Ignore self
|
||||
}
|
||||
|
||||
if foundClient.protoRevision == 101 {
|
||||
if !client.isAtc && client.protoRevision == 101 && foundClient.protoRevision == 101 {
|
||||
clientLatLon := client.latLon()
|
||||
foundClientLatLon := foundClient.latLon()
|
||||
dist := distance(clientLatLon[0], clientLatLon[1], foundClientLatLon[0], foundClientLatLon[1])
|
||||
|
||||
Reference in New Issue
Block a user