getObjectInitialWidth
Definition
-- @/=[C]:-1
function getObjectInitialWidth(...)
Callers
@/lua/vehicle/extensions/tech/ACC.lua
upB:normalize()
local widthB, lengthB = obj:getObjectInitialWidth(k), obj:getObjectInitialLength(k) -- The other vehicle's dimensions.
local frontB = obj:getObjectFrontPosition(k) -- The other vehicle's front/rear bumper midpoint positions.
@/lua/vehicle/controller/tech/idealRADARSensor.lua
upB:normalize()
local widthB, lengthB = obj:getObjectInitialWidth(k), obj:getObjectInitialLength(k) -- The other vehicle's dimensions.
local frontB = obj:getObjectFrontPosition(k) -- The other vehicle's front/rear bumper midpoint positions.
@/lua/vehicle/ai.lua
local y = z:cross(x)
y:setScaled(obj:getObjectInitialWidth(id) * 0.5 / max(y:length(), 1e-30))
x:setScaled(obj:getObjectInitialLength(id) * 0.5)
-- Scale bounding box direction vectors to vehicle diamensions
twt.OBBinRange[i+3]:setScaled(obj:getObjectInitialWidth(id) * 0.5)
twt.OBBinRange[i+2]:setScaled(obj:getObjectInitialLength(id) * 0.5)
v.length = obj:getObjectInitialLength(plID) + 0.3
v.width = obj:getObjectInitialWidth(plID)
local posFront = obj:getObjectFrontPosition(plID)
v.length = obj:getObjectInitialLength(plID) + 0.3
v.width = obj:getObjectInitialWidth(plID)
local posFront = obj:getObjectFrontPosition(plID)
if dist1 > max(radii[wp1], radii[wp2]) + ego.width and dist2 > max(radii[plwp1], radii[plwp2]) + obj:getObjectInitialWidth(player.id) then
internalState.road = 'offroad'
@/lua/vehicle/extensions/tech/platooning.lua
upB:normalize()
local widthB, lengthB = obj:getObjectInitialWidth(k), obj:getObjectInitialLength(k) -- The other vehicle's dimensions.
local frontB = obj:getObjectFrontPosition(k) -- The other vehicle's front/rear bumper midpoint positions.