screeps
screeps copied to clipboard
Layout code runs every tick in impossible rooms
548 | Executing room failed: W57S2 Error: Can't set layout for room W57S2. Not enough space for filler area Error: Can't set layout for room W57S2. Not enough space for filler area
In addition to spamming me with email notifications, this failure also ate up my cpu bucket because the layout code was running every tick. Maybe upon a failure it should wait for a while before trying again?
if this is really impossible room - we can only unclaim it and try something else the error is for human interaction to check, if algorithm is correct. Can you give me a screenshot with paths?
I should mention that I'm using the mineral PR that's going to merge tomorrow. However, that's not relevant here, because this failure could happen in a very cramped room even with the current code.
I can't screenshot the paths because I already modified my code to put the upgrader farther from the controller to fix this room.
as I remember in current code there will be no exception. room layout will just fail silently, and you'll figure it out only on RCL 4
As mentioned in slack, if you can provide the room (room data) I will try to include rooms in the private server test. So that we check further room layout changes in such rooms.
Shard 1, room W57S2. I don't know how to turn the room into parseable data, but you should be able to duplicate just the immediate neighborhood of the controller for testing purposes?

Will have to look into that, too. If it is on the public server I will find a way. I have to make sure that the exits are at the same place, will need to check how to do that :-)
Another room faced with the same problem: shard1, W15N41

oh shirt) I'm not sure it's possible to handle this room even if we move upgrader 3 tiles far from controller
kahojyun's example would work with the upgrader 2-3 tiles northeast of the controller. I think my current code would put it 2E3N from the controller.
However, this issue is not the right place to discuss fixing a specific layout failure. #437 is the right place to move this discussion. THIS issue is just about making the script not try to do layout every tick and throw an error every tick, regardless of which part of layout fails.