Changes

equipment_armor
Line 664: Line 664:  
function ShipData:range()
 
function ShipData:range()
 
return self._range
 
return self._range
 +
end
 +
 +
function ShipData:equipment_armor()
 +
    local armor = 0
 +
    for i = 1, self:slots_length() or 0 do
 +
        local equipment = self:slot(i)
 +
        if equipment then
 +
            armor = armor + equipment:armor()
 +
        end
 +
    end
 +
    return armor
 
end
 
end
  
cssedit, gkautomate
7,064

edits