Creep.transfer returns wrong value



  • Hello, I think I've found a bug. This code

    console.log("Putting in storage");
    var logv = creep.transfer(creep.room.storage, RESOURCE_ENERGY);
    console.log(logv);
    if(logv == ERR_NOT_IN_RANGE) {
      console.log("Going to storage");
      creep.moveTo(creep.room.storage);
    }

    Shows "Putting in storage" followed by "0" also when the storage is out of range.

    It happens on shard1, following there is room history. It seems that works only when the spawns are full.
    Recently I've made Observer and Power Spawn construction sites, maybe that's the problem. There aren't any other places where that log can come from. I've also tried to use legacy (shared) VM, no changes.
    What do you think about this problem?
    Sadly enough I can't be active in the forum.

    Good game and goodbye - MrFasolo97