Lumberyard

by nobake

Chop down trees within area

4 months ago
1.1 - 2.0
817

i game version 2.0

9 months ago

This mod is not compatible with game version 2.0

5 months ago

I am currently working through a book to learn Lua properly, and after that I will look at hopefully updating mods to work in 2.0.
I can't make any promises on if or when this will happen, unfortunately. This originally was written by someone else and I just updated the version string.

4 months ago
(updated 4 months ago)

hi, i just learned that you are also in the process to bring back some wood processing.

Check out my mod https://mods.factorio.com/mod/fct-WoodHarvester which i released a few days ago to the public.
I was inspired by the old WoodHarvester and Lumberyard mods but they lacked the handling of side products like sap, seeds and so on.

It took me a while to mold my mod into the current version localy. For handling everything correct a special item is created for each qualifying tree.
Beside the entity consuming electricity i created a burner version for early game. Depending on your scenario it takes a while to get to electricity.

In the past WoodHarvester and LumberYard just processed a dummy-item named "timber", which didn't contain any information about the original
chopped tree.

I am currently in the process of cleaning up my code before i release it on github.
I would suggest that we aggregate our ideas, i still have a few things on mind.

4 months ago

Hello @fctusr!

Quite the coincidence that you uploaded your mod and then I updated mine within days of each other.

I'm not against any sort of sharing of ideas or anything else, though to be honest I don't really have much.
I do want to support modded sideproducts like seeds and I have a couple ideas on how to do this. It sounds like this is a problem you have already solved.
Beyond that there really isn't anything else I can think of that I would like for Lumberyard. My intent is just a mod to cut down trees and get wood. Actually doing anything with that wood would be left to other mods such as Wooden Industry.

4 months ago
(updated 4 months ago)

My focus is on keeping my factory clean ... i use also Noxys Trees which let trees pop up again, so we share the same intentions.

I am also in the process of releasing a RockHarvester ... same as for Wood/Trees get rid of those obstacles around.
both Variants have still some open challenges, like BoomPuff trees on gleba ... when harvesting those you may burn down a large area ..

i still have a few open issues but in general it does what i wanted to achieve.

I want to add research for speed and range, buttons exist but don't have any function yet.
Taking also the distance of the entity to be harvested into account.
For various overhaul setups maybe adding fluid driven or heat driven variants ..
Maybe create a "universal" harvester reading from a destruction planner which entities should be harvested or which should be ignored.

Currently i am hunting a problem that entities got orphaned ...
"we have 13 entities known" .... but i "found 44 entities" on the surface ...
which means that 31 entities are not "working"

4 months ago

Yes, I suppose mod compatibility is something I should perhaps keep in mind more myself, beyond just tree byproducts.

For one I do intend to do at least some building recipe changes depending on mods. Right now all I have in mind is Lumber and Wooden Gears from Wooden Industry, but there are likely more that would be appropriate.

Also I do know that Lumberyard would not work that well with tree planting or something like Noxys Trees. Just didn't occur to me at all when rewriting. My current logic will remove a lumberyard from the an internal list when all trees in range are destroyed - basically "turning them off" - but there is no logic to turn them back on if more trees appear. You'd have to pick up and replace the building. Maybe the logic in your mod is similar?

Space Age compatibility is something I expect you will be far ahead of me on. I didn't like SA, so I don't play or test in it. If any of my mods happen to work with it, great! But if not someone would have to provide me working code. That will limit the potential audience for my mods, but I'm okay with that.

I do like your idea of a Rock Harvester. The idea had occurred to me, but I hadn't even thought to start putting it in to action.

4 months ago

there is an option to destruct the building in the game settings, with growing trees i have this option disabled. For the RockHarvester it is enabled, since Rocks wont grow again at the moment, time will tell.

The RockHarvester made it necessary to deal with more than one harvestable since some rocks give also coal. So the concept to handle more than one result was mandatory. I also had some kind of working WoodHarvester for 1.1 being able to handle more than just wood, since Pyanodon/Industrial Revolution and other mods introduced seeds, sap and so on. same goes for rocks were you can get moss as well.

In the latest version i create a recipe for each harvestable and copy the minable.results of the tree/rock into the results of the recipe to get identical behavior.
Before i had a machine which harvested like magic, the machine always showed a red light, didnt count finished products ... one of the reasons for not publishing it. You need to go via a recipe that the machine shows its status.

Still my learning curve is steep since i dig more and more into the rabbit hole. Once it was just fiddling with the info.json, then some tweaks in the data ... and it got more and more ... Factorio 2 put again a high pile of new challenges since a lot of structures changed ... and i spent more time on porting other mods.

4 months ago

that all sounds quite familiar to me :)
First was changing the version for other mods.
Then was a lot of changing prototypes in the data stage - lots of recipes, researches, a little bit of entity properties like crafting speed.
This is the first time I've touched runtime code.

And that sounds almost the same method I had in mind. My thought was to just keep the dummy item that is currently used, but copy minable_results from some random tree for the recipe. This would not handle different trees giving different items, but so far I have not run into that other than the defunct Industrial Revolution. Or I could make it "magic" as you said - look at minable_results before I destroy the tree and insert that into the machine inventory. Wouldn't even need to be a machine then, just a chest. Or finally I could do the same as you and create items and recipes for each tree entity, but I'd rather not do that if I can avoid it.

4 months ago

This is just "evolution" and following the needs. Do you have other mods you work on? WoodHarvester is imho the mod i put most of my effort in yet. I took over several other orphaned mods while i contribute to others still alive.

4 months ago

Well, there's the Coal Gasification mod that I adopted a while back. Minimal work on that one other than integration with another mod (Wood Gasification).

Then there's Patchwork Overhaul where I took a bunch of small mods and tried to integrate them into a reasonable overhaul. The old version on the mod portal had some issues even before some of the mods got deprecated, but I'm working on a bigger and hopefully better one now.

That's about it for now. A long time ago now there were a couple others that I updated while the original authors seemed to be on hiatus (brevven's Titanium and Mylon's Fracking) but I don't work on either of them now. Brevven's been back taking care of his mods and there's at least been mention of Mylon updating Fracking to 2.0.

There are at least 2 now-abandoned mods I have my eye on possibly forking and redoing, but I'm in no rush on those.

New response