new energy category

Place to get help with not working mods / modding interface.
Post Reply
Silberschatten
Manual Inserter
Manual Inserter
Posts: 2
Joined: Mon Mar 20, 2017 7:20 pm
Contact:

new energy category

Post by Silberschatten »

Hi all!

I would like to add Mechanical Energy to the game.
I haven't found any mod introducing anything similar, for example several electricity levels.

Let me explain the base idea:
Mechanical energy and energy transfer would be the early game energy transmitting network:
- energy sources would be windmills and steam engines (those would NOT produce electricity, maybe an additional entity)
- axles (and maybe gears for corners) would be placeable entities that transmitted mechanical energy only to the corresponding next tile(s) adjacent (somewhat like pipes)
- all M1 machines would have a mechanical version, the axles could be connected to specific points (like pipes) or at any point (like inserters)

The transition to electricity would be locked behind some research.
It would make for a strongly extended early game.
Also one could scrap the basic burner stuff, which is great, that stuff doesn't make sense (at least I don't know of any reasonable way to directly produce mechanical energy from burning things, it's usually through steam-powered devices).

Extending that idea:
- Generators could be connected to axles to transform machanical to electrical energy.
- Electric motors could be placeable and transform electrical to mechanical energy
- generator and electric motor modules could be introduced to change machines energy source (ideally those module slots would be additional and only possible to take one of those modules)
- the "belts need energy" mod(s) could be adjusted to take mechanical energy
_____

Possible ways to introduce it:

- Ideally I'd like to introduce it as a new energy category if possible, then the specifics of how it works would need to be scripted, or maybe a modified copy of the workings of electric energy could be used. - ideal but unlikely possible

- Maybe one could introduce mechanical energy as fluid burner fuel (with minimum volume size or something, so it can't be stored significantly), and extend the pipe-prototype to axle-pipes, that can only transfer mechanical energy. - seems harder but maybe possible

I do not think it is possible to make this kind of mod at this point (maybe with high scripting effort that would most probably lead to performance problems, but I haven't tried my hand at scripting much yet)

Does someone have an idea? Is there already a similar idea? If it is not possible, have there been made according requests to the api?

Yoyobuae
Filter Inserter
Filter Inserter
Posts: 499
Joined: Fri Nov 04, 2016 11:04 pm
Contact:

Re: new energy category

Post by Yoyobuae »

Energy source -> assembler entity producing special fluid
Axle -> pipe entity with tweaked parameters
mechanical machines -> electric machine with hidden steam engine entity where pipe axle input is supposed to be

Tricky part will be ensuring the hidden fluid doesn't leak out into normal pipes, and that normal pipes don't connect into axles and such. Not entirely sure about how pipe connections work.

As for "adding new energy category", that's something only the devs can do. Mods can only make entities be either electric or burner powered. Can't even make something burner powered directly use liquid fuel (there's nothing like it in vanilla which could be used as a base).

User avatar
darkfrei
Smart Inserter
Smart Inserter
Posts: 2904
Joined: Thu Nov 20, 2014 11:11 pm
Contact:

Re: new energy category

Post by darkfrei »

This special fluid must be in recipe. Special recipe for special Assembler, that have energy interface. It's much cheaper for performance and no need checking which fluid is on input.

Silberschatten
Manual Inserter
Manual Inserter
Posts: 2
Joined: Mon Mar 20, 2017 7:20 pm
Contact:

Re: new energy category

Post by Silberschatten »

I like the hidden entity idea (didn't know it's possible), I'll try to find that in other mods.

The specific recipe idea may be interesting, but I'll have to look into it, might be a bit "ugly" or rather cumbersome.

User avatar
Adil
Filter Inserter
Filter Inserter
Posts: 945
Joined: Fri Aug 15, 2014 8:36 pm
Contact:

Re: new energy category

Post by Adil »

Yuoki Tani did all that in his mod somewhere.
The problem is he never documents what he does. My guess it is added by this mod:
https://mods.factorio.com/mods/YuokiTani/yi_engines
I do mods. Modding wiki is friend, it teaches how to mod. Api docs is friend too...
I also update mods, some of them even work.
Recently I did a mod tutorial.

Post Reply

Return to “Modding help”