Factories, new resources, NPC Strongholds


  • Dev Team

    UPDATE:

    Lesser cores spawn interval now depends on stronghold level:

    • Level 1: 4000 ticks
    • Level 2: 3500 ticks
    • Level 3: 3000 ticks
    • Level 4: 2500 ticks
    • Level 5: 2000 ticks
    👍


  • @artch this makes all the sense.



  • Some things looks strange to me with the store refactoring, is that intentional:

    • Using getCapacity with a not valid resource returns null, while using getUsedCapacity with the same resource returns 0.

      extension.store.getCapacity("power") // => null
      extension.store.getUsedCapacity("power") // => 0
      

      It seems inconsistent to me, maybe it should be aligned on one or the other behavior (I personally think returning 0 in both cases makes more sense, but the spec/doc seems to expect null in both cases).

    • Using getCapacity on tombstones returns null (I guess it is the same for ruins).
      I think there is actually no limit, so returning Number.MAX_SAFE_INTEGER or Infinity would make more sense and be more useful.
      For example, having this behavior looks inconsistent to me:

      tombstone.store.getUsedCapacity("energy") // => 500
      tombstone.store.getCapacity("energy") // => null (even though there is actually some energy in the tombstone...)
      

      Note that mostly, the issue is that when getting null, we don't know if the store does not accept this resource at all, or if the limit is actually infinity. So if my first point is taken into account so that getCapacity returns 0 when the store does not accept the resource, then it would be kind of ok to keep null for infinity...



  • Since invader cores are hostile structures in room, we should be allowed to dismantle them.



  • @warinternal TBH I agree. I don't think that dismantle not working on the core adds anything to the game besides not allowing miners to attack it, and it's a needless complexity. You can attack all room structures except this one means that there will be a lot of special cases in people's usual cleanup code.


  • Dev Team

    Power Banks are structures also, and you also cannot dismantle them. You can only dismantle what you can construct. Dismantling returns energy which someone else spent for construction. If there was no energy spent, dismantle should not work.

    Think of it as a method to "disassemble" some piece of tech about which you know how it's assembled. If that's some weird tech like Invader Core which you cannot assemble, you don't have enough knowledge to disassemble it properly, you can only break it.



  • Invader cores can also apparently overlap structures

    0_1571686182512_6ce7e0c4-4393-478f-854b-a6227b3b7de0-image.png


  • Dev Team

    @warinternal weird, where is it?



  • @o4kapuk That's in shard0 E55S37



  • @artch I like that explanation. However how does Shield fit into that? No energy spent, no energy returned, but dismantle works.

    From a gameplay perspective the invader cores not allowing dismantle makes perfect sense to make them require a non-eco creep to deal with them.

    Does dismantle work on tombstones/ruins? I always thought of dismantle as kinda like bulldozing everything down and picking up the scraps.


  • Dev Team

    @davaned However how does Shield fit into that? No energy spent, no energy returned, but dismantle works.

    Power-created entities are meant to be "magic" exceptions.

    Does dismantle work on tombstones/ruins? I always thought of dismantle as kinda like bulldozing everything down and picking up the scraps.

    It does not work on tombstones/ruins.

    Dismantle returns 50% of the energy spent (for walls/ramparts). It's not just "scraps", it's a lot. Imagine if you disassemble a house and retrieve back every other item from it in a reusable condition. It cannot be done by a bulldozer, it requires accuracy and skills.



  • @artch As we think about newer players. It was a little counter intuitive to discover that reservation cores cannot be dismantled and can only be attacked. I understand why because you could just simply have all of your drillers engage reservation cores but a design theme for screeps has been to dismantle structures and to attack living things. It may be too late to change it now but if the reservation cores were a living (and stationary) invader vs a stationary structure then newer players more easily see that dismantling it won't work.



  • @artch Will this 10% variation on stronghold decays be added to the constants in the documentation?

    Also the current value for stronghold_decay_ticks still says 150000 vs 75000 in the constants of the docs



  • A couple ideas:

    Stronghold Loot Levels: Have greater variance in loot. Similar to mineral patches, lootboxes etc, you want to have highs and lows. If you very occasionally have a L3 SH spawn with a T5 commodity lower level players can get excited and try to crack something that might be a stretch for them. It also makes them less of a pure loot farm mechanic for a player who has "solved" them, they can do some math around expected expenditure vs reward etc.

    An idea for a new L1 so that there is a reason to empower factories even if you don't want to take on the commodities.

    Enriched Power (ER)

    Factory T1 item: 100 power and 5000 energy, cd 700.

    1 ER = 100 power and can be uncompressed in a factory (PS?) to gain processed power to their account. Give new players a way to acquire some early power levels for factories easier, and a new trade item. Alternatively, could offer a smaller energy cost than processing but an extremely long cd.

    An odd behavior: https://screeps.com/a/#!/history/shard2/W24N54?t=19920555 Invaders killed off the ramparts of a stronghold deploying. Is this intended?



  • Hi,

    Im using typescript, and i cant find updates of @types/screeps reflecting the API changes. what can i do ?


  • Dev Team

    @chuckingame you can find the maintainers (probably at #screepers) and ask them to update the package. Or help them to do it.



  • @chuckingame said in Factories, new resources, NPC Strongholds:

    Hi,

    Im using typescript, and i cant find updates of @types/screeps reflecting the API changes. what can i do ?

    According to https://github.com/screepers/typed-screeps/:

    As of 29 Oct 19, the published version on npm is out of date, and the project is currently updating to reflect the latest Screeps changes. If you wish to use these types, it is currently recommended that you copy the current typings manually.



  • @jbyoshi thanks, that works for me



  • This post is deleted!