[MOD 0.12.x] Specialized oil refineries (not 3 at once)

Topics and discussion about specific mods
Walter
Burner Inserter
Burner Inserter
Posts: 18
Joined: Sun Apr 10, 2016 2:52 pm
Contact:

Re: [MOD 0.12.x] Specialized oil refineries (not 3 at once)

Post by Walter »

Thanks Slimey. I took the time to diddle a little more and now it is perfectly in the right order too. (1.0.4 is now available)
Qloshae
Inserter
Inserter
Posts: 36
Joined: Sun Apr 17, 2016 12:59 pm
Contact:

Re: [MOD 0.12.x] Specialized oil refineries (not 3 at once)

Post by Qloshae »

Getting an on_init error when I try this for mp.
Attachments
on_init.PNG
on_init.PNG (62.73 KiB) Viewed 7679 times
Walter
Burner Inserter
Burner Inserter
Posts: 18
Joined: Sun Apr 10, 2016 2:52 pm
Contact:

Re: [MOD 0.12.x] Specialized oil refineries (not 3 at once)

Post by Walter »

Qloshae wrote:Getting an on_init error when I try this for mp.
I've just released a fix (1.0.5), it works for both singleplayer and multiplayer now.
Sander_Bouwhuis
Filter Inserter
Filter Inserter
Posts: 292
Joined: Mon Dec 07, 2015 10:45 pm
Contact:

Re: [MOD 0.12.x] Specialized oil refineries (not 3 at once)

Post by Sander_Bouwhuis »

Walter, Sir, you are awesome!
Walter
Burner Inserter
Burner Inserter
Posts: 18
Joined: Sun Apr 10, 2016 2:52 pm
Contact:

Re: [MOD 0.12.x] Specialized oil refineries (not 3 at once)

Post by Walter »

You're welcome buddy ;-)
WindStrike
Burner Inserter
Burner Inserter
Posts: 5
Joined: Mon Apr 25, 2016 10:21 am
Contact:

Re: [MOD 0.12.x] Specialized oil refineries (not 3 at once)

Post by WindStrike »

Russian translation (ru)

Code: Select all

[item-name]
specialized-refinery=Спец. нефтеперерабатывающий завод

[item-description]
specialized-refinery=Завод для переработки сырой нефти в один продукт.

[entity-name]
specialized-refinery=Спец. нефтеперерабатывающий завод

[technology-name]
specialized-refineries=Спец. нефтеперерабатывающие заводы
specialized-refining-petroleum=Специализация попутный нефтяной газ
specialized-refining-light-oil=Специализация легкая нефть
specialized-refining-heavy-oil=Специализация тяжелая нефть

[recipe-name]
specialized-refining-petroleum=Специализация: сырую нефть в попутный нефтяной газ
specialized-refining-light-oil=Специализация: сырую нефть в легкую нефть
specialized-refining-heavy-oil=Специализация: сырую нефть в тяжелую нефть 

[item-group-name]
specialized-oil-processing=Специализированная переработка нефти

[item-subgroup-name]
specialized-fluid-recipes=Специализированные рецепты жидкости

[technology-description]
specialized-refineries=Переработка сырой нефти в один продукт в специализированных НПЗ.
specialized-refining-petroleum=Позволяет специализированным НПЗ перерабатывать сырую нефть только в попутный нефтяной газ.
specialized-refining-light-oil=Позволяет специализированным НПЗ перерабатывать сырую нефть только в легкую нефть.
specialized-refining-heavy-oil=Позволяет специализированным НПЗ перерабатывать сырую нефть только в тяжелую нефть.
Walter
Burner Inserter
Burner Inserter
Posts: 18
Joined: Sun Apr 10, 2016 2:52 pm
Contact:

Re: [MOD 0.12.x] Specialized oil refineries (not 3 at once)

Post by Walter »

Thank you! I will release an update containing Russian and Dutch translations soon.
BULIGO
Burner Inserter
Burner Inserter
Posts: 19
Joined: Thu Jun 16, 2016 9:36 am
Contact:

Re: [MOD 0.12.x] Specialized oil refineries (not 3 at once)

Post by BULIGO »

Many thanks for the super useful mod!
I always hated when i produced too much of some refinery product X which i didnt need and had to dump some or plop another tank. Now i produce exactly what i need, in proper quantities. No more switching among various light/heavy oil/petroleum gas pipe jumble. I plop the specialized refinery there and it stays there for the duration of the game. I think the vanilla refineries system is OK and logical, but i just prefer your less-fuss system.
Have a nice day.
Bobthebuilder
Manual Inserter
Manual Inserter
Posts: 1
Joined: Fri Jun 17, 2016 9:27 am
Contact:

Re: [MOD 0.12.x] Specialized oil refineries (not 3 at once)

Post by Bobthebuilder »

Very nice mod Walter, thanks :D

Although initially I had and issue reloading my saved game I stumbled upon this error "__specialized_refineries__/control.lua:4: attempt to index global 'script' (a nil value)"
on version 0.12.3 I ended up deleting control.lua and it works perfectly.


Regards Builder
Walter
Burner Inserter
Burner Inserter
Posts: 18
Joined: Sun Apr 10, 2016 2:52 pm
Contact:

Re: [MOD 0.12.x] Specialized oil refineries (not 3 at once)

Post by Walter »

BULIGO wrote:Many thanks for the super useful mod!
I always hated when i produced too much of some refinery product X which i didnt need and had to dump some or plop another tank. Now i produce exactly what i need, in proper quantities. No more switching among various light/heavy oil/petroleum gas pipe jumble. I plop the specialized refinery there and it stays there for the duration of the game. I think the vanilla refineries system is OK and logical, but i just prefer your less-fuss system.
Have a nice day.

