Allow flag creation in rooms without visibility



  • It seems creating a flag requires visibility in the target room.

    Could we change that?



  • I really hope not. The way a lot of people use flags that would essentially mean that flags could replace actually needing visibility, which they kind of already do.


  • Culture

    You can, it just takes two ticks.

    1) Create the flag in a room you have visibility to,

    2) Use the `flag.setPosition(pos)` method to move the flag where ever you want.

    3) Profit!



  • Such a change would be consistent with the GUI capabilities.

    I always found it a bit curious that I'm able to create a flag using the GUI in a room I don't have vision in, but that my scripts don't have that same capability. (Unless you use the 'hack' tedivm mentioned).


  • Dev Team

    Unfortunately, it's a limitation regarding how inactive rooms are processed. We'll try to find the solution for this.



  • Tedivm, thanks. I hadn't thought of that.

     

    Thanks artem, take your time.



  • Is this still the status quo? It seems as if it is.

     

    Edit: Did some testing and uhh, moving the flag either deletes it, returns success, or returns success and does nothing. Sometimes it actually works, but that's a rarity.



  • Since the implementation of visuals, I've moved away from flags almost entirely. I only have flags left for direct control of military strategies.

    I would suggest the same. Flags are a dead end.



  • OCS is tracking some detail about how this API works: https://github.com/ScreepsOCS/screeps.behaviour-action-pattern/issues/894

    There's a special flag which I move to W0N0 @ 49,49

    basically you get a 40-50 tick delay when you move a flag to a room without vision. This is more or less consistent for many different players.