Robot Recall V2


Lets you recall all robots in your network

Utilities
6 months ago
2.0
562
Logistic network

b LuaEntity API call when LuaEntity was invalid

5 months ago

I rarely see this message:

33622.858 Error MainLoop.cpp:1435: Exception at tick 166877290: The mod Robot Recall V2 (0.3.2) caused a non-recoverable error.
Please report this error to the mod author.

Error while running event robot-recall-v2::on_nth_tick(10)
LuaEntity API call when LuaEntity was invalid.
stack traceback:
    [C]: in function '__index'
    __robot-recall-v2__/control/robot-recall.lua:404: in function 'updateTeleportJobs'
    __robot-recall-v2__/control/robot-recall.lua:562: in function <__robot-recall-v2__/control/robot-recall.lua:560>

Maybe some var.valid check needs to be added?

5 months ago
(updated 5 months ago)

A few lines above:
if ((not e.destination or not e.destination.valid)) then
But in comment also source is being checked while this code checks only destination?

5 months ago
(updated 5 months ago)

After I added a check for not e.source or not e.source.valid in that line, I got another crash, the API function surface.spill_item_stack() does now take only one parameter, you have to do a few things to get it working:
e.surface.spill_item_stack({position=e.srcPos, stack={name=e.itemname, count=count}, allow_belts=false})
I have added the optional parameter allow_belts so items won't be dropped on active belts which then transport the dropped item away.

EDIT: No, then no bot is being collected. :-( I need an other fix here.

5 months ago

And I noticed that when a bot has higher quality, a normal bot is being deployed instead.

5 months ago
(updated 5 months ago)

Ah, the invocation of v.ent.surface.create_entity() must be expanded with quality. EDIT: Included in PR!

5 months ago

And the GUI for recall chest misses quality separation, e.g. recall only "low-quality" bots, but not current wanted quality.

5 months ago

I have fixed many pressing issues in my fork: https://github.com/Quix0r/robot-recall-v2 If you like, I can send you a PR?

New response