Possibly. Only catch is that I'd then have to sort through the fluids, find ones that should be considered as "invalid" for this mod (like steam, water, etc), and then override their values when going into the locomotive. I think this may be more tedious as other mods add different fluids that could potentially be used as fuel in something.BlueTemplar wrote: βMon Jul 29, 2019 7:39 pmHeh, looks like that this is pretty much what I was asking for !
(Not sure why I missed it before, as it's not the first time that I looks into that file...)BlueTemplar wrote: βSat Jul 13, 2019 12:17 pmIt really sounds like these fuel values should be handled by vanilla...
[...]
Or at least it should be a "community" mod, like https://mods.factorio.com/mod/stdlib
[MOD 0.16] Diesel Locomotive
-
- Smart Inserter
- Posts: 2541
- Joined: Tue Apr 25, 2017 2:01 pm
- Contact:
Re: [MOD 0.16] Diesel Locomotive
My Mods: Classic Factorio Basic Oil Processing | Sulfur Production from Oils | Wood to Oil Processing | Infinite Resources - Normal Yield | Tree Saplings (Redux) | Alien Biomes Tweaked | Restrictions on Artificial Tiles
Re: [MOD 0.16] Diesel Locomotive
I'm really just trying to learn about compatibilities, how to integrate and make my mod a useful part of the Factorio world.
This is a challenge from the technical perspective but also in finding the right balance in terms of friendly behavior towards everybody else in the community. So I'm really just trying to find my feet as to what is possible and what not.
This is a challenge from the technical perspective but also in finding the right balance in terms of friendly behavior towards everybody else in the community. So I'm really just trying to find my feet as to what is possible and what not.
-
- Smart Inserter
- Posts: 2541
- Joined: Tue Apr 25, 2017 2:01 pm
- Contact:
Re: [MOD 0.16] Diesel Locomotive
Oh, you're good. I'm actually working on another mod that modifies other mods as well.Shenpen wrote: βMon Jul 29, 2019 8:34 pmI'm really just trying to learn about compatibilities, how to integrate and make my mod a useful part of the Factorio world.
This is a challenge from the technical perspective but also in finding the right balance in terms of friendly behavior towards everybody else in the community. So I'm really just trying to find my feet as to what is possible and what not.
Here, I think you need something like this (code is untested).
In info.json:
Code: Select all
"dependencies": ["?Diesel-Locomotive >= 0.2.3"]
Code: Select all
if mods["Diesel-Locomotive"] then
local diesellocokerosene = data.raw["item"]["Diesel-Locomotive-kerosene"]
diesellocokerosene.fuel_value = "1MJ" -- Modify as desired
diesellocokerosene.fuel_acceleration_multiplier = 1 -- Modify as desired
diesellocokerosene.fuel_top_speed_multiplier = 1 -- Modify as desired
end
Sorry, sometimes my understanding of what's being done starts off wrong, then as it slowly dawns on me I go back and make corrections as I'm typing and sometimes the whole post can wind up a mess.
My Mods: Classic Factorio Basic Oil Processing | Sulfur Production from Oils | Wood to Oil Processing | Infinite Resources - Normal Yield | Tree Saplings (Redux) | Alien Biomes Tweaked | Restrictions on Artificial Tiles
Re: [MOD 0.16] Diesel Locomotive
The questionmark makes it a soft dependency?["?Diesel-Locomotive
-
- Smart Inserter
- Posts: 2541
- Joined: Tue Apr 25, 2017 2:01 pm
- Contact:
Re: [MOD 0.16] Diesel Locomotive
Yes!
My Mods: Classic Factorio Basic Oil Processing | Sulfur Production from Oils | Wood to Oil Processing | Infinite Resources - Normal Yield | Tree Saplings (Redux) | Alien Biomes Tweaked | Restrictions on Artificial Tiles
Re: [MOD 0.16] Diesel Locomotive
There is also a balance regarding other uses. The main use for kerosine is actually as a solvent for cocaine production...diesellocokerosene
Which is why I hesitate about renaming it a loco-fuel...
Re: [MOD 0.16] Diesel Locomotive
I think I will find a way to "change" the main kerosine into a loco fuel. If I had lead I would process the kerosine with lead to make a loco-fuel.
As it happens I dont have any lead, but perhaps I can add some other additive.
As it happens I dont have any lead, but perhaps I can add some other additive.
-
- Smart Inserter
- Posts: 2541
- Joined: Tue Apr 25, 2017 2:01 pm
- Contact:
Re: [MOD 0.16] Diesel Locomotive
Note that this does not modify your kerosene fluid. The diesel locomotive mod creates items (similar in nature to solid fuel) that are reresentative of all fluids in the game. These items are what are actually consumed by the locomotive (not the fluid) and thus the change in the code example is to the representative item of kerosene, not the actual fluid.
My Mods: Classic Factorio Basic Oil Processing | Sulfur Production from Oils | Wood to Oil Processing | Infinite Resources - Normal Yield | Tree Saplings (Redux) | Alien Biomes Tweaked | Restrictions on Artificial Tiles
-
- Filter Inserter
- Posts: 587
- Joined: Sun Jun 09, 2019 10:40 pm
- Contact:
Re: [MOD 0.16] Diesel Locomotive
Which, specifically, makes sure that *if* it is installed, the dependency mod will be loaded *before* your mod is loaded, and all the data stuff will run in there first. If you don't need that ordering you can also check out the list of loaded mods via the in-game objects to figure that out.
-
- Manual Inserter
- Posts: 1
- Joined: Mon Sep 23, 2019 6:21 pm
- Contact:
Re: [MOD 0.16] Diesel Locomotive
Hi, I'm not sure if your still activly working on the 0.16 Factorio version of this mod but. I have a Mod Conflict to Report, When You use Pressurized Fluids It Has an issue with A Fluid It creates. Here's a imgur of the Error on Factorio Startup. https://imgur.com/a/3OXunmj
Here's the Links to the Mods Involved:
https://mods.factorio.com/mod/Diesel-Locomotive
https://mods.factorio.com/mod/CompressedFluids
Im Not Sure which Mod is at fault, But I have posted a Bug Report on both mods pages.
Here's the Links to the Mods Involved:
https://mods.factorio.com/mod/Diesel-Locomotive
https://mods.factorio.com/mod/CompressedFluids
Im Not Sure which Mod is at fault, But I have posted a Bug Report on both mods pages.
Re: [MOD 0.16] Diesel Locomotive
That's a sloppy written fluid parser in Diesel Locomotive.PurityLegion wrote: βMon Sep 23, 2019 6:45 pmHi, I'm not sure if your still activly working on the 0.16 Factorio version of this mod but. I have a Mod Conflict to Report, When You use Pressurized Fluids It Has an issue with A Fluid It creates. Here's a imgur of the Error on Factorio Startup. https://imgur.com/a/3OXunmj
Here's the Links to the Mods Involved:
https://mods.factorio.com/mod/Diesel-Locomotive
https://mods.factorio.com/mod/CompressedFluids
Im Not Sure which Mod is at fault, But I have posted a Bug Report on both mods pages.
It should support icons or icon like base game. If you need to layer icons my library offers a function to convert icon or icons into an icons array while optionally adding another layer https://github.com/Yousei9/Opteras-Libr ... eate_icons
My Mods: mods.factorio.com
-
- Smart Inserter
- Posts: 2541
- Joined: Tue Apr 25, 2017 2:01 pm
- Contact:
Re: [MOD 0.16] Diesel Locomotive
PurityLegion wrote: βMon Sep 23, 2019 6:45 pmHi, I'm not sure if your still activly working on the 0.16 Factorio version of this mod but. I have a Mod Conflict to Report, When You use Pressurized Fluids It Has an issue with A Fluid It creates. Here's a imgur of the Error on Factorio Startup. https://imgur.com/a/3OXunmj
Here's the Links to the Mods Involved:
https://mods.factorio.com/mod/Diesel-Locomotive
https://mods.factorio.com/mod/CompressedFluids
Im Not Sure which Mod is at fault, But I have posted a Bug Report on both mods pages.
Yup, as Optera said, the 0.16 version of the mod did not take icons vs icon into account. I believe I fixed this when I took over the mod and updated it for 0.17.Optera wrote: βTue Sep 24, 2019 5:34 amThat's a sloppy written fluid parser in Diesel Locomotive.
It should support icons or icon like base game. If you need to layer icons my library offers a function to convert icon or icons into an icons array while optionally adding another layer https://github.com/Yousei9/Opteras-Libr ... eate_icons
That said, I am no longer working on this. I've lost interest in the game since the 0.17.60 update and have stopped following updates somewhere around .62 or .63. I even got a new laptop recently and have not reinstalled the game or even transferred any of the related files.
Sorry.
My Mods: Classic Factorio Basic Oil Processing | Sulfur Production from Oils | Wood to Oil Processing | Infinite Resources - Normal Yield | Tree Saplings (Redux) | Alien Biomes Tweaked | Restrictions on Artificial Tiles
-
- Manual Inserter
- Posts: 2
- Joined: Wed Oct 29, 2014 9:59 pm
- Contact:
Re: [MOD 0.16] Diesel Locomotive
Hi,
I would like to offer taking over this mod. There are requests to upgrade it to 0.18 and I have a few ideas for a few improvements. I am already familiar with the code base as I wrote a mod based on this one. And since I will maintain mine, it would be little to no effort to also support this one. They share most of their code. What do you think?
Cheers
I would like to offer taking over this mod. There are requests to upgrade it to 0.18 and I have a few ideas for a few improvements. I am already familiar with the code base as I wrote a mod based on this one. And since I will maintain mine, it would be little to no effort to also support this one. They share most of their code. What do you think?
Cheers
-
- Burner Inserter
- Posts: 11
- Joined: Mon Dec 04, 2017 12:05 am
- Contact:
Re: [MOD 0.16] Diesel Locomotive
hi, solution for a this problem?
impossible load mod
error while loading item prototype" diesel-Locomotive-high-pressure-water-1"(item): Key "icon" not found in property tree at ROOT.item.Diesel-locomotive-high-pressure-water-1 modifications :diesel locomotive
thanks
impossible load mod
error while loading item prototype" diesel-Locomotive-high-pressure-water-1"(item): Key "icon" not found in property tree at ROOT.item.Diesel-locomotive-high-pressure-water-1 modifications :diesel locomotive
thanks
-
- Manual Inserter
- Posts: 2
- Joined: Wed Oct 29, 2014 9:59 pm
- Contact:
Re: [MOD 0.16] Diesel Locomotive
The problem is another mod adding a fluid named "high-pressure-water-1". apparently the way the icon for this fluid is created is not compatible with the way Diesel Locomotives creates icons for all the fluid in-game. I could in theory create a fix for this in 0.17, but it's an old known issue. In my continuation mod for 0.18 (Diesel Trains) it should also be fixed already.Gamestrust-TS wrote: βSun Apr 26, 2020 3:40 pmhi, solution for a this problem?
impossible load mod
error while loading item prototype" diesel-Locomotive-high-pressure-water-1"(item): Key "icon" not found in property tree at ROOT.item.Diesel-locomotive-high-pressure-water-1 modifications :diesel locomotive
thanks