Glad you like it, enjoy!
Walter
Burner Inserter
Burner Inserter
Posts: 18
Joined: Sun Apr 10, 2016 2:52 pm
Contact:

Re: [MOD 0.12.x] Specialized oil refineries (not 3 at once)

Post by Walter »

Bobthebuilder wrote:Very nice mod Walter, thanks :D

Although initially I had and issue reloading my saved game I stumbled upon this error "__specialized_refineries__/control.lua:4: attempt to index global 'script' (a nil value)"
on version 0.12.3 I ended up deleting control.lua and it works perfectly.


Regards Builder
I haven't played in a while. Perhaps they changed something in the game. If other experience this too, let me know. Control.lua is pretty important so i'd love to update it. But if it works for you without the file, lol, great ^^
User avatar
MtnDew
Burner Inserter
Burner Inserter
Posts: 18
Joined: Sun Aug 02, 2015 3:29 am
Contact:

Re: [MOD 0.12.x] Specialized oil refineries (not 3 at once)

Post by MtnDew »

I like the idea of this mod but it seems a little too powerful. After doing some comparisons with materials and time to do this with vanilla, I find that in the case of petroleum so far, it gives a little more petroleum then you could get in vanilla in a shorter time with way less water usage along with far less materials needed to create the structures. The recipe would need to be closer to 10 oil and 11 water to create 9 petrolum in 8.75 seconds with the recipe for the new refinery being more in line with 1 oil refinery + 10 steel plate + 10 pipes + 10 gears + 10 electronic circuits ( but I think it should be 5 advanced circuits to show an increase in technology and slight increase in expense ( added plastic and copper) for the ease of automation).

After I started to alter the default recipes, I noticed that water is a constant between all recipes and may not allow properly setting this up for each recipe. Is there a plan to add water variable to each recipe?

EDIT: After doing some more calculations and reversing recipes for petroleum into light and light into heavy, I find that water actually goes into negatives so basically you would be evaporating it. So one water amount is fine with me. The recipes actually go the opposite way with light and you don't get enough and heavy is way farther then that. Although time gets longer in the light and even more in the heavy which compensates. I am now confident that I can keep the recipes for each type (heavy, light, and petroleum) even with vanilla. The one last thing to check is power consumption which again can't be per recipe so I will just have to deal with it. Thank you for the MOD!
easygoing
Manual Inserter
Manual Inserter
Posts: 1
Joined: Tue Jun 28, 2016 12:00 pm
Contact:

Re: [MOD 0.12.x] Specialized oil refineries (not 3 at once)

Post by easygoing »

please update to 0.13, please :(
Skitt
Burner Inserter
Burner Inserter
Posts: 14
Joined: Thu May 12, 2016 1:26 am
Contact:

Re: [MOD 0.12.x] Specialized oil refineries (not 3 at once)

Post by Skitt »

Any chance this will be updated to 0.13?
Sunnova
Fast Inserter
Fast Inserter
Posts: 169
Joined: Mon May 16, 2016 12:10 pm
Contact:

Re: [MOD 0.12.x] Specialized oil refineries (not 3 at once)

Post by Sunnova »

simple fix

unzip into your mods folder, delete the zip file

your mods folder should now have a sub folder of specialized_refineries_1.0.5

in the control.lua file, change this line

local srPlayer = game.players(_event.player_index)

to

local srPlayer = game.players[_event.player_index]


in the info.json file, add

"factorio_version": "0.13",

That's all I did to make it work.
Skitt
Burner Inserter
Burner Inserter
Posts: 14
Joined: Thu May 12, 2016 1:26 am
Contact:

Re: [MOD 0.12.x] Specialized oil refineries (not 3 at once)

Post by Skitt »

tied that didnt work.
there is no string called
local srPlayer = game.players(_event.player_index)
in control.lua
Sunnova
Fast Inserter
Fast Inserter
Posts: 169
Joined: Mon May 16, 2016 12:10 pm
Contact:

Re: [MOD 0.12.x] Specialized oil refineries (not 3 at once)

Post by Sunnova »

my bad, I was looking at the wrong folder, my final changes in the control.lua were.

old

srPlayer = game.get_player(_event.player_index)

new

srPlayer = game.players[_event.player_index]

Sorry about that.
Skitt
Burner Inserter
Burner Inserter
Posts: 14
Joined: Thu May 12, 2016 1:26 am
Contact:

Re: [MOD 0.12.x] Specialized oil refineries (not 3 at once)

Post by Skitt »

hmm still not working
Sunnova
Fast Inserter
Fast Inserter
Posts: 169
Joined: Mon May 16, 2016 12:10 pm
Contact:

Re: [MOD 0.12.x] Specialized oil refineries (not 3 at once)

Post by Sunnova »

Skitt wrote:hmm still not working
what error are you getting?

this is the control.lua I now have.

Code: Select all

-- reset recipes so changes in the config are working in previously saved games

script.on_event(defines.events.on_player_created, function(event) resetRecipes(event) end)

function resetRecipes(_event)
	srPlayer = game.players[_event.player_index]
	srPlayer.print("Specialized refineries: resetting recipes..")
	srPlayer.force.reset_recipes()
end
and the info.json

Code: Select all

{
	"name": "specialized_refineries",
	"version": "1.0.5",
	"factorio_version": "0.13",
	"title": "Specialized Oil Refineries",
	"author": "Walter, Exclusive-IT.nl",
	"contact": "https://forums.factorio.com/viewtopic.php?f=97&t=23441",
	"homepage": "http://www.factoriomods.com/mods/specialized-oil-refineries-not-3-at-once",
	"description": "Process crude oil into a single product in specialized refineries.",
	"dependencies": [
	"base >= 0.12"
  ] 
}
Post Reply

Return to “Mods”