Start using IDs instead of element objects

This commit is contained in:
Vortrex
2022-05-31 08:35:40 -05:00
parent eabf63cf86
commit ee014b2578
4 changed files with 15 additions and 18 deletions

View File

@@ -163,12 +163,6 @@ function clearLocalPlayerWeapons(clearData) {
// ===========================================================================
function getClosestVehicle(pos) {
return getElementsByType(ELEMENT_VEHICLE).reduce((i, j) => (i.position.distance(pos) < j.position.distance(pos)) ? i : j);
}
// ===========================================================================
function setLocalPlayerPosition(position) {
logToConsole(LOG_DEBUG, `[VRR.Utilities] Setting position to ${position.x}, ${position.y}, ${position.z}`);
if(typeof localPlayer.velocity != "undefined") {