• Welcome to the Kancolle Wiki!
  • If you have any questions regarding site content, account registration, etc., please visit the KanColle Wiki Discord

Changes

Jump to navigation Jump to search
m
optimize
Line 199: Line 199:  
      
 
      
 
     local selectInstallation = stringKey('installation', context, n, ''):lower()
 
     local selectInstallation = stringKey('installation', context, n, ''):lower()
     local predInstallation = function(e)
+
     local predInstallation = selectInstallation == 'yes' and
        if selectInstallation == 'yes' then
+
        function(e) return e._speed == 0 end
            return e._speed == 0
+
         or selectInstallation == 'no' and
         elseif selectInstallation == 'no' then
+
        function(e) return e._speed ~=0 end
            return e._speed ~= 0
+
         or
         else
+
        function(e) return true end
            return true
  −
        end
  −
    end
   
      
 
      
 
     local selectBoss = stringKey('boss', context, n, ''):lower()
 
     local selectBoss = stringKey('boss', context, n, ''):lower()
     local predBoss = function(e)
+
     local predBoss = selectBoss == 'yes' and
        if selectBoss == 'yes' then
+
        function(e) return e._back <= -11 end
            return e._back <= -11
+
         or selectBoss == 'no' and
         elseif selectBoss == 'no' then
+
        function(e) return e._back >= -10 end
            return e._back >= -10
+
         or
         else
+
        function(e) return true end
            return true
  −
        end
  −
    end
   
      
 
      
 
     return Iterator.enemiesBy(context, n, function(e)
 
     return Iterator.enemiesBy(context, n, function(e)
         return (e:type() == type or type == 0)
+
         return e._hp -- skip unimplemented units
        and e._hp -- skip unimplemented units
+
        and (e:type() == type or type == 0)
 
         and predInstallation(e)
 
         and predInstallation(e)
 
         and predBoss(e)
 
         and predBoss(e)
Anonymous user

Navigation menu