I don't get how they are supposed to be setup. The documentation says that the trunk is supposed to have one more frame than the leaves. Why is that the case? While the leaves changes according to the tree stage, the trunk is staying the same.
Also, by looking at the data.raw visualiser in this post, I can see that the base tree have one frame for the trunk and tree for the leaves, witch break the rule specified in the documentation. If I try to do the same thing, I get an error message telling the frame count is incorrect.
Right now my solution is to make an animation with the correct frame count using the same sprite for the trunk in each one. It feels more like a hack than a good solution.
Am I not understanding how tree work correctly? What would be the correct way of having a single trunk for many leaves sprites?
How to setup the trunk of tree variations?
-
- Burner Inserter
- Posts: 9
- Joined: Sun Oct 18, 2020 1:02 am
- Contact:
Re: How to setup the trunk of tree variations?
Hey, the frame_count restriction for trunk only applies if shadow isn't loaded. I fixed the documentation to indicate this.
Why this works like that: If your shadow is part of the trunk sprites, then the leaf shadow will be visible there. This means that the leaf progression is visible in the sprite so you need different trunk sprites for the different leaf progressions. You can see this in action in the 0.16.51 tree definitions and graphics, so maybe download that old version if you want to get more familiar with that method of defining the tree graphics. For illustration I have attached the 0.16.51 hr-tree-01-a-trunk.png.
Why this works like that: If your shadow is part of the trunk sprites, then the leaf shadow will be visible there. This means that the leaf progression is visible in the sprite so you need different trunk sprites for the different leaf progressions. You can see this in action in the 0.16.51 tree definitions and graphics, so maybe download that old version if you want to get more familiar with that method of defining the tree graphics. For illustration I have attached the 0.16.51 hr-tree-01-a-trunk.png.
- Attachments
-
- hr-tree-01-a-trunk.png (108.62 KiB) Viewed 1019 times
I'm an admin over at https://wiki.factorio.com. Feel free to contact me if there's anything wrong (or right) with it.
-
- Burner Inserter
- Posts: 9
- Joined: Sun Oct 18, 2020 1:02 am
- Contact:
Re: How to setup the trunk of tree variations?
The problem was that I didn't have shadows.
Thank you! That's really helpful.
Thank you! That's really helpful.