Re: [Mod 0.11.x] Rail Tanker - Liquid transport
Posted: Tue Jan 06, 2015 11:39 am
I hope that it can upload a copy on here because I can't link to google drive easily.
www.factorio.com
https://forums.factorio.com/
That works for me, thank you.JamesOFarrell wrote:You can change this by editing prototypes\entity\entities.lua. Lines 59 and 119 need to be uncommentated and you need to comment line 60 and 118Narc wrote:I noticed v0.0.7 restored the tiny size of the invisible tank -- problem is, I rather liked the larger one, as it made it easier to check on the tanker car's contents.
All right, thanks.JamesOFarrell wrote:Nothing good comes from aligning the thing to the grid, as trains can move less than a tiles space things go funky. There are better solutions than the one I've chosen and I'll eventually change it but for the moment it works.Narc wrote:Also, is there any way to force the invisible tank to align to grid? I haven't looked into Factorio modding at all, but it really should be feasible.
The sprites raise the mod over the forums attachment limit, sorry.dyf123 wrote:I hope that it can upload a copy on here because I can't link to google drive easily.
The rail tanker should have 600HP. If that's not the case try using the latest version. Unless you are talking about the invisible storage tank, that has 1HP but nothing should be able to interact with it.UntouchedWagons wrote:Can you give the tanker more health? 1HP isn't enough.
Yeah well I've lost two full tanker cars from bumping into them to connect them to my train.JamesOFarrell wrote:The rail tanker should have 600HP. If that's not the case try using the latest version. Unless you are talking about the invisible storage tank, that has 1HP but nothing should be able to interact with it.
Are you using 0.0.8? If you build a new one what is its health set to?UntouchedWagons wrote:Yeah well I've lost two full tanker cars from bumping into them to connect them to my train.
Sure, all my mods are licensed under the MIT license so do with them as you wish.delfiler wrote:can i add your mod to a modpack?
oh that won't be needed just gonna add it to my mod pack of handy modsJamesOFarrell wrote:Sure, all my mods are licensed under the MIT license so do with them as you wish.
Also, if you want the blender files so you can extend the mod let me know and I'll upload them somewhere
Does this work with the The Fat Controller? I have both the latest of the 2 but I can't see anything data wise from the liquids.Choumiko wrote:Could you add an interface for other mods to get the stored liquid when the train is stopped? I managed to get the following to work: (added at the end of control.lua)Should even work when the train is moving, not sure though, i simply tried until it workedCode: Select all
remote.addinterface("railtanker", { getLiquidByWagon = function(wagon) local tanker = getTankerFromEntity(glob.tankers, wagon) local res = nil reattachProxy(tanker) if tanker.entity.name == "rail-tanker" then if tanker.proxy ~= nil then if tanker.proxy.fluidbox[1] ~= nil then res = {amount = tanker.proxy.fluidbox[1].amount, type = tanker.proxy.fluidbox[1].type} else res = {amount = 0, type = nil} end else if tanker.fluidbox ~= nil then res = {amount = tanker.fluidbox.amount, type = tanker.fluidbox.type} else res = {amount = 0, type = nil} end end end return res end }
While looking at your code i think i found a typo: Line 42 is tanker.proxy = bil should be nil i guess
You would need to find the function in FAT controller where it gathers the data and tweak it to use the interface for railtanker wagonsKane wrote:Does this work with the The Fat Controller? I have both the latest of the 2 but I can't see anything data wise from the liquids.
I changed the selectionbox in prototypes/entity/entities.lua to the one that has been commented outKane wrote:Just wondering if there was or is going to be some sort of tool tip to see how much liquid is inside the tanker. Someone said they thought it had in the past but now is broken. They said you had to sort of find the "right spot" to see it's liquid amount.
Code: Select all
selection_box = {{-1.0, -1.0}, {1.0, 1.0}},
--selection_box = {{-0.5, -0.5}, {0.5, 0.5}},
I don't exactly understand the situation, but:Choumiko wrote: I changed the selectionbox in prototypes/entity/entities.lua to the one that has been commented out
~line 59-60It's still a matter of finding the right spot (south of the liquid icon when horizontal, west for vertical) but better than nothingCode: Select all
selection_box = {{-1.0, -1.0}, {1.0, 1.0}}, --selection_box = {{-0.5, -0.5}, {0.5, 0.5}},
Code: Select all
--selection_box = {{-1.0, -1.0}, {1.0, 1.0}},
selection_box = {{-0.5, -0.5}, {0.5, 0.5}},
Code: Select all
selection_box = {{-1.0, -1.0}, {1.0, 1.0}},
--selection_box = {{-0.5, -0.5}, {0.5, 0.5}},
If i remember correctly, this has always been the case. The fake/proxy tanks get removed when a train movesMion wrote: 3) BUT. This information shows up ONLY when railtanker is near small pump in the middle of railtanker. In other words, when railtanker is in the process of pumping.
Am I wrong somewhere?
Ok, thanks. I didn't know mechanics of this modChoumiko wrote:If i remember correctly, this has always been the case. The fake/proxy tanks get removed when a train movesMion wrote: 3) BUT. This information shows up ONLY when railtanker is near small pump in the middle of railtanker. In other words, when railtanker is in the process of pumping.
Am I wrong somewhere?