Hello Everyone,
I saw a punch of mods which allow you to deactivate personal roboports via hotkey to prevent personal robots filling up your inventory when something is deconstructed nearby.
Would it be possible to create a Mod to disable stationary roboports construction, for example by setting the construction area to 2x2?
In this way a blueprint next to me would be completed with my personal robots, it is sometimes very annoying to wait for other construction bots to carry over parts when the parts are actually in my inventory.
Maybe someone could make this mod or give some directions if it is possible.
Best wishes
Mod to disable Roboport construction via Hotkey
-
- Manual Inserter
- Posts: 1
- Joined: Wed Dec 06, 2017 7:16 pm
- Contact:
Re: Mod to disable Roboport construction via Hotkey
Something like this?terrormortis wrote:Hello Everyone,
I saw a punch of mods which allow you to deactivate personal roboports via hotkey to prevent personal robots filling up your inventory when something is deconstructed nearby.
Would it be possible to create a Mod to disable stationary roboports construction, for example by setting the construction area to 2x2?
In this way a blueprint next to me would be completed with my personal robots, it is sometimes very annoying to wait for other construction bots to carry over parts when the parts are actually in my inventory.
Maybe someone could make this mod or give some directions if it is possible.
Best wishes
Code: Select all
function active_roboports (active) -- active is bool
for i, roboport in pairs (global.roboports) do
if roboport.valid then
roboport.active = active
end
end
Re: Mod to disable Roboport construction via Hotkey
Try this one. Proof of concept.
It works now for old roboports only.
It works now for old roboports only.
- Attachments
-
- 2017-12-11 22_59_30.png (162.67 KiB) Viewed 2533 times
Re: Mod to disable Roboport construction via Hotkey
New version: you can enable/disable roboports and robots.
- Attachments
-
- GUI
- 2017-12-13 20_00_12.png (6.6 KiB) Viewed 2506 times
-
- DisableEntities_0.0.2.zip
- For 0.15
- (41.36 KiB) Downloaded 74 times
Re: Mod to disable Roboport construction via Hotkey
Yes, it's possible, but not for robots: they haven't last_user parameter.Jon8RFC wrote:This looks great and I hope to try it out when I get some free time.
Is it too difficult to add an additional function to disable on two levels? The first level would be disable only for other players' construction, so that in multi-player environments, if they're blueprinting or deconstructing, mine only work for myself. The second level would be a complete disabling.
Re: Mod to disable Roboport construction via Hotkey
I realized after I posted that this wasn't for personal robo ports and deleted the post, but you're too quick for me and managed to answer. Thanks for the information!
A follow-up, since I don't understand Lua functionality--does this mean that even though entities are blueprinted by someone else, the robots/ports can't read that parameter? I understand that a robot itself doesn't have a "last user" parameter for itself, but I'm asking for clarification regarding robots or the robo port's ability to read "last user" of entities which do support "last user".
A follow-up, since I don't understand Lua functionality--does this mean that even though entities are blueprinted by someone else, the robots/ports can't read that parameter? I understand that a robot itself doesn't have a "last user" parameter for itself, but I'm asking for clarification regarding robots or the robo port's ability to read "last user" of entities which do support "last user".
Re: Mod to disable Roboport construction via Hotkey
Robots have no API, they are too optimized and can be paused and unpaused.Jon8RFC wrote:I'm asking for clarification regarding robots or the robo port's ability to read "last user" of entities which do support "last user".