VE Lua Documentation

Press F to search!

getNodeMass

Definition


-- @/=[C]:-1
function getNodeMass(...)

Callers

@/lua/vehicle/bdebugImpl.lua
        local node = v.data.nodes[i]
        local nodeWeight = obj:getNodeMass(node.cid)
        local nodeText = getNodeText(node, string.format("%.2fkg", nodeWeight))

        local nodeMass = obj:getNodeMass(node.cid)

        local r = (obj:getNodeMass(node.cid) / (totalWeight / nodesCount)) ^ 0.4 * 0.05
        if nodeMass >= rangeMin and nodeMass <= rangeMax then
@/lua/vehicle/extensions/vehicleeditor/nodes.lua
  for _,node in pairs(nodesTbl) do
    totalWeight = totalWeight + obj:getNodeMass(node.cid)
    if obj:getNodeMass(node.cid) > max then max = obj:getNodeMass(node.cid) end
    totalWeight = totalWeight + obj:getNodeMass(node.cid)
    if obj:getNodeMass(node.cid) > max then max = obj:getNodeMass(node.cid) end
    if obj:getNodeMass(node.cid) < min then min = obj:getNodeMass(node.cid) end
    totalWeight = totalWeight + obj:getNodeMass(node.cid)
    if obj:getNodeMass(node.cid) > max then max = obj:getNodeMass(node.cid) end
    if obj:getNodeMass(node.cid) < min then min = obj:getNodeMass(node.cid) end
    if obj:getNodeMass(node.cid) > max then max = obj:getNodeMass(node.cid) end
    if obj:getNodeMass(node.cid) < min then min = obj:getNodeMass(node.cid) end
  end
    if obj:getNodeMass(node.cid) > max then max = obj:getNodeMass(node.cid) end
    if obj:getNodeMass(node.cid) < min then min = obj:getNodeMass(node.cid) end
  end
@/lua/vehicle/controller/tech/advancedIMU.lua
  -- Get the kinematics properties at each triangle corner.
  local m1, m2, m3 = obj:getNodeMass(state.node1Idx), obj:getNodeMass(state.node2Idx), obj:getNodeMass(state.node3Idx) -- Node masses.
  a1:setScaled2(obj:getNodeForceVector(state.node1Idx), 1.0 / m1) -- Compute acceleration at each node, using Newton II [a := F / m].
  -- Get the kinematics properties at each triangle corner.
  local m1, m2, m3 = obj:getNodeMass(state.node1Idx), obj:getNodeMass(state.node2Idx), obj:getNodeMass(state.node3Idx) -- Node masses.
  a1:setScaled2(obj:getNodeForceVector(state.node1Idx), 1.0 / m1) -- Compute acceleration at each node, using Newton II [a := F / m].
  -- Get the kinematics properties at each triangle corner.
  local m1, m2, m3 = obj:getNodeMass(state.node1Idx), obj:getNodeMass(state.node2Idx), obj:getNodeMass(state.node3Idx) -- Node masses.
  a1:setScaled2(obj:getNodeForceVector(state.node1Idx), 1.0 / m1) -- Compute acceleration at each node, using Newton II [a := F / m].
@/lua/vehicle/extensions/tech/mesh.lua
    nodes[i][3]:set(obj:getNodeVelocityVector(i))
    nodes[i][4] = obj:getNodeMass(i)
    nodes[i][5] = partOrigins[i]
@/lua/vehicle/controller/tech/mesh.lua
        velX = vel.x, velY = vel.y, velZ = vel.z,
        mass = obj:getNodeMass(i) }
  end
@/lua/vehicle/tech/techVehicleUtils.lua
    local r = obj:getAbsNodePosition(cid)
    local m = obj:getNodeMass(cid)
    local isWheelNode = n.wheelID ~= nil
    local pos = obj:getAbsNodePosition(cid)
    local mass = obj:getNodeMass(cid)
    local info = {
@/lua/vehicle/beamstate.lua
    local d = {obj:getNodePosition(node.cid):toTable()}
    if math.abs(obj:getOriginalNodeMass(node.cid) - obj:getNodeMass(node.cid)) > 0.1 then
      table.insert(d, obj:getNodeMass(node.cid))
    if math.abs(obj:getOriginalNodeMass(node.cid) - obj:getNodeMass(node.cid)) > 0.1 then
      table.insert(d, obj:getNodeMass(node.cid))
    end