[MOD 0.16] Bulk Rail Loaders
Re: [MOD 0.16] Bulk Rail Loaders
I think I screwed up my game. I've modified the rail loaders so that there is a lager version (railloader mk II) but I had a bug in the pattern matching to detect the new entities. Now I think one of the inserters are placed wrong. The effect I'm seeing is that something constantly takes something out of the unloader and puts it back in. Worse, if a train is present, it sometimes puts the items back in the train and then out again. So the train never gets 2s inactivity and never leaves.
I fixed the code but now I have to deconstruct every loader/unloader and place them again. And most have items in them making that a huge problem.
Is there a mod function I can trigger to remove and rebuild all the hidden entities of the railloader and unloader?
I fixed the code but now I have to deconstruct every loader/unloader and place them again. And most have items in them making that a huge problem.
Is there a mod function I can trigger to remove and rebuild all the hidden entities of the railloader and unloader?
Re: [MOD 0.16] Bulk Rail Loaders
Unfortunately there isn’t. The function that creates the inserters also creates the chest.
If you’re not going for mod achievements it’s probably possible to fix through the console, but it’s hard for me to tell from here exactly what went wrong.
You could script moving the contents of each railloader into a chest, then mining/rebuilding, then moving the chestcontents back into the new railloader.
Miniloader — UPS-friendly 1x1 loaders
Bulk Rail Loaders — Rapid train loading and unloading
Beltlayer & Pipelayer — Route items and fluids freely underground
Bulk Rail Loaders — Rapid train loading and unloading
Beltlayer & Pipelayer — Route items and fluids freely underground
Re: [MOD 0.16] Bulk Rail Loaders
I was hoping you already have some function that would find all chests and for each recreate or update the hidden entities. But I'm sure I can script something and then have the mod call it once on the next load.Therax wrote: ↑Tue Jun 11, 2019 4:03 pmUnfortunately there isn’t. The function that creates the inserters also creates the chest.
If you’re not going for mod achievements it’s probably possible to fix through the console, but it’s hard for me to tell from here exactly what went wrong.
You could script moving the contents of each railloader into a chest, then mining/rebuilding, then moving the chestcontents back into the new railloader.
Re: [MOD 0.16] Bulk Rail Loaders
In control.lua in the on_blueprint function you build an array of all the directions of bulk rail loader and unloader chests by looking at the direction of the rails below the chest. Then in a second loop you create placement proxies for each chest. Problem is that if the first loop doesn't find any rails then you don't add an entry in the directions array so the second loop will a) get out of sync and b) overflow the array dimensions. I fixed that by adding a dummy direction when no rail is found:
Code: Select all
diff --git a/railloader_0.6.1/control.lua b/railloader_0.6.1/control.lua
index c22ee5f..3e53fe0 100644
--- a/railloader_0.6.1/control.lua
+++ b/railloader_0.6.1/control.lua
@@ -309,6 +309,8 @@ local function on_blueprint(event)
}[1]
if rail then
directions[#directions+1] = rail.direction
+ else
+ directions[#directions+1] = 0
end
end
end
Re: [MOD 0.16] Bulk Rail Loaders
You should never have a BRL without rails underneath it. When a BRL is built the rails are created automatically and made unminable. If something is breaking that setup that’s a bug in whatever is breaking it.
Miniloader — UPS-friendly 1x1 loaders
Bulk Rail Loaders — Rapid train loading and unloading
Beltlayer & Pipelayer — Route items and fluids freely underground
Bulk Rail Loaders — Rapid train loading and unloading
Beltlayer & Pipelayer — Route items and fluids freely underground
Re: [MOD 0.16] Bulk Rail Loaders
Sure, it shouldn't happen. But it can happen or you wouldn't check for it. I think it can happen with waterfill as that drowns even unminable entities.
Re: [MOD 0.16] Bulk Rail Loaders
Actually, I check for it because chests don't have a concept of direction, they always point "north." So I need to know the direction of the rails underneath to know what direction the BRL in the blueprint should be facing. I always expect a rail to be present. Anything like Waterfill that destroys the (unminable, undamageable) rail would almost certainly destroy the overlapping main chest entity as well.
Miniloader — UPS-friendly 1x1 loaders
Bulk Rail Loaders — Rapid train loading and unloading
Beltlayer & Pipelayer — Route items and fluids freely underground
Bulk Rail Loaders — Rapid train loading and unloading
Beltlayer & Pipelayer — Route items and fluids freely underground
Re: [MOD 0.16] Bulk Rail Loaders
I know why you look for the rail. That's not what I'm talking about. It's the "if rail then" part. You expect that you might not find a rail. As long as there is an "if rail then" there must be an "else" for the code to be correct.Therax wrote: ↑Mon Jun 17, 2019 4:56 amActually, I check for it because chests don't have a concept of direction, they always point "north." So I need to know the direction of the rails underneath to know what direction the BRL in the blueprint should be facing. I always expect a rail to be present. Anything like Waterfill that destroys the (unminable, undamageable) rail would almost certainly destroy the overlapping main chest entity as well.
Re: [MOD 0.16] Bulk Rail Loaders
Sorry, you are correct. I misunderstood what you were saying. How did you discover the bug? Did you have a situation where you blueprinted a BRL which had no rails? How did that come about?
Miniloader — UPS-friendly 1x1 loaders
Bulk Rail Loaders — Rapid train loading and unloading
Beltlayer & Pipelayer — Route items and fluids freely underground
Bulk Rail Loaders — Rapid train loading and unloading
Beltlayer & Pipelayer — Route items and fluids freely underground
Re: [MOD 0.16] Bulk Rail Loaders
As mentioned I expanded the mod to have a loader mkII with bigger chest. I broke lots of things while adding that. I think I discovered it there.
-
- Burner Inserter
- Posts: 8
- Joined: Tue Jan 16, 2018 4:51 pm
- Contact:
Re: [MOD 0.16] Bulk Rail Loaders
Hi,
When BRL is used with other mod :
Bio-Industries
Bob's Functions Library
Bob's Logistics
The standard recipe for rail is removed.
Instead it's replace with "Wooden straight rail".
So the BRL beacame uncraftable due to that.
I'dont really know who is reponsible for the disapearance of the vanilla rail...
Thanks for reading.
When BRL is used with other mod :
Bio-Industries
Bob's Functions Library
Bob's Logistics
The standard recipe for rail is removed.
Instead it's replace with "Wooden straight rail".
So the BRL beacame uncraftable due to that.
I'dont really know who is reponsible for the disapearance of the vanilla rail...
Thanks for reading.
Re: [MOD 0.16] Bulk Rail Loaders
Bio-Industries doesn't remove the vanilla rail, but it is the advanced version of rails. You can upgrade wooden straight rails to regular rails by crafting them with stone bricks.MoiAimeBien wrote: ↑Sun Jun 30, 2019 10:50 am Hi,
When BRL is used with other mod :
Bio-Industries
Bob's Functions Library
Bob's Logistics
The standard recipe for rail is removed.
Instead it's replace with "Wooden straight rail".
So the BRL beacame uncraftable due to that.
I'dont really know who is reponsible for the disapearance of the vanilla rail...
Thanks for reading.
Miniloader — UPS-friendly 1x1 loaders
Bulk Rail Loaders — Rapid train loading and unloading
Beltlayer & Pipelayer — Route items and fluids freely underground
Bulk Rail Loaders — Rapid train loading and unloading
Beltlayer & Pipelayer — Route items and fluids freely underground
Re: [MOD 0.16] Bulk Rail Loaders
It also adds a new tech for the advanced rails so you need to do some more research before you can build BRLs.Therax wrote: ↑Sun Jun 30, 2019 5:20 pmBio-Industries doesn't remove the vanilla rail, but it is the advanced version of rails. You can upgrade wooden straight rails to regular rails by crafting them with stone bricks.MoiAimeBien wrote: ↑Sun Jun 30, 2019 10:50 am Hi,
When BRL is used with other mod :
Bio-Industries
Bob's Functions Library
Bob's Logistics
The standard recipe for rail is removed.
Instead it's replace with "Wooden straight rail".
So the BRL beacame uncraftable due to that.
I'dont really know who is reponsible for the disapearance of the vanilla rail...
Thanks for reading.
Personally I've edited the BRLs to have a wooden rail recipe. I should really polish the changes and send them as patch. Currently the new recipes are unconditional which needs to change. Here is what I made:
1) BRLs mk I: needs wooden rails, smaller inventory
2) BRLs mk II: needs rails (mk II), normal inventory
3) BRLs mk III: needs BRL mk II + warehouse, extra large inventory
Re: [MOD 0.16] Bulk Rail Loaders
I'm probably a bit thick here but I can't get the unloaders to move the unloaded stuff. Here there's some stone in the unloader but how does it get from there?
Re: [MOD 0.16] Bulk Rail Loaders
Inserters like from every container?
The mod miniloaders can fill the belts with full throughput.
Re: [MOD 0.16] Bulk Rail Loaders
Ah yes - I'll go with them. Thanks for the pointer Steinio. Just noticed we joined these forms same day. But I ain't added much...
Re: [MOD 0.16] Bulk Rail Loaders
Ha, better few but quality content then a lot nonsense like the most of my posts
Re: [MOD 0.16] Bulk Rail Loaders
BLR don't load to rail wagon with filters
I think that the reason for this icreased inserter stack size. My theory - internal inserter have items but can't put in inventory.
Save: https://yadi.sk/d/els-xQlmtyiPpw
P.S. Sorry for english
I think that the reason for this icreased inserter stack size. My theory - internal inserter have items but can't put in inventory.
Save: https://yadi.sk/d/els-xQlmtyiPpw
P.S. Sorry for english
Re: [MOD 0.16] Bulk Rail Loaders
Is it possible for BRLs to respect slot limiting when blueprinting? Trying to limit the massive inventories to a single rail car worth, but it doesn't seem to save in blueprints
Re: [MOD 0.16] Bulk Rail Loaders
Yes, it’s possible. It’s even been on my todo list for a while, but just haven’t gotten around to it. I’ll have another look and see how much work it will take.
Miniloader — UPS-friendly 1x1 loaders
Bulk Rail Loaders — Rapid train loading and unloading
Beltlayer & Pipelayer — Route items and fluids freely underground
Bulk Rail Loaders — Rapid train loading and unloading
Beltlayer & Pipelayer — Route items and fluids freely underground