Navigation

    forum

    • Login
    • Search
    • Categories
    • Recent
    • Popular
    • Users
    • Groups
    1. Home
    2. Kp0ral
    3. Topics
    • Flag Profile
    • block_user
    • Profile
    • Following
    • Followers
    • Topics
    • Posts
    • Groups
    • Blog

    Topics created by Kp0ral

    • Add / Remove base Structures
      Private servers • • Kp0ral

      2
      2
      Posts
      3582
      Views

      Yes, you will be able to modify game object types, but this is still in development.
    • Creep.say including unicode
      Feature Requests • • Kp0ral

      1
      1
      Posts
      3165
      Views

      No one has replied

    • Error from using array to findClosestByPath
      Help • • Kp0ral

      4
      4
      Posts
      6259
      Views

      Concatenating together a list of the different roomobjects could work fine.  However, your array (finds) does not contain all the hostile creeps, hostile structures, etc.  What it actually contains are the constants mapped to each of those find conditions.  According to https://screeps.com/a/constants.js ,that would be:    FIND_HOSTILE_CREEPS: 103,    FIND_HOSTILE_STRUCTURES: 109,    FIND_HOSTILE_SPAWNS: 113,    FIND_HOSTILE_CONSTRUCTION_SITES: 115 So you're not handing it an array of all the hostile targets in the room, you're handing it an array with the content: [103, 109, 113, 115].  Since findClosestByPath will accept either a constant (representing one of those find conditions) or an array of roomobjects, it tries to process it as an array of roomobjects and fails.